Changeset 89

Show
Ignore:
Timestamp:
01/08/06 08:43:10 (3 years ago)
Author:
Shawn Liu
Message:

add method : Widget.setData(char[], char[])

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/current/win32/import/dwt/custom/busyindicator.d

    r82 r89  
    8484            if (id == busyId) { 
    8585                shells[i].setCursor(null); 
    86                 shells[i].setData(BUSYID_NAME, null); 
     86                shells[i].setData(BUSYID_NAME, cast(Object)null); 
    8787            } 
    8888        } 
  • trunk/current/win32/import/dwt/dnd/dragsource.d

    r82 r89  
    456456    } 
    457457    controlListener = null; 
    458     control.setData(DRAGSOURCEID, null); 
     458    control.setData(DRAGSOURCEID, cast(Object)null); 
    459459    control = null; 
    460460    transferAgents = null; 
  • trunk/current/win32/import/dwt/dnd/droptarget.d

    r82 r89  
    581581        control.removeListener(DWT.Dispose, controlListener); 
    582582    controlListener = null; 
    583     control.setData(DROPTARGETID, null); 
     583    control.setData(DROPTARGETID, cast(Object)null); 
    584584    transferAgents = null; 
    585585    control = null; 
  • trunk/current/win32/import/dwt/widgets/widget.d

    r82 r89  
    893893    checkWidget();   
    894894    this.singleData = data; 
    895      
    896895    // KEYED_DATA ignored    
    897     // if value is null, would we delete data[""]??? 
    898896} 
    899897 
     
    922920 * @see #getData 
    923921 */ 
    924  
    925 // Note : users don't map "" key to an object,or it will overwrite the one set by setObject() 
     922public void setData (char[] key, char[] value) { 
     923    if(value is null)  
     924        setData(key, cast(Object)null); 
     925    else 
     926        setData(key, new StringObj(value));  
     927
    926928public void setData (char[] key, Object value) {     
    927929    checkWidget();