diff options
author | Kevin Chabowski <kevin@kch42.de> | 2013-11-02 17:54:32 +0100 |
---|---|---|
committer | Kevin Chabowski <kevin@kch42.de> | 2013-11-02 17:54:32 +0100 |
commit | 613c8855cd8fcace4b7ba4f6662bd0486e9ad5f1 (patch) | |
tree | ac3ab78d18d1d718c6a1bd65248c416bfd2fdcb9 | |
parent | 2ac5529a8973c262ddc5674f5846a6b293ca0ce1 (diff) | |
download | biomed-613c8855cd8fcace4b7ba4f6662bd0486e9ad5f1.tar.gz biomed-613c8855cd8fcace4b7ba4f6662bd0486e9ad5f1.tar.bz2 biomed-613c8855cd8fcace4b7ba4f6662bd0486e9ad5f1.zip |
New menu items
-rw-r--r-- | main.go | 26 |
1 files changed, 13 insertions, 13 deletions
@@ -103,23 +103,23 @@ func (g *GUI) mkMenuBar() *gtk.MenuBar { quit.Connect("activate", g.exitApp) fileMenu.Append(quit) - foo := gtk.NewMenuItemWithLabel("Foo") - foo.Connect("activate", func() { - f, _ := os.Open("test.biomes") - defer f.Close() - biomes, err := ReadBiomeInfos(f) - if err != nil { - panic(err) - } - g.biomes = biomes - g.updateBiomeInfo() - }) - fileMenu.Append(foo) - fileMenuItem := gtk.NewMenuItemWithLabel("File") fileMenuItem.SetSubmenu(fileMenu) menubar.Append(fileMenuItem) + prefMenu := gtk.NewMenu() + + confbiomes := gtk.NewMenuItemWithLabel("Configure Biomes") + confbiomes.Connect("activate", func() { + // TODO: Display awesome biome editor dialog thing. + fmt.Println("(...)") + }) + prefMenu.Append(confbiomes) + + prefMenuItem := gtk.NewMenuItemWithLabel("Preferences") + prefMenuItem.SetSubmenu(prefMenu) + menubar.Append(prefMenuItem) + helpMenu := gtk.NewMenu() controls := gtk.NewMenuItemWithLabel("Controls") |