File tree Expand file tree Collapse file tree 2 files changed +4
-6
lines changed Expand file tree Collapse file tree 2 files changed +4
-6
lines changed Original file line number Diff line number Diff line change 1+ github : [metaspartan]
Original file line number Diff line number Diff line change 11// Copyright (c) 2024 Carsen Klock under MIT License
2- // mactop is a simple terminal based Apple Silicon power monitor written in Go Lang!
3- // github.com/context-labs/mactop
2+ // mactop is a simple terminal based Apple Silicon power monitor written in Go Lang! github.com/context-labs/mactop
43package main
54
65import (
@@ -415,7 +414,7 @@ func main() {
415414 select {
416415 case e := <- uiEvents :
417416 switch e .ID {
418- case "q" , "<C-c>" : // "q" or Ctrl+C to quit
417+ case "q" , "<C-c>" :
419418 close (done )
420419 ui .Close ()
421420 os .Exit (0 )
@@ -425,19 +424,17 @@ func main() {
425424 grid .SetRect (0 , 0 , payload .Width , payload .Height )
426425 ui .Render (grid )
427426 case "r" :
428- // refresh ui data
429427 termWidth , termHeight := ui .TerminalDimensions ()
430428 grid .SetRect (0 , 0 , termWidth , termHeight )
431429 ui .Clear ()
432430 ui .Render (grid )
433431 case "l" :
434- // Set the new grid's dimensions to match the terminal size
435432 termWidth , termHeight := ui .TerminalDimensions ()
436433 grid .SetRect (0 , 0 , termWidth , termHeight )
437434 ui .Clear ()
438435 switchGridLayout ()
439436 ui .Render (grid )
440- case "h" , "?" : // "h" or "?" to open help menu
437+ case "h" , "?" :
441438 termWidth , termHeight := ui .TerminalDimensions ()
442439 grid .SetRect (0 , 0 , termWidth , termHeight )
443440 ui .Clear ()
You can’t perform that action at this time.
0 commit comments