Skip to content

Commit 635ecf9

Browse files
committed
ui: remove unused count variable during loading
1 parent d80d974 commit 635ecf9

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

src/ui/playerui.nim

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import
1111

1212
../link/link,
1313
../utils/[
14-
utils
14+
utils
1515
],
1616

1717
../misc/like
@@ -22,7 +22,7 @@ when not defined(simple):
2222
../ui/[
2323
scroll,
2424
animation,
25-
]
25+
]
2626

2727
proc editBadFileHint(config: MenuConfig, extraMsg = "") =
2828
if extraMsg != "": warn(extraMsg)
@@ -89,6 +89,7 @@ proc playStation*(ctx: ptr Handle, config: MenuConfig) =
8989
var lastWidth: int = 0
9090
var fullTitle: string # Declare fullTitle here
9191
var finishedLoading = false
92+
var spinnerState = 0
9293

9394
when not defined(simple):
9495
var metadata = initTable[string, string](8) # Declare metadata here
@@ -108,8 +109,6 @@ proc playStation*(ctx: ptr Handle, config: MenuConfig) =
108109
when defined(simple):
109110
fullTitle = fullTitle.truncateMe()
110111

111-
var spinnerState = 0
112-
var count = 0
113112
while true:
114113
if not state.isPaused:
115114
event = ctx.waitEvent(mpvEventLoopTimeout)
@@ -144,7 +143,6 @@ proc playStation*(ctx: ptr Handle, config: MenuConfig) =
144143
else:
145144
if not finishedLoading:
146145
spinnerState.spinLoadingSpinnerOnce()
147-
count += 1
148146

149147
when not defined(simple):
150148
# Increment the animation counter every 25ms (getKeyWithTimeout interval)

0 commit comments

Comments
 (0)