void SetCelOpacity::onFireNotifications() { Cel* cel = this->cel(); DocumentEvent ev(cel->document()); ev.sprite(cel->sprite()); ev.cel(cel); cel->document()->notifyObservers<DocumentEvent&>(&DocumentObserver::onCelOpacityChanged, ev); }
void SetCelPosition::onFireNotifications() { Cel* cel = this->cel(); Doc* doc = static_cast<Doc*>(cel->document()); DocEvent ev(doc); ev.sprite(cel->sprite()); ev.cel(cel); doc->notify_observers<DocEvent&>(&DocObserver::onCelPositionChanged, ev); }