]> Creatis software - bbtkGEditor.git/blobdiff - lib/EditorGraphicBBS/bbsWxGUIEditorGraphic/bbtkwxGUIEditorGraphicBBS.cxx
Exit menu option activated
[bbtkGEditor.git] / lib / EditorGraphicBBS / bbsWxGUIEditorGraphic / bbtkwxGUIEditorGraphicBBS.cxx
index 2d93e2fa7f454775d5d0b196e40184f3a80f31d9..8d8c5774f5e74919c41593bcaecc8b19f479750a 100644 (file)
@@ -66,7 +66,7 @@ namespace bbtk
                initToolbar();
                initTabPanelsManager();
                initPackageBrowser();
-               
+               initHelpHTMLBrowser();
 
                CreateStatusBar();
                _frameAUIMgr->Update();
@@ -109,6 +109,13 @@ namespace bbtk
                Connect(15,wxEVT_COMMAND_TOOL_CLICKED,wxCommandEventHandler(wxGUIEditorGraphicBBS::OnToolLeftClick));
 
        }
+       //=========================================================================
+       void wxGUIEditorGraphicBBS::initHelpHTMLBrowser()
+       {
+               
+               _helpHtmlBrowser = new WxGUIHtmlBrowser(this,wxSize(200,0));
+               _frameAUIMgr->AddPane(_helpHtmlBrowser,wxAuiPaneInfo().Right().MinSize(200,200));       
+       }
 
        //=========================================================================
        void wxGUIEditorGraphicBBS::initMenu()
@@ -121,6 +128,8 @@ namespace bbtk
                helpMenu->Append(wxID_ABOUT, _T("&About..."), _T("About"));
                fileMenu->Append(wxID_EXIT, _T("E&xit"), _T("Exit"));
 
+               Connect(wxID_EXIT,wxEVT_COMMAND_MENU_SELECTED,wxCommandEventHandler(wxGUIEditorGraphicBBS::OnExit));
+
                // now append the freshly created menu to the menu bar...
                wxMenuBar *menuBar = new wxMenuBar();
                menuBar->Append(fileMenu, _T("&File"));
@@ -144,8 +153,7 @@ namespace bbtk
        {
                _pkgBrowser = new WxGUIPackageBrowser2(this);
                _pkgBrowser->IncludeAll();
-               _frameAUIMgr->AddPane(_pkgBrowser,wxAuiPaneInfo().Left().MinSize(200,200).CloseButton(false));  
-               
+               _frameAUIMgr->AddPane(_pkgBrowser,wxAuiPaneInfo().Left().MinSize(200,200).CloseButton(false));          
        }
 
        /*****************************************************
@@ -166,6 +174,11 @@ namespace bbtk
                }
        }
 
+       void wxGUIEditorGraphicBBS::OnExit(wxCommandEvent& event)
+       {
+               Close(true);
+       }
+
 
 }  // EO namespace bbtk