change drag and drop filename length to MAX_PATH

This commit is contained in:
zilmar 2015-02-18 07:41:34 +11:00
parent d033a4f2b8
commit dba475a1ae
1 changed files with 3 additions and 6 deletions

View File

@ -864,15 +864,12 @@ DWORD CALLBACK CMainGui::MainGui_Proc (HWND hWnd, DWORD uMsg, DWORD wParam, DWOR
break;
case WM_DROPFILES:
{
//We need to stop the filename from the file dropped
char filename[200];
//Set HRDOP to the paramater that we have recieved
char filename[MAX_PATH];
HDROP hDrop = (HDROP)wParam;
//Queery the file so we can get the filename
DragQueryFile(hDrop, 0, filename, sizeof(filename));
//Now we have queried, lets tell windows to release the memory.
DragFinish(hDrop);
//Now the important part, run said image.
CN64System::RunFileImage(filename);
}
break;