MirrorBar+ panels follow the bar transparency, part 2
This commit is contained in:
+14
-1
@@ -36,12 +36,14 @@ func loadFeatures() {
|
||||
showNews = on
|
||||
case "sys":
|
||||
showSys = on
|
||||
case "panelfade":
|
||||
flyMatchBar = on
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func saveFeatures() {
|
||||
s := "weather=" + b01(showWeather) + "\nnews=" + b01(showNews) + "\nsys=" + b01(showSys) + "\n"
|
||||
s := "weather=" + b01(showWeather) + "\nnews=" + b01(showNews) + "\nsys=" + b01(showSys) + "\npanelfade=" + b01(flyMatchBar) + "\n"
|
||||
_ = os.MkdirAll(dataDir(), 0o755)
|
||||
_ = os.WriteFile(featuresFile(), []byte(s), 0o644)
|
||||
}
|
||||
@@ -96,6 +98,17 @@ func setShowSys(on bool) {
|
||||
featuresChanged()
|
||||
}
|
||||
|
||||
// setFlyMatchBar is called by the settings window: should the panels be as
|
||||
// see-through as the bar?
|
||||
func setFlyMatchBar(on bool) {
|
||||
if flyMatchBar == on {
|
||||
return
|
||||
}
|
||||
flyMatchBar = on
|
||||
saveFeatures()
|
||||
flyRefreshAll()
|
||||
}
|
||||
|
||||
func featuresChanged() {
|
||||
settingsZipStatusUpdate()
|
||||
redraw(hwndMain)
|
||||
|
||||
Reference in New Issue
Block a user