Helios-Commands.deploy.js 7.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403
  1. smalltalk.addPackage('Helios-Commands', {});
  2. smalltalk.addClass('HLCommand', smalltalk.Object, [], 'Helios-Commands');
  3. smalltalk.addMethod(
  4. "_asBinding",
  5. smalltalk.method({
  6. selector: "asBinding",
  7. fn: function () {
  8. var self = this;
  9. var $1;
  10. $1 = smalltalk.send(smalltalk.send(smalltalk.HLBindingAction || HLBindingAction, "_on_labelled_", [smalltalk.send(self, "_key", []), smalltalk.send(self, "_label", [])]), "_callback_", [function () {return smalltalk.send(self, "_execute", []);}]);
  11. return $1;
  12. }
  13. }),
  14. smalltalk.HLCommand);
  15. smalltalk.addMethod(
  16. "_documentation",
  17. smalltalk.method({
  18. selector: "documentation",
  19. fn: function () {
  20. var self = this;
  21. var $1;
  22. $1 = smalltalk.send(smalltalk.send(self, "_class", []), "_documentation", []);
  23. return $1;
  24. }
  25. }),
  26. smalltalk.HLCommand);
  27. smalltalk.addMethod(
  28. "_execute",
  29. smalltalk.method({
  30. selector: "execute",
  31. fn: function () {
  32. var self = this;
  33. return self;
  34. }
  35. }),
  36. smalltalk.HLCommand);
  37. smalltalk.addMethod(
  38. "_key",
  39. smalltalk.method({
  40. selector: "key",
  41. fn: function () {
  42. var self = this;
  43. var $1;
  44. $1 = smalltalk.send(smalltalk.send(self, "_class", []), "_key", []);
  45. return $1;
  46. }
  47. }),
  48. smalltalk.HLCommand);
  49. smalltalk.addMethod(
  50. "_label",
  51. smalltalk.method({
  52. selector: "label",
  53. fn: function () {
  54. var self = this;
  55. var $1;
  56. $1 = smalltalk.send(smalltalk.send(self, "_class", []), "_label", []);
  57. return $1;
  58. }
  59. }),
  60. smalltalk.HLCommand);
  61. smalltalk.addMethod(
  62. "_bindingGroup",
  63. smalltalk.method({
  64. selector: "bindingGroup",
  65. fn: function () {
  66. var self = this;
  67. return nil;
  68. }
  69. }),
  70. smalltalk.HLCommand.klass);
  71. smalltalk.addMethod(
  72. "_documentation",
  73. smalltalk.method({
  74. selector: "documentation",
  75. fn: function () {
  76. var self = this;
  77. return "";
  78. }
  79. }),
  80. smalltalk.HLCommand.klass);
  81. smalltalk.addMethod(
  82. "_key",
  83. smalltalk.method({
  84. selector: "key",
  85. fn: function () {
  86. var self = this;
  87. return nil;
  88. }
  89. }),
  90. smalltalk.HLCommand.klass);
  91. smalltalk.addMethod(
  92. "_label",
  93. smalltalk.method({
  94. selector: "label",
  95. fn: function () {
  96. var self = this;
  97. return "";
  98. }
  99. }),
  100. smalltalk.HLCommand.klass);
  101. smalltalk.addClass('HLBrowserCommand', smalltalk.HLCommand, ['model'], 'Helios-Commands');
  102. smalltalk.addMethod(
  103. "_model",
  104. smalltalk.method({
  105. selector: "model",
  106. fn: function () {
  107. var self = this;
  108. return self['@model'];
  109. }
  110. }),
  111. smalltalk.HLBrowserCommand);
  112. smalltalk.addMethod(
  113. "_model_",
  114. smalltalk.method({
  115. selector: "model:",
  116. fn: function (aBrowserModel) {
  117. var self = this;
  118. self['@model'] = aBrowserModel;
  119. return self;
  120. }
  121. }),
  122. smalltalk.HLBrowserCommand);
  123. smalltalk.addMethod(
  124. "_on_",
  125. smalltalk.method({
  126. selector: "on:",
  127. fn: function (aBrowserModel) {
  128. var self = this;
  129. var $2, $3, $1;
  130. $2 = smalltalk.send(self, "_new", []);
  131. smalltalk.send($2, "_model_", [aBrowserModel]);
  132. $3 = smalltalk.send($2, "_yourself", []);
  133. $1 = $3;
  134. return $1;
  135. }
  136. }),
  137. smalltalk.HLBrowserCommand.klass);
  138. smalltalk.addClass('HLGoToCommand', smalltalk.HLBrowserCommand, [], 'Helios-Commands');
  139. smalltalk.addMethod(
  140. "_bindingGroup",
  141. smalltalk.method({
  142. selector: "bindingGroup",
  143. fn: function () {
  144. var self = this;
  145. return "Go to";
  146. }
  147. }),
  148. smalltalk.HLGoToCommand.klass);
  149. smalltalk.addClass('HLGoToClassesCommand', smalltalk.HLGoToCommand, [], 'Helios-Commands');
  150. smalltalk.addMethod(
  151. "_execute",
  152. smalltalk.method({
  153. selector: "execute",
  154. fn: function () {
  155. var self = this;
  156. smalltalk.send(smalltalk.send(self, "_model", []), "_selectedClass_", [smalltalk.send(smalltalk.send(self, "_model", []), "_selectedClass", [])]);
  157. return self;
  158. }
  159. }),
  160. smalltalk.HLGoToClassesCommand);
  161. smalltalk.addMethod(
  162. "_key",
  163. smalltalk.method({
  164. selector: "key",
  165. fn: function () {
  166. var self = this;
  167. return 67;
  168. }
  169. }),
  170. smalltalk.HLGoToClassesCommand.klass);
  171. smalltalk.addMethod(
  172. "_label",
  173. smalltalk.method({
  174. selector: "label",
  175. fn: function () {
  176. var self = this;
  177. return "Classes";
  178. }
  179. }),
  180. smalltalk.HLGoToClassesCommand.klass);
  181. smalltalk.addClass('HLGoToMethodsCommand', smalltalk.HLGoToCommand, [], 'Helios-Commands');
  182. smalltalk.addMethod(
  183. "_execute",
  184. smalltalk.method({
  185. selector: "execute",
  186. fn: function () {
  187. var self = this;
  188. smalltalk.send(smalltalk.send(self, "_model", []), "_selectedMethod_", [smalltalk.send(smalltalk.send(self, "_model", []), "_selectedMethod", [])]);
  189. return self;
  190. }
  191. }),
  192. smalltalk.HLGoToMethodsCommand);
  193. smalltalk.addMethod(
  194. "_key",
  195. smalltalk.method({
  196. selector: "key",
  197. fn: function () {
  198. var self = this;
  199. return 77;
  200. }
  201. }),
  202. smalltalk.HLGoToMethodsCommand.klass);
  203. smalltalk.addMethod(
  204. "_label",
  205. smalltalk.method({
  206. selector: "label",
  207. fn: function () {
  208. var self = this;
  209. return "Methods";
  210. }
  211. }),
  212. smalltalk.HLGoToMethodsCommand.klass);
  213. smalltalk.addClass('HLGoToPackagesCommand', smalltalk.HLGoToCommand, [], 'Helios-Commands');
  214. smalltalk.addMethod(
  215. "_execute",
  216. smalltalk.method({
  217. selector: "execute",
  218. fn: function () {
  219. var self = this;
  220. smalltalk.send(smalltalk.send(self, "_model", []), "_selectedPackage_", [smalltalk.send(smalltalk.send(self, "_model", []), "_selectedPackage", [])]);
  221. return self;
  222. }
  223. }),
  224. smalltalk.HLGoToPackagesCommand);
  225. smalltalk.addMethod(
  226. "_key",
  227. smalltalk.method({
  228. selector: "key",
  229. fn: function () {
  230. var self = this;
  231. return 80;
  232. }
  233. }),
  234. smalltalk.HLGoToPackagesCommand.klass);
  235. smalltalk.addMethod(
  236. "_label",
  237. smalltalk.method({
  238. selector: "label",
  239. fn: function () {
  240. var self = this;
  241. return "Packages";
  242. }
  243. }),
  244. smalltalk.HLGoToPackagesCommand.klass);
  245. smalltalk.addClass('HLGoToProtocolsCommand', smalltalk.HLGoToCommand, [], 'Helios-Commands');
  246. smalltalk.addMethod(
  247. "_execute",
  248. smalltalk.method({
  249. selector: "execute",
  250. fn: function () {
  251. var self = this;
  252. smalltalk.send(smalltalk.send(self, "_model", []), "_selectedProtocol_", [smalltalk.send(smalltalk.send(self, "_model", []), "_selectedProtocol", [])]);
  253. return self;
  254. }
  255. }),
  256. smalltalk.HLGoToProtocolsCommand);
  257. smalltalk.addMethod(
  258. "_key",
  259. smalltalk.method({
  260. selector: "key",
  261. fn: function () {
  262. var self = this;
  263. return 84;
  264. }
  265. }),
  266. smalltalk.HLGoToProtocolsCommand.klass);
  267. smalltalk.addMethod(
  268. "_label",
  269. smalltalk.method({
  270. selector: "label",
  271. fn: function () {
  272. var self = this;
  273. return "Protocols";
  274. }
  275. }),
  276. smalltalk.HLGoToProtocolsCommand.klass);
  277. smalltalk.addClass('HLToggleCommand', smalltalk.HLBrowserCommand, [], 'Helios-Commands');
  278. smalltalk.addMethod(
  279. "_bindingGroup",
  280. smalltalk.method({
  281. selector: "bindingGroup",
  282. fn: function () {
  283. var self = this;
  284. return "Toggle";
  285. }
  286. }),
  287. smalltalk.HLToggleCommand.klass);
  288. smalltalk.addClass('HLToggleClassSideCommand', smalltalk.HLToggleCommand, [], 'Helios-Commands');
  289. smalltalk.addMethod(
  290. "_execute",
  291. smalltalk.method({
  292. selector: "execute",
  293. fn: function () {
  294. var self = this;
  295. smalltalk.send(smalltalk.send(self, "_model", []), "_showInstance_", [false]);
  296. return self;
  297. }
  298. }),
  299. smalltalk.HLToggleClassSideCommand);
  300. smalltalk.addMethod(
  301. "_key",
  302. smalltalk.method({
  303. selector: "key",
  304. fn: function () {
  305. var self = this;
  306. return 67;
  307. }
  308. }),
  309. smalltalk.HLToggleClassSideCommand.klass);
  310. smalltalk.addMethod(
  311. "_label",
  312. smalltalk.method({
  313. selector: "label",
  314. fn: function () {
  315. var self = this;
  316. return "Class side";
  317. }
  318. }),
  319. smalltalk.HLToggleClassSideCommand.klass);
  320. smalltalk.addClass('HLToggleInstanceSideCommand', smalltalk.HLToggleCommand, [], 'Helios-Commands');
  321. smalltalk.addMethod(
  322. "_execute",
  323. smalltalk.method({
  324. selector: "execute",
  325. fn: function () {
  326. var self = this;
  327. smalltalk.send(smalltalk.send(self, "_model", []), "_showInstance_", [true]);
  328. return self;
  329. }
  330. }),
  331. smalltalk.HLToggleInstanceSideCommand);
  332. smalltalk.addMethod(
  333. "_key",
  334. smalltalk.method({
  335. selector: "key",
  336. fn: function () {
  337. var self = this;
  338. return 73;
  339. }
  340. }),
  341. smalltalk.HLToggleInstanceSideCommand.klass);
  342. smalltalk.addMethod(
  343. "_label",
  344. smalltalk.method({
  345. selector: "label",
  346. fn: function () {
  347. var self = this;
  348. return "Instance side";
  349. }
  350. }),
  351. smalltalk.HLToggleInstanceSideCommand.klass);