diff options
author | 2016-07-08 18:52:57 -0500 | |
---|---|---|
committer | 2016-07-08 18:52:57 -0500 | |
commit | 1a54c908384a79e3332800cabb75815348cb28b6 (patch) | |
tree | d216d7ca11970a3f29d94bbbd47a967e94d67de8 /plugins | |
parent | a4704047d5fc82da92cef8678d65ef91f3f7290c (diff) |
plugins/cheatfind: don't show arrow when one option (nw)
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/cheatfind/init.lua | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/plugins/cheatfind/init.lua b/plugins/cheatfind/init.lua index e529c3d5402..659ffca33db 100644 --- a/plugins/cheatfind/init.lua +++ b/plugins/cheatfind/init.lua @@ -295,7 +295,9 @@ function cheatfind.startplugin() local menu = {} local function menu_lim(val, min, max, menuitem) - if val == min then + if min == max then + menuitem[3] = 0 + elseif val == min then menuitem[3] = "r" elseif val == max then menuitem[3] = "l" @@ -319,11 +321,7 @@ function cheatfind.startplugin() menu[#menu + 1] = function() local m = { "CPU or RAM", devtable[devsel].tag, 0 } - if #devtable == 1 then - m[3] = 0 - else - menu_lim(devsel, 1, #devtable, m) - end + menu_lim(devsel, 1, #devtable, m) local function f(event) if (event == "left" or event == "right") and #menu_blocks ~= 0 then manager:machine():popmessage("Changes to this only take effect when \"Start new search\" is selected") |