Kaydet (Commit) 46a153cb authored tarafından Chris Sherlock's avatar Chris Sherlock

vcl: update error codes to defined constants for code clarity

Change-Id: I6e86c45b71fc15d6645501128e7d86f8e179e652
Reviewed-on: https://gerrit.libreoffice.org/36851Reviewed-by: 's avatarChris Sherlock <chris.sherlock79@gmail.com>
Tested-by: 's avatarChris Sherlock <chris.sherlock79@gmail.com>
üst 437105b9
......@@ -259,7 +259,7 @@ bool ErrorHandler::GetErrorString(sal_uInt32 nErrCodeId, OUString& rErrStr)
*/
DialogMask ErrorHandler::HandleError(sal_uInt32 nErrCodeId, DialogMask nFlags)
{
if(!nErrCodeId || nErrCodeId == ERRCODE_ABORT)
if(nErrCodeId != ERRCODE_NONE || nErrCodeId == ERRCODE_ABORT)
return DialogMask::NONE;
ErrorRegistry &rData = TheErrorRegistry::get();
......@@ -327,11 +327,11 @@ DialogMask ErrorHandler::HandleError(sal_uInt32 nErrCodeId, DialogMask nFlags)
}
OSL_FAIL("Error not handled");
// Error 1 is classified as a General Error in sfx
if (pInfo->GetErrorCode()!=1)
HandleError(1);
// Error 1 (ERRCODE_ABORT) is classified as a General Error in sfx
if (pInfo->GetErrorCode() != ERRCODE_ABORT)
HandleError(ERRCODE_ABORT);
else
OSL_FAIL("Error 1 not handled");
OSL_FAIL("ERRCODE_ABORT not handled");
delete pInfo;
return DialogMask::NONE;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment