| 299 | } |
| 300 | |
| 301 | void UploadDialogShow2() |
| 302 | { |
| 303 | if (!UploadDialogCheckHasUploadRights()) |
| 304 | return; |
| 305 | |
| 306 | const int MAX_FILE = 4096; |
| 307 | TCHAR buffer[MAX_FILE]; |
| 308 | TCHAR buffer2[MAX_FILE]; |
| 309 | buffer[0] = buffer2[0] = 0; |
| 310 | |
| 311 | OPENFILENAME ofn{}; |
| 312 | ofn.lStructSize = SIZEOF_OPENFILENAME_NT4; |
| 313 | ofn.hwndOwner = g_Hwnd; |
| 314 | ofn.hInstance = g_hInstance; |
| 315 | ofn.nMaxFile = MAX_FILE; |
| 316 | ofn.lpstrFile = buffer; |
| 317 | ofn.nMaxFileTitle = MAX_FILE; |
| 318 | ofn.lpstrFileTitle = buffer2; |
| 319 | ofn.lpstrFilter = TEXT("All files\0*.*\0\0"); |
| 320 | ofn.lpstrTitle = TmGetTString(IDS_FILE_UPLOAD); |
| 321 | |
| 322 | if (!GetOpenFileName(&ofn)) { |
| 323 | // maybe they cancelled. hope there's no error! |
| 324 | DbgPrintW("User cancelled upload operation at file name box"); |
| 325 | return; |
| 326 | } |
| 327 | |
| 328 | UploadDialogShowWithFileName( |
| 329 | ofn.lpstrFile, |
| 330 | ofn.lpstrFileTitle |
| 331 | ); |
| 332 | } |
| 333 | |
| 334 | void UploadDialogShow() |
| 335 | { |
no test coverage detected