Canvas.js 112 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014
  1. define("amber_core/Canvas", ["amber_vm/smalltalk", "amber_vm/nil", "amber_vm/_st", "amber_core/Kernel-Objects", "amber_core/Kernel-Infrastructure", "amber_core/Kernel-Methods", "amber_core/Kernel-Collections"], function(smalltalk,nil,_st){
  2. smalltalk.addPackage('Canvas');
  3. smalltalk.packages["Canvas"].transport = {"type":"amd","amdNamespace":"amber_core"};
  4. smalltalk.addClass('BrowserInterface', smalltalk.Object, [], 'Canvas');
  5. smalltalk.BrowserInterface.comment="I am platform interface class that tries to use window and jQuery; that is, one for browser environment.\x0a\x0a## API\x0a\x0a self isAvailable. \x22true if window and jQuery exist\x22.\x0a\x0a self alert: 'Hey, there is a problem'.\x0a self confirm: 'Affirmative?'.\x0a self prompt: 'Your name:'.\x0a\x0a self ajax: #{\x0a 'url' -> '/patch.js'. 'type' -> 'GET'. dataType->'script'\x0a }.";
  6. smalltalk.addMethod(
  7. smalltalk.method({
  8. selector: "ajax:",
  9. category: 'actions',
  10. fn: function (anObject){
  11. var self=this;
  12. return smalltalk.withContext(function($ctx1) {
  13. var $1;
  14. $1=_st(jQuery)._ajax_(anObject);
  15. return $1;
  16. }, function($ctx1) {$ctx1.fill(self,"ajax:",{anObject:anObject},smalltalk.BrowserInterface)})},
  17. args: ["anObject"],
  18. source: "ajax: anObject\x0a\x09^jQuery ajax: anObject",
  19. messageSends: ["ajax:"],
  20. referencedClasses: []
  21. }),
  22. smalltalk.BrowserInterface);
  23. smalltalk.addMethod(
  24. smalltalk.method({
  25. selector: "alert:",
  26. category: 'actions',
  27. fn: function (aString){
  28. var self=this;
  29. return smalltalk.withContext(function($ctx1) {
  30. var $1;
  31. $1=_st(window)._alert_(aString);
  32. return $1;
  33. }, function($ctx1) {$ctx1.fill(self,"alert:",{aString:aString},smalltalk.BrowserInterface)})},
  34. args: ["aString"],
  35. source: "alert: aString\x0a\x09^window alert: aString",
  36. messageSends: ["alert:"],
  37. referencedClasses: []
  38. }),
  39. smalltalk.BrowserInterface);
  40. smalltalk.addMethod(
  41. smalltalk.method({
  42. selector: "confirm:",
  43. category: 'actions',
  44. fn: function (aString){
  45. var self=this;
  46. return smalltalk.withContext(function($ctx1) {
  47. var $1;
  48. $1=_st(window)._confirm_(aString);
  49. return $1;
  50. }, function($ctx1) {$ctx1.fill(self,"confirm:",{aString:aString},smalltalk.BrowserInterface)})},
  51. args: ["aString"],
  52. source: "confirm: aString\x0a\x09^window confirm: aString",
  53. messageSends: ["confirm:"],
  54. referencedClasses: []
  55. }),
  56. smalltalk.BrowserInterface);
  57. smalltalk.addMethod(
  58. smalltalk.method({
  59. selector: "isAvailable",
  60. category: 'testing',
  61. fn: function (){
  62. var self=this;
  63. return smalltalk.withContext(function($ctx1) {
  64. return typeof window !== "undefined" && typeof jQuery !== "undefined";
  65. return self}, function($ctx1) {$ctx1.fill(self,"isAvailable",{},smalltalk.BrowserInterface)})},
  66. args: [],
  67. source: "isAvailable\x0a<return typeof window !== \x22undefined\x22 && typeof jQuery !== \x22undefined\x22>",
  68. messageSends: [],
  69. referencedClasses: []
  70. }),
  71. smalltalk.BrowserInterface);
  72. smalltalk.addMethod(
  73. smalltalk.method({
  74. selector: "prompt:",
  75. category: 'actions',
  76. fn: function (aString){
  77. var self=this;
  78. return smalltalk.withContext(function($ctx1) {
  79. var $1;
  80. $1=_st(window)._prompt_(aString);
  81. return $1;
  82. }, function($ctx1) {$ctx1.fill(self,"prompt:",{aString:aString},smalltalk.BrowserInterface)})},
  83. args: ["aString"],
  84. source: "prompt: aString\x0a\x09^window prompt: aString",
  85. messageSends: ["prompt:"],
  86. referencedClasses: []
  87. }),
  88. smalltalk.BrowserInterface);
  89. smalltalk.BrowserInterface.klass.iVarNames = ['uiWorker','ajaxWorker'];
  90. smalltalk.addClass('HTMLCanvas', smalltalk.Object, ['root'], 'Canvas');
  91. smalltalk.HTMLCanvas.comment="I am a canvas for building HTML.\x0a\x0aI provide the `#tag:` method to create a `TagBrush` (wrapping a DOM element) and convenience methods in the `tags` protocol.\x0a\x0a## API\x0a\x0aMy instances are used as the argument of the `#renderOn:` method of `Widget` objects.\x0a\x0aThe `#with:` method is used to compose HTML, nesting tags. `#with:` can take a `TagBrush`, a `String`, a `BlockClosure` or a `Widget` as argument.\x0a\x0a## Usage example:\x0a\x0a aCanvas a \x0a with: [ aCanvas span with: 'click me' ];\x0a onClick: [ window alert: 'clicked!' ]";
  92. smalltalk.addMethod(
  93. smalltalk.method({
  94. selector: "a",
  95. category: 'tags',
  96. fn: function (){
  97. var self=this;
  98. return smalltalk.withContext(function($ctx1) {
  99. var $1;
  100. $1=self._tag_("a");
  101. return $1;
  102. }, function($ctx1) {$ctx1.fill(self,"a",{},smalltalk.HTMLCanvas)})},
  103. args: [],
  104. source: "a\x0a\x09^self tag: 'a'",
  105. messageSends: ["tag:"],
  106. referencedClasses: []
  107. }),
  108. smalltalk.HTMLCanvas);
  109. smalltalk.addMethod(
  110. smalltalk.method({
  111. selector: "abbr",
  112. category: 'tags',
  113. fn: function (){
  114. var self=this;
  115. return smalltalk.withContext(function($ctx1) {
  116. var $1;
  117. $1=self._tag_("abbr");
  118. return $1;
  119. }, function($ctx1) {$ctx1.fill(self,"abbr",{},smalltalk.HTMLCanvas)})},
  120. args: [],
  121. source: "abbr\x0a\x09^self tag: 'abbr'",
  122. messageSends: ["tag:"],
  123. referencedClasses: []
  124. }),
  125. smalltalk.HTMLCanvas);
  126. smalltalk.addMethod(
  127. smalltalk.method({
  128. selector: "address",
  129. category: 'tags',
  130. fn: function (){
  131. var self=this;
  132. return smalltalk.withContext(function($ctx1) {
  133. var $1;
  134. $1=self._tag_("address");
  135. return $1;
  136. }, function($ctx1) {$ctx1.fill(self,"address",{},smalltalk.HTMLCanvas)})},
  137. args: [],
  138. source: "address\x0a\x09^self tag: 'address'",
  139. messageSends: ["tag:"],
  140. referencedClasses: []
  141. }),
  142. smalltalk.HTMLCanvas);
  143. smalltalk.addMethod(
  144. smalltalk.method({
  145. selector: "area",
  146. category: 'tags',
  147. fn: function (){
  148. var self=this;
  149. return smalltalk.withContext(function($ctx1) {
  150. var $1;
  151. $1=self._tag_("area");
  152. return $1;
  153. }, function($ctx1) {$ctx1.fill(self,"area",{},smalltalk.HTMLCanvas)})},
  154. args: [],
  155. source: "area\x0a\x09^self tag: 'area'",
  156. messageSends: ["tag:"],
  157. referencedClasses: []
  158. }),
  159. smalltalk.HTMLCanvas);
  160. smalltalk.addMethod(
  161. smalltalk.method({
  162. selector: "article",
  163. category: 'tags',
  164. fn: function (){
  165. var self=this;
  166. return smalltalk.withContext(function($ctx1) {
  167. var $1;
  168. $1=self._tag_("article");
  169. return $1;
  170. }, function($ctx1) {$ctx1.fill(self,"article",{},smalltalk.HTMLCanvas)})},
  171. args: [],
  172. source: "article\x0a\x09^self tag: 'article'",
  173. messageSends: ["tag:"],
  174. referencedClasses: []
  175. }),
  176. smalltalk.HTMLCanvas);
  177. smalltalk.addMethod(
  178. smalltalk.method({
  179. selector: "aside",
  180. category: 'tags',
  181. fn: function (){
  182. var self=this;
  183. return smalltalk.withContext(function($ctx1) {
  184. var $1;
  185. $1=self._tag_("aside");
  186. return $1;
  187. }, function($ctx1) {$ctx1.fill(self,"aside",{},smalltalk.HTMLCanvas)})},
  188. args: [],
  189. source: "aside\x0a\x09^self tag: 'aside'",
  190. messageSends: ["tag:"],
  191. referencedClasses: []
  192. }),
  193. smalltalk.HTMLCanvas);
  194. smalltalk.addMethod(
  195. smalltalk.method({
  196. selector: "audio",
  197. category: 'tags',
  198. fn: function (){
  199. var self=this;
  200. return smalltalk.withContext(function($ctx1) {
  201. var $1;
  202. $1=self._tag_("audio");
  203. return $1;
  204. }, function($ctx1) {$ctx1.fill(self,"audio",{},smalltalk.HTMLCanvas)})},
  205. args: [],
  206. source: "audio\x0a\x09^self tag: 'audio'",
  207. messageSends: ["tag:"],
  208. referencedClasses: []
  209. }),
  210. smalltalk.HTMLCanvas);
  211. smalltalk.addMethod(
  212. smalltalk.method({
  213. selector: "base",
  214. category: 'tags',
  215. fn: function (){
  216. var self=this;
  217. return smalltalk.withContext(function($ctx1) {
  218. var $1;
  219. $1=self._tag_("base");
  220. return $1;
  221. }, function($ctx1) {$ctx1.fill(self,"base",{},smalltalk.HTMLCanvas)})},
  222. args: [],
  223. source: "base\x0a\x09^self tag: 'base'",
  224. messageSends: ["tag:"],
  225. referencedClasses: []
  226. }),
  227. smalltalk.HTMLCanvas);
  228. smalltalk.addMethod(
  229. smalltalk.method({
  230. selector: "blockquote",
  231. category: 'tags',
  232. fn: function (){
  233. var self=this;
  234. return smalltalk.withContext(function($ctx1) {
  235. var $1;
  236. $1=self._tag_("blockquote");
  237. return $1;
  238. }, function($ctx1) {$ctx1.fill(self,"blockquote",{},smalltalk.HTMLCanvas)})},
  239. args: [],
  240. source: "blockquote\x0a\x09^self tag: 'blockquote'",
  241. messageSends: ["tag:"],
  242. referencedClasses: []
  243. }),
  244. smalltalk.HTMLCanvas);
  245. smalltalk.addMethod(
  246. smalltalk.method({
  247. selector: "body",
  248. category: 'tags',
  249. fn: function (){
  250. var self=this;
  251. return smalltalk.withContext(function($ctx1) {
  252. var $1;
  253. $1=self._tag_("body");
  254. return $1;
  255. }, function($ctx1) {$ctx1.fill(self,"body",{},smalltalk.HTMLCanvas)})},
  256. args: [],
  257. source: "body\x0a\x09^self tag: 'body'",
  258. messageSends: ["tag:"],
  259. referencedClasses: []
  260. }),
  261. smalltalk.HTMLCanvas);
  262. smalltalk.addMethod(
  263. smalltalk.method({
  264. selector: "br",
  265. category: 'tags',
  266. fn: function (){
  267. var self=this;
  268. return smalltalk.withContext(function($ctx1) {
  269. var $1;
  270. $1=self._tag_("br");
  271. return $1;
  272. }, function($ctx1) {$ctx1.fill(self,"br",{},smalltalk.HTMLCanvas)})},
  273. args: [],
  274. source: "br\x0a\x09^self tag: 'br'",
  275. messageSends: ["tag:"],
  276. referencedClasses: []
  277. }),
  278. smalltalk.HTMLCanvas);
  279. smalltalk.addMethod(
  280. smalltalk.method({
  281. selector: "button",
  282. category: 'tags',
  283. fn: function (){
  284. var self=this;
  285. return smalltalk.withContext(function($ctx1) {
  286. var $1;
  287. $1=self._tag_("button");
  288. return $1;
  289. }, function($ctx1) {$ctx1.fill(self,"button",{},smalltalk.HTMLCanvas)})},
  290. args: [],
  291. source: "button\x0a\x09^self tag: 'button'",
  292. messageSends: ["tag:"],
  293. referencedClasses: []
  294. }),
  295. smalltalk.HTMLCanvas);
  296. smalltalk.addMethod(
  297. smalltalk.method({
  298. selector: "canvas",
  299. category: 'tags',
  300. fn: function (){
  301. var self=this;
  302. return smalltalk.withContext(function($ctx1) {
  303. var $1;
  304. $1=self._tag_("canvas");
  305. return $1;
  306. }, function($ctx1) {$ctx1.fill(self,"canvas",{},smalltalk.HTMLCanvas)})},
  307. args: [],
  308. source: "canvas\x0a\x09^self tag: 'canvas'",
  309. messageSends: ["tag:"],
  310. referencedClasses: []
  311. }),
  312. smalltalk.HTMLCanvas);
  313. smalltalk.addMethod(
  314. smalltalk.method({
  315. selector: "caption",
  316. category: 'tags',
  317. fn: function (){
  318. var self=this;
  319. return smalltalk.withContext(function($ctx1) {
  320. var $1;
  321. $1=self._tag_("caption");
  322. return $1;
  323. }, function($ctx1) {$ctx1.fill(self,"caption",{},smalltalk.HTMLCanvas)})},
  324. args: [],
  325. source: "caption\x0a\x09^self tag: 'caption'",
  326. messageSends: ["tag:"],
  327. referencedClasses: []
  328. }),
  329. smalltalk.HTMLCanvas);
  330. smalltalk.addMethod(
  331. smalltalk.method({
  332. selector: "cite",
  333. category: 'tags',
  334. fn: function (){
  335. var self=this;
  336. return smalltalk.withContext(function($ctx1) {
  337. var $1;
  338. $1=self._tag_("cite");
  339. return $1;
  340. }, function($ctx1) {$ctx1.fill(self,"cite",{},smalltalk.HTMLCanvas)})},
  341. args: [],
  342. source: "cite\x0a\x09^self tag: 'cite'",
  343. messageSends: ["tag:"],
  344. referencedClasses: []
  345. }),
  346. smalltalk.HTMLCanvas);
  347. smalltalk.addMethod(
  348. smalltalk.method({
  349. selector: "code",
  350. category: 'tags',
  351. fn: function (){
  352. var self=this;
  353. return smalltalk.withContext(function($ctx1) {
  354. var $1;
  355. $1=self._tag_("code");
  356. return $1;
  357. }, function($ctx1) {$ctx1.fill(self,"code",{},smalltalk.HTMLCanvas)})},
  358. args: [],
  359. source: "code\x0a\x09^self tag: 'code'",
  360. messageSends: ["tag:"],
  361. referencedClasses: []
  362. }),
  363. smalltalk.HTMLCanvas);
  364. smalltalk.addMethod(
  365. smalltalk.method({
  366. selector: "col",
  367. category: 'tags',
  368. fn: function (){
  369. var self=this;
  370. return smalltalk.withContext(function($ctx1) {
  371. var $1;
  372. $1=self._tag_("col");
  373. return $1;
  374. }, function($ctx1) {$ctx1.fill(self,"col",{},smalltalk.HTMLCanvas)})},
  375. args: [],
  376. source: "col\x0a\x09^self tag: 'col'",
  377. messageSends: ["tag:"],
  378. referencedClasses: []
  379. }),
  380. smalltalk.HTMLCanvas);
  381. smalltalk.addMethod(
  382. smalltalk.method({
  383. selector: "colgroup",
  384. category: 'tags',
  385. fn: function (){
  386. var self=this;
  387. return smalltalk.withContext(function($ctx1) {
  388. var $1;
  389. $1=self._tag_("colgroup");
  390. return $1;
  391. }, function($ctx1) {$ctx1.fill(self,"colgroup",{},smalltalk.HTMLCanvas)})},
  392. args: [],
  393. source: "colgroup\x0a\x09^self tag: 'colgroup'",
  394. messageSends: ["tag:"],
  395. referencedClasses: []
  396. }),
  397. smalltalk.HTMLCanvas);
  398. smalltalk.addMethod(
  399. smalltalk.method({
  400. selector: "command",
  401. category: 'tags',
  402. fn: function (){
  403. var self=this;
  404. return smalltalk.withContext(function($ctx1) {
  405. var $1;
  406. $1=self._tag_("command");
  407. return $1;
  408. }, function($ctx1) {$ctx1.fill(self,"command",{},smalltalk.HTMLCanvas)})},
  409. args: [],
  410. source: "command\x0a\x09^self tag: 'command'",
  411. messageSends: ["tag:"],
  412. referencedClasses: []
  413. }),
  414. smalltalk.HTMLCanvas);
  415. smalltalk.addMethod(
  416. smalltalk.method({
  417. selector: "datalist",
  418. category: 'tags',
  419. fn: function (){
  420. var self=this;
  421. return smalltalk.withContext(function($ctx1) {
  422. var $1;
  423. $1=self._tag_("datalist");
  424. return $1;
  425. }, function($ctx1) {$ctx1.fill(self,"datalist",{},smalltalk.HTMLCanvas)})},
  426. args: [],
  427. source: "datalist\x0a\x09^self tag: 'datalist'",
  428. messageSends: ["tag:"],
  429. referencedClasses: []
  430. }),
  431. smalltalk.HTMLCanvas);
  432. smalltalk.addMethod(
  433. smalltalk.method({
  434. selector: "dd",
  435. category: 'tags',
  436. fn: function (){
  437. var self=this;
  438. return smalltalk.withContext(function($ctx1) {
  439. var $1;
  440. $1=self._tag_("dd");
  441. return $1;
  442. }, function($ctx1) {$ctx1.fill(self,"dd",{},smalltalk.HTMLCanvas)})},
  443. args: [],
  444. source: "dd\x0a\x09^self tag: 'dd'",
  445. messageSends: ["tag:"],
  446. referencedClasses: []
  447. }),
  448. smalltalk.HTMLCanvas);
  449. smalltalk.addMethod(
  450. smalltalk.method({
  451. selector: "del",
  452. category: 'tags',
  453. fn: function (){
  454. var self=this;
  455. return smalltalk.withContext(function($ctx1) {
  456. var $1;
  457. $1=self._tag_("del");
  458. return $1;
  459. }, function($ctx1) {$ctx1.fill(self,"del",{},smalltalk.HTMLCanvas)})},
  460. args: [],
  461. source: "del\x0a\x09^self tag: 'del'",
  462. messageSends: ["tag:"],
  463. referencedClasses: []
  464. }),
  465. smalltalk.HTMLCanvas);
  466. smalltalk.addMethod(
  467. smalltalk.method({
  468. selector: "details",
  469. category: 'tags',
  470. fn: function (){
  471. var self=this;
  472. return smalltalk.withContext(function($ctx1) {
  473. var $1;
  474. $1=self._tag_("details");
  475. return $1;
  476. }, function($ctx1) {$ctx1.fill(self,"details",{},smalltalk.HTMLCanvas)})},
  477. args: [],
  478. source: "details\x0a\x09^self tag: 'details'",
  479. messageSends: ["tag:"],
  480. referencedClasses: []
  481. }),
  482. smalltalk.HTMLCanvas);
  483. smalltalk.addMethod(
  484. smalltalk.method({
  485. selector: "div",
  486. category: 'tags',
  487. fn: function (){
  488. var self=this;
  489. return smalltalk.withContext(function($ctx1) {
  490. var $1;
  491. $1=self._tag_("div");
  492. return $1;
  493. }, function($ctx1) {$ctx1.fill(self,"div",{},smalltalk.HTMLCanvas)})},
  494. args: [],
  495. source: "div\x0a\x09^self tag: 'div'",
  496. messageSends: ["tag:"],
  497. referencedClasses: []
  498. }),
  499. smalltalk.HTMLCanvas);
  500. smalltalk.addMethod(
  501. smalltalk.method({
  502. selector: "div:",
  503. category: 'tags',
  504. fn: function (aBlock){
  505. var self=this;
  506. return smalltalk.withContext(function($ctx1) {
  507. var $1;
  508. $1=_st(self._div())._with_(aBlock);
  509. return $1;
  510. }, function($ctx1) {$ctx1.fill(self,"div:",{aBlock:aBlock},smalltalk.HTMLCanvas)})},
  511. args: ["aBlock"],
  512. source: "div: aBlock\x0a\x09^self div with: aBlock",
  513. messageSends: ["with:", "div"],
  514. referencedClasses: []
  515. }),
  516. smalltalk.HTMLCanvas);
  517. smalltalk.addMethod(
  518. smalltalk.method({
  519. selector: "dl",
  520. category: 'tags',
  521. fn: function (){
  522. var self=this;
  523. return smalltalk.withContext(function($ctx1) {
  524. var $1;
  525. $1=self._tag_("dl");
  526. return $1;
  527. }, function($ctx1) {$ctx1.fill(self,"dl",{},smalltalk.HTMLCanvas)})},
  528. args: [],
  529. source: "dl\x0a\x09^self tag: 'dl'",
  530. messageSends: ["tag:"],
  531. referencedClasses: []
  532. }),
  533. smalltalk.HTMLCanvas);
  534. smalltalk.addMethod(
  535. smalltalk.method({
  536. selector: "dt",
  537. category: 'tags',
  538. fn: function (){
  539. var self=this;
  540. return smalltalk.withContext(function($ctx1) {
  541. var $1;
  542. $1=self._tag_("dt");
  543. return $1;
  544. }, function($ctx1) {$ctx1.fill(self,"dt",{},smalltalk.HTMLCanvas)})},
  545. args: [],
  546. source: "dt\x0a\x09^self tag: 'dt'",
  547. messageSends: ["tag:"],
  548. referencedClasses: []
  549. }),
  550. smalltalk.HTMLCanvas);
  551. smalltalk.addMethod(
  552. smalltalk.method({
  553. selector: "em",
  554. category: 'tags',
  555. fn: function (){
  556. var self=this;
  557. return smalltalk.withContext(function($ctx1) {
  558. var $1;
  559. $1=self._tag_("em");
  560. return $1;
  561. }, function($ctx1) {$ctx1.fill(self,"em",{},smalltalk.HTMLCanvas)})},
  562. args: [],
  563. source: "em\x0a\x09^self tag: 'em'",
  564. messageSends: ["tag:"],
  565. referencedClasses: []
  566. }),
  567. smalltalk.HTMLCanvas);
  568. smalltalk.addMethod(
  569. smalltalk.method({
  570. selector: "embed",
  571. category: 'tags',
  572. fn: function (){
  573. var self=this;
  574. return smalltalk.withContext(function($ctx1) {
  575. var $1;
  576. $1=self._tag_("embed");
  577. return $1;
  578. }, function($ctx1) {$ctx1.fill(self,"embed",{},smalltalk.HTMLCanvas)})},
  579. args: [],
  580. source: "embed\x0a\x09^self tag: 'embed'",
  581. messageSends: ["tag:"],
  582. referencedClasses: []
  583. }),
  584. smalltalk.HTMLCanvas);
  585. smalltalk.addMethod(
  586. smalltalk.method({
  587. selector: "entity:",
  588. category: 'adding',
  589. fn: function (aString){
  590. var self=this;
  591. var result;
  592. return smalltalk.withContext(function($ctx1) {
  593. var $1;
  594. result=_st(_st("<span />"._asJQuery())._html_(_st("&".__comma(aString)).__comma(";")))._text();
  595. $1=_st(_st(result)._size()).__eq((1));
  596. if(! smalltalk.assert($1)){
  597. self._error_("Not an HTML entity: ".__comma(aString));
  598. };
  599. self._with_(result);
  600. return self}, function($ctx1) {$ctx1.fill(self,"entity:",{aString:aString,result:result},smalltalk.HTMLCanvas)})},
  601. args: ["aString"],
  602. source: "entity: aString\x0a\x09\x22Adds a character representing html entity, eg.\x0a\x09html entity: 'copy'\x0a\x09adds a copyright sign.\x0a\x09If a name does not represent valid HTML entity, error is raised.\x22\x0a\x09| result |\x0a\x09result := ('<span />' asJQuery html: '&', aString, ';') text.\x0a\x09result size = 1 ifFalse: [ self error: 'Not an HTML entity: ', aString ].\x0a\x09self with: result",
  603. messageSends: ["text", "html:", "asJQuery", ",", "ifFalse:", "=", "size", "error:", "with:"],
  604. referencedClasses: []
  605. }),
  606. smalltalk.HTMLCanvas);
  607. smalltalk.addMethod(
  608. smalltalk.method({
  609. selector: "fieldset",
  610. category: 'tags',
  611. fn: function (){
  612. var self=this;
  613. return smalltalk.withContext(function($ctx1) {
  614. var $1;
  615. $1=self._tag_("fieldset");
  616. return $1;
  617. }, function($ctx1) {$ctx1.fill(self,"fieldset",{},smalltalk.HTMLCanvas)})},
  618. args: [],
  619. source: "fieldset\x0a\x09^self tag: 'fieldset'",
  620. messageSends: ["tag:"],
  621. referencedClasses: []
  622. }),
  623. smalltalk.HTMLCanvas);
  624. smalltalk.addMethod(
  625. smalltalk.method({
  626. selector: "figcaption",
  627. category: 'tags',
  628. fn: function (){
  629. var self=this;
  630. return smalltalk.withContext(function($ctx1) {
  631. var $1;
  632. $1=self._tag_("figcaption");
  633. return $1;
  634. }, function($ctx1) {$ctx1.fill(self,"figcaption",{},smalltalk.HTMLCanvas)})},
  635. args: [],
  636. source: "figcaption\x0a\x09^self tag: 'figcaption'",
  637. messageSends: ["tag:"],
  638. referencedClasses: []
  639. }),
  640. smalltalk.HTMLCanvas);
  641. smalltalk.addMethod(
  642. smalltalk.method({
  643. selector: "figure",
  644. category: 'tags',
  645. fn: function (){
  646. var self=this;
  647. return smalltalk.withContext(function($ctx1) {
  648. var $1;
  649. $1=self._tag_("figure");
  650. return $1;
  651. }, function($ctx1) {$ctx1.fill(self,"figure",{},smalltalk.HTMLCanvas)})},
  652. args: [],
  653. source: "figure\x0a\x09^self tag: 'figure'",
  654. messageSends: ["tag:"],
  655. referencedClasses: []
  656. }),
  657. smalltalk.HTMLCanvas);
  658. smalltalk.addMethod(
  659. smalltalk.method({
  660. selector: "footer",
  661. category: 'tags',
  662. fn: function (){
  663. var self=this;
  664. return smalltalk.withContext(function($ctx1) {
  665. var $1;
  666. $1=self._tag_("footer");
  667. return $1;
  668. }, function($ctx1) {$ctx1.fill(self,"footer",{},smalltalk.HTMLCanvas)})},
  669. args: [],
  670. source: "footer\x0a\x09^self tag: 'footer'",
  671. messageSends: ["tag:"],
  672. referencedClasses: []
  673. }),
  674. smalltalk.HTMLCanvas);
  675. smalltalk.addMethod(
  676. smalltalk.method({
  677. selector: "form",
  678. category: 'tags',
  679. fn: function (){
  680. var self=this;
  681. return smalltalk.withContext(function($ctx1) {
  682. var $1;
  683. $1=self._tag_("form");
  684. return $1;
  685. }, function($ctx1) {$ctx1.fill(self,"form",{},smalltalk.HTMLCanvas)})},
  686. args: [],
  687. source: "form\x0a\x09^self tag: 'form'",
  688. messageSends: ["tag:"],
  689. referencedClasses: []
  690. }),
  691. smalltalk.HTMLCanvas);
  692. smalltalk.addMethod(
  693. smalltalk.method({
  694. selector: "h1",
  695. category: 'tags',
  696. fn: function (){
  697. var self=this;
  698. return smalltalk.withContext(function($ctx1) {
  699. var $1;
  700. $1=self._tag_("h1");
  701. return $1;
  702. }, function($ctx1) {$ctx1.fill(self,"h1",{},smalltalk.HTMLCanvas)})},
  703. args: [],
  704. source: "h1\x0a\x09^self tag: 'h1'",
  705. messageSends: ["tag:"],
  706. referencedClasses: []
  707. }),
  708. smalltalk.HTMLCanvas);
  709. smalltalk.addMethod(
  710. smalltalk.method({
  711. selector: "h1:",
  712. category: 'tags',
  713. fn: function (anObject){
  714. var self=this;
  715. return smalltalk.withContext(function($ctx1) {
  716. var $1;
  717. $1=_st(self._h1())._with_(anObject);
  718. return $1;
  719. }, function($ctx1) {$ctx1.fill(self,"h1:",{anObject:anObject},smalltalk.HTMLCanvas)})},
  720. args: ["anObject"],
  721. source: "h1: anObject\x0a\x09^self h1 with: anObject",
  722. messageSends: ["with:", "h1"],
  723. referencedClasses: []
  724. }),
  725. smalltalk.HTMLCanvas);
  726. smalltalk.addMethod(
  727. smalltalk.method({
  728. selector: "h2",
  729. category: 'tags',
  730. fn: function (){
  731. var self=this;
  732. return smalltalk.withContext(function($ctx1) {
  733. var $1;
  734. $1=self._tag_("h2");
  735. return $1;
  736. }, function($ctx1) {$ctx1.fill(self,"h2",{},smalltalk.HTMLCanvas)})},
  737. args: [],
  738. source: "h2\x0a\x09^self tag: 'h2'",
  739. messageSends: ["tag:"],
  740. referencedClasses: []
  741. }),
  742. smalltalk.HTMLCanvas);
  743. smalltalk.addMethod(
  744. smalltalk.method({
  745. selector: "h2:",
  746. category: 'tags',
  747. fn: function (anObject){
  748. var self=this;
  749. return smalltalk.withContext(function($ctx1) {
  750. var $1;
  751. $1=_st(self._h2())._with_(anObject);
  752. return $1;
  753. }, function($ctx1) {$ctx1.fill(self,"h2:",{anObject:anObject},smalltalk.HTMLCanvas)})},
  754. args: ["anObject"],
  755. source: "h2: anObject\x0a\x09^ self h2 with: anObject",
  756. messageSends: ["with:", "h2"],
  757. referencedClasses: []
  758. }),
  759. smalltalk.HTMLCanvas);
  760. smalltalk.addMethod(
  761. smalltalk.method({
  762. selector: "h3",
  763. category: 'tags',
  764. fn: function (){
  765. var self=this;
  766. return smalltalk.withContext(function($ctx1) {
  767. var $1;
  768. $1=self._tag_("h3");
  769. return $1;
  770. }, function($ctx1) {$ctx1.fill(self,"h3",{},smalltalk.HTMLCanvas)})},
  771. args: [],
  772. source: "h3\x0a\x09^self tag: 'h3'",
  773. messageSends: ["tag:"],
  774. referencedClasses: []
  775. }),
  776. smalltalk.HTMLCanvas);
  777. smalltalk.addMethod(
  778. smalltalk.method({
  779. selector: "h3:",
  780. category: 'tags',
  781. fn: function (anObject){
  782. var self=this;
  783. return smalltalk.withContext(function($ctx1) {
  784. var $1;
  785. $1=_st(self._h3())._with_(anObject);
  786. return $1;
  787. }, function($ctx1) {$ctx1.fill(self,"h3:",{anObject:anObject},smalltalk.HTMLCanvas)})},
  788. args: ["anObject"],
  789. source: "h3: anObject\x0a\x09^self h3 with: anObject",
  790. messageSends: ["with:", "h3"],
  791. referencedClasses: []
  792. }),
  793. smalltalk.HTMLCanvas);
  794. smalltalk.addMethod(
  795. smalltalk.method({
  796. selector: "h4",
  797. category: 'tags',
  798. fn: function (){
  799. var self=this;
  800. return smalltalk.withContext(function($ctx1) {
  801. var $1;
  802. $1=self._tag_("h4");
  803. return $1;
  804. }, function($ctx1) {$ctx1.fill(self,"h4",{},smalltalk.HTMLCanvas)})},
  805. args: [],
  806. source: "h4\x0a\x09^self tag: 'h4'",
  807. messageSends: ["tag:"],
  808. referencedClasses: []
  809. }),
  810. smalltalk.HTMLCanvas);
  811. smalltalk.addMethod(
  812. smalltalk.method({
  813. selector: "h4:",
  814. category: 'tags',
  815. fn: function (anObject){
  816. var self=this;
  817. return smalltalk.withContext(function($ctx1) {
  818. var $1;
  819. $1=_st(self._h4())._with_(anObject);
  820. return $1;
  821. }, function($ctx1) {$ctx1.fill(self,"h4:",{anObject:anObject},smalltalk.HTMLCanvas)})},
  822. args: ["anObject"],
  823. source: "h4: anObject\x0a\x09^self h4 with: anObject",
  824. messageSends: ["with:", "h4"],
  825. referencedClasses: []
  826. }),
  827. smalltalk.HTMLCanvas);
  828. smalltalk.addMethod(
  829. smalltalk.method({
  830. selector: "h5",
  831. category: 'tags',
  832. fn: function (){
  833. var self=this;
  834. return smalltalk.withContext(function($ctx1) {
  835. var $1;
  836. $1=self._tag_("h5");
  837. return $1;
  838. }, function($ctx1) {$ctx1.fill(self,"h5",{},smalltalk.HTMLCanvas)})},
  839. args: [],
  840. source: "h5\x0a\x09^self tag: 'h5'",
  841. messageSends: ["tag:"],
  842. referencedClasses: []
  843. }),
  844. smalltalk.HTMLCanvas);
  845. smalltalk.addMethod(
  846. smalltalk.method({
  847. selector: "h5:",
  848. category: 'tags',
  849. fn: function (anObject){
  850. var self=this;
  851. return smalltalk.withContext(function($ctx1) {
  852. var $1;
  853. $1=_st(self._h5())._with_(anObject);
  854. return $1;
  855. }, function($ctx1) {$ctx1.fill(self,"h5:",{anObject:anObject},smalltalk.HTMLCanvas)})},
  856. args: ["anObject"],
  857. source: "h5: anObject\x0a\x09^self h5 with: anObject",
  858. messageSends: ["with:", "h5"],
  859. referencedClasses: []
  860. }),
  861. smalltalk.HTMLCanvas);
  862. smalltalk.addMethod(
  863. smalltalk.method({
  864. selector: "h6",
  865. category: 'tags',
  866. fn: function (){
  867. var self=this;
  868. return smalltalk.withContext(function($ctx1) {
  869. var $1;
  870. $1=self._tag_("h6");
  871. return $1;
  872. }, function($ctx1) {$ctx1.fill(self,"h6",{},smalltalk.HTMLCanvas)})},
  873. args: [],
  874. source: "h6\x0a\x09^self tag: 'h6'",
  875. messageSends: ["tag:"],
  876. referencedClasses: []
  877. }),
  878. smalltalk.HTMLCanvas);
  879. smalltalk.addMethod(
  880. smalltalk.method({
  881. selector: "h6:",
  882. category: 'tags',
  883. fn: function (anObject){
  884. var self=this;
  885. return smalltalk.withContext(function($ctx1) {
  886. var $1;
  887. $1=_st(self._h6())._with_(anObject);
  888. return $1;
  889. }, function($ctx1) {$ctx1.fill(self,"h6:",{anObject:anObject},smalltalk.HTMLCanvas)})},
  890. args: ["anObject"],
  891. source: "h6: anObject\x0a\x09^self h6 with: anObject",
  892. messageSends: ["with:", "h6"],
  893. referencedClasses: []
  894. }),
  895. smalltalk.HTMLCanvas);
  896. smalltalk.addMethod(
  897. smalltalk.method({
  898. selector: "head",
  899. category: 'tags',
  900. fn: function (){
  901. var self=this;
  902. return smalltalk.withContext(function($ctx1) {
  903. var $1;
  904. $1=self._tag_("head");
  905. return $1;
  906. }, function($ctx1) {$ctx1.fill(self,"head",{},smalltalk.HTMLCanvas)})},
  907. args: [],
  908. source: "head\x0a\x09^self tag: 'head'",
  909. messageSends: ["tag:"],
  910. referencedClasses: []
  911. }),
  912. smalltalk.HTMLCanvas);
  913. smalltalk.addMethod(
  914. smalltalk.method({
  915. selector: "header",
  916. category: 'tags',
  917. fn: function (){
  918. var self=this;
  919. return smalltalk.withContext(function($ctx1) {
  920. var $1;
  921. $1=self._tag_("header");
  922. return $1;
  923. }, function($ctx1) {$ctx1.fill(self,"header",{},smalltalk.HTMLCanvas)})},
  924. args: [],
  925. source: "header\x0a\x09^self tag: 'header'",
  926. messageSends: ["tag:"],
  927. referencedClasses: []
  928. }),
  929. smalltalk.HTMLCanvas);
  930. smalltalk.addMethod(
  931. smalltalk.method({
  932. selector: "hgroup",
  933. category: 'tags',
  934. fn: function (){
  935. var self=this;
  936. return smalltalk.withContext(function($ctx1) {
  937. var $1;
  938. $1=self._tag_("hgroup");
  939. return $1;
  940. }, function($ctx1) {$ctx1.fill(self,"hgroup",{},smalltalk.HTMLCanvas)})},
  941. args: [],
  942. source: "hgroup\x0a\x09^self tag: 'hgroup'",
  943. messageSends: ["tag:"],
  944. referencedClasses: []
  945. }),
  946. smalltalk.HTMLCanvas);
  947. smalltalk.addMethod(
  948. smalltalk.method({
  949. selector: "hr",
  950. category: 'tags',
  951. fn: function (){
  952. var self=this;
  953. return smalltalk.withContext(function($ctx1) {
  954. var $1;
  955. $1=self._tag_("hr");
  956. return $1;
  957. }, function($ctx1) {$ctx1.fill(self,"hr",{},smalltalk.HTMLCanvas)})},
  958. args: [],
  959. source: "hr\x0a\x09^self tag: 'hr'",
  960. messageSends: ["tag:"],
  961. referencedClasses: []
  962. }),
  963. smalltalk.HTMLCanvas);
  964. smalltalk.addMethod(
  965. smalltalk.method({
  966. selector: "html",
  967. category: 'tags',
  968. fn: function (){
  969. var self=this;
  970. return smalltalk.withContext(function($ctx1) {
  971. var $1;
  972. $1=self._tag_("html");
  973. return $1;
  974. }, function($ctx1) {$ctx1.fill(self,"html",{},smalltalk.HTMLCanvas)})},
  975. args: [],
  976. source: "html\x0a\x09^self tag: 'html'",
  977. messageSends: ["tag:"],
  978. referencedClasses: []
  979. }),
  980. smalltalk.HTMLCanvas);
  981. smalltalk.addMethod(
  982. smalltalk.method({
  983. selector: "iframe",
  984. category: 'tags',
  985. fn: function (){
  986. var self=this;
  987. return smalltalk.withContext(function($ctx1) {
  988. var $1;
  989. $1=self._tag_("iframe");
  990. return $1;
  991. }, function($ctx1) {$ctx1.fill(self,"iframe",{},smalltalk.HTMLCanvas)})},
  992. args: [],
  993. source: "iframe\x0a\x09^self tag: 'iframe'",
  994. messageSends: ["tag:"],
  995. referencedClasses: []
  996. }),
  997. smalltalk.HTMLCanvas);
  998. smalltalk.addMethod(
  999. smalltalk.method({
  1000. selector: "iframe:",
  1001. category: 'tags',
  1002. fn: function (aString){
  1003. var self=this;
  1004. return smalltalk.withContext(function($ctx1) {
  1005. var $1;
  1006. $1=_st(self._iframe())._src_(aString);
  1007. return $1;
  1008. }, function($ctx1) {$ctx1.fill(self,"iframe:",{aString:aString},smalltalk.HTMLCanvas)})},
  1009. args: ["aString"],
  1010. source: "iframe: aString\x0a\x09^self iframe src: aString",
  1011. messageSends: ["src:", "iframe"],
  1012. referencedClasses: []
  1013. }),
  1014. smalltalk.HTMLCanvas);
  1015. smalltalk.addMethod(
  1016. smalltalk.method({
  1017. selector: "img",
  1018. category: 'tags',
  1019. fn: function (){
  1020. var self=this;
  1021. return smalltalk.withContext(function($ctx1) {
  1022. var $1;
  1023. $1=self._tag_("img");
  1024. return $1;
  1025. }, function($ctx1) {$ctx1.fill(self,"img",{},smalltalk.HTMLCanvas)})},
  1026. args: [],
  1027. source: "img\x0a\x09^self tag: 'img'",
  1028. messageSends: ["tag:"],
  1029. referencedClasses: []
  1030. }),
  1031. smalltalk.HTMLCanvas);
  1032. smalltalk.addMethod(
  1033. smalltalk.method({
  1034. selector: "img:",
  1035. category: 'tags',
  1036. fn: function (aString){
  1037. var self=this;
  1038. return smalltalk.withContext(function($ctx1) {
  1039. var $1;
  1040. $1=_st(self._img())._src_(aString);
  1041. return $1;
  1042. }, function($ctx1) {$ctx1.fill(self,"img:",{aString:aString},smalltalk.HTMLCanvas)})},
  1043. args: ["aString"],
  1044. source: "img: aString\x0a\x09^self img src: aString",
  1045. messageSends: ["src:", "img"],
  1046. referencedClasses: []
  1047. }),
  1048. smalltalk.HTMLCanvas);
  1049. smalltalk.addMethod(
  1050. smalltalk.method({
  1051. selector: "initialize",
  1052. category: 'initialization',
  1053. fn: function (){
  1054. var self=this;
  1055. function $TagBrush(){return smalltalk.TagBrush||(typeof TagBrush=="undefined"?nil:TagBrush)}
  1056. return smalltalk.withContext(function($ctx1) {
  1057. var $1;
  1058. smalltalk.HTMLCanvas.superclass.fn.prototype._initialize.apply(_st(self), []);
  1059. $1=self["@root"];
  1060. if(($receiver = $1) == nil || $receiver == null){
  1061. self["@root"]=_st($TagBrush())._fromString_canvas_("div",self);
  1062. self["@root"];
  1063. } else {
  1064. $1;
  1065. };
  1066. return self}, function($ctx1) {$ctx1.fill(self,"initialize",{},smalltalk.HTMLCanvas)})},
  1067. args: [],
  1068. source: "initialize\x0a\x09super initialize.\x0a\x09root ifNil: [root := TagBrush fromString: 'div' canvas: self]",
  1069. messageSends: ["initialize", "ifNil:", "fromString:canvas:"],
  1070. referencedClasses: ["TagBrush"]
  1071. }),
  1072. smalltalk.HTMLCanvas);
  1073. smalltalk.addMethod(
  1074. smalltalk.method({
  1075. selector: "initializeFromJQuery:",
  1076. category: 'initialization',
  1077. fn: function (aJQuery){
  1078. var self=this;
  1079. function $TagBrush(){return smalltalk.TagBrush||(typeof TagBrush=="undefined"?nil:TagBrush)}
  1080. return smalltalk.withContext(function($ctx1) {
  1081. self["@root"]=_st($TagBrush())._fromJQuery_canvas_(aJQuery,self);
  1082. return self}, function($ctx1) {$ctx1.fill(self,"initializeFromJQuery:",{aJQuery:aJQuery},smalltalk.HTMLCanvas)})},
  1083. args: ["aJQuery"],
  1084. source: "initializeFromJQuery: aJQuery\x0a\x09root := TagBrush fromJQuery: aJQuery canvas: self",
  1085. messageSends: ["fromJQuery:canvas:"],
  1086. referencedClasses: ["TagBrush"]
  1087. }),
  1088. smalltalk.HTMLCanvas);
  1089. smalltalk.addMethod(
  1090. smalltalk.method({
  1091. selector: "input",
  1092. category: 'tags',
  1093. fn: function (){
  1094. var self=this;
  1095. return smalltalk.withContext(function($ctx1) {
  1096. var $1;
  1097. $1=self._tag_("input");
  1098. return $1;
  1099. }, function($ctx1) {$ctx1.fill(self,"input",{},smalltalk.HTMLCanvas)})},
  1100. args: [],
  1101. source: "input\x0a\x09^self tag: 'input'",
  1102. messageSends: ["tag:"],
  1103. referencedClasses: []
  1104. }),
  1105. smalltalk.HTMLCanvas);
  1106. smalltalk.addMethod(
  1107. smalltalk.method({
  1108. selector: "label",
  1109. category: 'tags',
  1110. fn: function (){
  1111. var self=this;
  1112. return smalltalk.withContext(function($ctx1) {
  1113. var $1;
  1114. $1=self._tag_("label");
  1115. return $1;
  1116. }, function($ctx1) {$ctx1.fill(self,"label",{},smalltalk.HTMLCanvas)})},
  1117. args: [],
  1118. source: "label\x0a\x09^self tag: 'label'",
  1119. messageSends: ["tag:"],
  1120. referencedClasses: []
  1121. }),
  1122. smalltalk.HTMLCanvas);
  1123. smalltalk.addMethod(
  1124. smalltalk.method({
  1125. selector: "legend",
  1126. category: 'tags',
  1127. fn: function (){
  1128. var self=this;
  1129. return smalltalk.withContext(function($ctx1) {
  1130. var $1;
  1131. $1=self._tag_("legend");
  1132. return $1;
  1133. }, function($ctx1) {$ctx1.fill(self,"legend",{},smalltalk.HTMLCanvas)})},
  1134. args: [],
  1135. source: "legend\x0a\x09^self tag: 'legend'",
  1136. messageSends: ["tag:"],
  1137. referencedClasses: []
  1138. }),
  1139. smalltalk.HTMLCanvas);
  1140. smalltalk.addMethod(
  1141. smalltalk.method({
  1142. selector: "li",
  1143. category: 'tags',
  1144. fn: function (){
  1145. var self=this;
  1146. return smalltalk.withContext(function($ctx1) {
  1147. var $1;
  1148. $1=self._tag_("li");
  1149. return $1;
  1150. }, function($ctx1) {$ctx1.fill(self,"li",{},smalltalk.HTMLCanvas)})},
  1151. args: [],
  1152. source: "li\x0a\x09^self tag: 'li'",
  1153. messageSends: ["tag:"],
  1154. referencedClasses: []
  1155. }),
  1156. smalltalk.HTMLCanvas);
  1157. smalltalk.addMethod(
  1158. smalltalk.method({
  1159. selector: "li:",
  1160. category: 'tags',
  1161. fn: function (anObject){
  1162. var self=this;
  1163. return smalltalk.withContext(function($ctx1) {
  1164. var $1;
  1165. $1=_st(self._li())._with_(anObject);
  1166. return $1;
  1167. }, function($ctx1) {$ctx1.fill(self,"li:",{anObject:anObject},smalltalk.HTMLCanvas)})},
  1168. args: ["anObject"],
  1169. source: "li: anObject\x0a\x09^self li with: anObject",
  1170. messageSends: ["with:", "li"],
  1171. referencedClasses: []
  1172. }),
  1173. smalltalk.HTMLCanvas);
  1174. smalltalk.addMethod(
  1175. smalltalk.method({
  1176. selector: "link",
  1177. category: 'tags',
  1178. fn: function (){
  1179. var self=this;
  1180. return smalltalk.withContext(function($ctx1) {
  1181. var $1;
  1182. $1=self._tag_("link");
  1183. return $1;
  1184. }, function($ctx1) {$ctx1.fill(self,"link",{},smalltalk.HTMLCanvas)})},
  1185. args: [],
  1186. source: "link\x0a\x09^self tag: 'link'",
  1187. messageSends: ["tag:"],
  1188. referencedClasses: []
  1189. }),
  1190. smalltalk.HTMLCanvas);
  1191. smalltalk.addMethod(
  1192. smalltalk.method({
  1193. selector: "map",
  1194. category: 'tags',
  1195. fn: function (){
  1196. var self=this;
  1197. return smalltalk.withContext(function($ctx1) {
  1198. var $1;
  1199. $1=self._tag_("map");
  1200. return $1;
  1201. }, function($ctx1) {$ctx1.fill(self,"map",{},smalltalk.HTMLCanvas)})},
  1202. args: [],
  1203. source: "map\x0a\x09^self tag: 'map'",
  1204. messageSends: ["tag:"],
  1205. referencedClasses: []
  1206. }),
  1207. smalltalk.HTMLCanvas);
  1208. smalltalk.addMethod(
  1209. smalltalk.method({
  1210. selector: "mark",
  1211. category: 'tags',
  1212. fn: function (){
  1213. var self=this;
  1214. return smalltalk.withContext(function($ctx1) {
  1215. var $1;
  1216. $1=self._tag_("mark");
  1217. return $1;
  1218. }, function($ctx1) {$ctx1.fill(self,"mark",{},smalltalk.HTMLCanvas)})},
  1219. args: [],
  1220. source: "mark\x0a\x09^self tag: 'mark'",
  1221. messageSends: ["tag:"],
  1222. referencedClasses: []
  1223. }),
  1224. smalltalk.HTMLCanvas);
  1225. smalltalk.addMethod(
  1226. smalltalk.method({
  1227. selector: "menu",
  1228. category: 'tags',
  1229. fn: function (){
  1230. var self=this;
  1231. return smalltalk.withContext(function($ctx1) {
  1232. var $1;
  1233. $1=self._tag_("menu");
  1234. return $1;
  1235. }, function($ctx1) {$ctx1.fill(self,"menu",{},smalltalk.HTMLCanvas)})},
  1236. args: [],
  1237. source: "menu\x0a\x09^self tag: 'menu'",
  1238. messageSends: ["tag:"],
  1239. referencedClasses: []
  1240. }),
  1241. smalltalk.HTMLCanvas);
  1242. smalltalk.addMethod(
  1243. smalltalk.method({
  1244. selector: "meta",
  1245. category: 'tags',
  1246. fn: function (){
  1247. var self=this;
  1248. return smalltalk.withContext(function($ctx1) {
  1249. var $1;
  1250. $1=self._tag_("meta");
  1251. return $1;
  1252. }, function($ctx1) {$ctx1.fill(self,"meta",{},smalltalk.HTMLCanvas)})},
  1253. args: [],
  1254. source: "meta\x0a\x09^self tag: 'meta'",
  1255. messageSends: ["tag:"],
  1256. referencedClasses: []
  1257. }),
  1258. smalltalk.HTMLCanvas);
  1259. smalltalk.addMethod(
  1260. smalltalk.method({
  1261. selector: "nav",
  1262. category: 'tags',
  1263. fn: function (){
  1264. var self=this;
  1265. return smalltalk.withContext(function($ctx1) {
  1266. var $1;
  1267. $1=self._tag_("nav");
  1268. return $1;
  1269. }, function($ctx1) {$ctx1.fill(self,"nav",{},smalltalk.HTMLCanvas)})},
  1270. args: [],
  1271. source: "nav\x0a\x09^self tag: 'nav'",
  1272. messageSends: ["tag:"],
  1273. referencedClasses: []
  1274. }),
  1275. smalltalk.HTMLCanvas);
  1276. smalltalk.addMethod(
  1277. smalltalk.method({
  1278. selector: "newTag:",
  1279. category: 'tags',
  1280. fn: function (aString){
  1281. var self=this;
  1282. function $TagBrush(){return smalltalk.TagBrush||(typeof TagBrush=="undefined"?nil:TagBrush)}
  1283. return smalltalk.withContext(function($ctx1) {
  1284. var $1;
  1285. $1=_st($TagBrush())._fromString_canvas_(aString,self);
  1286. return $1;
  1287. }, function($ctx1) {$ctx1.fill(self,"newTag:",{aString:aString},smalltalk.HTMLCanvas)})},
  1288. args: ["aString"],
  1289. source: "newTag: aString\x0a\x09^TagBrush fromString: aString canvas: self",
  1290. messageSends: ["fromString:canvas:"],
  1291. referencedClasses: ["TagBrush"]
  1292. }),
  1293. smalltalk.HTMLCanvas);
  1294. smalltalk.addMethod(
  1295. smalltalk.method({
  1296. selector: "noscript",
  1297. category: 'tags',
  1298. fn: function (){
  1299. var self=this;
  1300. return smalltalk.withContext(function($ctx1) {
  1301. var $1;
  1302. $1=self._tag_("noscript");
  1303. return $1;
  1304. }, function($ctx1) {$ctx1.fill(self,"noscript",{},smalltalk.HTMLCanvas)})},
  1305. args: [],
  1306. source: "noscript\x0a\x09^self tag: 'noscript'",
  1307. messageSends: ["tag:"],
  1308. referencedClasses: []
  1309. }),
  1310. smalltalk.HTMLCanvas);
  1311. smalltalk.addMethod(
  1312. smalltalk.method({
  1313. selector: "object",
  1314. category: 'tags',
  1315. fn: function (){
  1316. var self=this;
  1317. return smalltalk.withContext(function($ctx1) {
  1318. var $1;
  1319. $1=self._tag_("object");
  1320. return $1;
  1321. }, function($ctx1) {$ctx1.fill(self,"object",{},smalltalk.HTMLCanvas)})},
  1322. args: [],
  1323. source: "object\x0a\x09^self tag: 'object'",
  1324. messageSends: ["tag:"],
  1325. referencedClasses: []
  1326. }),
  1327. smalltalk.HTMLCanvas);
  1328. smalltalk.addMethod(
  1329. smalltalk.method({
  1330. selector: "ol",
  1331. category: 'tags',
  1332. fn: function (){
  1333. var self=this;
  1334. return smalltalk.withContext(function($ctx1) {
  1335. var $1;
  1336. $1=self._tag_("ol");
  1337. return $1;
  1338. }, function($ctx1) {$ctx1.fill(self,"ol",{},smalltalk.HTMLCanvas)})},
  1339. args: [],
  1340. source: "ol\x0a\x09^self tag: 'ol'",
  1341. messageSends: ["tag:"],
  1342. referencedClasses: []
  1343. }),
  1344. smalltalk.HTMLCanvas);
  1345. smalltalk.addMethod(
  1346. smalltalk.method({
  1347. selector: "ol:",
  1348. category: 'tags',
  1349. fn: function (anObject){
  1350. var self=this;
  1351. return smalltalk.withContext(function($ctx1) {
  1352. var $1;
  1353. $1=_st(self._ol())._with_(anObject);
  1354. return $1;
  1355. }, function($ctx1) {$ctx1.fill(self,"ol:",{anObject:anObject},smalltalk.HTMLCanvas)})},
  1356. args: ["anObject"],
  1357. source: "ol: anObject\x0a\x09^self ol with: anObject",
  1358. messageSends: ["with:", "ol"],
  1359. referencedClasses: []
  1360. }),
  1361. smalltalk.HTMLCanvas);
  1362. smalltalk.addMethod(
  1363. smalltalk.method({
  1364. selector: "optgroup",
  1365. category: 'tags',
  1366. fn: function (){
  1367. var self=this;
  1368. return smalltalk.withContext(function($ctx1) {
  1369. var $1;
  1370. $1=self._tag_("optgroup");
  1371. return $1;
  1372. }, function($ctx1) {$ctx1.fill(self,"optgroup",{},smalltalk.HTMLCanvas)})},
  1373. args: [],
  1374. source: "optgroup\x0a\x09^self tag: 'optgroup'",
  1375. messageSends: ["tag:"],
  1376. referencedClasses: []
  1377. }),
  1378. smalltalk.HTMLCanvas);
  1379. smalltalk.addMethod(
  1380. smalltalk.method({
  1381. selector: "option",
  1382. category: 'tags',
  1383. fn: function (){
  1384. var self=this;
  1385. return smalltalk.withContext(function($ctx1) {
  1386. var $1;
  1387. $1=self._tag_("option");
  1388. return $1;
  1389. }, function($ctx1) {$ctx1.fill(self,"option",{},smalltalk.HTMLCanvas)})},
  1390. args: [],
  1391. source: "option\x0a\x09^self tag: 'option'",
  1392. messageSends: ["tag:"],
  1393. referencedClasses: []
  1394. }),
  1395. smalltalk.HTMLCanvas);
  1396. smalltalk.addMethod(
  1397. smalltalk.method({
  1398. selector: "output",
  1399. category: 'tags',
  1400. fn: function (){
  1401. var self=this;
  1402. return smalltalk.withContext(function($ctx1) {
  1403. var $1;
  1404. $1=self._tag_("output");
  1405. return $1;
  1406. }, function($ctx1) {$ctx1.fill(self,"output",{},smalltalk.HTMLCanvas)})},
  1407. args: [],
  1408. source: "output\x0a\x09^self tag: 'output'",
  1409. messageSends: ["tag:"],
  1410. referencedClasses: []
  1411. }),
  1412. smalltalk.HTMLCanvas);
  1413. smalltalk.addMethod(
  1414. smalltalk.method({
  1415. selector: "p",
  1416. category: 'tags',
  1417. fn: function (){
  1418. var self=this;
  1419. return smalltalk.withContext(function($ctx1) {
  1420. var $1;
  1421. $1=self._tag_("p");
  1422. return $1;
  1423. }, function($ctx1) {$ctx1.fill(self,"p",{},smalltalk.HTMLCanvas)})},
  1424. args: [],
  1425. source: "p\x0a\x09^self tag: 'p'",
  1426. messageSends: ["tag:"],
  1427. referencedClasses: []
  1428. }),
  1429. smalltalk.HTMLCanvas);
  1430. smalltalk.addMethod(
  1431. smalltalk.method({
  1432. selector: "p:",
  1433. category: 'tags',
  1434. fn: function (anObject){
  1435. var self=this;
  1436. return smalltalk.withContext(function($ctx1) {
  1437. var $1;
  1438. $1=_st(self._p())._with_(anObject);
  1439. return $1;
  1440. }, function($ctx1) {$ctx1.fill(self,"p:",{anObject:anObject},smalltalk.HTMLCanvas)})},
  1441. args: ["anObject"],
  1442. source: "p: anObject\x0a\x09^self p with: anObject",
  1443. messageSends: ["with:", "p"],
  1444. referencedClasses: []
  1445. }),
  1446. smalltalk.HTMLCanvas);
  1447. smalltalk.addMethod(
  1448. smalltalk.method({
  1449. selector: "param",
  1450. category: 'tags',
  1451. fn: function (){
  1452. var self=this;
  1453. return smalltalk.withContext(function($ctx1) {
  1454. var $1;
  1455. $1=self._tag_("param");
  1456. return $1;
  1457. }, function($ctx1) {$ctx1.fill(self,"param",{},smalltalk.HTMLCanvas)})},
  1458. args: [],
  1459. source: "param\x0a\x09^self tag: 'param'",
  1460. messageSends: ["tag:"],
  1461. referencedClasses: []
  1462. }),
  1463. smalltalk.HTMLCanvas);
  1464. smalltalk.addMethod(
  1465. smalltalk.method({
  1466. selector: "pre",
  1467. category: 'tags',
  1468. fn: function (){
  1469. var self=this;
  1470. return smalltalk.withContext(function($ctx1) {
  1471. var $1;
  1472. $1=self._tag_("pre");
  1473. return $1;
  1474. }, function($ctx1) {$ctx1.fill(self,"pre",{},smalltalk.HTMLCanvas)})},
  1475. args: [],
  1476. source: "pre\x0a\x09^self tag: 'pre'",
  1477. messageSends: ["tag:"],
  1478. referencedClasses: []
  1479. }),
  1480. smalltalk.HTMLCanvas);
  1481. smalltalk.addMethod(
  1482. smalltalk.method({
  1483. selector: "progress",
  1484. category: 'tags',
  1485. fn: function (){
  1486. var self=this;
  1487. return smalltalk.withContext(function($ctx1) {
  1488. var $1;
  1489. $1=self._tag_("progress");
  1490. return $1;
  1491. }, function($ctx1) {$ctx1.fill(self,"progress",{},smalltalk.HTMLCanvas)})},
  1492. args: [],
  1493. source: "progress\x0a\x09^self tag: 'progress'",
  1494. messageSends: ["tag:"],
  1495. referencedClasses: []
  1496. }),
  1497. smalltalk.HTMLCanvas);
  1498. smalltalk.addMethod(
  1499. smalltalk.method({
  1500. selector: "root",
  1501. category: 'accessing',
  1502. fn: function (){
  1503. var self=this;
  1504. return smalltalk.withContext(function($ctx1) {
  1505. var $1;
  1506. $1=self["@root"];
  1507. return $1;
  1508. }, function($ctx1) {$ctx1.fill(self,"root",{},smalltalk.HTMLCanvas)})},
  1509. args: [],
  1510. source: "root\x0a\x09^root",
  1511. messageSends: [],
  1512. referencedClasses: []
  1513. }),
  1514. smalltalk.HTMLCanvas);
  1515. smalltalk.addMethod(
  1516. smalltalk.method({
  1517. selector: "root:",
  1518. category: 'accessing',
  1519. fn: function (aTagBrush){
  1520. var self=this;
  1521. return smalltalk.withContext(function($ctx1) {
  1522. self["@root"]=aTagBrush;
  1523. return self}, function($ctx1) {$ctx1.fill(self,"root:",{aTagBrush:aTagBrush},smalltalk.HTMLCanvas)})},
  1524. args: ["aTagBrush"],
  1525. source: "root: aTagBrush\x0a\x09root := aTagBrush",
  1526. messageSends: [],
  1527. referencedClasses: []
  1528. }),
  1529. smalltalk.HTMLCanvas);
  1530. smalltalk.addMethod(
  1531. smalltalk.method({
  1532. selector: "script",
  1533. category: 'tags',
  1534. fn: function (){
  1535. var self=this;
  1536. return smalltalk.withContext(function($ctx1) {
  1537. var $1;
  1538. $1=self._tag_("script");
  1539. return $1;
  1540. }, function($ctx1) {$ctx1.fill(self,"script",{},smalltalk.HTMLCanvas)})},
  1541. args: [],
  1542. source: "script\x0a\x09^self tag: 'script'",
  1543. messageSends: ["tag:"],
  1544. referencedClasses: []
  1545. }),
  1546. smalltalk.HTMLCanvas);
  1547. smalltalk.addMethod(
  1548. smalltalk.method({
  1549. selector: "section",
  1550. category: 'tags',
  1551. fn: function (){
  1552. var self=this;
  1553. return smalltalk.withContext(function($ctx1) {
  1554. var $1;
  1555. $1=self._tag_("section");
  1556. return $1;
  1557. }, function($ctx1) {$ctx1.fill(self,"section",{},smalltalk.HTMLCanvas)})},
  1558. args: [],
  1559. source: "section\x0a\x09^self tag: 'section'",
  1560. messageSends: ["tag:"],
  1561. referencedClasses: []
  1562. }),
  1563. smalltalk.HTMLCanvas);
  1564. smalltalk.addMethod(
  1565. smalltalk.method({
  1566. selector: "select",
  1567. category: 'tags',
  1568. fn: function (){
  1569. var self=this;
  1570. return smalltalk.withContext(function($ctx1) {
  1571. var $1;
  1572. $1=self._tag_("select");
  1573. return $1;
  1574. }, function($ctx1) {$ctx1.fill(self,"select",{},smalltalk.HTMLCanvas)})},
  1575. args: [],
  1576. source: "select\x0a\x09^self tag: 'select'",
  1577. messageSends: ["tag:"],
  1578. referencedClasses: []
  1579. }),
  1580. smalltalk.HTMLCanvas);
  1581. smalltalk.addMethod(
  1582. smalltalk.method({
  1583. selector: "small",
  1584. category: 'tags',
  1585. fn: function (){
  1586. var self=this;
  1587. return smalltalk.withContext(function($ctx1) {
  1588. var $1;
  1589. $1=self._tag_("small");
  1590. return $1;
  1591. }, function($ctx1) {$ctx1.fill(self,"small",{},smalltalk.HTMLCanvas)})},
  1592. args: [],
  1593. source: "small\x0a\x09^self tag: 'small'",
  1594. messageSends: ["tag:"],
  1595. referencedClasses: []
  1596. }),
  1597. smalltalk.HTMLCanvas);
  1598. smalltalk.addMethod(
  1599. smalltalk.method({
  1600. selector: "snippet:",
  1601. category: 'accessing',
  1602. fn: function (anElement){
  1603. var self=this;
  1604. var clone,caret;
  1605. function $TagBrush(){return smalltalk.TagBrush||(typeof TagBrush=="undefined"?nil:TagBrush)}
  1606. return smalltalk.withContext(function($ctx1) {
  1607. var $1,$2;
  1608. clone=_st(_st(anElement)._asJQuery())._clone();
  1609. self._with_(_st($TagBrush())._fromJQuery_canvas_(clone,self));
  1610. caret=_st(clone)._find_("[data-snippet=\x22*\x22]");
  1611. $1=_st(_st(caret)._toArray())._isEmpty();
  1612. if(smalltalk.assert($1)){
  1613. caret=clone;
  1614. caret;
  1615. };
  1616. $2=_st($TagBrush())._fromJQuery_canvas_(_st(caret)._removeAttr_("data-snippet"),self);
  1617. return $2;
  1618. }, function($ctx1) {$ctx1.fill(self,"snippet:",{anElement:anElement,clone:clone,caret:caret},smalltalk.HTMLCanvas)})},
  1619. args: ["anElement"],
  1620. source: "snippet: anElement\x0a\x09\x22Adds clone of anElement, finds [data-snippet=\x22\x22*\x22\x22] subelement\x0a\x09and returns TagBrush as if that subelement was just added.\x0a\x09\x0a\x09Rarely needed to use directly, use `html foo` dynamically installed method\x0a\x09for a snippet named foo.\x22\x0a\x09\x0a\x09| clone caret |\x0a\x09\x0a\x09clone := anElement asJQuery clone.\x0a\x09self with: (TagBrush fromJQuery: clone canvas: self).\x0a\x09caret := clone find: '[data-snippet=\x22*\x22]'.\x0a\x09caret toArray isEmpty ifTrue: [ caret := clone ].\x0a\x09^TagBrush fromJQuery: (caret removeAttr: 'data-snippet') canvas: self",
  1621. messageSends: ["clone", "asJQuery", "with:", "fromJQuery:canvas:", "find:", "ifTrue:", "isEmpty", "toArray", "removeAttr:"],
  1622. referencedClasses: ["TagBrush"]
  1623. }),
  1624. smalltalk.HTMLCanvas);
  1625. smalltalk.addMethod(
  1626. smalltalk.method({
  1627. selector: "source",
  1628. category: 'tags',
  1629. fn: function (){
  1630. var self=this;
  1631. return smalltalk.withContext(function($ctx1) {
  1632. var $1;
  1633. $1=self._tag_("source");
  1634. return $1;
  1635. }, function($ctx1) {$ctx1.fill(self,"source",{},smalltalk.HTMLCanvas)})},
  1636. args: [],
  1637. source: "source\x0a\x09^self tag: 'source'",
  1638. messageSends: ["tag:"],
  1639. referencedClasses: []
  1640. }),
  1641. smalltalk.HTMLCanvas);
  1642. smalltalk.addMethod(
  1643. smalltalk.method({
  1644. selector: "span",
  1645. category: 'tags',
  1646. fn: function (){
  1647. var self=this;
  1648. return smalltalk.withContext(function($ctx1) {
  1649. var $1;
  1650. $1=self._tag_("span");
  1651. return $1;
  1652. }, function($ctx1) {$ctx1.fill(self,"span",{},smalltalk.HTMLCanvas)})},
  1653. args: [],
  1654. source: "span\x0a\x09^self tag: 'span'",
  1655. messageSends: ["tag:"],
  1656. referencedClasses: []
  1657. }),
  1658. smalltalk.HTMLCanvas);
  1659. smalltalk.addMethod(
  1660. smalltalk.method({
  1661. selector: "span:",
  1662. category: 'tags',
  1663. fn: function (anObject){
  1664. var self=this;
  1665. return smalltalk.withContext(function($ctx1) {
  1666. var $1;
  1667. $1=_st(self._span())._with_(anObject);
  1668. return $1;
  1669. }, function($ctx1) {$ctx1.fill(self,"span:",{anObject:anObject},smalltalk.HTMLCanvas)})},
  1670. args: ["anObject"],
  1671. source: "span: anObject\x0a\x09^self span with: anObject",
  1672. messageSends: ["with:", "span"],
  1673. referencedClasses: []
  1674. }),
  1675. smalltalk.HTMLCanvas);
  1676. smalltalk.addMethod(
  1677. smalltalk.method({
  1678. selector: "strong",
  1679. category: 'tags',
  1680. fn: function (){
  1681. var self=this;
  1682. return smalltalk.withContext(function($ctx1) {
  1683. var $1;
  1684. $1=self._tag_("strong");
  1685. return $1;
  1686. }, function($ctx1) {$ctx1.fill(self,"strong",{},smalltalk.HTMLCanvas)})},
  1687. args: [],
  1688. source: "strong\x0a\x09^self tag: 'strong'",
  1689. messageSends: ["tag:"],
  1690. referencedClasses: []
  1691. }),
  1692. smalltalk.HTMLCanvas);
  1693. smalltalk.addMethod(
  1694. smalltalk.method({
  1695. selector: "strong:",
  1696. category: 'tags',
  1697. fn: function (anObject){
  1698. var self=this;
  1699. return smalltalk.withContext(function($ctx1) {
  1700. var $1;
  1701. $1=_st(self._strong())._with_(anObject);
  1702. return $1;
  1703. }, function($ctx1) {$ctx1.fill(self,"strong:",{anObject:anObject},smalltalk.HTMLCanvas)})},
  1704. args: ["anObject"],
  1705. source: "strong: anObject\x0a\x09^self strong with: anObject",
  1706. messageSends: ["with:", "strong"],
  1707. referencedClasses: []
  1708. }),
  1709. smalltalk.HTMLCanvas);
  1710. smalltalk.addMethod(
  1711. smalltalk.method({
  1712. selector: "style",
  1713. category: 'tags',
  1714. fn: function (){
  1715. var self=this;
  1716. function $StyleTag(){return smalltalk.StyleTag||(typeof StyleTag=="undefined"?nil:StyleTag)}
  1717. return smalltalk.withContext(function($ctx1) {
  1718. var $1;
  1719. $1=_st(self["@root"])._addBrush_(_st($StyleTag())._canvas_(self));
  1720. return $1;
  1721. }, function($ctx1) {$ctx1.fill(self,"style",{},smalltalk.HTMLCanvas)})},
  1722. args: [],
  1723. source: "style\x0a\x09^ root addBrush: (StyleTag canvas: self)",
  1724. messageSends: ["addBrush:", "canvas:"],
  1725. referencedClasses: ["StyleTag"]
  1726. }),
  1727. smalltalk.HTMLCanvas);
  1728. smalltalk.addMethod(
  1729. smalltalk.method({
  1730. selector: "style:",
  1731. category: 'tags',
  1732. fn: function (aString){
  1733. var self=this;
  1734. return smalltalk.withContext(function($ctx1) {
  1735. var $2,$3,$1;
  1736. $2=self._style();
  1737. _st($2)._with_(aString);
  1738. $3=_st($2)._yourself();
  1739. $1=$3;
  1740. return $1;
  1741. }, function($ctx1) {$ctx1.fill(self,"style:",{aString:aString},smalltalk.HTMLCanvas)})},
  1742. args: ["aString"],
  1743. source: "style: aString\x0a\x09^ self style with: aString; yourself",
  1744. messageSends: ["with:", "style", "yourself"],
  1745. referencedClasses: []
  1746. }),
  1747. smalltalk.HTMLCanvas);
  1748. smalltalk.addMethod(
  1749. smalltalk.method({
  1750. selector: "sub",
  1751. category: 'tags',
  1752. fn: function (){
  1753. var self=this;
  1754. return smalltalk.withContext(function($ctx1) {
  1755. var $1;
  1756. $1=self._tag_("sub");
  1757. return $1;
  1758. }, function($ctx1) {$ctx1.fill(self,"sub",{},smalltalk.HTMLCanvas)})},
  1759. args: [],
  1760. source: "sub\x0a\x09^self tag: 'sub'",
  1761. messageSends: ["tag:"],
  1762. referencedClasses: []
  1763. }),
  1764. smalltalk.HTMLCanvas);
  1765. smalltalk.addMethod(
  1766. smalltalk.method({
  1767. selector: "summary",
  1768. category: 'tags',
  1769. fn: function (){
  1770. var self=this;
  1771. return smalltalk.withContext(function($ctx1) {
  1772. var $1;
  1773. $1=self._tag_("summary");
  1774. return $1;
  1775. }, function($ctx1) {$ctx1.fill(self,"summary",{},smalltalk.HTMLCanvas)})},
  1776. args: [],
  1777. source: "summary\x0a\x09^self tag: 'summary'",
  1778. messageSends: ["tag:"],
  1779. referencedClasses: []
  1780. }),
  1781. smalltalk.HTMLCanvas);
  1782. smalltalk.addMethod(
  1783. smalltalk.method({
  1784. selector: "sup",
  1785. category: 'tags',
  1786. fn: function (){
  1787. var self=this;
  1788. return smalltalk.withContext(function($ctx1) {
  1789. var $1;
  1790. $1=self._tag_("sup");
  1791. return $1;
  1792. }, function($ctx1) {$ctx1.fill(self,"sup",{},smalltalk.HTMLCanvas)})},
  1793. args: [],
  1794. source: "sup\x0a\x09^self tag: 'sup'",
  1795. messageSends: ["tag:"],
  1796. referencedClasses: []
  1797. }),
  1798. smalltalk.HTMLCanvas);
  1799. smalltalk.addMethod(
  1800. smalltalk.method({
  1801. selector: "table",
  1802. category: 'tags',
  1803. fn: function (){
  1804. var self=this;
  1805. return smalltalk.withContext(function($ctx1) {
  1806. var $1;
  1807. $1=self._tag_("table");
  1808. return $1;
  1809. }, function($ctx1) {$ctx1.fill(self,"table",{},smalltalk.HTMLCanvas)})},
  1810. args: [],
  1811. source: "table\x0a\x09^self tag: 'table'",
  1812. messageSends: ["tag:"],
  1813. referencedClasses: []
  1814. }),
  1815. smalltalk.HTMLCanvas);
  1816. smalltalk.addMethod(
  1817. smalltalk.method({
  1818. selector: "tag:",
  1819. category: 'tags',
  1820. fn: function (aString){
  1821. var self=this;
  1822. return smalltalk.withContext(function($ctx1) {
  1823. var $1;
  1824. $1=_st(self["@root"])._addBrush_(self._newTag_(aString));
  1825. return $1;
  1826. }, function($ctx1) {$ctx1.fill(self,"tag:",{aString:aString},smalltalk.HTMLCanvas)})},
  1827. args: ["aString"],
  1828. source: "tag: aString\x0a\x09^root addBrush: (self newTag: aString)",
  1829. messageSends: ["addBrush:", "newTag:"],
  1830. referencedClasses: []
  1831. }),
  1832. smalltalk.HTMLCanvas);
  1833. smalltalk.addMethod(
  1834. smalltalk.method({
  1835. selector: "tbody",
  1836. category: 'tags',
  1837. fn: function (){
  1838. var self=this;
  1839. return smalltalk.withContext(function($ctx1) {
  1840. var $1;
  1841. $1=self._tag_("tbody");
  1842. return $1;
  1843. }, function($ctx1) {$ctx1.fill(self,"tbody",{},smalltalk.HTMLCanvas)})},
  1844. args: [],
  1845. source: "tbody\x0a\x09^self tag: 'tbody'",
  1846. messageSends: ["tag:"],
  1847. referencedClasses: []
  1848. }),
  1849. smalltalk.HTMLCanvas);
  1850. smalltalk.addMethod(
  1851. smalltalk.method({
  1852. selector: "td",
  1853. category: 'tags',
  1854. fn: function (){
  1855. var self=this;
  1856. return smalltalk.withContext(function($ctx1) {
  1857. var $1;
  1858. $1=self._tag_("td");
  1859. return $1;
  1860. }, function($ctx1) {$ctx1.fill(self,"td",{},smalltalk.HTMLCanvas)})},
  1861. args: [],
  1862. source: "td\x0a\x09^self tag: 'td'",
  1863. messageSends: ["tag:"],
  1864. referencedClasses: []
  1865. }),
  1866. smalltalk.HTMLCanvas);
  1867. smalltalk.addMethod(
  1868. smalltalk.method({
  1869. selector: "textarea",
  1870. category: 'tags',
  1871. fn: function (){
  1872. var self=this;
  1873. return smalltalk.withContext(function($ctx1) {
  1874. var $1;
  1875. $1=self._tag_("textarea");
  1876. return $1;
  1877. }, function($ctx1) {$ctx1.fill(self,"textarea",{},smalltalk.HTMLCanvas)})},
  1878. args: [],
  1879. source: "textarea\x0a\x09^self tag: 'textarea'",
  1880. messageSends: ["tag:"],
  1881. referencedClasses: []
  1882. }),
  1883. smalltalk.HTMLCanvas);
  1884. smalltalk.addMethod(
  1885. smalltalk.method({
  1886. selector: "tfoot",
  1887. category: 'tags',
  1888. fn: function (){
  1889. var self=this;
  1890. return smalltalk.withContext(function($ctx1) {
  1891. var $1;
  1892. $1=self._tag_("tfoot");
  1893. return $1;
  1894. }, function($ctx1) {$ctx1.fill(self,"tfoot",{},smalltalk.HTMLCanvas)})},
  1895. args: [],
  1896. source: "tfoot\x0a\x09^self tag: 'tfoot'",
  1897. messageSends: ["tag:"],
  1898. referencedClasses: []
  1899. }),
  1900. smalltalk.HTMLCanvas);
  1901. smalltalk.addMethod(
  1902. smalltalk.method({
  1903. selector: "th",
  1904. category: 'tags',
  1905. fn: function (){
  1906. var self=this;
  1907. return smalltalk.withContext(function($ctx1) {
  1908. var $1;
  1909. $1=self._tag_("th");
  1910. return $1;
  1911. }, function($ctx1) {$ctx1.fill(self,"th",{},smalltalk.HTMLCanvas)})},
  1912. args: [],
  1913. source: "th\x0a\x09^self tag: 'th'",
  1914. messageSends: ["tag:"],
  1915. referencedClasses: []
  1916. }),
  1917. smalltalk.HTMLCanvas);
  1918. smalltalk.addMethod(
  1919. smalltalk.method({
  1920. selector: "thead",
  1921. category: 'tags',
  1922. fn: function (){
  1923. var self=this;
  1924. return smalltalk.withContext(function($ctx1) {
  1925. var $1;
  1926. $1=self._tag_("thead");
  1927. return $1;
  1928. }, function($ctx1) {$ctx1.fill(self,"thead",{},smalltalk.HTMLCanvas)})},
  1929. args: [],
  1930. source: "thead\x0a\x09^self tag: 'thead'",
  1931. messageSends: ["tag:"],
  1932. referencedClasses: []
  1933. }),
  1934. smalltalk.HTMLCanvas);
  1935. smalltalk.addMethod(
  1936. smalltalk.method({
  1937. selector: "time",
  1938. category: 'tags',
  1939. fn: function (){
  1940. var self=this;
  1941. return smalltalk.withContext(function($ctx1) {
  1942. var $1;
  1943. $1=self._tag_("time");
  1944. return $1;
  1945. }, function($ctx1) {$ctx1.fill(self,"time",{},smalltalk.HTMLCanvas)})},
  1946. args: [],
  1947. source: "time\x0a\x09^self tag: 'time'",
  1948. messageSends: ["tag:"],
  1949. referencedClasses: []
  1950. }),
  1951. smalltalk.HTMLCanvas);
  1952. smalltalk.addMethod(
  1953. smalltalk.method({
  1954. selector: "title",
  1955. category: 'tags',
  1956. fn: function (){
  1957. var self=this;
  1958. return smalltalk.withContext(function($ctx1) {
  1959. var $1;
  1960. $1=self._tag_("title");
  1961. return $1;
  1962. }, function($ctx1) {$ctx1.fill(self,"title",{},smalltalk.HTMLCanvas)})},
  1963. args: [],
  1964. source: "title\x0a\x09^self tag: 'title'",
  1965. messageSends: ["tag:"],
  1966. referencedClasses: []
  1967. }),
  1968. smalltalk.HTMLCanvas);
  1969. smalltalk.addMethod(
  1970. smalltalk.method({
  1971. selector: "tr",
  1972. category: 'tags',
  1973. fn: function (){
  1974. var self=this;
  1975. return smalltalk.withContext(function($ctx1) {
  1976. var $1;
  1977. $1=self._tag_("tr");
  1978. return $1;
  1979. }, function($ctx1) {$ctx1.fill(self,"tr",{},smalltalk.HTMLCanvas)})},
  1980. args: [],
  1981. source: "tr\x0a\x09^self tag: 'tr'",
  1982. messageSends: ["tag:"],
  1983. referencedClasses: []
  1984. }),
  1985. smalltalk.HTMLCanvas);
  1986. smalltalk.addMethod(
  1987. smalltalk.method({
  1988. selector: "ul",
  1989. category: 'tags',
  1990. fn: function (){
  1991. var self=this;
  1992. return smalltalk.withContext(function($ctx1) {
  1993. var $1;
  1994. $1=self._tag_("ul");
  1995. return $1;
  1996. }, function($ctx1) {$ctx1.fill(self,"ul",{},smalltalk.HTMLCanvas)})},
  1997. args: [],
  1998. source: "ul\x0a\x09^self tag: 'ul'",
  1999. messageSends: ["tag:"],
  2000. referencedClasses: []
  2001. }),
  2002. smalltalk.HTMLCanvas);
  2003. smalltalk.addMethod(
  2004. smalltalk.method({
  2005. selector: "ul:",
  2006. category: 'tags',
  2007. fn: function (anObject){
  2008. var self=this;
  2009. return smalltalk.withContext(function($ctx1) {
  2010. var $1;
  2011. $1=_st(self._ul())._with_(anObject);
  2012. return $1;
  2013. }, function($ctx1) {$ctx1.fill(self,"ul:",{anObject:anObject},smalltalk.HTMLCanvas)})},
  2014. args: ["anObject"],
  2015. source: "ul: anObject\x0a\x09^self ul with: anObject",
  2016. messageSends: ["with:", "ul"],
  2017. referencedClasses: []
  2018. }),
  2019. smalltalk.HTMLCanvas);
  2020. smalltalk.addMethod(
  2021. smalltalk.method({
  2022. selector: "video",
  2023. category: 'tags',
  2024. fn: function (){
  2025. var self=this;
  2026. return smalltalk.withContext(function($ctx1) {
  2027. var $1;
  2028. $1=self._tag_("video");
  2029. return $1;
  2030. }, function($ctx1) {$ctx1.fill(self,"video",{},smalltalk.HTMLCanvas)})},
  2031. args: [],
  2032. source: "video\x0a\x09^self tag: 'video'",
  2033. messageSends: ["tag:"],
  2034. referencedClasses: []
  2035. }),
  2036. smalltalk.HTMLCanvas);
  2037. smalltalk.addMethod(
  2038. smalltalk.method({
  2039. selector: "with:",
  2040. category: 'adding',
  2041. fn: function (anObject){
  2042. var self=this;
  2043. return smalltalk.withContext(function($ctx1) {
  2044. var $1;
  2045. $1=_st(self._root())._with_(anObject);
  2046. return $1;
  2047. }, function($ctx1) {$ctx1.fill(self,"with:",{anObject:anObject},smalltalk.HTMLCanvas)})},
  2048. args: ["anObject"],
  2049. source: "with: anObject\x0a\x09^self root with: anObject",
  2050. messageSends: ["with:", "root"],
  2051. referencedClasses: []
  2052. }),
  2053. smalltalk.HTMLCanvas);
  2054. smalltalk.addMethod(
  2055. smalltalk.method({
  2056. selector: "browserVersion",
  2057. category: 'instance creation',
  2058. fn: function (){
  2059. var self=this;
  2060. return smalltalk.withContext(function($ctx1) {
  2061. var $1;
  2062. $1=_st(_st(jQuery)._at_("browser"))._version();
  2063. return $1;
  2064. }, function($ctx1) {$ctx1.fill(self,"browserVersion",{},smalltalk.HTMLCanvas.klass)})},
  2065. args: [],
  2066. source: "browserVersion\x0a\x09^(jQuery at: #browser) version",
  2067. messageSends: ["version", "at:"],
  2068. referencedClasses: []
  2069. }),
  2070. smalltalk.HTMLCanvas.klass);
  2071. smalltalk.addMethod(
  2072. smalltalk.method({
  2073. selector: "isMSIE",
  2074. category: 'instance creation',
  2075. fn: function (){
  2076. var self=this;
  2077. return smalltalk.withContext(function($ctx1) {
  2078. var $1;
  2079. $1=_st(_st(_st(jQuery)._at_("browser"))._at_("msie"))._notNil();
  2080. return $1;
  2081. }, function($ctx1) {$ctx1.fill(self,"isMSIE",{},smalltalk.HTMLCanvas.klass)})},
  2082. args: [],
  2083. source: "isMSIE\x0a\x09^((jQuery at: #browser) at: #msie) notNil",
  2084. messageSends: ["notNil", "at:"],
  2085. referencedClasses: []
  2086. }),
  2087. smalltalk.HTMLCanvas.klass);
  2088. smalltalk.addMethod(
  2089. smalltalk.method({
  2090. selector: "isMozilla",
  2091. category: 'instance creation',
  2092. fn: function (){
  2093. var self=this;
  2094. return smalltalk.withContext(function($ctx1) {
  2095. var $1;
  2096. $1=_st(_st(_st(jQuery)._at_("browser"))._at_("mozilla"))._notNil();
  2097. return $1;
  2098. }, function($ctx1) {$ctx1.fill(self,"isMozilla",{},smalltalk.HTMLCanvas.klass)})},
  2099. args: [],
  2100. source: "isMozilla\x0a\x09^((jQuery at: #browser) at: #mozilla) notNil",
  2101. messageSends: ["notNil", "at:"],
  2102. referencedClasses: []
  2103. }),
  2104. smalltalk.HTMLCanvas.klass);
  2105. smalltalk.addMethod(
  2106. smalltalk.method({
  2107. selector: "isOpera",
  2108. category: 'instance creation',
  2109. fn: function (){
  2110. var self=this;
  2111. return smalltalk.withContext(function($ctx1) {
  2112. var $1;
  2113. $1=_st(_st(_st(jQuery)._at_("browser"))._at_("opera"))._notNil();
  2114. return $1;
  2115. }, function($ctx1) {$ctx1.fill(self,"isOpera",{},smalltalk.HTMLCanvas.klass)})},
  2116. args: [],
  2117. source: "isOpera\x0a\x09^((jQuery at: #browser) at: #opera) notNil",
  2118. messageSends: ["notNil", "at:"],
  2119. referencedClasses: []
  2120. }),
  2121. smalltalk.HTMLCanvas.klass);
  2122. smalltalk.addMethod(
  2123. smalltalk.method({
  2124. selector: "isWebkit",
  2125. category: 'instance creation',
  2126. fn: function (){
  2127. var self=this;
  2128. return smalltalk.withContext(function($ctx1) {
  2129. var $1;
  2130. $1=_st(_st(_st(jQuery)._at_("browser"))._at_("webkit"))._notNil();
  2131. return $1;
  2132. }, function($ctx1) {$ctx1.fill(self,"isWebkit",{},smalltalk.HTMLCanvas.klass)})},
  2133. args: [],
  2134. source: "isWebkit\x0a\x09^((jQuery at: #browser) at: #webkit) notNil",
  2135. messageSends: ["notNil", "at:"],
  2136. referencedClasses: []
  2137. }),
  2138. smalltalk.HTMLCanvas.klass);
  2139. smalltalk.addMethod(
  2140. smalltalk.method({
  2141. selector: "onJQuery:",
  2142. category: 'instance creation',
  2143. fn: function (aJQuery){
  2144. var self=this;
  2145. return smalltalk.withContext(function($ctx1) {
  2146. var $2,$3,$1;
  2147. $2=self._basicNew();
  2148. _st($2)._initializeFromJQuery_(aJQuery);
  2149. _st($2)._initialize();
  2150. $3=_st($2)._yourself();
  2151. $1=$3;
  2152. return $1;
  2153. }, function($ctx1) {$ctx1.fill(self,"onJQuery:",{aJQuery:aJQuery},smalltalk.HTMLCanvas.klass)})},
  2154. args: ["aJQuery"],
  2155. source: "onJQuery: aJQuery\x0a\x09^self basicNew\x0a\x09\x09initializeFromJQuery: aJQuery;\x0a\x09\x09initialize;\x0a\x09\x09yourself",
  2156. messageSends: ["initializeFromJQuery:", "basicNew", "initialize", "yourself"],
  2157. referencedClasses: []
  2158. }),
  2159. smalltalk.HTMLCanvas.klass);
  2160. smalltalk.addClass('HTMLSnippet', smalltalk.Object, ['snippets'], 'Canvas');
  2161. smalltalk.HTMLSnippet.comment="My sole instance is the registry of html snippets.\x0a`HTMLSnippet current` is the public singleton instance.\x0a\x0aOn startup, it scans the document for any html elements\x0awith `'data-snippet=\x22foo\x22'` attribute and takes them off the document,\x0aremembering them in the store under the specified name.\x0aIt also install method #foo into HTMLCanvas dynamically.\x0a\x0aEvery html snippet should mark a 'caret', a place where contents\x0acan be inserted, by 'data-snippet=\x22*\x22' (a special name for caret).\x0aFor example:\x0a\x0a`<li data-snippet='menuelement' class='...'><a data-snippet='*'></a></li>`\x0a\x0adefines a list element with a link inside; the link itself is marked as a caret.\x0a\x0aYou can later issue\x0a\x0a`html menuelement href: '/foo'; with: 'A foo'`\x0a\x0ato insert the whole snippet and directly manipulate the caret, so it renders:\x0a\x0a`<li class='...'><a href='/foo'>A foo</a></li>`\x0a\x0aFor a self-careting tags (not very useful, but you do not need to fill class etc.\x0ayou can use\x0a\x0a`<div class='lots of classes' attr1='one' attr2='two' data-snippet='*bar'></div>`\x0a\x0aand in code later do:\x0a\x0a`html bar with: [ xxx ]`\x0a\x0ato render\x0a\x0a`<div class='lots of classes' attr1='one' attr2='two'>...added by xxx...</div>`";
  2162. smalltalk.addMethod(
  2163. smalltalk.method({
  2164. selector: "initializeFromJQuery:",
  2165. category: 'initialization',
  2166. fn: function (aJQuery){
  2167. var self=this;
  2168. return smalltalk.withContext(function($ctx1) {
  2169. _st(self._snippetsFromJQuery_(aJQuery))._do_((function(each){
  2170. return smalltalk.withContext(function($ctx2) {
  2171. return self._installSnippetFromJQuery_(_st(each)._asJQuery());
  2172. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)})}));
  2173. return self}, function($ctx1) {$ctx1.fill(self,"initializeFromJQuery:",{aJQuery:aJQuery},smalltalk.HTMLSnippet)})},
  2174. args: ["aJQuery"],
  2175. source: "initializeFromJQuery: aJQuery\x0a\x09\x22Finds and takes out all snippets out of aJQuery.\x0a\x09Installs it into self.\x22\x0a\x09\x0a\x09(self snippetsFromJQuery: aJQuery) do: [ :each |\x0a\x09\x09self installSnippetFromJQuery: each asJQuery ]",
  2176. messageSends: ["do:", "snippetsFromJQuery:", "installSnippetFromJQuery:", "asJQuery"],
  2177. referencedClasses: []
  2178. }),
  2179. smalltalk.HTMLSnippet);
  2180. smalltalk.addMethod(
  2181. smalltalk.method({
  2182. selector: "installSnippetFromJQuery:",
  2183. category: 'snippet installation',
  2184. fn: function (element){
  2185. var self=this;
  2186. var name;
  2187. return smalltalk.withContext(function($ctx1) {
  2188. var $1,$2;
  2189. name=_st(element)._attr_("data-snippet");
  2190. $1=_st(name).__eq("*");
  2191. if(! smalltalk.assert($1)){
  2192. $2=_st("^\x5c*"._asRegexp())._test_(name);
  2193. if(smalltalk.assert($2)){
  2194. name=_st(name)._allButFirst();
  2195. name;
  2196. _st(element)._attr_put_("data-snippet","*");
  2197. } else {
  2198. _st(element)._removeAttr_("data-snippet");
  2199. };
  2200. self._snippetAt_install_(name,_st(_st(element)._detach())._get_((0)));
  2201. };
  2202. return self}, function($ctx1) {$ctx1.fill(self,"installSnippetFromJQuery:",{element:element,name:name},smalltalk.HTMLSnippet)})},
  2203. args: ["element"],
  2204. source: "installSnippetFromJQuery: element\x0a\x09| name |\x0a\x09name := element attr: 'data-snippet'.\x0a\x09name = '*' ifFalse: [\x0a\x09\x09('^\x5c*' asRegexp test: name)\x0a\x09\x09\x09ifTrue: [\x0a\x09\x09\x09\x09name := name allButFirst.\x0a\x09\x09\x09\x09element attr: 'data-snippet' put: '*' ]\x0a\x09\x09\x09ifFalse: [\x0a\x09\x09\x09\x09element removeAttr: 'data-snippet' ].\x0a\x09\x09self snippetAt: name install: (element detach get: 0) ]",
  2205. messageSends: ["attr:", "ifFalse:", "=", "ifTrue:ifFalse:", "test:", "asRegexp", "allButFirst", "attr:put:", "removeAttr:", "snippetAt:install:", "get:", "detach"],
  2206. referencedClasses: []
  2207. }),
  2208. smalltalk.HTMLSnippet);
  2209. smalltalk.addMethod(
  2210. smalltalk.method({
  2211. selector: "snippetAt:",
  2212. category: 'accessing',
  2213. fn: function (aString){
  2214. var self=this;
  2215. return smalltalk.withContext(function($ctx1) {
  2216. var $1;
  2217. $1=_st(self._snippets())._at_(aString);
  2218. return $1;
  2219. }, function($ctx1) {$ctx1.fill(self,"snippetAt:",{aString:aString},smalltalk.HTMLSnippet)})},
  2220. args: ["aString"],
  2221. source: "snippetAt: aString\x0a\x09^ self snippets at: aString",
  2222. messageSends: ["at:", "snippets"],
  2223. referencedClasses: []
  2224. }),
  2225. smalltalk.HTMLSnippet);
  2226. smalltalk.addMethod(
  2227. smalltalk.method({
  2228. selector: "snippetAt:compile:",
  2229. category: 'method generation',
  2230. fn: function (aString,anElement){
  2231. var self=this;
  2232. function $ClassBuilder(){return smalltalk.ClassBuilder||(typeof ClassBuilder=="undefined"?nil:ClassBuilder)}
  2233. function $HTMLCanvas(){return smalltalk.HTMLCanvas||(typeof HTMLCanvas=="undefined"?nil:HTMLCanvas)}
  2234. return smalltalk.withContext(function($ctx1) {
  2235. _st(_st($ClassBuilder())._new())._installMethod_forClass_category_(_st(_st((function(htmlReceiver){
  2236. return smalltalk.withContext(function($ctx2) {
  2237. return _st(htmlReceiver)._snippet_(anElement);
  2238. }, function($ctx2) {$ctx2.fillBlock({htmlReceiver:htmlReceiver},$ctx1,1)})}))._currySelf())._asCompiledMethod_(aString),$HTMLCanvas(),"**snippets");
  2239. return self}, function($ctx1) {$ctx1.fill(self,"snippetAt:compile:",{aString:aString,anElement:anElement},smalltalk.HTMLSnippet)})},
  2240. args: ["aString", "anElement"],
  2241. source: "snippetAt: aString compile: anElement\x0a\x09\x22Method generation for the snippet.\x0a\x09The selector is aString, the method block uses anElement\x22\x0a\x09\x0a\x09ClassBuilder new\x0a\x09\x09installMethod: ([ :htmlReceiver | htmlReceiver snippet: anElement ]\x0a\x09\x09\x09currySelf asCompiledMethod: aString)\x0a\x09\x09forClass: HTMLCanvas\x0a\x09\x09category: '**snippets'",
  2242. messageSends: ["installMethod:forClass:category:", "new", "asCompiledMethod:", "currySelf", "snippet:"],
  2243. referencedClasses: ["ClassBuilder", "HTMLCanvas"]
  2244. }),
  2245. smalltalk.HTMLSnippet);
  2246. smalltalk.addMethod(
  2247. smalltalk.method({
  2248. selector: "snippetAt:install:",
  2249. category: 'snippet installation',
  2250. fn: function (aString,anElement){
  2251. var self=this;
  2252. return smalltalk.withContext(function($ctx1) {
  2253. _st(self._snippets())._at_put_(aString,anElement);
  2254. self._snippetAt_compile_(aString,anElement);
  2255. return self}, function($ctx1) {$ctx1.fill(self,"snippetAt:install:",{aString:aString,anElement:anElement},smalltalk.HTMLSnippet)})},
  2256. args: ["aString", "anElement"],
  2257. source: "snippetAt: aString install: anElement\x0a\x09self snippets at: aString put: anElement.\x0a\x09self snippetAt: aString compile: anElement",
  2258. messageSends: ["at:put:", "snippets", "snippetAt:compile:"],
  2259. referencedClasses: []
  2260. }),
  2261. smalltalk.HTMLSnippet);
  2262. smalltalk.addMethod(
  2263. smalltalk.method({
  2264. selector: "snippets",
  2265. category: 'accessing',
  2266. fn: function (){
  2267. var self=this;
  2268. return smalltalk.withContext(function($ctx1) {
  2269. var $2,$1;
  2270. $2=self["@snippets"];
  2271. if(($receiver = $2) == nil || $receiver == null){
  2272. self["@snippets"]=smalltalk.HashedCollection._from_([]);
  2273. $1=self["@snippets"];
  2274. } else {
  2275. $1=$2;
  2276. };
  2277. return $1;
  2278. }, function($ctx1) {$ctx1.fill(self,"snippets",{},smalltalk.HTMLSnippet)})},
  2279. args: [],
  2280. source: "snippets\x0a\x09^snippets ifNil: [ snippets := #{} ]",
  2281. messageSends: ["ifNil:"],
  2282. referencedClasses: []
  2283. }),
  2284. smalltalk.HTMLSnippet);
  2285. smalltalk.addMethod(
  2286. smalltalk.method({
  2287. selector: "snippetsFromJQuery:",
  2288. category: 'private',
  2289. fn: function (aJQuery){
  2290. var self=this;
  2291. return smalltalk.withContext(function($ctx1) {
  2292. var $1;
  2293. $1=_st(_st(aJQuery)._find_("[data-snippet]"))._toArray();
  2294. return $1;
  2295. }, function($ctx1) {$ctx1.fill(self,"snippetsFromJQuery:",{aJQuery:aJQuery},smalltalk.HTMLSnippet)})},
  2296. args: ["aJQuery"],
  2297. source: "snippetsFromJQuery: aJQuery\x0a\x09^ (aJQuery find: '[data-snippet]') toArray",
  2298. messageSends: ["toArray", "find:"],
  2299. referencedClasses: []
  2300. }),
  2301. smalltalk.HTMLSnippet);
  2302. smalltalk.HTMLSnippet.klass.iVarNames = ['current'];
  2303. smalltalk.addMethod(
  2304. smalltalk.method({
  2305. selector: "current",
  2306. category: 'instance creation',
  2307. fn: function (){
  2308. var self=this;
  2309. return smalltalk.withContext(function($ctx1) {
  2310. var $1;
  2311. $1=self["@current"];
  2312. return $1;
  2313. }, function($ctx1) {$ctx1.fill(self,"current",{},smalltalk.HTMLSnippet.klass)})},
  2314. args: [],
  2315. source: "current\x0a\x09^ current",
  2316. messageSends: [],
  2317. referencedClasses: []
  2318. }),
  2319. smalltalk.HTMLSnippet.klass);
  2320. smalltalk.addMethod(
  2321. smalltalk.method({
  2322. selector: "ensureCurrent",
  2323. category: 'initialization',
  2324. fn: function (){
  2325. var self=this;
  2326. return smalltalk.withContext(function($ctx1) {
  2327. var $1,$2,$3;
  2328. $1=self["@current"];
  2329. if(($receiver = $1) == nil || $receiver == null){
  2330. $2=smalltalk.HTMLSnippet.klass.superclass.fn.prototype._new.apply(_st(self), []);
  2331. _st($2)._initializeFromJQuery_(_st(document)._asJQuery());
  2332. $3=_st($2)._yourself();
  2333. self["@current"]=$3;
  2334. self["@current"];
  2335. } else {
  2336. $1;
  2337. };
  2338. return self}, function($ctx1) {$ctx1.fill(self,"ensureCurrent",{},smalltalk.HTMLSnippet.klass)})},
  2339. args: [],
  2340. source: "ensureCurrent\x0a\x09current ifNil: [\x0a\x09\x09current := super new\x0a\x09\x09\x09initializeFromJQuery: document asJQuery;\x0a\x09\x09\x09yourself ]",
  2341. messageSends: ["ifNil:", "initializeFromJQuery:", "new", "asJQuery", "yourself"],
  2342. referencedClasses: []
  2343. }),
  2344. smalltalk.HTMLSnippet.klass);
  2345. smalltalk.addMethod(
  2346. smalltalk.method({
  2347. selector: "initialize",
  2348. category: 'initialization',
  2349. fn: function (){
  2350. var self=this;
  2351. return smalltalk.withContext(function($ctx1) {
  2352. var $1;
  2353. smalltalk.HTMLSnippet.klass.superclass.fn.prototype._initialize.apply(_st(self), []);
  2354. $1=self._isDOMAvailable();
  2355. if(smalltalk.assert($1)){
  2356. self._ensureCurrent();
  2357. };
  2358. return self}, function($ctx1) {$ctx1.fill(self,"initialize",{},smalltalk.HTMLSnippet.klass)})},
  2359. args: [],
  2360. source: "initialize\x0a\x09super initialize.\x0a\x09self isDOMAvailable ifTrue: [\x0a\x09\x09self ensureCurrent ]",
  2361. messageSends: ["initialize", "ifTrue:", "isDOMAvailable", "ensureCurrent"],
  2362. referencedClasses: []
  2363. }),
  2364. smalltalk.HTMLSnippet.klass);
  2365. smalltalk.addMethod(
  2366. smalltalk.method({
  2367. selector: "isDOMAvailable",
  2368. category: 'instance creation',
  2369. fn: function (){
  2370. var self=this;
  2371. return smalltalk.withContext(function($ctx1) {
  2372. return typeof document !== 'undefined' ;
  2373. return self}, function($ctx1) {$ctx1.fill(self,"isDOMAvailable",{},smalltalk.HTMLSnippet.klass)})},
  2374. args: [],
  2375. source: "isDOMAvailable\x0a\x09< return typeof document !== 'undefined' >",
  2376. messageSends: [],
  2377. referencedClasses: []
  2378. }),
  2379. smalltalk.HTMLSnippet.klass);
  2380. smalltalk.addMethod(
  2381. smalltalk.method({
  2382. selector: "new",
  2383. category: 'instance creation',
  2384. fn: function (){
  2385. var self=this;
  2386. return smalltalk.withContext(function($ctx1) {
  2387. self._shouldNotImplement();
  2388. return self}, function($ctx1) {$ctx1.fill(self,"new",{},smalltalk.HTMLSnippet.klass)})},
  2389. args: [],
  2390. source: "new\x0a\x09self shouldNotImplement",
  2391. messageSends: ["shouldNotImplement"],
  2392. referencedClasses: []
  2393. }),
  2394. smalltalk.HTMLSnippet.klass);
  2395. smalltalk.addClass('TagBrush', smalltalk.Object, ['canvas', 'element'], 'Canvas');
  2396. smalltalk.TagBrush.comment="I am a brush for building a single DOM element (which I hold onto).\x0a\x0aAll tags but `<style>` are instances of me (see the `StyleBrush` class).\x0a\x0a## API\x0a\x0a1. Nesting\x0a\x0a Use `#with:` to nest tags. `#with:` can take aString, `TagBrush` instance, a `Widget` or block closure as parameter.\x0a\x0a Example: `aTag with: aString with: aCanvas div`\x0a\x0a2. Events\x0a\x0a The `events` protocol contains all methods related to events (delegating event handling to jQuery).\x0a\x0a Example: `aTag onClick: [ window alert: 'clicked' ]`\x0a\x0a3. Attributes\x0a\x0a The `attribute` protocol contains methods for attribute manipulation (delegating to jQuery too).\x0a\x0a Example: `aTag at: 'value' put: 'hello world'`\x0a\x0a4. Raw access and jQuery\x0a\x0a The `#element` method can be used to access to JavaScript DOM element object.\x0a\x0a Example: `aTag element cssStyle`\x0a\x0a Use `#asJQuery` to access to the receiver converted into a jQuery object.\x0a\x0a Example: `aTag asJQuery css: 'color' value: 'red'`";
  2397. smalltalk.addMethod(
  2398. smalltalk.method({
  2399. selector: "accesskey:",
  2400. category: 'attributes',
  2401. fn: function (aString){
  2402. var self=this;
  2403. return smalltalk.withContext(function($ctx1) {
  2404. self._at_put_("accesskey",aString);
  2405. return self}, function($ctx1) {$ctx1.fill(self,"accesskey:",{aString:aString},smalltalk.TagBrush)})},
  2406. args: ["aString"],
  2407. source: "accesskey: aString\x0a\x09self at: 'accesskey' put: aString",
  2408. messageSends: ["at:put:"],
  2409. referencedClasses: []
  2410. }),
  2411. smalltalk.TagBrush);
  2412. smalltalk.addMethod(
  2413. smalltalk.method({
  2414. selector: "action:",
  2415. category: 'attributes',
  2416. fn: function (aString){
  2417. var self=this;
  2418. return smalltalk.withContext(function($ctx1) {
  2419. self._at_put_("action",aString);
  2420. return self}, function($ctx1) {$ctx1.fill(self,"action:",{aString:aString},smalltalk.TagBrush)})},
  2421. args: ["aString"],
  2422. source: "action: aString\x0a\x09self at: 'action' put: aString",
  2423. messageSends: ["at:put:"],
  2424. referencedClasses: []
  2425. }),
  2426. smalltalk.TagBrush);
  2427. smalltalk.addMethod(
  2428. smalltalk.method({
  2429. selector: "addBrush:",
  2430. category: 'adding',
  2431. fn: function (aTagBrush){
  2432. var self=this;
  2433. return smalltalk.withContext(function($ctx1) {
  2434. var $1;
  2435. self._appendChild_(_st(aTagBrush)._element());
  2436. $1=aTagBrush;
  2437. return $1;
  2438. }, function($ctx1) {$ctx1.fill(self,"addBrush:",{aTagBrush:aTagBrush},smalltalk.TagBrush)})},
  2439. args: ["aTagBrush"],
  2440. source: "addBrush: aTagBrush\x0a\x09self appendChild: aTagBrush element.\x0a\x09^aTagBrush",
  2441. messageSends: ["appendChild:", "element"],
  2442. referencedClasses: []
  2443. }),
  2444. smalltalk.TagBrush);
  2445. smalltalk.addMethod(
  2446. smalltalk.method({
  2447. selector: "align:",
  2448. category: 'attributes',
  2449. fn: function (aString){
  2450. var self=this;
  2451. return smalltalk.withContext(function($ctx1) {
  2452. self._at_put_("align",aString);
  2453. return self}, function($ctx1) {$ctx1.fill(self,"align:",{aString:aString},smalltalk.TagBrush)})},
  2454. args: ["aString"],
  2455. source: "align: aString\x0a\x09self at: 'align' put: aString",
  2456. messageSends: ["at:put:"],
  2457. referencedClasses: []
  2458. }),
  2459. smalltalk.TagBrush);
  2460. smalltalk.addMethod(
  2461. smalltalk.method({
  2462. selector: "alt:",
  2463. category: 'attributes',
  2464. fn: function (aString){
  2465. var self=this;
  2466. return smalltalk.withContext(function($ctx1) {
  2467. self._at_put_("alt",aString);
  2468. return self}, function($ctx1) {$ctx1.fill(self,"alt:",{aString:aString},smalltalk.TagBrush)})},
  2469. args: ["aString"],
  2470. source: "alt: aString\x0a\x09self at: 'alt' put: aString",
  2471. messageSends: ["at:put:"],
  2472. referencedClasses: []
  2473. }),
  2474. smalltalk.TagBrush);
  2475. smalltalk.addMethod(
  2476. smalltalk.method({
  2477. selector: "append:",
  2478. category: 'adding',
  2479. fn: function (anObject){
  2480. var self=this;
  2481. return smalltalk.withContext(function($ctx1) {
  2482. _st(anObject)._appendToBrush_(self);
  2483. return self}, function($ctx1) {$ctx1.fill(self,"append:",{anObject:anObject},smalltalk.TagBrush)})},
  2484. args: ["anObject"],
  2485. source: "append: anObject\x0a\x09anObject appendToBrush: self",
  2486. messageSends: ["appendToBrush:"],
  2487. referencedClasses: []
  2488. }),
  2489. smalltalk.TagBrush);
  2490. smalltalk.addMethod(
  2491. smalltalk.method({
  2492. selector: "appendBlock:",
  2493. category: 'adding',
  2494. fn: function (aBlock){
  2495. var self=this;
  2496. var root;
  2497. return smalltalk.withContext(function($ctx1) {
  2498. root=_st(self["@canvas"])._root();
  2499. _st(self["@canvas"])._root_(self);
  2500. _st(aBlock)._value_(self["@canvas"]);
  2501. _st(self["@canvas"])._root_(root);
  2502. return self}, function($ctx1) {$ctx1.fill(self,"appendBlock:",{aBlock:aBlock,root:root},smalltalk.TagBrush)})},
  2503. args: ["aBlock"],
  2504. source: "appendBlock: aBlock\x0a\x09| root |\x0a\x09root := canvas root.\x0a\x09canvas root: self.\x0a\x09aBlock value: canvas.\x0a\x09canvas root: root",
  2505. messageSends: ["root", "root:", "value:"],
  2506. referencedClasses: []
  2507. }),
  2508. smalltalk.TagBrush);
  2509. smalltalk.addMethod(
  2510. smalltalk.method({
  2511. selector: "appendChild:",
  2512. category: 'adding',
  2513. fn: function (anElement){
  2514. var self=this;
  2515. return smalltalk.withContext(function($ctx1) {
  2516. var element=self['@element'];
  2517. if (null == element.canHaveChildren || element.canHaveChildren) {
  2518. element.appendChild(anElement);
  2519. } else {
  2520. element.text = String(element.text) + anElement.innerHTML;
  2521. } ;
  2522. return self}, function($ctx1) {$ctx1.fill(self,"appendChild:",{anElement:anElement},smalltalk.TagBrush)})},
  2523. args: ["anElement"],
  2524. source: "appendChild: anElement\x0a\x09\x22In IE7 and IE8 appendChild fails on several node types. So we need to check\x22\x0a\x09<var element=self['@element'];\x0a\x09if (null == element.canHaveChildren || element.canHaveChildren) {\x0a\x09\x09element.appendChild(anElement);\x0a\x09} else {\x0a\x09\x09element.text = String(element.text) + anElement.innerHTML;\x0a\x09} >",
  2525. messageSends: [],
  2526. referencedClasses: []
  2527. }),
  2528. smalltalk.TagBrush);
  2529. smalltalk.addMethod(
  2530. smalltalk.method({
  2531. selector: "appendDocumentFragment:",
  2532. category: 'private',
  2533. fn: function (anElement){
  2534. var self=this;
  2535. return smalltalk.withContext(function($ctx1) {
  2536. var element=self['@element'].appendChild(anElement["@element"]);
  2537. return self}, function($ctx1) {$ctx1.fill(self,"appendDocumentFragment:",{anElement:anElement},smalltalk.TagBrush)})},
  2538. args: ["anElement"],
  2539. source: "appendDocumentFragment: anElement\x0a\x09<var element=self['@element'].appendChild(anElement[\x22@element\x22])>",
  2540. messageSends: [],
  2541. referencedClasses: []
  2542. }),
  2543. smalltalk.TagBrush);
  2544. smalltalk.addMethod(
  2545. smalltalk.method({
  2546. selector: "appendString:",
  2547. category: 'adding',
  2548. fn: function (aString){
  2549. var self=this;
  2550. return smalltalk.withContext(function($ctx1) {
  2551. self._appendChild_(self._createTextNodeFor_(aString));
  2552. return self}, function($ctx1) {$ctx1.fill(self,"appendString:",{aString:aString},smalltalk.TagBrush)})},
  2553. args: ["aString"],
  2554. source: "appendString: aString\x0a\x09self appendChild: (self createTextNodeFor: aString)",
  2555. messageSends: ["appendChild:", "createTextNodeFor:"],
  2556. referencedClasses: []
  2557. }),
  2558. smalltalk.TagBrush);
  2559. smalltalk.addMethod(
  2560. smalltalk.method({
  2561. selector: "appendToBrush:",
  2562. category: 'adding',
  2563. fn: function (aTagBrush){
  2564. var self=this;
  2565. return smalltalk.withContext(function($ctx1) {
  2566. _st(aTagBrush)._addBrush_(self);
  2567. return self}, function($ctx1) {$ctx1.fill(self,"appendToBrush:",{aTagBrush:aTagBrush},smalltalk.TagBrush)})},
  2568. args: ["aTagBrush"],
  2569. source: "appendToBrush: aTagBrush\x0a\x09aTagBrush addBrush: self",
  2570. messageSends: ["addBrush:"],
  2571. referencedClasses: []
  2572. }),
  2573. smalltalk.TagBrush);
  2574. smalltalk.addMethod(
  2575. smalltalk.method({
  2576. selector: "asJQuery",
  2577. category: 'converting',
  2578. fn: function (){
  2579. var self=this;
  2580. return smalltalk.withContext(function($ctx1) {
  2581. var $1;
  2582. $1=_st(self._element())._asJQuery();
  2583. return $1;
  2584. }, function($ctx1) {$ctx1.fill(self,"asJQuery",{},smalltalk.TagBrush)})},
  2585. args: [],
  2586. source: "asJQuery\x0a\x09^self element asJQuery",
  2587. messageSends: ["asJQuery", "element"],
  2588. referencedClasses: []
  2589. }),
  2590. smalltalk.TagBrush);
  2591. smalltalk.addMethod(
  2592. smalltalk.method({
  2593. selector: "at:put:",
  2594. category: 'attributes',
  2595. fn: function (aString,aValue){
  2596. var self=this;
  2597. return smalltalk.withContext(function($ctx1) {
  2598. self['@element'].setAttribute(aString, aValue);
  2599. return self}, function($ctx1) {$ctx1.fill(self,"at:put:",{aString:aString,aValue:aValue},smalltalk.TagBrush)})},
  2600. args: ["aString", "aValue"],
  2601. source: "at: aString put: aValue\x0a\x09<self['@element'].setAttribute(aString, aValue)>",
  2602. messageSends: [],
  2603. referencedClasses: []
  2604. }),
  2605. smalltalk.TagBrush);
  2606. smalltalk.addMethod(
  2607. smalltalk.method({
  2608. selector: "class:",
  2609. category: 'attributes',
  2610. fn: function (aString){
  2611. var self=this;
  2612. return smalltalk.withContext(function($ctx1) {
  2613. self['@element'].className = aString;
  2614. return self}, function($ctx1) {$ctx1.fill(self,"class:",{aString:aString},smalltalk.TagBrush)})},
  2615. args: ["aString"],
  2616. source: "class: aString\x0a\x09<self['@element'].className = aString>",
  2617. messageSends: [],
  2618. referencedClasses: []
  2619. }),
  2620. smalltalk.TagBrush);
  2621. smalltalk.addMethod(
  2622. smalltalk.method({
  2623. selector: "cols:",
  2624. category: 'attributes',
  2625. fn: function (aString){
  2626. var self=this;
  2627. return smalltalk.withContext(function($ctx1) {
  2628. self._at_put_("cols",aString);
  2629. return self}, function($ctx1) {$ctx1.fill(self,"cols:",{aString:aString},smalltalk.TagBrush)})},
  2630. args: ["aString"],
  2631. source: "cols: aString\x0a\x09self at: 'cols' put: aString",
  2632. messageSends: ["at:put:"],
  2633. referencedClasses: []
  2634. }),
  2635. smalltalk.TagBrush);
  2636. smalltalk.addMethod(
  2637. smalltalk.method({
  2638. selector: "contenteditable:",
  2639. category: 'attributes',
  2640. fn: function (aString){
  2641. var self=this;
  2642. return smalltalk.withContext(function($ctx1) {
  2643. self._at_put_("contenteditable",aString);
  2644. return self}, function($ctx1) {$ctx1.fill(self,"contenteditable:",{aString:aString},smalltalk.TagBrush)})},
  2645. args: ["aString"],
  2646. source: "contenteditable: aString\x0a\x09self at: 'contenteditable' put: aString",
  2647. messageSends: ["at:put:"],
  2648. referencedClasses: []
  2649. }),
  2650. smalltalk.TagBrush);
  2651. smalltalk.addMethod(
  2652. smalltalk.method({
  2653. selector: "contents:",
  2654. category: 'adding',
  2655. fn: function (anObject){
  2656. var self=this;
  2657. return smalltalk.withContext(function($ctx1) {
  2658. var $1,$2;
  2659. $1=self;
  2660. _st($1)._empty();
  2661. $2=_st($1)._append_(anObject);
  2662. return self}, function($ctx1) {$ctx1.fill(self,"contents:",{anObject:anObject},smalltalk.TagBrush)})},
  2663. args: ["anObject"],
  2664. source: "contents: anObject\x0a\x09self\x0a\x09empty;\x0a\x09append: anObject",
  2665. messageSends: ["empty", "append:"],
  2666. referencedClasses: []
  2667. }),
  2668. smalltalk.TagBrush);
  2669. smalltalk.addMethod(
  2670. smalltalk.method({
  2671. selector: "contextmenu:",
  2672. category: 'attributes',
  2673. fn: function (aString){
  2674. var self=this;
  2675. return smalltalk.withContext(function($ctx1) {
  2676. self._at_put_("contextmenu",aString);
  2677. return self}, function($ctx1) {$ctx1.fill(self,"contextmenu:",{aString:aString},smalltalk.TagBrush)})},
  2678. args: ["aString"],
  2679. source: "contextmenu: aString\x0a\x09self at: 'contextmenu' put: aString",
  2680. messageSends: ["at:put:"],
  2681. referencedClasses: []
  2682. }),
  2683. smalltalk.TagBrush);
  2684. smalltalk.addMethod(
  2685. smalltalk.method({
  2686. selector: "createElementFor:",
  2687. category: 'private',
  2688. fn: function (aString){
  2689. var self=this;
  2690. return smalltalk.withContext(function($ctx1) {
  2691. return document.createElement(String(aString));
  2692. return self}, function($ctx1) {$ctx1.fill(self,"createElementFor:",{aString:aString},smalltalk.TagBrush)})},
  2693. args: ["aString"],
  2694. source: "createElementFor: aString\x0a\x09<return document.createElement(String(aString))>",
  2695. messageSends: [],
  2696. referencedClasses: []
  2697. }),
  2698. smalltalk.TagBrush);
  2699. smalltalk.addMethod(
  2700. smalltalk.method({
  2701. selector: "createTextNodeFor:",
  2702. category: 'private',
  2703. fn: function (aString){
  2704. var self=this;
  2705. return smalltalk.withContext(function($ctx1) {
  2706. return document.createTextNode(String(aString));
  2707. return self}, function($ctx1) {$ctx1.fill(self,"createTextNodeFor:",{aString:aString},smalltalk.TagBrush)})},
  2708. args: ["aString"],
  2709. source: "createTextNodeFor: aString\x0a\x09<return document.createTextNode(String(aString))>",
  2710. messageSends: [],
  2711. referencedClasses: []
  2712. }),
  2713. smalltalk.TagBrush);
  2714. smalltalk.addMethod(
  2715. smalltalk.method({
  2716. selector: "draggable:",
  2717. category: 'attributes',
  2718. fn: function (aString){
  2719. var self=this;
  2720. return smalltalk.withContext(function($ctx1) {
  2721. self._at_put_("draggable",aString);
  2722. return self}, function($ctx1) {$ctx1.fill(self,"draggable:",{aString:aString},smalltalk.TagBrush)})},
  2723. args: ["aString"],
  2724. source: "draggable: aString\x0a\x09self at: 'draggable' put: aString",
  2725. messageSends: ["at:put:"],
  2726. referencedClasses: []
  2727. }),
  2728. smalltalk.TagBrush);
  2729. smalltalk.addMethod(
  2730. smalltalk.method({
  2731. selector: "element",
  2732. category: 'accessing',
  2733. fn: function (){
  2734. var self=this;
  2735. return smalltalk.withContext(function($ctx1) {
  2736. var $1;
  2737. $1=self["@element"];
  2738. return $1;
  2739. }, function($ctx1) {$ctx1.fill(self,"element",{},smalltalk.TagBrush)})},
  2740. args: [],
  2741. source: "element\x0a\x09^element",
  2742. messageSends: [],
  2743. referencedClasses: []
  2744. }),
  2745. smalltalk.TagBrush);
  2746. smalltalk.addMethod(
  2747. smalltalk.method({
  2748. selector: "empty",
  2749. category: 'adding',
  2750. fn: function (){
  2751. var self=this;
  2752. return smalltalk.withContext(function($ctx1) {
  2753. _st(self._asJQuery())._empty();
  2754. return self}, function($ctx1) {$ctx1.fill(self,"empty",{},smalltalk.TagBrush)})},
  2755. args: [],
  2756. source: "empty\x0a\x09self asJQuery empty",
  2757. messageSends: ["empty", "asJQuery"],
  2758. referencedClasses: []
  2759. }),
  2760. smalltalk.TagBrush);
  2761. smalltalk.addMethod(
  2762. smalltalk.method({
  2763. selector: "for:",
  2764. category: 'attributes',
  2765. fn: function (aString){
  2766. var self=this;
  2767. return smalltalk.withContext(function($ctx1) {
  2768. self._at_put_("for",aString);
  2769. return self}, function($ctx1) {$ctx1.fill(self,"for:",{aString:aString},smalltalk.TagBrush)})},
  2770. args: ["aString"],
  2771. source: "for: aString\x0a\x09self at: 'for' put: aString",
  2772. messageSends: ["at:put:"],
  2773. referencedClasses: []
  2774. }),
  2775. smalltalk.TagBrush);
  2776. smalltalk.addMethod(
  2777. smalltalk.method({
  2778. selector: "height:",
  2779. category: 'attributes',
  2780. fn: function (aString){
  2781. var self=this;
  2782. return smalltalk.withContext(function($ctx1) {
  2783. self._at_put_("height",aString);
  2784. return self}, function($ctx1) {$ctx1.fill(self,"height:",{aString:aString},smalltalk.TagBrush)})},
  2785. args: ["aString"],
  2786. source: "height: aString\x0a\x09self at: 'height' put: aString",
  2787. messageSends: ["at:put:"],
  2788. referencedClasses: []
  2789. }),
  2790. smalltalk.TagBrush);
  2791. smalltalk.addMethod(
  2792. smalltalk.method({
  2793. selector: "hidden",
  2794. category: 'attributes',
  2795. fn: function (){
  2796. var self=this;
  2797. return smalltalk.withContext(function($ctx1) {
  2798. self._at_put_("hidden","hidden");
  2799. return self}, function($ctx1) {$ctx1.fill(self,"hidden",{},smalltalk.TagBrush)})},
  2800. args: [],
  2801. source: "hidden\x0a\x09self at: 'hidden' put: 'hidden'",
  2802. messageSends: ["at:put:"],
  2803. referencedClasses: []
  2804. }),
  2805. smalltalk.TagBrush);
  2806. smalltalk.addMethod(
  2807. smalltalk.method({
  2808. selector: "href:",
  2809. category: 'attributes',
  2810. fn: function (aString){
  2811. var self=this;
  2812. return smalltalk.withContext(function($ctx1) {
  2813. self._at_put_("href",aString);
  2814. return self}, function($ctx1) {$ctx1.fill(self,"href:",{aString:aString},smalltalk.TagBrush)})},
  2815. args: ["aString"],
  2816. source: "href: aString\x0a\x09self at: 'href' put: aString",
  2817. messageSends: ["at:put:"],
  2818. referencedClasses: []
  2819. }),
  2820. smalltalk.TagBrush);
  2821. smalltalk.addMethod(
  2822. smalltalk.method({
  2823. selector: "id:",
  2824. category: 'attributes',
  2825. fn: function (aString){
  2826. var self=this;
  2827. return smalltalk.withContext(function($ctx1) {
  2828. self._at_put_("id",aString);
  2829. return self}, function($ctx1) {$ctx1.fill(self,"id:",{aString:aString},smalltalk.TagBrush)})},
  2830. args: ["aString"],
  2831. source: "id: aString\x0a\x09self at: 'id' put: aString",
  2832. messageSends: ["at:put:"],
  2833. referencedClasses: []
  2834. }),
  2835. smalltalk.TagBrush);
  2836. smalltalk.addMethod(
  2837. smalltalk.method({
  2838. selector: "initializeFromJQuery:canvas:",
  2839. category: 'initialization',
  2840. fn: function (aJQuery,aCanvas){
  2841. var self=this;
  2842. return smalltalk.withContext(function($ctx1) {
  2843. self["@element"]=_st(aJQuery)._get_((0));
  2844. self["@canvas"]=aCanvas;
  2845. return self}, function($ctx1) {$ctx1.fill(self,"initializeFromJQuery:canvas:",{aJQuery:aJQuery,aCanvas:aCanvas},smalltalk.TagBrush)})},
  2846. args: ["aJQuery", "aCanvas"],
  2847. source: "initializeFromJQuery: aJQuery canvas: aCanvas\x0a\x09element := aJQuery get: 0.\x0a\x09canvas := aCanvas",
  2848. messageSends: ["get:"],
  2849. referencedClasses: []
  2850. }),
  2851. smalltalk.TagBrush);
  2852. smalltalk.addMethod(
  2853. smalltalk.method({
  2854. selector: "initializeFromString:canvas:",
  2855. category: 'initialization',
  2856. fn: function (aString,aCanvas){
  2857. var self=this;
  2858. return smalltalk.withContext(function($ctx1) {
  2859. self["@element"]=self._createElementFor_(aString);
  2860. self["@canvas"]=aCanvas;
  2861. return self}, function($ctx1) {$ctx1.fill(self,"initializeFromString:canvas:",{aString:aString,aCanvas:aCanvas},smalltalk.TagBrush)})},
  2862. args: ["aString", "aCanvas"],
  2863. source: "initializeFromString: aString canvas: aCanvas\x0a\x09element := self createElementFor: aString.\x0a\x09canvas := aCanvas",
  2864. messageSends: ["createElementFor:"],
  2865. referencedClasses: []
  2866. }),
  2867. smalltalk.TagBrush);
  2868. smalltalk.addMethod(
  2869. smalltalk.method({
  2870. selector: "media:",
  2871. category: 'attributes',
  2872. fn: function (aString){
  2873. var self=this;
  2874. return smalltalk.withContext(function($ctx1) {
  2875. self._at_put_("media",aString);
  2876. return self}, function($ctx1) {$ctx1.fill(self,"media:",{aString:aString},smalltalk.TagBrush)})},
  2877. args: ["aString"],
  2878. source: "media: aString\x0a\x09self at: 'media' put: aString",
  2879. messageSends: ["at:put:"],
  2880. referencedClasses: []
  2881. }),
  2882. smalltalk.TagBrush);
  2883. smalltalk.addMethod(
  2884. smalltalk.method({
  2885. selector: "method:",
  2886. category: 'attributes',
  2887. fn: function (aString){
  2888. var self=this;
  2889. return smalltalk.withContext(function($ctx1) {
  2890. self._at_put_("method",aString);
  2891. return self}, function($ctx1) {$ctx1.fill(self,"method:",{aString:aString},smalltalk.TagBrush)})},
  2892. args: ["aString"],
  2893. source: "method: aString\x0a\x09self at: 'method' put: aString",
  2894. messageSends: ["at:put:"],
  2895. referencedClasses: []
  2896. }),
  2897. smalltalk.TagBrush);
  2898. smalltalk.addMethod(
  2899. smalltalk.method({
  2900. selector: "name:",
  2901. category: 'attributes',
  2902. fn: function (aString){
  2903. var self=this;
  2904. return smalltalk.withContext(function($ctx1) {
  2905. self._at_put_("name",aString);
  2906. return self}, function($ctx1) {$ctx1.fill(self,"name:",{aString:aString},smalltalk.TagBrush)})},
  2907. args: ["aString"],
  2908. source: "name: aString\x0a\x09self at: 'name' put: aString",
  2909. messageSends: ["at:put:"],
  2910. referencedClasses: []
  2911. }),
  2912. smalltalk.TagBrush);
  2913. smalltalk.addMethod(
  2914. smalltalk.method({
  2915. selector: "onBlur:",
  2916. category: 'events',
  2917. fn: function (aBlock){
  2918. var self=this;
  2919. return smalltalk.withContext(function($ctx1) {
  2920. _st(self._asJQuery())._bind_do_("blur",aBlock);
  2921. return self}, function($ctx1) {$ctx1.fill(self,"onBlur:",{aBlock:aBlock},smalltalk.TagBrush)})},
  2922. args: ["aBlock"],
  2923. source: "onBlur: aBlock\x0a\x09self asJQuery bind: 'blur' do: aBlock",
  2924. messageSends: ["bind:do:", "asJQuery"],
  2925. referencedClasses: []
  2926. }),
  2927. smalltalk.TagBrush);
  2928. smalltalk.addMethod(
  2929. smalltalk.method({
  2930. selector: "onChange:",
  2931. category: 'events',
  2932. fn: function (aBlock){
  2933. var self=this;
  2934. return smalltalk.withContext(function($ctx1) {
  2935. _st(self._asJQuery())._bind_do_("change",aBlock);
  2936. return self}, function($ctx1) {$ctx1.fill(self,"onChange:",{aBlock:aBlock},smalltalk.TagBrush)})},
  2937. args: ["aBlock"],
  2938. source: "onChange: aBlock\x0a\x09self asJQuery bind: 'change' do: aBlock",
  2939. messageSends: ["bind:do:", "asJQuery"],
  2940. referencedClasses: []
  2941. }),
  2942. smalltalk.TagBrush);
  2943. smalltalk.addMethod(
  2944. smalltalk.method({
  2945. selector: "onClick:",
  2946. category: 'events',
  2947. fn: function (aBlock){
  2948. var self=this;
  2949. return smalltalk.withContext(function($ctx1) {
  2950. _st(self._asJQuery())._bind_do_("click",aBlock);
  2951. return self}, function($ctx1) {$ctx1.fill(self,"onClick:",{aBlock:aBlock},smalltalk.TagBrush)})},
  2952. args: ["aBlock"],
  2953. source: "onClick: aBlock\x0a\x09self asJQuery bind: 'click' do: aBlock",
  2954. messageSends: ["bind:do:", "asJQuery"],
  2955. referencedClasses: []
  2956. }),
  2957. smalltalk.TagBrush);
  2958. smalltalk.addMethod(
  2959. smalltalk.method({
  2960. selector: "onDblClick:",
  2961. category: 'events',
  2962. fn: function (aBlock){
  2963. var self=this;
  2964. return smalltalk.withContext(function($ctx1) {
  2965. _st(self._asJQuery())._bind_do_("dblclick",aBlock);
  2966. return self}, function($ctx1) {$ctx1.fill(self,"onDblClick:",{aBlock:aBlock},smalltalk.TagBrush)})},
  2967. args: ["aBlock"],
  2968. source: "onDblClick: aBlock\x0a\x09self asJQuery bind: 'dblclick' do: aBlock",
  2969. messageSends: ["bind:do:", "asJQuery"],
  2970. referencedClasses: []
  2971. }),
  2972. smalltalk.TagBrush);
  2973. smalltalk.addMethod(
  2974. smalltalk.method({
  2975. selector: "onFocus:",
  2976. category: 'events',
  2977. fn: function (aBlock){
  2978. var self=this;
  2979. return smalltalk.withContext(function($ctx1) {
  2980. _st(self._asJQuery())._bind_do_("focus",aBlock);
  2981. return self}, function($ctx1) {$ctx1.fill(self,"onFocus:",{aBlock:aBlock},smalltalk.TagBrush)})},
  2982. args: ["aBlock"],
  2983. source: "onFocus: aBlock\x0a\x09self asJQuery bind: 'focus' do: aBlock",
  2984. messageSends: ["bind:do:", "asJQuery"],
  2985. referencedClasses: []
  2986. }),
  2987. smalltalk.TagBrush);
  2988. smalltalk.addMethod(
  2989. smalltalk.method({
  2990. selector: "onFocusIn:",
  2991. category: 'events',
  2992. fn: function (aBlock){
  2993. var self=this;
  2994. return smalltalk.withContext(function($ctx1) {
  2995. _st(self._asJQuery())._bind_do_("focusin",aBlock);
  2996. return self}, function($ctx1) {$ctx1.fill(self,"onFocusIn:",{aBlock:aBlock},smalltalk.TagBrush)})},
  2997. args: ["aBlock"],
  2998. source: "onFocusIn: aBlock\x0a\x09self asJQuery bind: 'focusin' do: aBlock",
  2999. messageSends: ["bind:do:", "asJQuery"],
  3000. referencedClasses: []
  3001. }),
  3002. smalltalk.TagBrush);
  3003. smalltalk.addMethod(
  3004. smalltalk.method({
  3005. selector: "onFocusOut:",
  3006. category: 'events',
  3007. fn: function (aBlock){
  3008. var self=this;
  3009. return smalltalk.withContext(function($ctx1) {
  3010. _st(self._asJQuery())._bind_do_("focusout",aBlock);
  3011. return self}, function($ctx1) {$ctx1.fill(self,"onFocusOut:",{aBlock:aBlock},smalltalk.TagBrush)})},
  3012. args: ["aBlock"],
  3013. source: "onFocusOut: aBlock\x0a\x09self asJQuery bind: 'focusout' do: aBlock",
  3014. messageSends: ["bind:do:", "asJQuery"],
  3015. referencedClasses: []
  3016. }),
  3017. smalltalk.TagBrush);
  3018. smalltalk.addMethod(
  3019. smalltalk.method({
  3020. selector: "onHover:",
  3021. category: 'events',
  3022. fn: function (aBlock){
  3023. var self=this;
  3024. return smalltalk.withContext(function($ctx1) {
  3025. _st(self._asJQuery())._bind_do_("hover",aBlock);
  3026. return self}, function($ctx1) {$ctx1.fill(self,"onHover:",{aBlock:aBlock},smalltalk.TagBrush)})},
  3027. args: ["aBlock"],
  3028. source: "onHover: aBlock\x0a\x09self asJQuery bind: 'hover' do: aBlock",
  3029. messageSends: ["bind:do:", "asJQuery"],
  3030. referencedClasses: []
  3031. }),
  3032. smalltalk.TagBrush);
  3033. smalltalk.addMethod(
  3034. smalltalk.method({
  3035. selector: "onKeyDown:",
  3036. category: 'events',
  3037. fn: function (aBlock){
  3038. var self=this;
  3039. return smalltalk.withContext(function($ctx1) {
  3040. _st(self._asJQuery())._bind_do_("keydown",aBlock);
  3041. return self}, function($ctx1) {$ctx1.fill(self,"onKeyDown:",{aBlock:aBlock},smalltalk.TagBrush)})},
  3042. args: ["aBlock"],
  3043. source: "onKeyDown: aBlock\x0a\x09self asJQuery bind: 'keydown' do: aBlock",
  3044. messageSends: ["bind:do:", "asJQuery"],
  3045. referencedClasses: []
  3046. }),
  3047. smalltalk.TagBrush);
  3048. smalltalk.addMethod(
  3049. smalltalk.method({
  3050. selector: "onKeyPress:",
  3051. category: 'events',
  3052. fn: function (aBlock){
  3053. var self=this;
  3054. return smalltalk.withContext(function($ctx1) {
  3055. _st(self._asJQuery())._bind_do_("keypress",aBlock);
  3056. return self}, function($ctx1) {$ctx1.fill(self,"onKeyPress:",{aBlock:aBlock},smalltalk.TagBrush)})},
  3057. args: ["aBlock"],
  3058. source: "onKeyPress: aBlock\x0a\x09self asJQuery bind: 'keypress' do: aBlock",
  3059. messageSends: ["bind:do:", "asJQuery"],
  3060. referencedClasses: []
  3061. }),
  3062. smalltalk.TagBrush);
  3063. smalltalk.addMethod(
  3064. smalltalk.method({
  3065. selector: "onKeyUp:",
  3066. category: 'events',
  3067. fn: function (aBlock){
  3068. var self=this;
  3069. return smalltalk.withContext(function($ctx1) {
  3070. _st(self._asJQuery())._bind_do_("keyup",aBlock);
  3071. return self}, function($ctx1) {$ctx1.fill(self,"onKeyUp:",{aBlock:aBlock},smalltalk.TagBrush)})},
  3072. args: ["aBlock"],
  3073. source: "onKeyUp: aBlock\x0a\x09self asJQuery bind: 'keyup' do: aBlock",
  3074. messageSends: ["bind:do:", "asJQuery"],
  3075. referencedClasses: []
  3076. }),
  3077. smalltalk.TagBrush);
  3078. smalltalk.addMethod(
  3079. smalltalk.method({
  3080. selector: "onMouseDown:",
  3081. category: 'events',
  3082. fn: function (aBlock){
  3083. var self=this;
  3084. return smalltalk.withContext(function($ctx1) {
  3085. _st(self._asJQuery())._bind_do_("mousedown",aBlock);
  3086. return self}, function($ctx1) {$ctx1.fill(self,"onMouseDown:",{aBlock:aBlock},smalltalk.TagBrush)})},
  3087. args: ["aBlock"],
  3088. source: "onMouseDown: aBlock\x0a\x09self asJQuery bind: 'mousedown' do: aBlock",
  3089. messageSends: ["bind:do:", "asJQuery"],
  3090. referencedClasses: []
  3091. }),
  3092. smalltalk.TagBrush);
  3093. smalltalk.addMethod(
  3094. smalltalk.method({
  3095. selector: "onMouseEnter:",
  3096. category: 'events',
  3097. fn: function (aBlock){
  3098. var self=this;
  3099. return smalltalk.withContext(function($ctx1) {
  3100. _st(self._asJQuery())._bind_do_("mouseenter",aBlock);
  3101. return self}, function($ctx1) {$ctx1.fill(self,"onMouseEnter:",{aBlock:aBlock},smalltalk.TagBrush)})},
  3102. args: ["aBlock"],
  3103. source: "onMouseEnter: aBlock\x0a\x09self asJQuery bind: 'mouseenter' do: aBlock",
  3104. messageSends: ["bind:do:", "asJQuery"],
  3105. referencedClasses: []
  3106. }),
  3107. smalltalk.TagBrush);
  3108. smalltalk.addMethod(
  3109. smalltalk.method({
  3110. selector: "onMouseLeave:",
  3111. category: 'events',
  3112. fn: function (aBlock){
  3113. var self=this;
  3114. return smalltalk.withContext(function($ctx1) {
  3115. _st(self._asJQuery())._bind_do_("mouseleave",aBlock);
  3116. return self}, function($ctx1) {$ctx1.fill(self,"onMouseLeave:",{aBlock:aBlock},smalltalk.TagBrush)})},
  3117. args: ["aBlock"],
  3118. source: "onMouseLeave: aBlock\x0a\x09self asJQuery bind: 'mouseleave' do: aBlock",
  3119. messageSends: ["bind:do:", "asJQuery"],
  3120. referencedClasses: []
  3121. }),
  3122. smalltalk.TagBrush);
  3123. smalltalk.addMethod(
  3124. smalltalk.method({
  3125. selector: "onMouseMove:",
  3126. category: 'events',
  3127. fn: function (aBlock){
  3128. var self=this;
  3129. return smalltalk.withContext(function($ctx1) {
  3130. _st(self._asJQuery())._bind_do_("mousemove",aBlock);
  3131. return self}, function($ctx1) {$ctx1.fill(self,"onMouseMove:",{aBlock:aBlock},smalltalk.TagBrush)})},
  3132. args: ["aBlock"],
  3133. source: "onMouseMove: aBlock\x0a\x09self asJQuery bind: 'mousemove' do: aBlock",
  3134. messageSends: ["bind:do:", "asJQuery"],
  3135. referencedClasses: []
  3136. }),
  3137. smalltalk.TagBrush);
  3138. smalltalk.addMethod(
  3139. smalltalk.method({
  3140. selector: "onMouseOut:",
  3141. category: 'events',
  3142. fn: function (aBlock){
  3143. var self=this;
  3144. return smalltalk.withContext(function($ctx1) {
  3145. _st(self._asJQuery())._bind_do_("mouseout",aBlock);
  3146. return self}, function($ctx1) {$ctx1.fill(self,"onMouseOut:",{aBlock:aBlock},smalltalk.TagBrush)})},
  3147. args: ["aBlock"],
  3148. source: "onMouseOut: aBlock\x0a\x09self asJQuery bind: 'mouseout' do: aBlock",
  3149. messageSends: ["bind:do:", "asJQuery"],
  3150. referencedClasses: []
  3151. }),
  3152. smalltalk.TagBrush);
  3153. smalltalk.addMethod(
  3154. smalltalk.method({
  3155. selector: "onMouseOver:",
  3156. category: 'events',
  3157. fn: function (aBlock){
  3158. var self=this;
  3159. return smalltalk.withContext(function($ctx1) {
  3160. _st(self._asJQuery())._bind_do_("mouseover",aBlock);
  3161. return self}, function($ctx1) {$ctx1.fill(self,"onMouseOver:",{aBlock:aBlock},smalltalk.TagBrush)})},
  3162. args: ["aBlock"],
  3163. source: "onMouseOver: aBlock\x0a\x09self asJQuery bind: 'mouseover' do: aBlock",
  3164. messageSends: ["bind:do:", "asJQuery"],
  3165. referencedClasses: []
  3166. }),
  3167. smalltalk.TagBrush);
  3168. smalltalk.addMethod(
  3169. smalltalk.method({
  3170. selector: "onMouseUp:",
  3171. category: 'events',
  3172. fn: function (aBlock){
  3173. var self=this;
  3174. return smalltalk.withContext(function($ctx1) {
  3175. _st(self._asJQuery())._bind_do_("mouseup",aBlock);
  3176. return self}, function($ctx1) {$ctx1.fill(self,"onMouseUp:",{aBlock:aBlock},smalltalk.TagBrush)})},
  3177. args: ["aBlock"],
  3178. source: "onMouseUp: aBlock\x0a\x09self asJQuery bind: 'mouseup' do: aBlock",
  3179. messageSends: ["bind:do:", "asJQuery"],
  3180. referencedClasses: []
  3181. }),
  3182. smalltalk.TagBrush);
  3183. smalltalk.addMethod(
  3184. smalltalk.method({
  3185. selector: "onSelect:",
  3186. category: 'events',
  3187. fn: function (aBlock){
  3188. var self=this;
  3189. return smalltalk.withContext(function($ctx1) {
  3190. _st(self._asJQuery())._bind_do_("select",aBlock);
  3191. return self}, function($ctx1) {$ctx1.fill(self,"onSelect:",{aBlock:aBlock},smalltalk.TagBrush)})},
  3192. args: ["aBlock"],
  3193. source: "onSelect: aBlock\x0a\x09self asJQuery bind: 'select' do: aBlock",
  3194. messageSends: ["bind:do:", "asJQuery"],
  3195. referencedClasses: []
  3196. }),
  3197. smalltalk.TagBrush);
  3198. smalltalk.addMethod(
  3199. smalltalk.method({
  3200. selector: "onSubmit:",
  3201. category: 'events',
  3202. fn: function (aBlock){
  3203. var self=this;
  3204. return smalltalk.withContext(function($ctx1) {
  3205. _st(self._asJQuery())._bind_do_("submit",aBlock);
  3206. return self}, function($ctx1) {$ctx1.fill(self,"onSubmit:",{aBlock:aBlock},smalltalk.TagBrush)})},
  3207. args: ["aBlock"],
  3208. source: "onSubmit: aBlock\x0a\x09self asJQuery bind: 'submit' do: aBlock",
  3209. messageSends: ["bind:do:", "asJQuery"],
  3210. referencedClasses: []
  3211. }),
  3212. smalltalk.TagBrush);
  3213. smalltalk.addMethod(
  3214. smalltalk.method({
  3215. selector: "onUnload:",
  3216. category: 'events',
  3217. fn: function (aBlock){
  3218. var self=this;
  3219. return smalltalk.withContext(function($ctx1) {
  3220. _st(self._asJQuery())._bind_do_("unload",aBlock);
  3221. return self}, function($ctx1) {$ctx1.fill(self,"onUnload:",{aBlock:aBlock},smalltalk.TagBrush)})},
  3222. args: ["aBlock"],
  3223. source: "onUnload: aBlock\x0a\x09self asJQuery bind: 'unload' do: aBlock",
  3224. messageSends: ["bind:do:", "asJQuery"],
  3225. referencedClasses: []
  3226. }),
  3227. smalltalk.TagBrush);
  3228. smalltalk.addMethod(
  3229. smalltalk.method({
  3230. selector: "placeholder:",
  3231. category: 'attributes',
  3232. fn: function (aString){
  3233. var self=this;
  3234. return smalltalk.withContext(function($ctx1) {
  3235. self._at_put_("placeholder",aString);
  3236. return self}, function($ctx1) {$ctx1.fill(self,"placeholder:",{aString:aString},smalltalk.TagBrush)})},
  3237. args: ["aString"],
  3238. source: "placeholder: aString\x0a\x09self at: 'placeholder' put: aString",
  3239. messageSends: ["at:put:"],
  3240. referencedClasses: []
  3241. }),
  3242. smalltalk.TagBrush);
  3243. smalltalk.addMethod(
  3244. smalltalk.method({
  3245. selector: "rel:",
  3246. category: 'attributes',
  3247. fn: function (aString){
  3248. var self=this;
  3249. return smalltalk.withContext(function($ctx1) {
  3250. self._at_put_("rel",aString);
  3251. return self}, function($ctx1) {$ctx1.fill(self,"rel:",{aString:aString},smalltalk.TagBrush)})},
  3252. args: ["aString"],
  3253. source: "rel: aString\x0a\x09self at: 'rel' put: aString",
  3254. messageSends: ["at:put:"],
  3255. referencedClasses: []
  3256. }),
  3257. smalltalk.TagBrush);
  3258. smalltalk.addMethod(
  3259. smalltalk.method({
  3260. selector: "removeAt:",
  3261. category: 'attributes',
  3262. fn: function (aString){
  3263. var self=this;
  3264. return smalltalk.withContext(function($ctx1) {
  3265. self['@element'].removeAttribute(aString);
  3266. return self}, function($ctx1) {$ctx1.fill(self,"removeAt:",{aString:aString},smalltalk.TagBrush)})},
  3267. args: ["aString"],
  3268. source: "removeAt: aString\x0a\x09<self['@element'].removeAttribute(aString)>",
  3269. messageSends: [],
  3270. referencedClasses: []
  3271. }),
  3272. smalltalk.TagBrush);
  3273. smalltalk.addMethod(
  3274. smalltalk.method({
  3275. selector: "rows:",
  3276. category: 'attributes',
  3277. fn: function (aString){
  3278. var self=this;
  3279. return smalltalk.withContext(function($ctx1) {
  3280. self._at_put_("rows",aString);
  3281. return self}, function($ctx1) {$ctx1.fill(self,"rows:",{aString:aString},smalltalk.TagBrush)})},
  3282. args: ["aString"],
  3283. source: "rows: aString\x0a\x09self at: 'rows' put: aString",
  3284. messageSends: ["at:put:"],
  3285. referencedClasses: []
  3286. }),
  3287. smalltalk.TagBrush);
  3288. smalltalk.addMethod(
  3289. smalltalk.method({
  3290. selector: "src:",
  3291. category: 'attributes',
  3292. fn: function (aString){
  3293. var self=this;
  3294. return smalltalk.withContext(function($ctx1) {
  3295. self._at_put_("src",aString);
  3296. return self}, function($ctx1) {$ctx1.fill(self,"src:",{aString:aString},smalltalk.TagBrush)})},
  3297. args: ["aString"],
  3298. source: "src: aString\x0a\x09self at: 'src' put: aString",
  3299. messageSends: ["at:put:"],
  3300. referencedClasses: []
  3301. }),
  3302. smalltalk.TagBrush);
  3303. smalltalk.addMethod(
  3304. smalltalk.method({
  3305. selector: "style:",
  3306. category: 'attributes',
  3307. fn: function (aString){
  3308. var self=this;
  3309. return smalltalk.withContext(function($ctx1) {
  3310. self._at_put_("style",aString);
  3311. return self}, function($ctx1) {$ctx1.fill(self,"style:",{aString:aString},smalltalk.TagBrush)})},
  3312. args: ["aString"],
  3313. source: "style: aString\x0a\x09self at: 'style' put: aString",
  3314. messageSends: ["at:put:"],
  3315. referencedClasses: []
  3316. }),
  3317. smalltalk.TagBrush);
  3318. smalltalk.addMethod(
  3319. smalltalk.method({
  3320. selector: "tabindex:",
  3321. category: 'attributes',
  3322. fn: function (aNumber){
  3323. var self=this;
  3324. return smalltalk.withContext(function($ctx1) {
  3325. self._at_put_("tabindex",aNumber);
  3326. return self}, function($ctx1) {$ctx1.fill(self,"tabindex:",{aNumber:aNumber},smalltalk.TagBrush)})},
  3327. args: ["aNumber"],
  3328. source: "tabindex: aNumber\x0a\x09self at: 'tabindex' put: aNumber",
  3329. messageSends: ["at:put:"],
  3330. referencedClasses: []
  3331. }),
  3332. smalltalk.TagBrush);
  3333. smalltalk.addMethod(
  3334. smalltalk.method({
  3335. selector: "target:",
  3336. category: 'attributes',
  3337. fn: function (aString){
  3338. var self=this;
  3339. return smalltalk.withContext(function($ctx1) {
  3340. self._at_put_("target",aString);
  3341. return self}, function($ctx1) {$ctx1.fill(self,"target:",{aString:aString},smalltalk.TagBrush)})},
  3342. args: ["aString"],
  3343. source: "target: aString\x0a\x09self at: 'target' put: aString",
  3344. messageSends: ["at:put:"],
  3345. referencedClasses: []
  3346. }),
  3347. smalltalk.TagBrush);
  3348. smalltalk.addMethod(
  3349. smalltalk.method({
  3350. selector: "title:",
  3351. category: 'attributes',
  3352. fn: function (aString){
  3353. var self=this;
  3354. return smalltalk.withContext(function($ctx1) {
  3355. self._at_put_("title",aString);
  3356. return self}, function($ctx1) {$ctx1.fill(self,"title:",{aString:aString},smalltalk.TagBrush)})},
  3357. args: ["aString"],
  3358. source: "title: aString\x0a\x09self at: 'title' put: aString",
  3359. messageSends: ["at:put:"],
  3360. referencedClasses: []
  3361. }),
  3362. smalltalk.TagBrush);
  3363. smalltalk.addMethod(
  3364. smalltalk.method({
  3365. selector: "type:",
  3366. category: 'attributes',
  3367. fn: function (aString){
  3368. var self=this;
  3369. return smalltalk.withContext(function($ctx1) {
  3370. self._at_put_("type",aString);
  3371. return self}, function($ctx1) {$ctx1.fill(self,"type:",{aString:aString},smalltalk.TagBrush)})},
  3372. args: ["aString"],
  3373. source: "type: aString\x0a\x09self at: 'type' put: aString",
  3374. messageSends: ["at:put:"],
  3375. referencedClasses: []
  3376. }),
  3377. smalltalk.TagBrush);
  3378. smalltalk.addMethod(
  3379. smalltalk.method({
  3380. selector: "valign:",
  3381. category: 'attributes',
  3382. fn: function (aString){
  3383. var self=this;
  3384. return smalltalk.withContext(function($ctx1) {
  3385. self._at_put_("valign",aString);
  3386. return self}, function($ctx1) {$ctx1.fill(self,"valign:",{aString:aString},smalltalk.TagBrush)})},
  3387. args: ["aString"],
  3388. source: "valign: aString\x0a\x09self at: 'valign' put: aString",
  3389. messageSends: ["at:put:"],
  3390. referencedClasses: []
  3391. }),
  3392. smalltalk.TagBrush);
  3393. smalltalk.addMethod(
  3394. smalltalk.method({
  3395. selector: "value:",
  3396. category: 'attributes',
  3397. fn: function (aString){
  3398. var self=this;
  3399. return smalltalk.withContext(function($ctx1) {
  3400. self._at_put_("value",aString);
  3401. return self}, function($ctx1) {$ctx1.fill(self,"value:",{aString:aString},smalltalk.TagBrush)})},
  3402. args: ["aString"],
  3403. source: "value: aString\x0a\x09self at: 'value' put: aString",
  3404. messageSends: ["at:put:"],
  3405. referencedClasses: []
  3406. }),
  3407. smalltalk.TagBrush);
  3408. smalltalk.addMethod(
  3409. smalltalk.method({
  3410. selector: "width:",
  3411. category: 'attributes',
  3412. fn: function (aString){
  3413. var self=this;
  3414. return smalltalk.withContext(function($ctx1) {
  3415. self._at_put_("width",aString);
  3416. return self}, function($ctx1) {$ctx1.fill(self,"width:",{aString:aString},smalltalk.TagBrush)})},
  3417. args: ["aString"],
  3418. source: "width: aString\x0a\x09self at: 'width' put: aString",
  3419. messageSends: ["at:put:"],
  3420. referencedClasses: []
  3421. }),
  3422. smalltalk.TagBrush);
  3423. smalltalk.addMethod(
  3424. smalltalk.method({
  3425. selector: "with:",
  3426. category: 'adding',
  3427. fn: function (anObject){
  3428. var self=this;
  3429. return smalltalk.withContext(function($ctx1) {
  3430. self._append_(anObject);
  3431. return self}, function($ctx1) {$ctx1.fill(self,"with:",{anObject:anObject},smalltalk.TagBrush)})},
  3432. args: ["anObject"],
  3433. source: "with: anObject\x0a\x09self append: anObject",
  3434. messageSends: ["append:"],
  3435. referencedClasses: []
  3436. }),
  3437. smalltalk.TagBrush);
  3438. smalltalk.addMethod(
  3439. smalltalk.method({
  3440. selector: "fromJQuery:canvas:",
  3441. category: 'instance creation',
  3442. fn: function (aJQuery,aCanvas){
  3443. var self=this;
  3444. return smalltalk.withContext(function($ctx1) {
  3445. var $2,$3,$1;
  3446. $2=self._new();
  3447. _st($2)._initializeFromJQuery_canvas_(aJQuery,aCanvas);
  3448. $3=_st($2)._yourself();
  3449. $1=$3;
  3450. return $1;
  3451. }, function($ctx1) {$ctx1.fill(self,"fromJQuery:canvas:",{aJQuery:aJQuery,aCanvas:aCanvas},smalltalk.TagBrush.klass)})},
  3452. args: ["aJQuery", "aCanvas"],
  3453. source: "fromJQuery: aJQuery canvas: aCanvas\x0a\x09^self new\x0a\x09\x09initializeFromJQuery: aJQuery canvas: aCanvas;\x0a\x09\x09yourself",
  3454. messageSends: ["initializeFromJQuery:canvas:", "new", "yourself"],
  3455. referencedClasses: []
  3456. }),
  3457. smalltalk.TagBrush.klass);
  3458. smalltalk.addMethod(
  3459. smalltalk.method({
  3460. selector: "fromString:canvas:",
  3461. category: 'instance creation',
  3462. fn: function (aString,aCanvas){
  3463. var self=this;
  3464. return smalltalk.withContext(function($ctx1) {
  3465. var $2,$3,$1;
  3466. $2=self._new();
  3467. _st($2)._initializeFromString_canvas_(aString,aCanvas);
  3468. $3=_st($2)._yourself();
  3469. $1=$3;
  3470. return $1;
  3471. }, function($ctx1) {$ctx1.fill(self,"fromString:canvas:",{aString:aString,aCanvas:aCanvas},smalltalk.TagBrush.klass)})},
  3472. args: ["aString", "aCanvas"],
  3473. source: "fromString: aString canvas: aCanvas\x0a\x09^self new\x0a\x09initializeFromString: aString canvas: aCanvas;\x0a\x09yourself",
  3474. messageSends: ["initializeFromString:canvas:", "new", "yourself"],
  3475. referencedClasses: []
  3476. }),
  3477. smalltalk.TagBrush.klass);
  3478. smalltalk.addClass('DocumentFragmentTag', smalltalk.TagBrush, [], 'Canvas');
  3479. smalltalk.addMethod(
  3480. smalltalk.method({
  3481. selector: "createDocumentFragment",
  3482. category: 'private',
  3483. fn: function (){
  3484. var self=this;
  3485. return smalltalk.withContext(function($ctx1) {
  3486. return document.createDocumentFragment();
  3487. return self}, function($ctx1) {$ctx1.fill(self,"createDocumentFragment",{},smalltalk.DocumentFragmentTag)})},
  3488. args: [],
  3489. source: "createDocumentFragment\x0a\x09<return document.createDocumentFragment()>",
  3490. messageSends: [],
  3491. referencedClasses: []
  3492. }),
  3493. smalltalk.DocumentFragmentTag);
  3494. smalltalk.addMethod(
  3495. smalltalk.method({
  3496. selector: "initializeFromCanvas:",
  3497. category: 'initialization',
  3498. fn: function (aCanvas){
  3499. var self=this;
  3500. return smalltalk.withContext(function($ctx1) {
  3501. self["@canvas"]=aCanvas;
  3502. self["@element"]=self._createDocumentFragment();
  3503. return self}, function($ctx1) {$ctx1.fill(self,"initializeFromCanvas:",{aCanvas:aCanvas},smalltalk.DocumentFragmentTag)})},
  3504. args: ["aCanvas"],
  3505. source: "initializeFromCanvas: aCanvas\x0a\x09canvas := aCanvas.\x0a\x09element := self createDocumentFragment",
  3506. messageSends: ["createDocumentFragment"],
  3507. referencedClasses: []
  3508. }),
  3509. smalltalk.DocumentFragmentTag);
  3510. smalltalk.addMethod(
  3511. smalltalk.method({
  3512. selector: "canvas:",
  3513. category: 'instance creation',
  3514. fn: function (aCanvas){
  3515. var self=this;
  3516. return smalltalk.withContext(function($ctx1) {
  3517. var $2,$3,$1;
  3518. $2=self._new();
  3519. _st($2)._initializeFromCanvas_(aCanvas);
  3520. $3=_st($2)._yourself();
  3521. $1=$3;
  3522. return $1;
  3523. }, function($ctx1) {$ctx1.fill(self,"canvas:",{aCanvas:aCanvas},smalltalk.DocumentFragmentTag.klass)})},
  3524. args: ["aCanvas"],
  3525. source: "canvas: aCanvas\x0a\x09^ self new\x0a\x09\x09initializeFromCanvas: aCanvas;\x0a\x09\x09yourself",
  3526. messageSends: ["initializeFromCanvas:", "new", "yourself"],
  3527. referencedClasses: []
  3528. }),
  3529. smalltalk.DocumentFragmentTag.klass);
  3530. smalltalk.addClass('StyleTag', smalltalk.TagBrush, [], 'Canvas');
  3531. smalltalk.StyleTag.comment="I'm a `<style>` tag use to inline CSS or load a stylesheet.\x0a\x0a## Motivation\x0a\x0aThe need for a specific class comes from Internet Explorer compatibility issues.";
  3532. smalltalk.addMethod(
  3533. smalltalk.method({
  3534. selector: "with:",
  3535. category: 'adding',
  3536. fn: function (aString){
  3537. var self=this;
  3538. function $HTMLCanvas(){return smalltalk.HTMLCanvas||(typeof HTMLCanvas=="undefined"?nil:HTMLCanvas)}
  3539. return smalltalk.withContext(function($ctx1) {
  3540. var $1;
  3541. $1=_st($HTMLCanvas())._isMSIE();
  3542. if(smalltalk.assert($1)){
  3543. _st(_st(self._element())._styleSheet())._cssText_(aString);
  3544. } else {
  3545. smalltalk.StyleTag.superclass.fn.prototype._with_.apply(_st(self), [aString]);
  3546. };
  3547. return self}, function($ctx1) {$ctx1.fill(self,"with:",{aString:aString},smalltalk.StyleTag)})},
  3548. args: ["aString"],
  3549. source: "with: aString\x0a\x09HTMLCanvas isMSIE\x0a\x09\x09ifTrue: [self element styleSheet cssText: aString ]\x0a\x09\x09ifFalse: [super with: aString ].",
  3550. messageSends: ["ifTrue:ifFalse:", "isMSIE", "cssText:", "styleSheet", "element", "with:"],
  3551. referencedClasses: ["HTMLCanvas"]
  3552. }),
  3553. smalltalk.StyleTag);
  3554. smalltalk.addMethod(
  3555. smalltalk.method({
  3556. selector: "canvas:",
  3557. category: 'instance creation',
  3558. fn: function (aCanvas){
  3559. var self=this;
  3560. return smalltalk.withContext(function($ctx1) {
  3561. var $2,$3,$1;
  3562. $2=self._new();
  3563. _st($2)._initializeFromString_canvas_("style",aCanvas);
  3564. $3=_st($2)._yourself();
  3565. $1=$3;
  3566. return $1;
  3567. }, function($ctx1) {$ctx1.fill(self,"canvas:",{aCanvas:aCanvas},smalltalk.StyleTag.klass)})},
  3568. args: ["aCanvas"],
  3569. source: "canvas: aCanvas\x0a\x09^self new\x0a\x09initializeFromString: 'style' canvas: aCanvas;\x0a\x09yourself",
  3570. messageSends: ["initializeFromString:canvas:", "new", "yourself"],
  3571. referencedClasses: []
  3572. }),
  3573. smalltalk.StyleTag.klass);
  3574. smalltalk.addClass('Widget', smalltalk.InterfacingObject, [], 'Canvas');
  3575. smalltalk.Widget.comment="I am a presenter building HTML. Subclasses are typically reusable components.\x0a\x0a## API\x0a\x0aUse `#renderContentOn:` to build HTML. (See `HTMLCanvas` and `TagBrush` classes for more about building HTML).\x0a\x0aTo add a widget to the page, the convenience method `#appendToJQuery:` is very useful.\x0a\x0aExemple: \x0a\x0a Counter new appendToJQuery: 'body' asJQuery";
  3576. smalltalk.addMethod(
  3577. smalltalk.method({
  3578. selector: "appendToBrush:",
  3579. category: 'adding',
  3580. fn: function (aTagBrush){
  3581. var self=this;
  3582. return smalltalk.withContext(function($ctx1) {
  3583. self._appendToJQuery_(_st(aTagBrush)._asJQuery());
  3584. return self}, function($ctx1) {$ctx1.fill(self,"appendToBrush:",{aTagBrush:aTagBrush},smalltalk.Widget)})},
  3585. args: ["aTagBrush"],
  3586. source: "appendToBrush: aTagBrush\x0a\x09self appendToJQuery: aTagBrush asJQuery",
  3587. messageSends: ["appendToJQuery:", "asJQuery"],
  3588. referencedClasses: []
  3589. }),
  3590. smalltalk.Widget);
  3591. smalltalk.addMethod(
  3592. smalltalk.method({
  3593. selector: "appendToJQuery:",
  3594. category: 'adding',
  3595. fn: function (aJQuery){
  3596. var self=this;
  3597. function $HTMLCanvas(){return smalltalk.HTMLCanvas||(typeof HTMLCanvas=="undefined"?nil:HTMLCanvas)}
  3598. return smalltalk.withContext(function($ctx1) {
  3599. self._renderOn_(_st($HTMLCanvas())._onJQuery_(aJQuery));
  3600. return self}, function($ctx1) {$ctx1.fill(self,"appendToJQuery:",{aJQuery:aJQuery},smalltalk.Widget)})},
  3601. args: ["aJQuery"],
  3602. source: "appendToJQuery: aJQuery\x0a\x09self renderOn: (HTMLCanvas onJQuery: aJQuery)",
  3603. messageSends: ["renderOn:", "onJQuery:"],
  3604. referencedClasses: ["HTMLCanvas"]
  3605. }),
  3606. smalltalk.Widget);
  3607. smalltalk.addMethod(
  3608. smalltalk.method({
  3609. selector: "renderOn:",
  3610. category: 'rendering',
  3611. fn: function (html){
  3612. var self=this;
  3613. return smalltalk.withContext(function($ctx1) {
  3614. return self}, function($ctx1) {$ctx1.fill(self,"renderOn:",{html:html},smalltalk.Widget)})},
  3615. args: ["html"],
  3616. source: "renderOn: html\x0a\x09self",
  3617. messageSends: [],
  3618. referencedClasses: []
  3619. }),
  3620. smalltalk.Widget);
  3621. smalltalk.addMethod(
  3622. smalltalk.method({
  3623. selector: "heliosClass",
  3624. category: 'helios',
  3625. fn: function (){
  3626. var self=this;
  3627. return smalltalk.withContext(function($ctx1) {
  3628. return "widget";
  3629. }, function($ctx1) {$ctx1.fill(self,"heliosClass",{},smalltalk.Widget.klass)})},
  3630. args: [],
  3631. source: "heliosClass\x0a\x09^ 'widget'",
  3632. messageSends: [],
  3633. referencedClasses: []
  3634. }),
  3635. smalltalk.Widget.klass);
  3636. smalltalk.addMethod(
  3637. smalltalk.method({
  3638. selector: "appendToBrush:",
  3639. category: '*Canvas',
  3640. fn: function (aTagBrush){
  3641. var self=this;
  3642. return smalltalk.withContext(function($ctx1) {
  3643. _st(aTagBrush)._append_(self._asString());
  3644. return self}, function($ctx1) {$ctx1.fill(self,"appendToBrush:",{aTagBrush:aTagBrush},smalltalk.Object)})},
  3645. args: ["aTagBrush"],
  3646. source: "appendToBrush: aTagBrush\x0a\x09aTagBrush append: self asString",
  3647. messageSends: ["append:", "asString"],
  3648. referencedClasses: []
  3649. }),
  3650. smalltalk.Object);
  3651. smalltalk.addMethod(
  3652. smalltalk.method({
  3653. selector: "appendToJQuery:",
  3654. category: '*Canvas',
  3655. fn: function (aJQuery){
  3656. var self=this;
  3657. return smalltalk.withContext(function($ctx1) {
  3658. _st(aJQuery)._append_(self._asString());
  3659. return self}, function($ctx1) {$ctx1.fill(self,"appendToJQuery:",{aJQuery:aJQuery},smalltalk.Object)})},
  3660. args: ["aJQuery"],
  3661. source: "appendToJQuery: aJQuery\x0a\x09aJQuery append: self asString",
  3662. messageSends: ["append:", "asString"],
  3663. referencedClasses: []
  3664. }),
  3665. smalltalk.Object);
  3666. smalltalk.addMethod(
  3667. smalltalk.method({
  3668. selector: "appendToBrush:",
  3669. category: '*Canvas',
  3670. fn: function (aTagBrush){
  3671. var self=this;
  3672. return smalltalk.withContext(function($ctx1) {
  3673. _st(aTagBrush)._appendBlock_(self);
  3674. return self}, function($ctx1) {$ctx1.fill(self,"appendToBrush:",{aTagBrush:aTagBrush},smalltalk.BlockClosure)})},
  3675. args: ["aTagBrush"],
  3676. source: "appendToBrush: aTagBrush\x0a\x09aTagBrush appendBlock: self",
  3677. messageSends: ["appendBlock:"],
  3678. referencedClasses: []
  3679. }),
  3680. smalltalk.BlockClosure);
  3681. smalltalk.addMethod(
  3682. smalltalk.method({
  3683. selector: "appendToJQuery:",
  3684. category: '*Canvas',
  3685. fn: function (aJQuery){
  3686. var self=this;
  3687. function $HTMLCanvas(){return smalltalk.HTMLCanvas||(typeof HTMLCanvas=="undefined"?nil:HTMLCanvas)}
  3688. return smalltalk.withContext(function($ctx1) {
  3689. self._value_(_st($HTMLCanvas())._onJQuery_(aJQuery));
  3690. return self}, function($ctx1) {$ctx1.fill(self,"appendToJQuery:",{aJQuery:aJQuery},smalltalk.BlockClosure)})},
  3691. args: ["aJQuery"],
  3692. source: "appendToJQuery: aJQuery\x0a\x09self value: (HTMLCanvas onJQuery: aJQuery)",
  3693. messageSends: ["value:", "onJQuery:"],
  3694. referencedClasses: ["HTMLCanvas"]
  3695. }),
  3696. smalltalk.BlockClosure);
  3697. smalltalk.addMethod(
  3698. smalltalk.method({
  3699. selector: "asSnippet",
  3700. category: '*Canvas',
  3701. fn: function (){
  3702. var self=this;
  3703. function $HTMLSnippet(){return smalltalk.HTMLSnippet||(typeof HTMLSnippet=="undefined"?nil:HTMLSnippet)}
  3704. return smalltalk.withContext(function($ctx1) {
  3705. var $1;
  3706. $1=_st(_st($HTMLSnippet())._current())._snippetAt_(self._asString());
  3707. return $1;
  3708. }, function($ctx1) {$ctx1.fill(self,"asSnippet",{},smalltalk.CharacterArray)})},
  3709. args: [],
  3710. source: "asSnippet\x0a\x09^ HTMLSnippet current snippetAt: self asString",
  3711. messageSends: ["snippetAt:", "current", "asString"],
  3712. referencedClasses: ["HTMLSnippet"]
  3713. }),
  3714. smalltalk.CharacterArray);
  3715. smalltalk.addMethod(
  3716. smalltalk.method({
  3717. selector: "appendToBrush:",
  3718. category: '*Canvas',
  3719. fn: function (aTagBrush){
  3720. var self=this;
  3721. return smalltalk.withContext(function($ctx1) {
  3722. _st(aTagBrush)._appendString_(self);
  3723. return self}, function($ctx1) {$ctx1.fill(self,"appendToBrush:",{aTagBrush:aTagBrush},smalltalk.String)})},
  3724. args: ["aTagBrush"],
  3725. source: "appendToBrush: aTagBrush\x0a\x09aTagBrush appendString: self",
  3726. messageSends: ["appendString:"],
  3727. referencedClasses: []
  3728. }),
  3729. smalltalk.String);
  3730. smalltalk.addMethod(
  3731. smalltalk.method({
  3732. selector: "appendToJQuery:",
  3733. category: '*Canvas',
  3734. fn: function (aJQuery){
  3735. var self=this;
  3736. return smalltalk.withContext(function($ctx1) {
  3737. _st(aJQuery)._append_(self);
  3738. return self}, function($ctx1) {$ctx1.fill(self,"appendToJQuery:",{aJQuery:aJQuery},smalltalk.String)})},
  3739. args: ["aJQuery"],
  3740. source: "appendToJQuery: aJQuery\x0a\x09aJQuery append: self",
  3741. messageSends: ["append:"],
  3742. referencedClasses: []
  3743. }),
  3744. smalltalk.String);
  3745. smalltalk.addMethod(
  3746. smalltalk.method({
  3747. selector: "asJQuery",
  3748. category: '*Canvas',
  3749. fn: function (){
  3750. var self=this;
  3751. return smalltalk.withContext(function($ctx1) {
  3752. return jQuery(String(self));
  3753. return self}, function($ctx1) {$ctx1.fill(self,"asJQuery",{},smalltalk.String)})},
  3754. args: [],
  3755. source: "asJQuery\x0a\x09<return jQuery(String(self))>",
  3756. messageSends: [],
  3757. referencedClasses: []
  3758. }),
  3759. smalltalk.String);
  3760. smalltalk.addMethod(
  3761. smalltalk.method({
  3762. selector: "asJQuery",
  3763. category: '*Canvas',
  3764. fn: function (){
  3765. var self=this;
  3766. return smalltalk.withContext(function($ctx1) {
  3767. return jQuery(self['@jsObject']);
  3768. return self}, function($ctx1) {$ctx1.fill(self,"asJQuery",{},smalltalk.JSObjectProxy)})},
  3769. args: [],
  3770. source: "asJQuery\x0a\x09<return jQuery(self['@jsObject'])>",
  3771. messageSends: [],
  3772. referencedClasses: []
  3773. }),
  3774. smalltalk.JSObjectProxy);
  3775. });