MainWindow Class Reference

#include <MainWindow.hxx>

Inheritance diagram for MainWindow:
Inheritance graph
[legend]
Collaboration diagram for MainWindow:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 MainWindow (const TGWindow *w, int s1, int s2)
virtual ~MainWindow ()
virtual void CloseWindow ()
Bool_t ProcessMessage (Long_t msg, Long_t parm1, Long_t parm2)
 MainWindow (const TGWindow *w, int s1, int s2)
virtual ~MainWindow ()
virtual void CloseWindow ()
Bool_t ProcessMessage (Long_t msg, Long_t parm1, Long_t parm2)

Private Attributes

TGPopupMenu * menuFile
TGMenuBar * menuBar
TGLayoutHints * menuBarLayout
TGLayoutHints * menuBarItemLayout

Detailed Description

Definition at line 383 of file analyzer.cxx.


Constructor & Destructor Documentation

MainWindow::MainWindow ( const TGWindow *  w,
int  s1,
int  s2 
)

Definition at line 433 of file analyzer.cxx.

References M_FILE_EXIT, menuBar, menuBarItemLayout, menuBarLayout, and menuFile.

00434     : TGMainFrame(w,s1,s2)
00435 {
00436    //SetCleanup(kDeepCleanup);
00437    
00438    SetWindowName("ROOT Analyzer Control");
00439 
00440    // layout the gui
00441    menuFile = new TGPopupMenu(gClient->GetRoot());
00442    menuFile->AddEntry("Exit", M_FILE_EXIT);
00443 
00444    menuBarItemLayout = new TGLayoutHints(kLHintsTop|kLHintsLeft, 0, 4, 0, 0);
00445 
00446    menuFile->Associate(this);
00447    //menuControls->Associate(this);
00448 
00449    menuBar = new TGMenuBar(this, 1, 1, kRaisedFrame);
00450    menuBar->AddPopup("&File",     menuFile,     menuBarItemLayout);
00451    //menuBar->AddPopup("&Controls", menuControls, menuBarItemLayout);
00452    menuBar->Layout();
00453 
00454    menuBarLayout = new TGLayoutHints(kLHintsTop|kLHintsLeft|kLHintsExpandX);
00455    AddFrame(menuBar,menuBarLayout);
00456    
00457    MapSubwindows(); 
00458    Layout();
00459    MapWindow();
00460 }

MainWindow::~MainWindow (  )  [virtual]

Definition at line 462 of file analyzer.cxx.

References menuBar, menuBarItemLayout, menuBarLayout, and menuFile.

00463 {
00464     delete menuFile;
00465     //delete menuControls;
00466     delete menuBar;
00467     delete menuBarLayout;
00468     delete menuBarItemLayout;
00469 }

MainWindow::MainWindow ( const TGWindow *  w,
int  s1,
int  s2 
)
virtual MainWindow::~MainWindow (  )  [virtual]

Member Function Documentation

virtual void MainWindow::CloseWindow (  )  [virtual]
void MainWindow::CloseWindow (  )  [virtual]

Definition at line 471 of file analyzer.cxx.

References endRun(), gIsRunning, and gRunNumber.

00472 {
00473     if(gIsRunning)
00474         endRun(0,gRunNumber,0);
00475     gSystem->ExitLoop();
00476 }

Here is the call graph for this function:

Bool_t MainWindow::ProcessMessage ( Long_t  msg,
Long_t  parm1,
Long_t  parm2 
)
Bool_t MainWindow::ProcessMessage ( Long_t  msg,
Long_t  parm1,
Long_t  parm2 
)

Definition at line 402 of file analyzer.cxx.

References endRun(), gIsRunning, gRunNumber, and M_FILE_EXIT.

00403 {
00404    // printf("GUI Message %d %d %d\n",(int)msg,(int)parm1,(int)parm2);
00405     switch (GET_MSG(msg))
00406       {
00407       default:
00408         break;
00409       case kC_COMMAND:
00410         switch (GET_SUBMSG(msg))
00411           {
00412           default:
00413             break;
00414           case kCM_MENU:
00415             switch (parm1)
00416               {
00417               default:
00418                 break;
00419               case M_FILE_EXIT:
00420                 if(gIsRunning)
00421                    endRun(0,gRunNumber,0);
00422                 gSystem->ExitLoop();
00423                 break;
00424               }
00425             break;
00426           }
00427         break;
00428       }
00429 
00430     return kTRUE;
00431 }

Here is the call graph for this function:


Member Data Documentation

TGMenuBar * MainWindow::menuBar [private]

Definition at line 388 of file analyzer.cxx.

Referenced by MainWindow(), and ~MainWindow().

TGLayoutHints * MainWindow::menuBarItemLayout [private]

Definition at line 390 of file analyzer.cxx.

Referenced by MainWindow(), and ~MainWindow().

TGLayoutHints * MainWindow::menuBarLayout [private]

Definition at line 389 of file analyzer.cxx.

Referenced by MainWindow(), and ~MainWindow().

TGPopupMenu * MainWindow::menuFile [private]

Definition at line 386 of file analyzer.cxx.

Referenced by MainWindow(), and ~MainWindow().


The documentation for this class was generated from the following files:

Generated on 12 Feb 2016 for ROOT Analyzer by  doxygen 1.6.1