From 0d703508943f1e45a6a3caafe3759962f33ddf07 Mon Sep 17 00:00:00 2001 From: kylewill0725 Date: Fri, 1 Mar 2019 11:07:28 -0600 Subject: [PATCH 1/3] Repeat click check disabled as I can not find any instance where it happens and keeping it enabled results in checkboxes needing to be clicked multiple times. --- control.lua | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/control.lua b/control.lua index 1df7f91..3a2e7e0 100644 --- a/control.lua +++ b/control.lua @@ -73,12 +73,8 @@ local function raise_on_click(event) end script.on_event(defines.events.on_gui_checked_state_changed, function(event) - -- prevent raising on_click twice for the same element - if last_clicked ~= nil and last_clicked == event.element.name then - return - end last_checked = event.element.name - + raise_on_click(event) end) From 305c5b1bacbc25a75e137322fb07c2481f4b3172 Mon Sep 17 00:00:00 2001 From: kylewill0725 Date: Fri, 1 Mar 2019 11:15:04 -0600 Subject: [PATCH 2/3] Added a new style in order to remove border around frame. --- evoGUI.lua | 2 +- prototypes/styles.lua | 26 +++++++++++--------------- 2 files changed, 12 insertions(+), 16 deletions(-) diff --git a/evoGUI.lua b/evoGUI.lua index 99192da..09d254d 100644 --- a/evoGUI.lua +++ b/evoGUI.lua @@ -202,7 +202,7 @@ function evogui.create_sensor_display(player) local root = player.gui.top.add{type="frame", name="evogui_root", direction="horizontal", - style="outer_frame"} + style="EvoGUI_outer_frame_no_border"} local action_buttons = root.add{type="flow", name="action_buttons", diff --git a/prototypes/styles.lua b/prototypes/styles.lua index c6445bc..ad227c5 100644 --- a/prototypes/styles.lua +++ b/prototypes/styles.lua @@ -2,24 +2,20 @@ local default_gui = data.raw["gui-style"].default local function button_graphics(xpos, ypos) return { - type = "monolith", - - top_monolith_border = 0, - right_monolith_border = 0, - bottom_monolith_border = 0, - left_monolith_border = 0, - - monolith_image = { - filename = "__{{MOD_NAME}}__/graphics/gui.png", - priority = "extra-high-no-scale", - width = 16, - height = 16, - x = xpos, - y = ypos, - }, + filename = "__{{MOD_NAME}}__/graphics/gui.png", + priority = "extra-high-no-scale", + width = 16, + height = 16, + x = xpos, + y = ypos } end +default_gui.EvoGUI_outer_frame_no_border = { + type = "frame_style", + parent = "outer_frame", + graphical_set = {} +} default_gui.EvoGUI_button_with_icon = { type = "button_style", From 3858e461aeaecdf1cdfecf4beb8da17b0e486570 Mon Sep 17 00:00:00 2001 From: kylewill0725 Date: Fri, 1 Mar 2019 11:15:20 -0600 Subject: [PATCH 3/3] Updated to 0.17 --- VERSION | 2 +- info.json | 4 ++-- settingsGUI.lua | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/VERSION b/VERSION index ad01be3..94c458d 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -0.4.302 +0.4.303 diff --git a/info.json b/info.json index 821ceab..ff2a343 100644 --- a/info.json +++ b/info.json @@ -1,11 +1,11 @@ { "name": "{{MOD_NAME}}", "version": "{{VERSION}}", - "factorio_version": "0.16", + "factorio_version": "0.17", "title": "EvoGUI - Evolution Factor Indicator and more", "author": "Octav \"narc\" Sandulescu", "contact": "factorio-mods@narc.ro", "homepage": "https://github.com/narc0tiq/evoGUI/", "description": "Places some indicators on your UI for various little statistics that are nice to have.", - "dependencies": ["base >= 0.16.1", "? moweather"] + "dependencies": ["base >= 0.17", "? moweather"] } diff --git a/settingsGUI.lua b/settingsGUI.lua index feb7631..a45aaa5 100644 --- a/settingsGUI.lua +++ b/settingsGUI.lua @@ -114,7 +114,7 @@ function evogui.evoGUI_settings(event) local update_freq_flow = core_settings.add{type="flow", name="update_freq_flow", direction="horizontal"} update_freq_flow.add{type="label", caption={"settings.core_settings.update_freq_left"}} - local textfield = update_freq_flow.add{type="textfield", name="textfield", style="number_textfield"} + local textfield = update_freq_flow.add{type="textfield", name="textfield", style="short_number_textfield"} textfield.text=tostring(global.settings.update_delay) update_freq_flow.add{type="label", caption={"settings.core_settings.update_freq_right"}}