Skip to content

Commit 0ae849d

Browse files
committed
Remember outputs after change
This prevents the second call to xrandr after a change has been detected.
1 parent 181ae27 commit 0ae849d

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

cmd_watch.go

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,10 @@ func (cmd CmdWatch) Execute(args []string) error {
115115
return err
116116
}
117117

118-
lastOutputs = newOutputs
118+
lastOutputs, err = DetectOutputs()
119+
if err != nil {
120+
return err
121+
}
119122

120123
if globalOpts.Pause > 0 {
121124
V("disable polling for %d seconds\n", globalOpts.Pause)

0 commit comments

Comments
 (0)