summaryrefslogtreecommitdiffstatshomepage
path: root/plugins/timer/init.lua
diff options
context:
space:
mode:
author Vas Crabb <vas@vastheman.com>2021-10-20 02:03:43 +1100
committer Vas Crabb <vas@vastheman.com>2021-10-20 02:03:43 +1100
commit0a9ea09a9a328884b61ce57c2e3b51705da50467 (patch)
tree98153d6f2244b0053d9c1894b5c71277fb18522d /plugins/timer/init.lua
parent9e7779bdd5c17a847ed4c06a9b7e68a39ec6576b (diff)
Tie up a few loose ends:
debugger: Octal cheats for octal address spaces. frontend: Pass events for automatically generated menu items to the plugin - they will have index zero. frontend: Don't try calling the data plugin from the main menu if the system isn't starting yet - doing so will prevent the data plugin from loading at all.
Diffstat (limited to 'plugins/timer/init.lua')
-rw-r--r--plugins/timer/init.lua11
1 files changed, 4 insertions, 7 deletions
diff --git a/plugins/timer/init.lua b/plugins/timer/init.lua
index f0ddabbcf50..07b3e20162b 100644
--- a/plugins/timer/init.lua
+++ b/plugins/timer/init.lua
@@ -91,16 +91,13 @@ function timer.startplugin()
local function menu_populate()
local time = os.time() - start_time
- return {{ _("Current time"), "", "off" },
- { sectohms(time), "", "off" },
- { _("Total time"), "", "off" },
- { sectohms(total_time + time), "", "off" },
- { _("Play Count"), "", "off" },
- { play_count, "", "off" }}
+ return {{ _("Current time"), sectohms(time), "off" },
+ { _("Total time"), sectohms(total_time + time), "off" },
+ { _("Play Count"), play_count, "off" }}
end
local function menu_callback(index, event)
- return true
+ return false
end
emu.register_menu(menu_callback, menu_populate, _("Timer"))