History

stats.lua: rename a variable

Guido Cella committed 2 years ago

Commit e34f6561 parent 63a81511 file · +6 −7Browse files

Showing the changes to player/lua/stats.lua (1 of 1 file). Show all

Unified · Split

player/lua/stats.lua+6−7
@@ -1525,7 +1525,7 @@ local function print_page(page, after_scroll) · 1524 unmodified lines
1525 end1525 end
1526end1526end
1527 1527
1528local function update_scale(value)1528local function update_scale(osd_height)
1529 local scale_with_video1529 local scale_with_video
1530 if o.vidscale == "auto" then1530 if o.vidscale == "auto" then
1531 scale_with_video = mp.get_property_native("osd-scale-by-window")1531 scale_with_video = mp.get_property_native("osd-scale-by-window")
@@ -1535,8 +1535,8 @@ local function update_scale(value) · 3 unmodified lines
1535 1535
1536 -- Calculate scaled metrics.1536 -- Calculate scaled metrics.
1537 local scale = 11537 local scale = 1
1538 if not scale_with_video and value > 0 then1538 if not scale_with_video and osd_height > 0 then
1539 scale = 720 / value1539 scale = 720 / osd_height
1540 end1540 end
1541 font_size = o.font_size * scale1541 font_size = o.font_size * scale
1542 border_size = o.border_size * scale1542 border_size = o.border_size * scale
@@ -1548,13 +1548,12 @@ local function update_scale(value) · 5 unmodified lines
1548 end1548 end
1549end1549end
1550 1550
1551local function handle_osd_height_update(_, value)1551local function handle_osd_height_update(_, osd_height)
1552 update_scale(value)1552 update_scale(osd_height)
1553end1553end
1554 1554
1555local function handle_osd_scale_by_window_update()1555local function handle_osd_scale_by_window_update()
1556 local value = mp.get_property_native("osd-height")1556 update_scale(mp.get_property_native("osd-height"))
1557 update_scale(value)
1558end1557end
1559 1558
1560local function clear_screen()1559local function clear_screen()

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t