Show
Ignore:
Timestamp:
05/04/08 18:12:38 (7 months ago)
Author:
Frank Benoit <benoit@tionex.de>
branch:
default
Message:

reverted the char[] to String and use the an alias.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • dwt/custom/CCombo.d

    r194 r212  
    197197 * @see #add(String,int) 
    198198 */ 
    199 public void add (char[] string) { 
     199public void add (String string) { 
    200200    checkWidget(); 
    201201    if (string is null) DWT.error (DWT.ERROR_NULL_ARGUMENT); 
     
    225225 * @see #add(String) 
    226226 */ 
    227 public void add (char[] string, int index) { 
     227public void add (String string, int index) { 
    228228    checkWidget(); 
    229229    if (string is null) DWT.error (DWT.ERROR_NULL_ARGUMENT); 
     
    377377    checkWidget (); 
    378378    int width = 0, height = 0; 
    379     char[][] items = list.getItems (); 
     379    String[] items = list.getItems (); 
    380380    GC gc = new GC (text); 
    381381    int spacer = gc.stringExtent (" ").x; //$NON-NLS-1$ 
     
    413413    text.copy (); 
    414414} 
    415 void createPopup(char[][] items, int selectionIndex) { 
     415void createPopup(String[] items, int selectionIndex) { 
    416416    // create shell and list 
    417417    popup = new Shell (getShell (), DWT.NO_TRIM | DWT.ON_TOP); 
     
    497497 
    498498    if (getShell() !is popup.getParent ()) { 
    499         char[][] items = list.getItems (); 
     499        String[] items = list.getItems (); 
    500500        int selectionIndex = list.getSelectionIndex (); 
    501501        list.removeListener (DWT.Dispose, listener); 
     
    535535 * characters in the given string, return '\0'. 
    536536 */ 
    537 dchar _findMnemonic (char[] string) { 
     537dchar _findMnemonic (String string) { 
    538538    if (string is null) return '\0'; 
    539539    int index = 0; 
     
    603603 * </ul> 
    604604 */ 
    605 public char[] getItem (int index) { 
     605public String getItem (int index) { 
    606606    checkWidget(); 
    607607    return list.getItem (index); 
     
    652652 * </ul> 
    653653 */ 
    654 public char[] [] getItems () { 
     654public String [] getItems () { 
    655655    checkWidget (); 
    656656    return list.getItems (); 
     
    709709 * </ul> 
    710710 */ 
    711 public char[] getText () { 
     711public String getText () { 
    712712    checkWidget (); 
    713713    return text.getText (); 
     
    811811 * </ul> 
    812812 */ 
    813 public int indexOf (char[] string) { 
     813public int indexOf (String string) { 
    814814    checkWidget (); 
    815815    if (string is null) DWT.error (DWT.ERROR_NULL_ARGUMENT); 
     
    835835 * </ul> 
    836836 */ 
    837 public int indexOf (char[] string, int start) { 
     837public int indexOf (String string, int start) { 
    838838    checkWidget (); 
    839839    if (string is null) DWT.error (DWT.ERROR_NULL_ARGUMENT); 
     
    844844    AccessibleAdapter accessibleAdapter = new class() AccessibleAdapter { 
    845845        public void getName (AccessibleEvent e) { 
    846             char[] name = null; 
     846            String name = null; 
    847847            Label label = getAssociatedLabel (); 
    848848            if (label !is null) { 
     
    852852        } 
    853853        public void getKeyboardShortcut(AccessibleEvent e) { 
    854             char[] shortcut = null; 
     854            String shortcut = null; 
    855855            Label label = getAssociatedLabel (); 
    856856            if (label !is null) { 
    857                 char[] text = label.getText (); 
     857                String text = label.getText (); 
    858858                if (text !is null) { 
    859859                    dchar mnemonic = _findMnemonic (text); 
     
    965965        case DWT.Dispose: 
    966966            if (getShell () !is popup.getParent ()) { 
    967                 char[][] items = list.getItems (); 
     967                String[] items = list.getItems (); 
    968968                int selectionIndex = list.getSelectionIndex (); 
    969969                popup = null; 
     
    11711171 * </ul> 
    11721172 */ 
    1173 public void remove (char[] string) { 
     1173public void remove (String string) { 
    11741174    checkWidget(); 
    11751175    if (string is null) DWT.error (DWT.ERROR_NULL_ARGUMENT); 
     
    13531353 * </ul> 
    13541354 */ 
    1355 public void setItem (int index, char[] string) { 
     1355public void setItem (int index, String string) { 
    13561356    checkWidget(); 
    13571357    list.setItem (index, string); 
     
    13711371 * </ul> 
    13721372 */ 
    1373 public void setItems (char[] [] items) { 
     1373public void setItems (String [] items) { 
    13741374    checkWidget (); 
    13751375    list.setItems (items); 
     
    14411441 * </ul> 
    14421442 */ 
    1443 public void setText (char[] string) { 
     1443public void setText (String string) { 
    14441444    checkWidget(); 
    14451445    if (string is null) DWT.error (DWT.ERROR_NULL_ARGUMENT); 
     
    14741474} 
    14751475 
    1476 public override void setToolTipText (char[] string) { 
     1476public override void setToolTipText (String string) { 
    14771477    checkWidget(); 
    14781478    super.setToolTipText(string); 
     
    15081508    visibleItemCount = count; 
    15091509} 
    1510 char[] stripMnemonic (char[] string) { 
     1510String stripMnemonic (String string) { 
    15111511    int index = 0; 
    15121512    int length_ = string.length;