| 319 | Common::String ErrorMsg("Game could not be started.\n"); |
| 320 | switch(result){ |
| 321 | case (Common::kInvalidPathError): |
| 322 | ErrorMsg += "Reason: Invalid path error.\n"; |
| 323 | break; |
| 324 | case (Common::kNoGameDataFoundError): |
| 325 | ErrorMsg += "Reason: Game data file not found.\n"; |
| 326 | break; |
| 327 | case (Common::kUnsupportedGameidError): |
| 328 | ErrorMsg += "Reason: Unsupported gameid.\n"; |
| 329 | break; |
| 330 | case (Common::kReadPermissionDenied): |
| 331 | ErrorMsg += "Reason: Read permission denied.\n"; |
| 332 | break; |
| 333 | case (Common::kWritePermissionDenied): |
| 334 | ErrorMsg += "Reason: Write permission denied.\n"; |
| 335 | break; |
| 336 | case (Common::kPathDoesNotExist): |
| 337 | ErrorMsg += "Reason: Path does not exist.\n"; |
| 338 | break; |
| 339 | case (Common::kPathNotDirectory): |
| 340 | ErrorMsg += "Reason: Path is not a directory.\n"; |
| 341 | break; |
| 342 | case (Common::kPathNotFile): |
| 343 | ErrorMsg += "Reason: Path is not a file.\n"; |
| 344 | break; |
| 345 | case (Common::kCreatingFileFailed): |
| 346 | ErrorMsg += "Reason: File creation failed.\n"; |
| 347 | break; |
| 348 | case (Common::kReadingFailed): |
| 349 | ErrorMsg += "Reason: Error reading file.\n"; |
| 350 | break; |
| 351 | case (Common::kWritingFailed): |
| 352 | ErrorMsg += "Reason: Error writing file.\n"; |
| 353 | break; |
| 354 | case (Common::kUnknownError): |
| 355 | default: |
| 356 | ErrorMsg += "Reason: Unknown.\n"; |
| 357 | break; |
| 358 | } |
| 359 | GUI::MessageDialog ErrDlg(ErrorMsg); |
| 360 | ErrDlg.runModal(); |