mirror of
https://github.com/wailsapp/wails.git
synced 2025-05-03 05:19:11 +08:00
16 lines
300 B
Go
16 lines
300 B
Go
package wails
|
|
|
|
import (
|
|
"fmt"
|
|
"syscall"
|
|
)
|
|
|
|
// Init is called at the start of the application
|
|
func Init() error {
|
|
status, r, err := syscall.NewLazyDLL("user32.dll").NewProc("SetProcessDPIAware").Call()
|
|
if status == 0 {
|
|
return fmt.Errorf("exit status %d: %v %v", status, r, err)
|
|
}
|
|
return nil
|
|
}
|