end
def remove au
- d = false
- speech_balloons_attributes = {}
- self.panel.speech_balloons.each do |speech_balloon|
- attr = speech_balloon.attributes
- if speech_balloon == self
- attr['_destroy'] = true
- d = true
- else
- if d
- attr['t'] -= 1
- end
- end
- speech_balloons_attributes[speech_balloon.id] = attr
- end
- self.panel.attributes = {:speech_balloons_attributes => speech_balloons_attributes}
- self.panel.store({}, au)
+ self.panel.remove_element(self, au)
end
def scenario