mirror of
https://github.com/wailsapp/wails.git
synced 2026-03-14 22:55:48 +01:00
Merge pull request #1069 from redraskal/fix/v2-win-window-maximize
[v2] Fix: win window maximise/minimise
This commit is contained in:
commit
6eba8ec76f
1 changed files with 10 additions and 2 deletions
|
|
@ -199,7 +199,11 @@ func (f *Frontend) WindowHide() {
|
|||
}
|
||||
func (f *Frontend) WindowMaximise() {
|
||||
runtime.LockOSThread()
|
||||
f.mainWindow.Maximise()
|
||||
if f.hasStarted {
|
||||
f.mainWindow.Maximise()
|
||||
} else {
|
||||
f.frontendOptions.WindowStartState = options.Maximised
|
||||
}
|
||||
}
|
||||
func (f *Frontend) WindowUnmaximise() {
|
||||
runtime.LockOSThread()
|
||||
|
|
@ -207,7 +211,11 @@ func (f *Frontend) WindowUnmaximise() {
|
|||
}
|
||||
func (f *Frontend) WindowMinimise() {
|
||||
runtime.LockOSThread()
|
||||
f.mainWindow.Minimise()
|
||||
if f.hasStarted {
|
||||
f.mainWindow.Minimise()
|
||||
} else {
|
||||
f.frontendOptions.WindowStartState = options.Minimised
|
||||
}
|
||||
}
|
||||
func (f *Frontend) WindowUnminimise() {
|
||||
runtime.LockOSThread()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue