Working on 1827966: Angles are recalculated to 360 mod.
authordooglus <dooglus@1f10aa63-cdf2-0310-b900-c93c546f37ac>
Mon, 12 Nov 2007 08:15:47 +0000 (08:15 +0000)
committerdooglus <dooglus@1f10aa63-cdf2-0310-b900-c93c546f37ac>
Mon, 12 Nov 2007 08:15:47 +0000 (08:15 +0000)
git-svn-id: http://svn.voria.com/code@1136 1f10aa63-cdf2-0310-b900-c93c546f37ac

synfig-studio/trunk/src/gtkmm/canvasview.cpp
synfig-studio/trunk/src/gtkmm/canvasview.h

index e317406..1d75c65 100644 (file)
@@ -2556,6 +2556,14 @@ CanvasView::on_duck_changed(const synfig::Point &value,const synfigapp::ValueDes
        return true;
 }
 
+bool
+CanvasView::on_duck_angle_changed(const synfig::Angle &rotation,const synfigapp::ValueDesc& value_desc)
+{
+       // \todo will this really always be the case?
+       assert(value_desc.get_value_type() == ValueBase::TYPE_ANGLE);
+       return canvas_interface()->change_value(value_desc, value_desc.get_value(get_time()).get(Angle()) + rotation);
+}
+
 void
 CanvasView::selected_layer_color_set(Color color)
 {
index a22daed..39658a4 100644 (file)
@@ -668,6 +668,7 @@ private:
        void on_audio_offset_notify();
 
        bool on_duck_changed(const synfig::Point &value,const synfigapp::ValueDesc& value_desc);
+       bool on_duck_angle_changed(const synfig::Angle &rotation,const synfigapp::ValueDesc& value_desc);
 
        void on_layer_toggle(synfig::Layer::Handle);