diff --git a/base/applications/mplay32/mplay32.c b/base/applications/mplay32/mplay32.c index e5299cb539f..2b70c1d0de6 100644 --- a/base/applications/mplay32/mplay32.c +++ b/base/applications/mplay32/mplay32.c @@ -12,6 +12,12 @@ #define MAIN_WINDOW_MIN_WIDTH 250 #define MAX_MCISTR 256 +#ifdef UNICODE +#define argv __wargv +#else +#define argv __argv +#endif + HINSTANCE hInstance = NULL; HWND hTrackBar = NULL; HWND hToolBar = NULL; @@ -1537,7 +1543,14 @@ _tWinMain(HINSTANCE hInst, HINSTANCE hPrevInst, LPTSTR lpCmdLine, INT nCmdShow) ShowWindow(hwnd, SW_SHOW); UpdateWindow(hwnd); - OpenMediaFile(hwnd, lpCmdLine, NULL); + if (*lpCmdLine == _T('"')) + { + OpenMediaFile(hwnd, argv[1], NULL); + } + else + { + OpenMediaFile(hwnd, lpCmdLine, NULL); + } /* Message Loop */ while (GetMessage(&msg, NULL, 0, 0))