Mercurial > projects > dwt-win
diff dwt/DWT.d @ 212:ab60f3309436
reverted the char[] to String and use the an alias.
author | Frank Benoit <benoit@tionex.de> |
---|---|
date | Mon, 05 May 2008 00:12:38 +0200 |
parents | 1e7701c27c03 |
children | 36f5cb12e1a2 |
line wrap: on
line diff
--- a/dwt/DWT.d Sat Apr 26 10:01:48 2008 +0200 +++ b/dwt/DWT.d Mon May 05 00:12:38 2008 +0200 @@ -20,6 +20,7 @@ import dwt.DWTException; import tango.core.Exception; +import dwt.dwthelper.utils; version(build){ pragma(link, "advapi32"); @@ -3392,7 +3393,7 @@ * * @see DWT */ -static char[] findErrorText (int code) { +static String findErrorText (int code) { switch (code) { case ERROR_UNSPECIFIED: return "Unspecified error"; //$NON-NLS-1$ case ERROR_NO_HANDLES: return "No more handles"; //$NON-NLS-1$ @@ -3448,7 +3449,7 @@ * <li>ERROR_NULL_ARGUMENT - if the key is null</li> * </ul> */ -public static char[] getMessage(char[] key) { +public static String getMessage(String key) { //return Compatibility.getMessage(key); return ""; } @@ -3459,7 +3460,7 @@ * * @return the DWT platform name */ -public static char[] getPlatform () { +public static String getPlatform () { return Platform.PLATFORM; } @@ -3478,7 +3479,7 @@ * * @param code the DWT error code */ -public static void error (char[] file, long line, int code) { +public static void error (String file, long line, int code) { error (code, null); } public static void error (int code) { @@ -3542,7 +3543,7 @@ * * @since 3.0 */ -public static void error (int code, Exception throwable, char[] detail) { +public static void error (int code, Exception throwable, String detail) { /* * This code prevents the creation of "chains" of SWTErrors and @@ -3563,7 +3564,7 @@ if (auto t = cast(DWTException)throwable ) throw t; } - char[] message = findErrorText (code); + String message = findErrorText (code); if (detail != null) message ~= detail; switch (code) {