feat(gioui): implement own file save / load dialogs

Removes the dependency on sqweek/dialogs, which was always very buggy.

Closes #12
This commit is contained in:
vsariola
2021-04-18 19:10:41 +03:00
parent ac95fb65c4
commit 147e8a2513
10 changed files with 464 additions and 100 deletions

View File

@ -36,7 +36,7 @@ func (t *Tracker) Run(w *app.Window) error {
case e := <-w.Events():
switch e := e.(type) {
case system.DestroyEvent:
if !t.TryQuit() {
if !t.Quit(false) {
// TODO: uh oh, there's no way of canceling the destroyevent in gioui? so we create a new window just to show the dialog
w = app.NewWindow(
app.Size(unit.Dp(800), unit.Dp(600)),