added Config_monitorDisplayChangeMessages (issue #72)
This commit is contained in:
parent
b55bd99ab5
commit
3320f14443
5 changed files with 12 additions and 1 deletions
BIN
bugn.exe
BIN
bugn.exe
Binary file not shown.
|
@ -26,6 +26,7 @@ called with the window ID as a paramater, when applying the rule.
|
|||
11. `+` Added the possibility to minimize windows, making them floating and thereby excluded from tiling.
|
||||
12. `+` Added configuration variables for customizing the date and time format shown in the status bar.
|
||||
13. `+` Added a function to override the rules applied from `Config.ini` for the active window.
|
||||
14. `+` Added a configuration variable for customizing the behaviour on display change messages.
|
||||
|
||||
| # | `-` or `~` Configuration Variables or <br/> `-` Hotkey Functions | `+` Configuration Variables or <br/> `+` Hotkey Functions |
|
||||
| ---:| ---------------------------------------------------------------- | --------------------------------------------------------- |
|
||||
|
@ -88,6 +89,7 @@ called with the window ID as a paramater, when applying the rule.
|
|||
| 11. | | `#^m::Manager_minimizeWindow()` |
|
||||
| 12. | | `Config_readinDateFormat` |
|
||||
| | | `Config_readinTimeFormat` |
|
||||
| 14. | | `Config_monitorDisplayChangeMessages` |
|
||||
|
||||
### 8.4.0
|
||||
|
||||
|
|
|
@ -364,3 +364,8 @@ the data directory of bug.n. Possible values are `off`, `auto` and `ask`.
|
|||
> The interval in milliseconds, in which the session will be automatically
|
||||
saved to especially support the recovery of window states after bug.n
|
||||
unintentionally quits.
|
||||
|
||||
`Config_monitorDisplayChangeMessages=1`
|
||||
> If true (`=1`) bug.n reacts on `WM_DISPLAYCHANGE` system messages asking to
|
||||
reset the monitor configuration, e. g. if a monitor is dis-/connected or the
|
||||
monitor resolution is changed.
|
||||
|
|
|
@ -103,6 +103,7 @@ Config_init() {
|
|||
;; Configuration management
|
||||
Config_autoSaveSession := "auto" ;; "off" | "auto" | "ask"
|
||||
Config_maintenanceInterval := 5000
|
||||
Config_monitorDisplayChangeMessages := True
|
||||
|
||||
Config_hotkeyCount := 0
|
||||
Config_restoreConfig(Config_filePath)
|
||||
|
|
|
@ -653,6 +653,8 @@ Manager_override(rule = "") {
|
|||
}
|
||||
|
||||
Manager_registerShellHook() {
|
||||
Global Config_monitorDisplayChangeMessages
|
||||
|
||||
WM_DISPLAYCHANGE := 126 ;; This message is sent when the display resolution has changed.
|
||||
Gui, +LastFound
|
||||
hWnd := WinExist()
|
||||
|
@ -662,7 +664,8 @@ Manager_registerShellHook() {
|
|||
Debug_logMessage("DEBUG[1] Manager_registerShellHook; hWnd: " . hWnd . ", wndClass: " . wndClass . ", wndTitle: " . wndTitle, 1)
|
||||
msgNum := DllCall("RegisterWindowMessage", "Str", "SHELLHOOK")
|
||||
OnMessage(msgNum, "Manager_onShellMessage")
|
||||
OnMessage(WM_DISPLAYCHANGE, "Manager_onDisplayChange")
|
||||
If Config_monitorDisplayChangeMessages
|
||||
OnMessage(WM_DISPLAYCHANGE, "Manager_onDisplayChange")
|
||||
}
|
||||
;; SKAN: How to Hook on to Shell to receive its messages? (http://www.autohotkey.com/forum/viewtopic.php?p=123323#123323)
|
||||
|
||||
|
|
Loading…
Reference in a new issue