- wxSetKeyboardHook(TRUE);
-
- wxModule::RegisterModules();
- if (!wxModule::InitializeModules())
- return FALSE;
- return TRUE;
-}
-
-// ---------------------------------------------------------------------------
-// RegisterWindowClasses
-// ---------------------------------------------------------------------------
-
-// TODO we should only register classes really used by the app. For this it
-// would be enough to just delay the class registration until an attempt
-// to create a window of this class is made.
-bool wxApp::RegisterWindowClasses()
-{
-// TODO:
-/*
- WNDCLASS wndclass;
-
- // for each class we register one with CS_(V|H)REDRAW style and one
- // without for windows created with wxNO_FULL_REDRAW_ON_REPAINT flag
- static const long styleNormal = 0; // TODO: CS_HREDRAW | CS_VREDRAW | CS_DBLCLKS;
- static const long styleNoRedraw = 0; // TODO: CS_DBLCLKS;
-
- // the fields which are common to all classes
- wndclass.lpfnWndProc = (WNDPROC)wxWndProc;
- wndclass.cbClsExtra = 0;
- wndclass.cbWndExtra = sizeof( DWORD ); // VZ: what is this DWORD used for?
- wndclass.hInstance = wxhInstance;
- wndclass.hIcon = (HICON) NULL;
- wndclass.hCursor = 0; // TODO: ::LoadCursor((HINSTANCE)NULL, IDC_ARROW);
- wndclass.lpszMenuName = NULL;
-
- // Register the frame window class.
- wndclass.hbrBackground = (HBRUSH)(COLOR_APPWORKSPACE + 1);
- wndclass.lpszClassName = wxFrameClassName;
- wndclass.style = styleNormal;
-
- if ( !RegisterClass(&wndclass) )
- {
- wxLogLastError("RegisterClass(frame)");
-
- return FALSE;
- }
-
- // "no redraw" frame
- wndclass.lpszClassName = wxFrameClassNameNoRedraw;
- wndclass.style = styleNoRedraw;
-
- if ( !RegisterClass(&wndclass) )
- {
- wxLogLastError("RegisterClass(no redraw frame)");
-
- return FALSE;
- }
-
- // Register the MDI frame window class.
- wndclass.hbrBackground = (HBRUSH)NULL; // paint MDI frame ourselves
- wndclass.lpszClassName = wxMDIFrameClassName;
- wndclass.style = styleNormal;
-
- if ( !RegisterClass(&wndclass) )
- {
- wxLogLastError("RegisterClass(MDI parent)");
-
- return FALSE;
- }
-
- // "no redraw" MDI frame
- wndclass.lpszClassName = wxMDIFrameClassNameNoRedraw;
- wndclass.style = styleNoRedraw;
-
- if ( !RegisterClass(&wndclass) )
- {
- wxLogLastError("RegisterClass(no redraw MDI parent frame)");
-
- return FALSE;
- }
-
- // Register the MDI child frame window class.
- wndclass.hbrBackground = (HBRUSH)(COLOR_WINDOW + 1);
- wndclass.lpszClassName = wxMDIChildFrameClassName;
- wndclass.style = styleNormal;
-
- if ( !RegisterClass(&wndclass) )
- {
- wxLogLastError("RegisterClass(MDI child)");
-
- return FALSE;
- }
-
- // "no redraw" MDI child frame
- wndclass.lpszClassName = wxMDIChildFrameClassNameNoRedraw;
- wndclass.style = styleNoRedraw;
-
- if ( !RegisterClass(&wndclass) )
- {
- wxLogLastError("RegisterClass(no redraw MDI child)");
-
- return FALSE;
- }
-
- // Register the panel window class.
- wndclass.hbrBackground = (HBRUSH) GetStockObject( LTGRAY_BRUSH );
- wndclass.lpszClassName = wxPanelClassName;
- wndclass.style = styleNormal;