Popup Menus. More...
#include <utility.h>
Public Member Functions | |
PopupMenu () | |
~PopupMenu () | |
PopupMenu (UINT nid) | |
operator HMENU () | |
void | Append (UINT id, LPCTSTR str, UINT flags=MF_STRING) |
int | TrackPopupMenu (HWND hwnd, const POINT &pt, UINT flags=TPM_LEFTBUTTON|TPM_RIGHTBUTTON, LPTPMPARAMS tpm=NULL) |
int | PopupContextMenu (HWND hwnd, POINTS pos, UINT flags=TPM_LEFTBUTTON|TPM_RIGHTBUTTON) |
int | TrackPopupMenu (HWND hwnd, POINTS pos, UINT flags=TPM_LEFTBUTTON|TPM_RIGHTBUTTON) |
int | TrackPopupMenuAtCursor (HWND hwnd, UINT flags=TPM_LEFTBUTTON) |
int | TrackPopupMenuAtPos (HWND hwnd, DWORD pos, UINT flags=TPM_LEFTBUTTON) |
Protected Attributes | |
HMENU | _hmenu |
Popup Menus.
Definition at line 659 of file utility.h.
PopupMenu::PopupMenu | ( | ) | [inline] |
PopupMenu::~PopupMenu | ( | ) | [inline] |
PopupMenu::PopupMenu | ( | UINT | nid ) |
Definition at line 854 of file explorer.cpp.
References ExplorerGlobals::_hInstance, and _hmenu.
{ HMENU hMenu = LoadMenu(g_Globals._hInstance, MAKEINTRESOURCE(nid)); _hmenu = GetSubMenu(hMenu, 0); RemoveMenu(hMenu, 0, MF_BYPOSITION); DestroyMenu(hMenu); }
void PopupMenu::Append | ( | UINT | id, |
LPCTSTR | str, | ||
UINT | flags = MF_STRING |
||
) | [inline] |
int PopupMenu::PopupContextMenu | ( | HWND | hwnd, |
POINTS | pos, | ||
UINT | flags = TPM_LEFTBUTTON|TPM_RIGHTBUTTON |
||
) | [inline] |
int PopupMenu::TrackPopupMenu | ( | HWND | hwnd, |
POINTS | pos, | ||
UINT | flags = TPM_LEFTBUTTON|TPM_RIGHTBUTTON |
||
) | [inline] |
Definition at line 691 of file utility.h.
References ClientToScreen().
{ POINT pt; pt.x = pos.x; pt.y = pos.y; ClientToScreen(hwnd, &pt); return TrackPopupMenuEx(_hmenu, flags, pt.x, pt.y, hwnd, NULL); }
int PopupMenu::TrackPopupMenu | ( | HWND | hwnd, |
const POINT & | pt, | ||
UINT | flags = TPM_LEFTBUTTON|TPM_RIGHTBUTTON , |
||
LPTPMPARAMS | tpm = NULL |
||
) | [inline] |
Definition at line 680 of file utility.h.
Referenced by NotifyArea::WndProc(), and DesktopBar::WndProc().
{ return TrackPopupMenuEx(_hmenu, flags, pt.x, pt.y, hwnd, tpm); }
int PopupMenu::TrackPopupMenuAtCursor | ( | HWND | hwnd, |
UINT | flags = TPM_LEFTBUTTON |
||
) | [inline] |
int PopupMenu::TrackPopupMenuAtPos | ( | HWND | hwnd, |
DWORD | pos, | ||
UINT | flags = TPM_LEFTBUTTON |
||
) | [inline] |
HMENU PopupMenu::_hmenu [protected] |
Definition at line 709 of file utility.h.
Referenced by PopupMenu().
ROS Explorer Source Code Documentation
generated on 02.01.2013 by ![]() |