From b34f00797ab34e36347eda6e45347db3c2e36d36 Mon Sep 17 00:00:00 2001 From: Andrew Kesterson Date: Tue, 6 May 2014 23:53:17 -0700 Subject: [PATCH] Introduced bug #18, stopping for tonight --- lib/tailor/GUI/MainWindow.rb | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/lib/tailor/GUI/MainWindow.rb b/lib/tailor/GUI/MainWindow.rb index d38f26d..8c443df 100644 --- a/lib/tailor/GUI/MainWindow.rb +++ b/lib/tailor/GUI/MainWindow.rb @@ -8,7 +8,6 @@ module Tailor def initialize() super(nil, -1, 'Tailor') init_menubar() - init_mainpanel() show() end @@ -38,11 +37,8 @@ module Tailor evt_menu(Wx::ID_ABOUT, :on_help_about) end - def init_mainpanel - @mainPanel = Wx::Panel.new(self) - end - def on_file_new + @mainPanel = Wx::Panel.new(self) @mainPanelSizer = Wx::BoxSizer.new(Wx::VERTICAL) @mainPanel.set_sizer(@mainPanelSizer) @tilesetProperties = Tailor::GUI::TilesetProperties.new(@mainPanel, Wx::ID_ANY) @@ -72,8 +68,7 @@ module Tailor end def on_file_close - @mainPanel.set_sizer(nil) - @mainPanelSizer = nil + @mainPanel.destroy end def on_help_about