diff --git a/app.go b/app.go index 6ae8582..fa64341 100644 --- a/app.go +++ b/app.go @@ -20,6 +20,7 @@ type app struct { icon *gdk.Pixbuf dir string ini *os.File + wine bool } func (a *app) getTreeIter(store *gtk.TreeStore) *gtk.TreeIter { @@ -242,7 +243,11 @@ func (a *app) edit(parent *gtk.Window, reload func()) { nameTxt.SetHExpand(true) nameTxt.SetVExpand(false) nameTxt.SetBorderWindowSize(gtk.TEXT_WINDOW_BOTTOM, 5) - txtBuf.SetText(tmp.name) + nameShow := tmp.name + if tmp.wine { + nameShow = strings.TrimSuffix(nameShow, " (Wine)") + } + txtBuf.SetText(nameShow) vScrollName, _ := gtk.AdjustmentNew(0, 0, 0, 0, 0, 0) hScrollName, _ := gtk.AdjustmentNew(0, 0, 0, 0, 0, 0) nameScr, _ := gtk.ScrolledWindowNew(hScrollName, vScrollName) diff --git a/settings.go b/settings.go index d1d52bf..9f0c45c 100644 --- a/settings.go +++ b/settings.go @@ -20,6 +20,7 @@ func settingsUI(parent *gtk.Window, onExit func()) { win.SetDefaultSize(600, 300) win.SetPosition(gtk.WIN_POS_CENTER_ON_PARENT) win.Connect("destroy", func() { + savePrefs() parent.SetSensitive(true) onExit() }) diff --git a/setup.go b/setup.go index f4114de..e03c56f 100644 --- a/setup.go +++ b/setup.go @@ -114,6 +114,7 @@ func processApp(fold string) (out app) { } if len(out.lin) == 0 { out.name += " (Wine)" + out.wine = true } return }