Program Flow

team bbl


This is how the application starts running:

  1. Depending on platform, the main, WinMain, or equivalent function runs (supplied by wxWidgets, not the application). wxWidgets initializes its internal data structures and creates an instance of MyApp.

  2. wxWidgets calls MyApp::OnInit, which creates an instance of MyFrame.

  3. The MyFrame constructor creates the window via the wxFrame constructor and adds an icon, menu bar, and status bar.

  4. MyApp::OnInit shows the frame and returns true.

  5. wxWidgets starts the event loop, waiting for events and dispatching them to the appropriate handlers.

As noted here, the application terminates when the frame is closed, when the user either selects the Quit menu item or closes the frame via standard buttons or menus (these will differ from one platform to the next).

    team bbl



    Cross-Platform GUI Programming with wxWidgets
    Cross-Platform GUI Programming with wxWidgets
    ISBN: 0131473816
    EAN: 2147483647
    Year: 2005
    Pages: 262

    flylib.com © 2008-2017.
    If you may any questions please contact us: flylib@qtcs.net