From 50280197e26e83210d63165572b6748e329d140f Mon Sep 17 00:00:00 2001 From: "Avi Halachmi (:avih)" Date: Fri, 16 Jul 2021 10:33:46 +0300 Subject: stats.lua: move internal performance from page 4 to page 0 This allows adding more pages without the internal performance page getting stuck at the middle of the list. --- DOCS/man/stats.rst | 6 +++--- player/lua/stats.lua | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/DOCS/man/stats.rst b/DOCS/man/stats.rst index 2cf730f673..f9c125447c 100644 --- a/DOCS/man/stats.rst +++ b/DOCS/man/stats.rst @@ -24,7 +24,7 @@ stats: 1 Show usual stats 2 Show frame timings (scroll) 3 Input cache stats -4 Internal stuff (scroll) +0 Internal stuff (scroll) ==== ================== On pages which support scroll, these key bindings are also active: @@ -64,8 +64,8 @@ Configurable Options Default: 2 ``key_page_3`` Default: 3 -``key_page_4`` - Default: 4 +``key_page_0`` + Default: 0 Key bindings for page switching while stats are displayed. diff --git a/player/lua/stats.lua b/player/lua/stats.lua index bfdf68aba6..653a367b77 100644 --- a/player/lua/stats.lua +++ b/player/lua/stats.lua @@ -18,7 +18,7 @@ local o = { key_page_1 = "1", key_page_2 = "2", key_page_3 = "3", - key_page_4 = "4", + key_page_0 = "0", -- For pages which support scrolling key_scroll_up = "UP", key_scroll_down = "DOWN", @@ -669,7 +669,7 @@ local function perf_stats() local stats = {} eval_ass_formatting() add_header(stats) - local page = pages[o.key_page_4] + local page = pages[o.key_page_0] append(stats, "", {prefix=o.nl .. o.nl .. page.desc .. ":", nl="", indent=""}) page.offset = append_general_perfdata(stats, page.offset) return table.concat(stats) @@ -800,7 +800,7 @@ pages = { [o.key_page_1] = { f = default_stats, desc = "Default" }, [o.key_page_2] = { f = vo_stats, desc = "Extended Frame Timings", scroll = true }, [o.key_page_3] = { f = cache_stats, desc = "Cache Statistics" }, - [o.key_page_4] = { f = perf_stats, desc = "Internal performance info", scroll = true }, + [o.key_page_0] = { f = perf_stats, desc = "Internal performance info", scroll = true }, } -- cgit v1.2.3