-
-
-
-
-
-
-
-
- //==================================================================
- // Dialog window which is modal
- class BBTK_EXPORT WxBlackBoxDialog : public wxDialog,
- public WidgetBlackBoxWindow<wxWindow>
- {
- public:
- typedef WidgetBlackBoxWindow<wxWindow> Parent;
- WxBlackBoxDialog(WxBlackBox::Pointer box,
- wxWindow *parent, wxString title, wxSize size);
- ~WxBlackBoxDialog();
- void bbShow();
- void bbHide();
- void bbDestroy();
- bool IsDialog() { return true; }
- bool IsFrame() { return false; }
- wxDialog* bbGetDialog() { return this; }
- };
- //==================================================================
-
- //==================================================================
- // Frame window which is not modal
- class BBTK_EXPORT WxBlackBoxFrame : public wxFrame,
- public WidgetBlackBoxWindow<wxWindow>
- {
- public:
- typedef WidgetBlackBoxWindow<wxWindow> Parent;
- WxBlackBoxFrame(WxBlackBox::Pointer box,
- wxWindow *parent, wxString title, wxSize size);
- ~WxBlackBoxFrame();
- void bbShow();
- void bbHide();
- void bbDestroy();
- bool IsDialog() { return false; }
- bool IsFrame() { return true; }
- wxFrame* bbGetFrame() { return this; }
- };
- //==================================================================
-
-
-
- //=================================================================
- // Handles the destroy events of a widget associated to a WxBlackBox
- // in order to signal the widget death to its associated box
- class BBTK_EXPORT WxBlackBoxWidgetEventHandler : public wxEvtHandler
- {
- public:
- /// Ctor with the box and widget
- WxBlackBoxWidgetEventHandler( WxBlackBox::Pointer box, wxWindow *widget );
- /// Dtor
- ~WxBlackBoxWidgetEventHandler();
- /// Returns true iff is the handler for that window
- bool IsHandlerOf( wxWindow* w ) { return mWindow == w; }
- // wxWindow* GetWxWindow() { return mWindow; }
- /// Method processing the destroy event of the widget
- void OnWindowDestroy(wxWindowDestroyEvent&);
- //
- //bool IsDead() { return mDead; }
-
- private:
- WxBlackBox::WeakPointer mBox;
- wxWindow* mWindow;
- //bool mDead;
- };
- //=================================================================
-
-
-