This commit is contained in:
rchicoli 2021-07-13 22:53:32 +02:00 committed by GitHub
commit 606563e810
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 10 additions and 5 deletions

View File

@ -3,8 +3,8 @@
package ui package ui
import ( import (
"runtime"
"errors" "errors"
"runtime"
"sync" "sync"
"unsafe" "unsafe"
) )
@ -42,6 +42,11 @@ func Main(f func()) error {
return nil return nil
} }
// Uninit calls C.uiUninit to uninitialize all allocated objects
func Uninit() {
C.uiUninit()
}
// Quit queues a return from Main. It does not exit the program. // Quit queues a return from Main. It does not exit the program.
// It also does not immediately cause Main to return; Main will // It also does not immediately cause Main to return; Main will
// return when it next can. Quit must be called from the GUI thread. // return when it next can. Quit must be called from the GUI thread.