app,app/internal/window: [macOS] add app.Window.Close for closing a window

Recently support was added for multiple top-level windows. Add support
for closing those windows.

macOS only; all others stubbed out.

Signed-off-by: Larry Clapp <larry@theclapp.org>
This commit is contained in:
Larry Clapp
2020-06-17 09:10:48 -04:00
committed by Elias Naur
parent 7f836fa627
commit 602d54dc5e
10 changed files with 49 additions and 0 deletions
+3
View File
@@ -501,6 +501,9 @@ func (w *window) HWND() (syscall.Handle, int, int) {
return w.hwnd, w.width, w.height
}
// Close the window. Not implemented for Windows.
func (w *window) Close() {}
func convertKeyCode(code uintptr) (string, bool) {
if '0' <= code && code <= '9' || 'A' <= code && code <= 'Z' {
return string(rune(code)), true