<% when 'PanelPicture' %>
<%= link_to_unless(elm.link.blank?, tag(:img, elm.opt_img_tag(spot)), elm.link) %>
<% when 'SpeechBalloon' %>
- <% balloon = elm.balloons.first %>
- <div id="vballoon<%= elm.id -%>" class="pettanr-comic-balloon" style="width:<%= balloon.width -%>px; height:<%= balloon.height -%>px; top:<%= balloon.y -%>px; left:<%= balloon.x -%>px; z-index:<%= elm.z -%>; ">
- <img src="<%= balloon.system_picture.url -%>" alt="<%= balloon.caption -%>">
- <% elm.speeches.each do |speech| %>
- <p style="top:<%= speech.y -%>px; left:<%= speech.x -%>px;width:<%= speech.width -%>px; height:<%= speech.height -%>px;">
- <span><%= h speech.content -%></span>
- </p>
- <% end %>
+ <div id="vballoon<%= elm.id -%>" class="pettanr-comic-balloon" style="width:<%= elm.balloon.width -%>px; height:<%= elm.balloon.height -%>px; top:<%= elm.balloon.y -%>px; left:<%= elm.balloon.x -%>px; z-index:<%= elm.z -%>; ">
+ <img src="<%= elm.balloon.system_picture.url -%>" alt="<%= elm.caption -%>">
+ <p style="top:<%= elm.speech.y -%>px; left:<%= elm.speech.x -%>px;width:<%= elm.speech.width -%>px; height:<%= elm.speech.height -%>px;">
+ <span><%= h elm.speech.content -%></span>
+ </p>
</div>
<% when 'GroundPicture' %>
<div id="ground-picture<%= elm.id -%>" class="pettanr-comic-ground-picture" style="<%= elm.opt_div_style(full_url(elm.picture.url), spot) -%>">