Canvas.js 112 KB

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