OSDN Git Service

fix: fetch fail
[pettanr/pettanr.git] / app / assets / javascripts / models / speech.js.coffee
index b0b3119..2094552 100644 (file)
@@ -14,6 +14,12 @@ class Pettanr.Speech extends Peta.Element
     height: 100\r
   } \r
   \r
+  @trace_routes: () ->\r
+    {\r
+      speech_balloon: 'speech_balloon',\r
+      symbol: ['speech_balloon', 'speech_balloon_template', 'system_picture']\r
+    }\r
+  \r
   pick: () ->\r
     # \r
     speech_balloon_template = @templates.speech_balloon_template\r
@@ -25,27 +31,9 @@ class Pettanr.Speech extends Peta.Element
       writing_format_module_name: writing_format.get('module_name'),\r
     }\r
   \r
-  speech_balloon: () ->\r
-    new Pettanr.Cache.Retriever(Pettanr.SpeechBalloon, @get('speech_balloon_id'))\r
-  \r
-  writing_format: () ->\r
-    new Pettanr.Cache.Retriever(Pettanr.WritingFormat, @get('writing_format_id'))\r
-  \r
   @text_align_texts: () -> \r
     ['left', 'left', 'right', 'center']\r
   \r
-  symbol_option: () ->\r
-    @get_parent('speech_balloon', this, {\r
-      success: (speech_balloon) => \r
-        speech_balloon.get_parent('speech_balloon_template', this, {\r
-          success: (speech_balloon_template) => \r
-            speech_balloon_template.get_parent('system_picture', this, {\r
-              success: (system_picture) => \r
-                @trigger('ready:symbol', system_picture.tmb_opt_img_tag())\r
-            })\r
-        })\r
-    })\r
-  \r
   text_align_text: () ->\r
     Pettanr.Speech.text_align_texts()[@get('text_align')]\r
   \r
@@ -53,6 +41,9 @@ class Pettanr.Speech extends Peta.Element
     @boosts('read')\r
     @render(@escape('content'))\r
   \r
+  plain_scenario: () ->\r
+    @escape('content')\r
+  \r
   initialize: (attr, options) ->\r
     super(attr, options)\r
   \r