app: merge app/internal/wm into package app

The app and app/internal/wm packages are tightly coupled, requiring
quite a bit of forwarding types, values and constants from the internal
package to export it. Further, no other package imports package wm.

This change merges the two packages.

While here, drop the pre-Go 1.14 SIGPIPE workaround.

Signed-off-by: Elias Naur <mail@eliasnaur.com>
This commit is contained in:
Elias Naur
2021-08-29 22:00:16 +02:00
parent fe52357141
commit 45da52cee7
46 changed files with 325 additions and 400 deletions
+1 -9
View File
@@ -5,16 +5,8 @@ package app
import (
"os"
"strings"
"gioui.org/app/internal/wm"
)
// ViewEvent carries the platform specific window handles for
// a Window.
//
// ViewEvent is implemented for Android, macOS, Windows.
type ViewEvent = wm.ViewEvent
// extraArgs contains extra arguments to append to
// os.Args. The arguments are separated with |.
// Useful for running programs on mobiles where the
@@ -50,5 +42,5 @@ func DataDir() (string, error) {
// require control of the main thread of the program for
// running windows.
func Main() {
wm.Main()
osMain()
}