Mercurial > projects > dwt-mac
diff dwt/DWT.d @ 1:8b48be5454ce
The internal cocoa classes compile now
author | Jacob Carlborg <doob@me.com> <jacob.carlborg@gmail.com> |
---|---|
date | Tue, 19 Aug 2008 17:35:17 +0200 |
parents | 380af2bdd8e5 |
children | 354c569b57a9 |
line wrap: on
line diff
--- a/dwt/DWT.d Sat Aug 09 17:00:02 2008 +0200 +++ b/dwt/DWT.d Tue Aug 19 17:35:17 2008 +0200 @@ -3766,7 +3766,7 @@ * * @since 3.0 */ - public static void error (int code, Exception throwable, String detail) { + public static void error (int code, Throwable throwable, String detail) { /* * This code prevents the creation of "chains" of DWTErrors and @@ -3782,17 +3782,13 @@ * NOTE: Exceptions thrown in syncExec and asyncExec must be * wrapped. */ - if (code !is DWT.ERROR_FAILED_EXEC) { - if (cast(DWTError) throwable) - throw cast(DWTError) throwable; - - if (cast(DWTException) throwable) - throw cast(DWTException) throwable; + if (code != SWT.ERROR_FAILED_EXEC) { + if (cast(SWTError) throwable) throw cast(SWTError) throwable; + if (cast(SWTException) throwable) throw cast(SWTException) throwable; } - String message = findErrorText(code); - if (detail !is null) - message += detail; + String message = findErrorText (code); + if (detail != null) message += detail; switch (code) { /* Illegal Arguments (non-fatal) */ @@ -3877,7 +3873,7 @@ * to stop the compiler from inlining. */ String platform = getPlatform(); - if ("carbon".opEquals(platform)) { //$NON-NLS-1$ + if ("carbon".equals(platform)) { //$NON-NLS-1$ MOD1 = COMMAND; MOD2 = SHIFT; MOD3 = ALT;