Google
Web alhem.net
Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members

MyMenu Class Reference

#include <MyMenu.h>

Inheritance diagram for MyMenu:

Inheritance graph
[legend]
Collaboration diagram for MyMenu:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 MyMenu (MenuHandler &)
 ~MyMenu ()
void Init ()
void OnCommand (int cmd)

Private Attributes

int m_id_properties

Constructor & Destructor Documentation

MyMenu::MyMenu MenuHandler h  ) 
 

File ......... MyMenu.cpp Published .... 2004-10-05

Definition at line 30 of file MyMenu.cpp.

References MyMenu().

Referenced by MyMenu().

00030 : Menu(h, CreatePopupMenu()) 00031 ,m_id_properties(-1) 00032 { 00033 }

MyMenu::~MyMenu  ) 
 

Definition at line 36 of file MyMenu.cpp.

References Menu::Handle().

00037 { 00038 if (Handle()) 00039 { 00040 ::DestroyMenu(Handle()); 00041 } 00042 }


Member Function Documentation

void MyMenu::Init  )  [virtual]
 

Reimplemented from Menu.

Definition at line 45 of file MyMenu.cpp.

References ID_POPUP_EXIT, and m_id_properties.

00046 { 00047 /* 00048 { 00049 DirMenu *p = new DirMenu(Handler()); // 'Menu' constructor adds new object to handler 00050 AddSubmenu(p); // AddSubmenu sets parent of child menu 00051 00052 AddMenuitem(MF_STRING | MF_POPUP, "Directories", (UINT)p->Handle()); 00053 } 00054 */ 00055 m_id_properties = AddMenuitem(MF_STRING, "Properties"); 00056 AddMenuitem(MF_SEPARATOR); 00057 AddMenuitem(MF_STRING, "E&xit", ID_POPUP_EXIT); 00058 }

void MyMenu::OnCommand int  cmd  )  [virtual]
 

Reimplemented from Menu.

Definition at line 61 of file MyMenu.cpp.

References g_app, g_hwndMain, IDED_LOCAL_PORT, m_id_properties, OnCommand(), and MyApp::SetDialogData().

Referenced by OnCommand().

00062 { 00063 if (cmd == m_id_properties) 00064 { 00065 g_app->SetDialogData(); 00066 ShowWindow(g_hwndMain, SW_SHOW); 00067 SetForegroundWindow(g_hwndMain); 00068 SetFocus(GetDlgItem(g_hwndMain, IDED_LOCAL_PORT)); 00069 } 00070 }


Member Data Documentation

int MyMenu::m_id_properties [private]
 

Definition at line 40 of file MyMenu.h.

Referenced by Init(), and OnCommand().


The documentation for this class was generated from the following files:
Generated on Thu Feb 10 22:42:40 2005 for Distributed URL Classification Tool by doxygen 1.3.7