Mercurial > projects > dwt-mac
comparison dwt/internal/cocoa/NSScriptCommand.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 |
comparison
equal
deleted
inserted
replaced
0:380af2bdd8e5 | 1:8b48be5454ce |
---|---|
36 super(id); | 36 super(id); |
37 } | 37 } |
38 | 38 |
39 public NSAppleEventDescriptor appleEvent () | 39 public NSAppleEventDescriptor appleEvent () |
40 { | 40 { |
41 objc.id result = OS.objc_msgSend(this.id, OS.sel_appleEvent); | 41 objc.id result = OS.objc_msgSend(this.id_, OS.sel_appleEvent); |
42 return result !is null ? new NSAppleEventDescriptor(result) : null; | 42 return result !is null ? new NSAppleEventDescriptor(result) : null; |
43 } | 43 } |
44 | 44 |
45 public NSDictionary arguments () | 45 public NSDictionary arguments () |
46 { | 46 { |
47 objc.id result = OS.objc_msgSend(this.id, OS.sel_arguments); | 47 objc.id result = OS.objc_msgSend(this.id_, OS.sel_arguments); |
48 return result !is null ? new NSDictionary(result) : null; | 48 return result !is null ? new NSDictionary(result) : null; |
49 } | 49 } |
50 | 50 |
51 public NSScriptCommandDescription commandDescription () | 51 public NSScriptCommandDescription commandDescription () |
52 { | 52 { |
53 objc.id result = OS.objc_msgSend(this.id, OS.sel_commandDescription); | 53 objc.id result = OS.objc_msgSend(this.id_, OS.sel_commandDescription); |
54 return result !is null ? new NSScriptCommandDescription(result) : null; | 54 return result !is null ? new NSScriptCommandDescription(result) : null; |
55 } | 55 } |
56 | 56 |
57 public static NSScriptCommand currentCommand () | 57 public static NSScriptCommand currentCommand () |
58 { | 58 { |
60 return result !is null ? new NSScriptCommand(result) : null; | 60 return result !is null ? new NSScriptCommand(result) : null; |
61 } | 61 } |
62 | 62 |
63 public id directParameter () | 63 public id directParameter () |
64 { | 64 { |
65 objc.id result = OS.objc_msgSend(this.id, OS.sel_directParameter); | 65 objc.id result = OS.objc_msgSend(this.id_, OS.sel_directParameter); |
66 return result !is null ? new id(result) : null; | 66 return result !is null ? new id(result) : null; |
67 } | 67 } |
68 | 68 |
69 public NSDictionary evaluatedArguments () | 69 public NSDictionary evaluatedArguments () |
70 { | 70 { |
71 objc.id result = OS.objc_msgSend(this.id, OS.sel_evaluatedArguments); | 71 objc.id result = OS.objc_msgSend(this.id_, OS.sel_evaluatedArguments); |
72 return result !is null ? new NSDictionary(result) : null; | 72 return result !is null ? new NSDictionary(result) : null; |
73 } | 73 } |
74 | 74 |
75 public id evaluatedReceivers () | 75 public id evaluatedReceivers () |
76 { | 76 { |
77 objc.id result = OS.objc_msgSend(this.id, OS.sel_evaluatedReceivers); | 77 objc.id result = OS.objc_msgSend(this.id_, OS.sel_evaluatedReceivers); |
78 return result !is null ? new id(result) : null; | 78 return result !is null ? new id(result) : null; |
79 } | 79 } |
80 | 80 |
81 public id executeCommand () | 81 public id executeCommand () |
82 { | 82 { |
83 objc.id result = OS.objc_msgSend(this.id, OS.sel_executeCommand); | 83 objc.id result = OS.objc_msgSend(this.id_, OS.sel_executeCommand); |
84 return result !is null ? new id(result) : null; | 84 return result !is null ? new id(result) : null; |
85 } | 85 } |
86 | 86 |
87 public id initWithCommandDescription (NSScriptCommandDescription commandDef) | 87 public id initWithCommandDescription (NSScriptCommandDescription commandDef) |
88 { | 88 { |
89 objc.id result = OS.objc_msgSend(this.id, OS.sel_initWithCommandDescription_1, commandDef !is null ? commandDef.id : null); | 89 objc.id result = OS.objc_msgSend(this.id_, OS.sel_initWithCommandDescription_1, commandDef !is null ? commandDef.id_ : null); |
90 return result !is null ? new id(result) : null; | 90 return result !is null ? new id(result) : null; |
91 } | 91 } |
92 | 92 |
93 public bool isWellFormed () | 93 public bool isWellFormed () |
94 { | 94 { |
95 return OS.objc_msgSend(this.id, OS.sel_isWellFormed) !is null; | 95 return OS.objc_msgSend(this.id_, OS.sel_isWellFormed) !is null; |
96 } | 96 } |
97 | 97 |
98 public id performDefaultImplementation () | 98 public id performDefaultImplementation () |
99 { | 99 { |
100 objc.id result = OS.objc_msgSend(this.id, OS.sel_performDefaultImplementation); | 100 objc.id result = OS.objc_msgSend(this.id_, OS.sel_performDefaultImplementation); |
101 return result !is null ? new id(result) : null; | 101 return result !is null ? new id(result) : null; |
102 } | 102 } |
103 | 103 |
104 public NSScriptObjectSpecifier receiversSpecifier () | 104 public NSScriptObjectSpecifier receiversSpecifier () |
105 { | 105 { |
106 objc.id result = OS.objc_msgSend(this.id, OS.sel_receiversSpecifier); | 106 objc.id result = OS.objc_msgSend(this.id_, OS.sel_receiversSpecifier); |
107 return result !is null ? new NSScriptObjectSpecifier(result) : null; | 107 return result !is null ? new NSScriptObjectSpecifier(result) : null; |
108 } | 108 } |
109 | 109 |
110 public void resumeExecutionWithResult (id result) | 110 public void resumeExecutionWithResult (id result) |
111 { | 111 { |
112 OS.objc_msgSend(this.id, OS.sel_resumeExecutionWithResult_1, result !is null ? result.id : null); | 112 OS.objc_msgSend(this.id_, OS.sel_resumeExecutionWithResult_1, result !is null ? result.id_ : null); |
113 } | 113 } |
114 | 114 |
115 public NSAppleEventDescriptor scriptErrorExpectedTypeDescriptor () | 115 public NSAppleEventDescriptor scriptErrorExpectedTypeDescriptor () |
116 { | 116 { |
117 objc.id result = OS.objc_msgSend(this.id, OS.sel_scriptErrorExpectedTypeDescriptor); | 117 objc.id result = OS.objc_msgSend(this.id_, OS.sel_scriptErrorExpectedTypeDescriptor); |
118 return result !is null ? new NSAppleEventDescriptor(result) : null; | 118 return result !is null ? new NSAppleEventDescriptor(result) : null; |
119 } | 119 } |
120 | 120 |
121 public int scriptErrorNumber () | 121 public int scriptErrorNumber () |
122 { | 122 { |
123 return cast(int) OS.objc_msgSend(this.id, OS.sel_scriptErrorNumber); | 123 return cast(int) OS.objc_msgSend(this.id_, OS.sel_scriptErrorNumber); |
124 } | 124 } |
125 | 125 |
126 public NSAppleEventDescriptor scriptErrorOffendingObjectDescriptor () | 126 public NSAppleEventDescriptor scriptErrorOffendingObjectDescriptor () |
127 { | 127 { |
128 objc.id result = OS.objc_msgSend(this.id, OS.sel_scriptErrorOffendingObjectDescriptor); | 128 objc.id result = OS.objc_msgSend(this.id_, OS.sel_scriptErrorOffendingObjectDescriptor); |
129 return result !is null ? new NSAppleEventDescriptor(result) : null; | 129 return result !is null ? new NSAppleEventDescriptor(result) : null; |
130 } | 130 } |
131 | 131 |
132 public NSString scriptErrorString () | 132 public NSString scriptErrorString () |
133 { | 133 { |
134 objc.id result = OS.objc_msgSend(this.id, OS.sel_scriptErrorString); | 134 objc.id result = OS.objc_msgSend(this.id_, OS.sel_scriptErrorString); |
135 return result !is null ? new NSString(result) : null; | 135 return result !is null ? new NSString(result) : null; |
136 } | 136 } |
137 | 137 |
138 public void setArguments (NSDictionary args) | 138 public void setArguments (NSDictionary args) |
139 { | 139 { |
140 OS.objc_msgSend(this.id, OS.sel_setArguments_1, args !is null ? args.id : null); | 140 OS.objc_msgSend(this.id_, OS.sel_setArguments_1, args !is null ? args.id_ : null); |
141 } | 141 } |
142 | 142 |
143 public void setDirectParameter (id directParameter) | 143 public void setDirectParameter (id directParameter) |
144 { | 144 { |
145 OS.objc_msgSend(this.id, OS.sel_setDirectParameter_1, directParameter !is null ? directParameter.id : null); | 145 OS.objc_msgSend(this.id_, OS.sel_setDirectParameter_1, directParameter !is null ? directParameter.id_ : null); |
146 } | 146 } |
147 | 147 |
148 public void setReceiversSpecifier (NSScriptObjectSpecifier receiversRef) | 148 public void setReceiversSpecifier (NSScriptObjectSpecifier receiversRef) |
149 { | 149 { |
150 OS.objc_msgSend(this.id, OS.sel_setReceiversSpecifier_1, receiversRef !is null ? receiversRef.id : null); | 150 OS.objc_msgSend(this.id_, OS.sel_setReceiversSpecifier_1, receiversRef !is null ? receiversRef.id_ : null); |
151 } | 151 } |
152 | 152 |
153 public void setScriptErrorExpectedTypeDescriptor (NSAppleEventDescriptor errorExpectedTypeDescriptor) | 153 public void setScriptErrorExpectedTypeDescriptor (NSAppleEventDescriptor errorExpectedTypeDescriptor) |
154 { | 154 { |
155 OS.objc_msgSend(this.id, OS.sel_setScriptErrorExpectedTypeDescriptor_1, | 155 OS.objc_msgSend(this.id_, OS.sel_setScriptErrorExpectedTypeDescriptor_1, |
156 errorExpectedTypeDescriptor !is null ? errorExpectedTypeDescriptor.id : null); | 156 errorExpectedTypeDescriptor !is null ? errorExpectedTypeDescriptor.id_ : null); |
157 } | 157 } |
158 | 158 |
159 public void setScriptErrorNumber (int errorNumber) | 159 public void setScriptErrorNumber (int errorNumber) |
160 { | 160 { |
161 OS.objc_msgSend(this.id, OS.sel_setScriptErrorNumber_1, errorNumber); | 161 OS.objc_msgSend(this.id_, OS.sel_setScriptErrorNumber_1, errorNumber); |
162 } | 162 } |
163 | 163 |
164 public void setScriptErrorOffendingObjectDescriptor (NSAppleEventDescriptor errorOffendingObjectDescriptor) | 164 public void setScriptErrorOffendingObjectDescriptor (NSAppleEventDescriptor errorOffendingObjectDescriptor) |
165 { | 165 { |
166 OS.objc_msgSend(this.id, OS.sel_setScriptErrorOffendingObjectDescriptor_1, | 166 OS.objc_msgSend(this.id_, OS.sel_setScriptErrorOffendingObjectDescriptor_1, |
167 errorOffendingObjectDescriptor !is null ? errorOffendingObjectDescriptor.id : null); | 167 errorOffendingObjectDescriptor !is null ? errorOffendingObjectDescriptor.id_ : null); |
168 } | 168 } |
169 | 169 |
170 public void setScriptErrorString (NSString errorString) | 170 public void setScriptErrorString (NSString errorString) |
171 { | 171 { |
172 OS.objc_msgSend(this.id, OS.sel_setScriptErrorString_1, errorString !is null ? errorString.id : null); | 172 OS.objc_msgSend(this.id_, OS.sel_setScriptErrorString_1, errorString !is null ? errorString.id_ : null); |
173 } | 173 } |
174 | 174 |
175 public void suspendExecution () | 175 public void suspendExecution () |
176 { | 176 { |
177 OS.objc_msgSend(this.id, OS.sel_suspendExecution); | 177 OS.objc_msgSend(this.id_, OS.sel_suspendExecution); |
178 } | 178 } |
179 | 179 |
180 } | 180 } |