Mercurial > projects > dwt-mac
diff dwt/internal/cocoa/NSMenuItem.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 | f565d3a95c0a |
line wrap: on
line diff
--- a/dwt/internal/cocoa/NSMenuItem.d Sat Aug 09 17:00:02 2008 +0200 +++ b/dwt/internal/cocoa/NSMenuItem.d Tue Aug 19 17:35:17 2008 +0200 @@ -39,117 +39,117 @@ public objc.SEL action () { - return OS.objc_msgSend(this.id, OS.sel_action); + return cast(objc.SEL) OS.objc_msgSend(this.id_, OS.sel_action); } public NSAttributedString attributedTitle () { - objc.id result = OS.objc_msgSend(this.id, OS.sel_attributedTitle); + objc.id result = OS.objc_msgSend(this.id_, OS.sel_attributedTitle); return result !is null ? new NSAttributedString(result) : null; } public bool hasSubmenu () { - return OS.objc_msgSend(this.id, OS.sel_hasSubmenu) !is null; + return OS.objc_msgSend(this.id_, OS.sel_hasSubmenu) !is null; } public NSImage image () { - objc.id result = OS.objc_msgSend(this.id, OS.sel_image); + objc.id result = OS.objc_msgSend(this.id_, OS.sel_image); return result !is null ? new NSImage(result) : null; } public NSInteger indentationLevel () { - return OS.objc_msgSend(this.id, OS.sel_indentationLevel); + return cast(NSInteger) OS.objc_msgSend(this.id_, OS.sel_indentationLevel); } public NSMenuItem initWithTitle (NSString aString, objc.SEL aSelector, NSString charCode) { - objc.id result = OS.objc_msgSend(this.id, OS.sel_initWithTitle_1action_1keyEquivalent_1, aString !is null ? aString.id : null, aSelector, - charCode !is null ? charCode.id : null); + objc.id result = OS.objc_msgSend(this.id_, OS.sel_initWithTitle_1action_1keyEquivalent_1, aString !is null ? aString.id_ : null, aSelector, + charCode !is null ? charCode.id_ : null); return result !is null ? this : null; } public bool isAlternate () { - return OS.objc_msgSend(this.id, OS.sel_isAlternate) !is null; + return OS.objc_msgSend(this.id_, OS.sel_isAlternate) !is null; } public bool isEnabled () { - return OS.objc_msgSend(this.id, OS.sel_isEnabled) !is null; + return OS.objc_msgSend(this.id_, OS.sel_isEnabled) !is null; } public bool isHidden () { - return OS.objc_msgSend(this.id, OS.sel_isHidden) !is null; + return OS.objc_msgSend(this.id_, OS.sel_isHidden) !is null; } public bool isHiddenOrHasHiddenAncestor () { - return OS.objc_msgSend(this.id, OS.sel_isHiddenOrHasHiddenAncestor) !is null; + return OS.objc_msgSend(this.id_, OS.sel_isHiddenOrHasHiddenAncestor) !is null; } public bool isHighlighted () { - return OS.objc_msgSend(this.id, OS.sel_isHighlighted) !is null; + return OS.objc_msgSend(this.id_, OS.sel_isHighlighted) !is null; } public bool isSeparatorItem () { - return OS.objc_msgSend(this.id, OS.sel_isSeparatorItem) !is null; + return OS.objc_msgSend(this.id_, OS.sel_isSeparatorItem) !is null; } public NSString keyEquivalent () { - objc.id result = OS.objc_msgSend(this.id, OS.sel_keyEquivalent); + objc.id result = OS.objc_msgSend(this.id_, OS.sel_keyEquivalent); return result !is null ? new NSString(result) : null; } public NSUInteger keyEquivalentModifierMask () { - return OS.objc_msgSend(this.id, OS.sel_keyEquivalentModifierMask); + return cast(NSUInteger) OS.objc_msgSend(this.id_, OS.sel_keyEquivalentModifierMask); } public NSMenu menu () { - objc.id result = OS.objc_msgSend(this.id, OS.sel_menu); + objc.id result = OS.objc_msgSend(this.id_, OS.sel_menu); return result !is null ? new NSMenu(result) : null; } public NSImage mixedStateImage () { - objc.id result = OS.objc_msgSend(this.id, OS.sel_mixedStateImage); + objc.id result = OS.objc_msgSend(this.id_, OS.sel_mixedStateImage); return result !is null ? new NSImage(result) : null; } public NSString mnemonic () { - objc.id result = OS.objc_msgSend(this.id, OS.sel_mnemonic); + objc.id result = OS.objc_msgSend(this.id_, OS.sel_mnemonic); return result !is null ? new NSString(result) : null; } public NSUInteger mnemonicLocation () { - return OS.objc_msgSend(this.id, OS.sel_mnemonicLocation); + return cast(NSUInteger) OS.objc_msgSend(this.id_, OS.sel_mnemonicLocation); } public NSImage offStateImage () { - objc.id result = OS.objc_msgSend(this.id, OS.sel_offStateImage); + objc.id result = OS.objc_msgSend(this.id_, OS.sel_offStateImage); return result !is null ? new NSImage(result) : null; } public NSImage onStateImage () { - objc.id result = OS.objc_msgSend(this.id, OS.sel_onStateImage); + objc.id result = OS.objc_msgSend(this.id_, OS.sel_onStateImage); return result !is null ? new NSImage(result) : null; } public id representedObject () { - objc.id result = OS.objc_msgSend(this.id, OS.sel_representedObject); + objc.id result = OS.objc_msgSend(this.id_, OS.sel_representedObject); return result !is null ? new id(result) : null; } @@ -161,112 +161,112 @@ public void setAction (objc.SEL aSelector) { - OS.objc_msgSend(this.id, OS.sel_setAction_1, aSelector); + OS.objc_msgSend(this.id_, OS.sel_setAction_1, aSelector); } public void setAlternate (bool isAlternate) { - OS.objc_msgSend(this.id, OS.sel_setAlternate_1, isAlternate); + OS.objc_msgSend(this.id_, OS.sel_setAlternate_1, isAlternate); } public void setAttributedTitle (NSAttributedString string) { - OS.objc_msgSend(this.id, OS.sel_setAttributedTitle_1, string !is null ? string.id : null); + OS.objc_msgSend(this.id_, OS.sel_setAttributedTitle_1, string !is null ? string.id_ : null); } public void setEnabled (bool flag) { - OS.objc_msgSend(this.id, OS.sel_setEnabled_1, flag); + OS.objc_msgSend(this.id_, OS.sel_setEnabled_1, flag); } public void setHidden (bool hidden) { - OS.objc_msgSend(this.id, OS.sel_setHidden_1, hidden); + OS.objc_msgSend(this.id_, OS.sel_setHidden_1, hidden); } public void setImage (NSImage menuImage) { - OS.objc_msgSend(this.id, OS.sel_setImage_1, menuImage !is null ? menuImage.id : null); + OS.objc_msgSend(this.id_, OS.sel_setImage_1, menuImage !is null ? menuImage.id_ : null); } public void setIndentationLevel (NSInteger indentationLevel) { - OS.objc_msgSend(this.id, OS.sel_setIndentationLevel_1, indentationLevel); + OS.objc_msgSend(this.id_, OS.sel_setIndentationLevel_1, indentationLevel); } public void setKeyEquivalent (NSString aKeyEquivalent) { - OS.objc_msgSend(this.id, OS.sel_setKeyEquivalent_1, aKeyEquivalent !is null ? aKeyEquivalent.id : null); + OS.objc_msgSend(this.id_, OS.sel_setKeyEquivalent_1, aKeyEquivalent !is null ? aKeyEquivalent.id_ : null); } public void setKeyEquivalentModifierMask (NSUInteger mask) { - OS.objc_msgSend(this.id, OS.sel_setKeyEquivalentModifierMask_1, mask); + OS.objc_msgSend(this.id_, OS.sel_setKeyEquivalentModifierMask_1, mask); } public void setMenu (NSMenu menu) { - OS.objc_msgSend(this.id, OS.sel_setMenu_1, menu !is null ? menu.id : null); + OS.objc_msgSend(this.id_, OS.sel_setMenu_1, menu !is null ? menu.id_ : null); } public void setMixedStateImage (NSImage image) { - OS.objc_msgSend(this.id, OS.sel_setMixedStateImage_1, image !is null ? image.id : null); + OS.objc_msgSend(this.id_, OS.sel_setMixedStateImage_1, image !is null ? image.id_ : null); } public void setMnemonicLocation (NSUInteger location) { - OS.objc_msgSend(this.id, OS.sel_setMnemonicLocation_1, location); + OS.objc_msgSend(this.id_, OS.sel_setMnemonicLocation_1, location); } public void setOffStateImage (NSImage image) { - OS.objc_msgSend(this.id, OS.sel_setOffStateImage_1, image !is null ? image.id : null); + OS.objc_msgSend(this.id_, OS.sel_setOffStateImage_1, image !is null ? image.id_ : null); } public void setOnStateImage (NSImage image) { - OS.objc_msgSend(this.id, OS.sel_setOnStateImage_1, image !is null ? image.id : null); + OS.objc_msgSend(this.id_, OS.sel_setOnStateImage_1, image !is null ? image.id_ : null); } public void setRepresentedObject (id anObject) { - OS.objc_msgSend(this.id, OS.sel_setRepresentedObject_1, anObject !is null ? anObject.id : null); + OS.objc_msgSend(this.id_, OS.sel_setRepresentedObject_1, anObject !is null ? anObject.id_ : null); } public void setState (NSInteger state) { - OS.objc_msgSend(this.id, OS.sel_setState_1, state); + OS.objc_msgSend(this.id_, OS.sel_setState_1, state); } public void setSubmenu (NSMenu submenu) { - OS.objc_msgSend(this.id, OS.sel_setSubmenu_1, submenu !is null ? submenu.id : null); + OS.objc_msgSend(this.id_, OS.sel_setSubmenu_1, submenu !is null ? submenu.id_ : null); } public void setTag (NSInteger anInt) { - OS.objc_msgSend(this.id, OS.sel_setTag_1, anInt); + OS.objc_msgSend(this.id_, OS.sel_setTag_1, anInt); } public void setTarget (id anObject) { - OS.objc_msgSend(this.id, OS.sel_setTarget_1, anObject !is null ? anObject.id : null); + OS.objc_msgSend(this.id_, OS.sel_setTarget_1, anObject !is null ? anObject.id_ : null); } public void setTitle (NSString aString) { - OS.objc_msgSend(this.id, OS.sel_setTitle_1, aString !is null ? aString.id : null); + OS.objc_msgSend(this.id_, OS.sel_setTitle_1, aString !is null ? aString.id_ : null); } public void setTitleWithMnemonic (NSString stringWithAmpersand) { - OS.objc_msgSend(this.id, OS.sel_setTitleWithMnemonic_1, stringWithAmpersand !is null ? stringWithAmpersand.id : null); + OS.objc_msgSend(this.id_, OS.sel_setTitleWithMnemonic_1, stringWithAmpersand !is null ? stringWithAmpersand.id_ : null); } public void setToolTip (NSString toolTip) { - OS.objc_msgSend(this.id, OS.sel_setToolTip_1, toolTip !is null ? toolTip.id : null); + OS.objc_msgSend(this.id_, OS.sel_setToolTip_1, toolTip !is null ? toolTip.id_ : null); } public static void setUsesUserKeyEquivalents (bool flag) @@ -276,46 +276,46 @@ public void setView (NSView view) { - OS.objc_msgSend(this.id, OS.sel_setView_1, view !is null ? view.id : null); + OS.objc_msgSend(this.id_, OS.sel_setView_1, view !is null ? view.id_ : null); } public NSInteger state () { - return OS.objc_msgSend(this.id, OS.sel_state); + return cast(NSInteger) OS.objc_msgSend(this.id_, OS.sel_state); } public NSMenu submenu () { - objc.id result = OS.objc_msgSend(this.id, OS.sel_submenu); + objc.id result = OS.objc_msgSend(this.id_, OS.sel_submenu); return result !is null ? new NSMenu(result) : null; } public NSInteger tag () { - return OS.objc_msgSend(this.id, OS.sel_tag); + return cast(NSInteger) OS.objc_msgSend(this.id_, OS.sel_tag); } public id target () { - objc.id result = OS.objc_msgSend(this.id, OS.sel_target); + objc.id result = OS.objc_msgSend(this.id_, OS.sel_target); return result !is null ? new id(result) : null; } public NSString title () { - objc.id result = OS.objc_msgSend(this.id, OS.sel_title); + objc.id result = OS.objc_msgSend(this.id_, OS.sel_title); return result !is null ? new NSString(result) : null; } public NSString toolTip () { - objc.id result = OS.objc_msgSend(this.id, OS.sel_toolTip); + objc.id result = OS.objc_msgSend(this.id_, OS.sel_toolTip); return result !is null ? new NSString(result) : null; } public NSString userKeyEquivalent () { - objc.id result = OS.objc_msgSend(this.id, OS.sel_userKeyEquivalent); + objc.id result = OS.objc_msgSend(this.id_, OS.sel_userKeyEquivalent); return result !is null ? new NSString(result) : null; } @@ -326,7 +326,7 @@ public NSView view () { - objc.id result = OS.objc_msgSend(this.id, OS.sel_view); + objc.id result = OS.objc_msgSend(this.id_, OS.sel_view); return result !is null ? new NSView(result) : null; }