Show
Ignore:
Timestamp:
05/04/08 18:42:55 (4 years ago)
Author:
Frank Benoit <benoit@tionex.de>
branch:
default
Message:

reverted char[] to String

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • dwt/widgets/MessageBox.d

    r210 r238  
    1212 *******************************************************************************/ 
    1313module dwt.widgets.MessageBox; 
     14 
     15import dwt.dwthelper.utils; 
    1416 
    1517 
     
    4648public class MessageBox : Dialog { 
    4749 
    48     char[] message = ""; 
     50    String message = ""; 
    4951    GtkWidget* handle; 
    5052    private bool allowNullParent = false; 
     
    117119 * @return the message 
    118120 */ 
    119 public char[] getMessage () { 
     121public String getMessage () { 
    120122    return message; 
    121123} 
     
    132134 * </ul> 
    133135 */ 
    134 public void setMessage (char[] string) { 
     136public void setMessage (String string) { 
    135137    if (string is null) error (DWT.ERROR_NULL_ARGUMENT); 
    136138    message = string; 
     
    201203} 
    202204 
    203 char[] fixPercent (char[] string) { 
     205char[] fixPercent (String string) { 
    204206    int i = 0, j = 0; 
    205     char [] result = new char[]( string.length * 2 ); 
     207    char [] result = new String( string.length * 2 ); 
    206208    while (i < string.length) { 
    207209        switch (string [i]) { 
     
    220222 + DWT extension 
    221223 +/ 
    222 public static int showMessageBox(char[] str, char[] title, Shell shell, int style) { 
     224public static int showMessageBox(String str, String title, Shell shell, int style) { 
    223225    MessageBox msgBox = (shell is null ) ? new MessageBox( style ) : new MessageBox(shell, style); 
    224226    msgBox.setMessage(str); 
     
    230232 
    231233/// DWT extension 
    232 public static int showInfo(char[] str, char[] title = null, Shell shell = null) { 
     234public static int showInfo(String str, String title = null, Shell shell = null) { 
    233235    return showMessageBox( str, title, shell, DWT.OK | DWT.ICON_INFORMATION ); 
    234236} 
     
    237239 
    238240/// DWT extension 
    239 public static int showWarning(char[] str, char[] title = null, Shell shell = null) { 
     241public static int showWarning(String str, String title = null, Shell shell = null) { 
    240242    return showMessageBox( str, title, shell, DWT.OK | DWT.ICON_WARNING ); 
    241243} 
    242244/// DWT extension 
    243 public static int showError(char[] str, char[] title = null, Shell shell = null) { 
     245public static int showError(String str, String title = null, Shell shell = null) { 
    244246    return showMessageBox( str, title, shell, DWT.OK | DWT.ICON_ERROR ); 
    245247}