ChildWindowGroup
Pretty much the same idea of ChildWindowClass, but for groups. It is different because it can have child windows (just like the MainView).
public:
~ChildWindowGroup( )
protected:
private:
static const std::string XML_NAME
enum MenuIDs
ChildWindowGroup( wxWindow* pParent, MainView* pMainView, GroupObjectPtr pGroup, const wxPoint& ActualPos, const wxSize& ActualSize)
void OnZoomChanged( )
std::string ConvertToXml( ) const
void LoadFromXml( XMLReader& Reader)
bool CanParentWindowView( ) const
void PaintToDC( wxDC& DC, const wxPoint& DeviceOrigin)
It annoys me that wxWidgets doesn't have this kind of thing built in. I need it to paint to the Bitmap for the HTMLDoc generation. I'll probably also need it for printing.
- const wxPoint& DeviceOrigin: When you paint a window in response to an OnPaint the top left corner of your window is 0,0. When you paint to a big MemoryDC the 0,0 position is the top left of the entire DC. wxWidgets has a wxDC::SetDeviceOrigin, but no GetDeviceOrigin. This helps you figure out where you are.
void InternalPaintToDC( wxDC& DC) const
wxWidgets handles painting the rectangle around the window itself when it paints to the screen. When I paint to a bitmap I'll need to do that myself. Then the common internal painting is handled in here
const wxPoint& GetObjectPosition( ) const
const wxSize& GetObjectSize( ) const
const std::string& GetObjectName( ) const
boost::posix_time::ptime GetLatestUpdateTime( ) const
void SetObjectPosition( const wxPoint& Pos)
void SetObjectSize( const wxSize& Size)
void ShowGroupDialog( )
void OnPositionChanged( const wxPoint& Delta)
void OnSizeChanged( const wxSize& Delta)
void OnPaint( wxPaintEvent& Event)
void OnMouseMove( wxMouseEvent& Event)
void OnLeftDown( wxMouseEvent& Event)
void OnLeftUp( wxMouseEvent& Event)
void OnLeftDoubleClick( wxMouseEvent& Event)
void OnContextMenu( wxContextMenuEvent& Event)
void OnCreateGroup( wxCommandEvent& Event)
void OnCreateClass( wxCommandEvent& Event)
void OnCreateFromHeader( wxCommandEvent& Event)
void OnShowInfo( wxCommandEvent& Event)
void OnDelete( wxCommandEvent& Event)
friend class ObjectFactory
GroupObjectPtr m_pGroup
bool m_bMouseMovingInheritance
wxPoint m_MousePoint
InheritanceInternalPtr m_pMovingInheritance
boost::posix_time::ptime m_LastUpdateTime
bool m_bPendingDelete
wxPoint m_ContextMenuPosition
DECLARE_EVENT_TABLE( )