|
From: <ma...@us...> - 2003-12-23 00:40:53
|
Update of /cvsroot/sharedaemon/ui-wx/src
In directory sc8-pr-cvs1:/tmp/cvs-serv18275
Modified Files:
MainDlg.cpp MainDlg.h
Log Message:
Moved class descriptions to header.
Index: MainDlg.cpp
===================================================================
RCS file: /cvsroot/sharedaemon/ui-wx/src/MainDlg.cpp,v
retrieving revision 1.35
retrieving revision 1.36
diff -u -d -r1.35 -r1.36
--- MainDlg.cpp 22 Dec 2003 22:00:10 -0000 1.35
+++ MainDlg.cpp 23 Dec 2003 00:40:50 -0000 1.36
@@ -43,12 +43,6 @@
class CStatusBar *statusbar;
class CToolBar *toolbar;
-/***************************** MyToolBar class ********************************/
-/* This class is derived from wxToolBar and is used for main frame */
-/* toolbar. The main purpose for this class is catching mouse right- */
-/* click events, and sending them to mainframe. Can't do it from */
-/* mainframe, so we'll do it here. */
-/******************************************************************************/
BEGIN_EVENT_TABLE(MyToolBar, wxToolBar)
EVT_RIGHT_DOWN(MyToolBar::RightClick) /* Toolbar Right-click */
END_EVENT_TABLE()
@@ -70,12 +64,6 @@
mainframe->ShowToolPopupMenu();
}
-/**************************** DetachedFrame class *****************************/
-/* This class is derived from wxFrame and provides minimal frame support */
-/* for displaying some dialog page. It is used mainly for detaching */
-/* pages from main frame and dumping here. When this frame is closed, */
-/* it passes the contents back to main frame. */
-/******************************************************************************/
BEGIN_EVENT_TABLE(DetachedFrame, wxFrame)
EVT_CLOSE(DetachedFrame::OnClose)
END_EVENT_TABLE()
@@ -116,25 +104,6 @@
Destroy();
}
-/************************** CMainDlg class ************************************/
-/* This is the MAIN frame of the entire interface. It servers as host */
-/* a number of controls, most importantly the following: */
-/* * Dialog Pages. These are wxPanel-derived classes with the actual */
-/* contents. "Server Page", "Search Page", "Transfer Page" are */
-/* examples of Dialog Pages. The number of possible dialog pages */
-/* is pretty much infinite. */
-/* * ToolBar. This is created using MyToolBar class, and contains main */
-/* navigation controls. The images for toolbar are generated */
-/* manually from image+text since toolbar texts are not */
-/* supported on wxMac. */
-/* * Menubar. This is a pretty much standard menubar that contains the */
-/* usual File/Edit/View/Help sections. By default, it is hidden, */
-/* but can be turned on from Preferences. */
-/* * StatusBar. This is NOT, as the name might suggest, derived from */
-/* wxStatusBar, simply because wxStatusBar doesn't give enough */
-/* functionality for what we need to do (on some platforms, */
-/* native statusbar is thinner, thus our images won't fit there) */
-/******************************************************************************/
BEGIN_EVENT_TABLE(CMainDlg, wxFrame)
EVT_CLOSE(CMainDlg::OnCloseWindow) /* Shutdown event */
EVT_TOOL(-1, CMainDlg::MenuOrToolEvent) /* Menu/Toolbar events */
Index: MainDlg.h
===================================================================
RCS file: /cvsroot/sharedaemon/ui-wx/src/MainDlg.h,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -d -r1.15 -r1.16
--- MainDlg.h 22 Dec 2003 05:04:15 -0000 1.15
+++ MainDlg.h 23 Dec 2003 00:40:50 -0000 1.16
@@ -56,10 +56,12 @@
wxWindowID id;
};
-/**
- * This class is only needed for catching some specific events (see the event
- * table. Actual event handling is still done in CMainDlg.
- */
+/***************************** MyToolBar class ********************************/
+/* This class is derived from wxToolBar and is used for main frame */
+/* toolbar. The main purpose for this class is catching mouse right- */
+/* click events, and sending them to mainframe. Can't do it from */
+/* mainframe, so we'll do it here. */
+/******************************************************************************/
class MyToolBar : public wxToolBar {
public:
MyToolBar(wxWindow *parent, wxWindowID id = -1,
@@ -72,7 +74,12 @@
void RightClick(wxMouseEvent &event); /* Right mouse clicks events */
};
-/* This very small class usually shows a frame with one dialog page as content*/
+/**************************** DetachedFrame class *****************************/
+/* This class is derived from wxFrame and provides minimal frame support */
+/* for displaying some dialog page. It is used mainly for detaching */
+/* pages from main frame and dumping here. When this frame is closed, */
+/* it passes the contents back to main frame. */
+/******************************************************************************/
class DetachedFrame : public wxFrame {
public:
DetachedFrame(
@@ -87,12 +94,27 @@
Page *cnt; /* Contents of the frame */
};
+/************************** CMainDlg class ************************************/
+/* This is the MAIN frame of the entire interface. It servers as host */
+/* a number of controls, most importantly the following: */
+/* * Dialog Pages. These are wxPanel-derived classes with the actual */
+/* contents. "Server Page", "Search Page", "Transfer Page" are */
+/* examples of Dialog Pages. The number of possible dialog pages */
+/* is pretty much infinite. */
+/* * ToolBar. This is created using MyToolBar class, and contains main */
+/* navigation controls. The images for toolbar are generated */
+/* manually from image+text since toolbar texts are not */
+/* supported on wxMac. */
+/* * Menubar. This is a pretty much standard menubar that contains the */
+/* usual File/Edit/View/Help sections. By default, it is hidden, */
+/* but can be turned on from Preferences. */
+/* * StatusBar. This is NOT, as the name might suggest, derived from */
+/* wxStatusBar, simply because wxStatusBar doesn't give enough */
+/* functionality for what we need to do (on some platforms, */
+/* native statusbar is thinner, thus our images won't fit there) */
+/******************************************************************************/
WX_DECLARE_LIST(Page, PageList);
-/**
- * MainDlg class. The main dialog functions like Toolbar and Statusbar
- * stuff go in here.
- */
extern class CMainDlg *mainframe;
class CMainDlg: public wxFrame {
friend class MyToolBar;
|