# HG changeset patch # User Matti Hamalainen # Date 1530687794 -10800 # Node ID 480ada584d8a9f9d90ece86a84074b96a3f3fa0f # Parent f356d9c176a6de2d667a9271defee5e7a85bd67f Remove the use of 'gui' variable. diff -r f356d9c176a6 -r 480ada584d8a events.pde --- a/events.pde Wed Jul 04 10:01:05 2018 +0300 +++ b/events.pde Wed Jul 04 10:03:14 2018 +0300 @@ -524,7 +524,6 @@ if (g_data[int('W')] == 1) { g_data[int('W')] = 0; if (g_formatextension != "") { - gui = true; exportfmt = true; message("Format|export"); } else { @@ -689,20 +688,17 @@ if (g_data[int('E')] == 1) { g_data[int('E')] = 0; message("Source|export"); - gui = true; exporttxt = true; //machine_export(1); } if (g_data[int('A')] == 1) { g_data[int('A')] = 0; message("Executable|export"); - gui = true; exportemu = true; //machine_export(0); } if (g_data[int('w')] == 1) { g_data[int('w')] = 0; - gui = true; importfmt = true; } if (g_data[int('O')] == 1) { @@ -823,12 +819,10 @@ } if (g_data[int('l')] == 1) { g_data[int('l')] = 0; - gui = true; fileselect = true; } if (g_data[int('s')] == 1) { g_data[int('s')] = 0; - gui = true; saveas = true; } if (g_data[int('L')] == 1) { diff -r f356d9c176a6 -r 480ada584d8a multipaint.pde --- a/multipaint.pde Wed Jul 04 10:01:05 2018 +0300 +++ b/multipaint.pde Wed Jul 04 10:03:14 2018 +0300 @@ -21,9 +21,9 @@ int g_animx, g_animy, g_animframes, g_animno, g_animtime, g_animspeed; int g_omag, g_bordh, g_bordv, g_keymacpos, g_framec; -boolean gui = true, fileselect = false, saveas = false, refselect = false, g_control = false, g_shift = false, exporttxt = false, importfmt = false, exportemu = false, exportfmt = false; String path = "", refpath = "", filename = "", elename = "", sfilename = "", refname = "", g_expname = "", g_fmtname = ""; String exporttxtname = "", exportemuname = "", exportfmtname; +boolean fileselect = false, saveas = false, refselect = false, g_control = false, g_shift = false, exporttxt = false, importfmt = false, exportemu = false, exportfmt = false; String g_keymacro = ""; int[] g_r = new int[266]; @@ -134,40 +134,6 @@ g_hedge = 32 * g_uizoom; g_vedge = 32 * g_uizoom; - if (machine == -1) { - if (gui) { - try { - UIManager.setLookAndFeel("javax.swing.plaf.metal.MetalLookAndFeel"); - } catch (Exception e) {}; - machine = selector("Select a Platform", "C64 hires,C64 multicolor,ZX Spectrum,MSX1 mode 2,Plus4 hires,Plus4 multicolor,Amstrad CPC mode 0"); - } - switch (machine) { - case 0: - machine = C64; - break; - case 1: - machine = C64M; - break; - case 2: - machine = SPECTRUM; - break; - case 3: - machine = MSX; - break; - case 4: - machine = PLUS4; - break; - case 5: - machine = PLUS4M; - break; - case 6: - machine = CPC; - break; - default: - ; - } - } - g_uindex[0] = 0; g_utop[0] = 0; g_ubottom[0] = 0; @@ -384,7 +350,6 @@ if (g_msgctr > 0) g_msgctr--; // UI file operations - if (gui) { if (fileselect) // Fileselect "event" for Load { String s = fileselector(path, LOADIMG); @@ -531,8 +496,6 @@ g_control = false; } - } - //if(g_framec==1){saveFrame("frames/out-######.png");} g_framec++; if (g_framec > 1) g_framec = 0;