Kernel-Transcript.deploy.js 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154
  1. (function(smalltalk,nil,_st){
  2. smalltalk.addPackage('Kernel-Transcript');
  3. smalltalk.addClass('ConsoleTranscript', smalltalk.Object, ['textarea'], 'Kernel-Transcript');
  4. smalltalk.addMethod(
  5. smalltalk.method({
  6. selector: "clear",
  7. fn: function (){
  8. var self=this;
  9. return smalltalk.withContext(function($ctx1) {
  10. return self}, function($ctx1) {$ctx1.fill(self,"clear",{},smalltalk.ConsoleTranscript)})},
  11. messageSends: []}),
  12. smalltalk.ConsoleTranscript);
  13. smalltalk.addMethod(
  14. smalltalk.method({
  15. selector: "cr",
  16. fn: function (){
  17. var self=this;
  18. return smalltalk.withContext(function($ctx1) {
  19. return self}, function($ctx1) {$ctx1.fill(self,"cr",{},smalltalk.ConsoleTranscript)})},
  20. messageSends: []}),
  21. smalltalk.ConsoleTranscript);
  22. smalltalk.addMethod(
  23. smalltalk.method({
  24. selector: "open",
  25. fn: function (){
  26. var self=this;
  27. return smalltalk.withContext(function($ctx1) {
  28. return self}, function($ctx1) {$ctx1.fill(self,"open",{},smalltalk.ConsoleTranscript)})},
  29. messageSends: []}),
  30. smalltalk.ConsoleTranscript);
  31. smalltalk.addMethod(
  32. smalltalk.method({
  33. selector: "show:",
  34. fn: function (anObject){
  35. var self=this;
  36. return smalltalk.withContext(function($ctx1) {
  37. console.log(String(_st(anObject)._asString()));
  38. return self}, function($ctx1) {$ctx1.fill(self,"show:",{anObject:anObject},smalltalk.ConsoleTranscript)})},
  39. messageSends: []}),
  40. smalltalk.ConsoleTranscript);
  41. smalltalk.addMethod(
  42. smalltalk.method({
  43. selector: "initialize",
  44. fn: function (){
  45. var self=this;
  46. function $Transcript(){return smalltalk.Transcript||(typeof Transcript=="undefined"?nil:Transcript)}
  47. return smalltalk.withContext(function($ctx1) {
  48. _st($Transcript())._register_(self._new());
  49. return self}, function($ctx1) {$ctx1.fill(self,"initialize",{},smalltalk.ConsoleTranscript.klass)})},
  50. messageSends: ["register:", "new"]}),
  51. smalltalk.ConsoleTranscript.klass);
  52. smalltalk.addClass('Transcript', smalltalk.Object, [], 'Kernel-Transcript');
  53. smalltalk.Transcript.klass.iVarNames = ['current'];
  54. smalltalk.addMethod(
  55. smalltalk.method({
  56. selector: "clear",
  57. fn: function (){
  58. var self=this;
  59. return smalltalk.withContext(function($ctx1) {
  60. _st(self._current())._clear();
  61. return self}, function($ctx1) {$ctx1.fill(self,"clear",{},smalltalk.Transcript.klass)})},
  62. messageSends: ["clear", "current"]}),
  63. smalltalk.Transcript.klass);
  64. smalltalk.addMethod(
  65. smalltalk.method({
  66. selector: "cr",
  67. fn: function (){
  68. var self=this;
  69. function $String(){return smalltalk.String||(typeof String=="undefined"?nil:String)}
  70. return smalltalk.withContext(function($ctx1) {
  71. _st(self._current())._show_(_st($String())._cr());
  72. return self}, function($ctx1) {$ctx1.fill(self,"cr",{},smalltalk.Transcript.klass)})},
  73. messageSends: ["show:", "cr", "current"]}),
  74. smalltalk.Transcript.klass);
  75. smalltalk.addMethod(
  76. smalltalk.method({
  77. selector: "current",
  78. fn: function (){
  79. var self=this;
  80. return smalltalk.withContext(function($ctx1) {
  81. var $1;
  82. $1=self["@current"];
  83. return $1;
  84. }, function($ctx1) {$ctx1.fill(self,"current",{},smalltalk.Transcript.klass)})},
  85. messageSends: []}),
  86. smalltalk.Transcript.klass);
  87. smalltalk.addMethod(
  88. smalltalk.method({
  89. selector: "inspect:",
  90. fn: function (anObject){
  91. var self=this;
  92. return smalltalk.withContext(function($ctx1) {
  93. self._show_(anObject);
  94. return self}, function($ctx1) {$ctx1.fill(self,"inspect:",{anObject:anObject},smalltalk.Transcript.klass)})},
  95. messageSends: ["show:"]}),
  96. smalltalk.Transcript.klass);
  97. smalltalk.addMethod(
  98. smalltalk.method({
  99. selector: "new",
  100. fn: function (){
  101. var self=this;
  102. return smalltalk.withContext(function($ctx1) {
  103. self._shouldNotImplement();
  104. return self}, function($ctx1) {$ctx1.fill(self,"new",{},smalltalk.Transcript.klass)})},
  105. messageSends: ["shouldNotImplement"]}),
  106. smalltalk.Transcript.klass);
  107. smalltalk.addMethod(
  108. smalltalk.method({
  109. selector: "open",
  110. fn: function (){
  111. var self=this;
  112. return smalltalk.withContext(function($ctx1) {
  113. _st(self._current())._open();
  114. return self}, function($ctx1) {$ctx1.fill(self,"open",{},smalltalk.Transcript.klass)})},
  115. messageSends: ["open", "current"]}),
  116. smalltalk.Transcript.klass);
  117. smalltalk.addMethod(
  118. smalltalk.method({
  119. selector: "register:",
  120. fn: function (aTranscript){
  121. var self=this;
  122. return smalltalk.withContext(function($ctx1) {
  123. self["@current"]=aTranscript;
  124. return self}, function($ctx1) {$ctx1.fill(self,"register:",{aTranscript:aTranscript},smalltalk.Transcript.klass)})},
  125. messageSends: []}),
  126. smalltalk.Transcript.klass);
  127. smalltalk.addMethod(
  128. smalltalk.method({
  129. selector: "show:",
  130. fn: function (anObject){
  131. var self=this;
  132. return smalltalk.withContext(function($ctx1) {
  133. _st(self._current())._show_(anObject);
  134. return self}, function($ctx1) {$ctx1.fill(self,"show:",{anObject:anObject},smalltalk.Transcript.klass)})},
  135. messageSends: ["show:", "current"]}),
  136. smalltalk.Transcript.klass);
  137. })(global_smalltalk,global_nil,global__st);