ReactOS  0.4.15-dev-1201-gb2cf5a4
vfdshmenu.cpp File Reference
#include <windows.h>
#include <shellapi.h>
#include <shlobj.h>
#include "vfdtypes.h"
#include "vfdapi.h"
#include "vfdlib.h"
#include "vfdmsg.h"
#include "vfdshext.h"
Include dependency graph for vfdshmenu.cpp:

Go to the source code of this file.

Classes

struct  _vfd_menu
 

Macros

#define WIN32_LEAN_AND_MEAN
 
#define SHOP_FILEPATH   0x00000002
 
#define SHOP_EXPORT_ORDINAL   178
 

Typedefs

typedef BOOL(WINAPISHOBJECTPROPERTIES) (HWND hwnd, DWORD dwType, LPCWSTR lpObject, LPCWSTR lpPage)
 

Enumerations

enum  {
  VFD_CMD_OPEN = 0, VFD_CMD_SAVE, VFD_CMD_CLOSE, VFD_CMD_PROTECT,
  VFD_CMD_DROP, VFD_CMD_PROP, VFD_CMD_MAX
}
 

Functions

static void AddMenuItem (HMENU hMenu, UINT uPos, UINT uFlags, UINT uCmd, UINT uText)
 

Variables

static struct _vfd_menu g_VfdMenu [VFD_CMD_MAX]
 

Macro Definition Documentation

◆ SHOP_EXPORT_ORDINAL

#define SHOP_EXPORT_ORDINAL   178

Definition at line 39 of file vfdshmenu.cpp.

◆ SHOP_FILEPATH

#define SHOP_FILEPATH   0x00000002

Definition at line 36 of file vfdshmenu.cpp.

◆ WIN32_LEAN_AND_MEAN

#define WIN32_LEAN_AND_MEAN

Definition at line 11 of file vfdshmenu.cpp.

Typedef Documentation

◆ SHOBJECTPROPERTIES

typedef BOOL(WINAPI * SHOBJECTPROPERTIES) (HWND hwnd, DWORD dwType, LPCWSTR lpObject, LPCWSTR lpPage)

Definition at line 32 of file vfdshmenu.cpp.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
VFD_CMD_OPEN 
VFD_CMD_SAVE 
VFD_CMD_CLOSE 
VFD_CMD_PROTECT 
VFD_CMD_DROP 
VFD_CMD_PROP 
VFD_CMD_MAX 

Definition at line 44 of file vfdshmenu.cpp.

Function Documentation

◆ AddMenuItem()

static void AddMenuItem ( HMENU  hMenu,
UINT  uPos,
UINT  uFlags,
UINT  uCmd,
UINT  uText 
)
static

Definition at line 77 of file vfdshmenu.cpp.

83 {
84  PSTR text = ModuleMessage(uText);
85 
86  if (text) {
87  InsertMenu(hMenu, uPos, uFlags, uCmd, text);
88  LocalFree(text);
89  }
90 }
PSTR ModuleMessage(DWORD nFormat,...)
Definition: vfdlib.c:124
#define InsertMenu
Definition: winuser.h:5778
const WCHAR * text
Definition: package.c:1827
UINT uFlags
Definition: api.c:59
HLOCAL NTAPI LocalFree(HLOCAL hMem)
Definition: heapmem.c:1577
signed char * PSTR
Definition: retypes.h:7

Referenced by CVfdShExt::QueryContextMenu().

Variable Documentation

◆ g_VfdMenu

struct _vfd_menu g_VfdMenu[VFD_CMD_MAX]
static
Initial value:
= {
{ MSG_MENU_OPEN, MSG_HELP_OPEN, "vfdopen", L"vfdopen" },
{ MSG_MENU_SAVE, MSG_HELP_SAVE, "vfdsave", L"vfdsave" },
{ MSG_MENU_CLOSE, MSG_HELP_CLOSE, "vfdclose", L"vfdclose" },
{ MSG_MENU_PROTECT, MSG_HELP_PROTECT, "protect", L"protect" },
{ MSG_MENU_DROP, MSG_HELP_DROP, "vfddrop", L"vfddrop" },
{ MSG_MENU_PROP, MSG_HELP_PROP, "vfdprop", L"vfdprop" },
}
static const WCHAR L[]
Definition: oid.c:1250

Referenced by CVfdShExt::GetCommandString(), CVfdShExt::InvokeCommand(), and CVfdShExt::QueryContextMenu().