ReactOS 0.4.15-dev-7924-g5949c20
COpenWithMenu.cpp File Reference
#include "precomp.h"
Include dependency graph for COpenWithMenu.cpp:

Go to the source code of this file.

Classes

class  COpenWithList
 
struct  COpenWithList::SApp
 
struct  COpenWithList::_LANGANDCODEPAGE
 
class  COpenWithDialog
 

Functions

 WINE_DEFAULT_DEBUG_CHANNEL (shell)
 
EXTERN_C BOOL PathIsExeW (LPCWSTR lpszPath)
 
HRESULT WINAPI SHOpenWithDialog (HWND hwndParent, const OPENASINFO *poainfo)
 

Function Documentation

◆ PathIsExeW()

EXTERN_C BOOL PathIsExeW ( LPCWSTR  lpszPath)

Definition at line 539 of file shellpath.c.

540{
541 LPCWSTR lpszExtension = PathGetExtensionW(lpszPath);
542 int i;
543 static const WCHAR lpszExtensions[][4] =
544 {L"exe", L"com", L"pif", L"cmd", L"bat", L"scf", L"scr", L"" };
545
546 TRACE("path=%s\n",debugstr_w(lpszPath));
547
548 for(i=0; lpszExtensions[i][0]; i++)
549 if (!wcsicmp(lpszExtension,lpszExtensions[i])) return TRUE;
550
551 return FALSE;
552}
#define TRUE
Definition: types.h:120
#define FALSE
Definition: types.h:117
#define wcsicmp
Definition: compat.h:15
static LPWSTR PathGetExtensionW(LPCWSTR lpszPath)
Definition: shellpath.c:434
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
#define debugstr_w
Definition: kernel32.h:32
#define L(x)
Definition: ntvdm.h:50
#define TRACE(s)
Definition: solgame.cpp:4
__wchar_t WCHAR
Definition: xmlstorage.h:180
const WCHAR * LPCWSTR
Definition: xmlstorage.h:185

Referenced by CFileDefExt::InitGeneralPage(), and COpenWithMenu::Initialize().

◆ SHOpenWithDialog()

HRESULT WINAPI SHOpenWithDialog ( HWND  hwndParent,
const OPENASINFO poainfo 
)

Definition at line 1428 of file COpenWithMenu.cpp.

1429{
1430 INT_PTR ret;
1431
1432 TRACE("SHOpenWithDialog hwndParent %p poainfo %p\n", hwndParent, poainfo);
1433
1435
1436 if (poainfo->pcszClass == NULL && poainfo->pcszFile == NULL)
1437 return E_FAIL;
1438
1439 COpenWithDialog pDialog(poainfo);
1440
1441 if (pDialog.IsNoOpen(hwndParent))
1442 return S_OK;
1443
1446
1447 if (ret == (INT_PTR)-1)
1448 {
1449 ERR("Failed to create dialog: %u\n", GetLastError());
1450 return E_FAIL;
1451 }
1452
1453 return S_OK;
1454}
#define shell32_hInstance
#define ERR(fmt,...)
Definition: debug.h:110
static INT_PTR CALLBACK DialogProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
VOID WINAPI InitCommonControls(void)
Definition: commctrl.c:863
static HWND hwndParent
Definition: cryptui.c:300
#define E_FAIL
Definition: ddrawi.h:102
#define NULL
Definition: types.h:112
#define S_OK
Definition: intsafe.h:52
#define IDD_OPEN_WITH
Definition: shresdef.h:516
LPCWSTR pcszFile
Definition: shlobj.h:2678
LPCWSTR pcszClass
Definition: shlobj.h:2679
int32_t INT_PTR
Definition: typedefs.h:64
int ret
DWORD WINAPI GetLastError(void)
Definition: except.c:1042
LONG_PTR LPARAM
Definition: windef.h:208
#define MAKEINTRESOURCE
Definition: winuser.h:591
INT_PTR WINAPI DialogBoxParamW(_In_opt_ HINSTANCE, _In_ LPCWSTR, _In_opt_ HWND, _In_opt_ DLGPROC, _In_ LPARAM)

Referenced by FolderOptionsFileTypesDlg(), CFileDefExt::GeneralPageProc(), COpenWithMenu::InvokeCommand(), and OpenAs_RunDLLW().

◆ WINE_DEFAULT_DEBUG_CHANNEL()

WINE_DEFAULT_DEBUG_CHANNEL ( shell  )