X-Git-Url: https://git.pterodactylus.net/?a=blobdiff_plain;f=synfig-studio%2Ftrunk%2Fsrc%2Fgtkmm%2Fstate_gradient.cpp;h=f116265ade6ac747ab417e109da9eed8e604650b;hb=7c3682a6d1bb940fd74e9e327bbc2dd3a8fdb504;hp=40deb658c6b623851eaf865428adaa297001b09d;hpb=62136261cc9eed43f117b46c61361dda07dfce97;p=synfig.git diff --git a/synfig-studio/trunk/src/gtkmm/state_gradient.cpp b/synfig-studio/trunk/src/gtkmm/state_gradient.cpp index 40deb65..f116265 100644 --- a/synfig-studio/trunk/src/gtkmm/state_gradient.cpp +++ b/synfig-studio/trunk/src/gtkmm/state_gradient.cpp @@ -6,6 +6,7 @@ ** ** \legal ** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley +** Copyright (c) 2008 Chris Moore ** ** This package is free software; you can redistribute it and/or ** modify it under the terms of the GNU General Public License as @@ -263,8 +264,8 @@ StateGradient_Context::StateGradient_Context(CanvasView* canvas_view): { egress_on_selection_change=true; // Set up the tool options dialog - ///options_table.attach(*manage(new Gtk::Label(_("Gradient Tool"))), 0, 2, 0, 1, Gtk::EXPAND|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0); - options_table.attach(entry_id, 0, 2, 1, 2, Gtk::EXPAND|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0); + options_table.attach(*manage(new Gtk::Label(_("Gradient Tool"))), 0, 2, 0, 1, Gtk::EXPAND|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0); + options_table.attach(entry_id, 0, 2, 1, 2, Gtk::EXPAND|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0); enum_type.set_param_desc(ParamDesc("type") .set_local_name(_("Gradient Type")) @@ -493,6 +494,7 @@ StateGradient_Context::event_mouse_click_handler(const Smach::event& x) if(event.key==EVENT_WORKAREA_MOUSE_BUTTON_DRAG && event.button==BUTTON_LEFT) { + if (!point2_duck) return Smach::RESULT_OK; point2_duck->set_point(get_work_area()->snap_point_to_grid(event.pos)); get_work_area()->queue_draw(); return Smach::RESULT_ACCEPT;