set_time(current_time_widget->get_value());
}
-Gtk::Widget*
-CanvasView::create_children_tree()
-{
- // Create the layer tree
- children_tree=manage(new class ChildrenTree());
-
- // Set up the layer tree
- //children_tree->set_model(children_tree_store());
- if(children_tree)children_tree->set_time_adjustment(time_adjustment());
- if(children_tree)children_tree->show();
-
- // Connect Signals
- if(children_tree)children_tree->signal_edited_value().connect(sigc::mem_fun(*this, &studio::CanvasView::on_edited_value));
- if(children_tree)children_tree->signal_user_click().connect(sigc::mem_fun(*this, &studio::CanvasView::on_children_user_click));
- if(children_tree)children_tree->signal_waypoint_clicked().connect(sigc::mem_fun(*this, &studio::CanvasView::on_waypoint_clicked));
- if(children_tree)children_tree->get_selection()->signal_changed().connect(SLOT_EVENT(EVENT_REFRESH_DUCKS));
-
- return children_tree;
-}
-
-Gtk::Widget*
-CanvasView::create_keyframe_tree()
-{
- keyframe_tree=manage(new KeyframeTree());
-
- //keyframe_tree->get_selection()->set_mode(Gtk::SELECTION_MULTIPLE);
- //keyframe_tree->show();
- //keyframe_tree->set_model(keyframe_tree_store());
- keyframe_tree->set_editable(true);
- //keyframe_tree->signal_edited().connect(sigc::hide_return(sigc::mem_fun(*canvas_interface(), &synfigapp::CanvasInterface::update_keyframe)));
-
- keyframe_tree->signal_event().connect(sigc::mem_fun(*this, &studio::CanvasView::on_keyframe_tree_event));
-
- Gtk::ScrolledWindow *scroll_layer_tree = manage(new class Gtk::ScrolledWindow());
- scroll_layer_tree->set_flags(Gtk::CAN_FOCUS);
- scroll_layer_tree->set_policy(Gtk::POLICY_AUTOMATIC, Gtk::POLICY_AUTOMATIC);
- scroll_layer_tree->add(*keyframe_tree);
- scroll_layer_tree->set_shadow_type(Gtk::SHADOW_ETCHED_IN);
- //scroll_layer_tree->show();
-
-
- Gtk::Table *layout_table= manage(new Gtk::Table(1, 2, false));
- layout_table->attach(*scroll_layer_tree, 0, 1, 0, 1, Gtk::EXPAND|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0);
-
- Gtk::Image *icon;
- Gtk::IconSize iconsize(Gtk::IconSize::from_name("synfig-small_icon"));
-
- NEW_SMALL_BUTTON(button_add,"gtk-add",_("New Keyframe"));
- NEW_SMALL_BUTTON(button_duplicate,"synfig-duplicate",_("Duplicate Keyframe"));
- NEW_SMALL_BUTTON(button_delete,"gtk-delete",_("Delete Keyframe"));
-
- Gtk::HBox *hbox(manage(new Gtk::HBox()));
- layout_table->attach(*hbox, 0, 1, 1, 2, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK, 0, 0);
-
- hbox->pack_start(*button_add,Gtk::PACK_SHRINK);
- hbox->pack_start(*button_duplicate,Gtk::PACK_SHRINK);
- hbox->pack_start(*button_delete,Gtk::PACK_SHRINK);
-
- /*
- button_raise->set_relief(Gtk::RELIEF_HALF);
- button_lower->set_relief(Gtk::RELIEF_HALF);
- button_duplicate->set_relief(Gtk::RELIEF_HALF);
- button_delete->set_relief(Gtk::RELIEF_HALF);
- */
-
- button_add->signal_clicked().connect(sigc::mem_fun(*this, &studio::CanvasView::on_keyframe_add_pressed));
- button_duplicate->signal_clicked().connect(sigc::mem_fun(*this, &studio::CanvasView::on_keyframe_duplicate_pressed));
- button_delete->signal_clicked().connect(sigc::mem_fun(*this, &studio::CanvasView::on_keyframe_remove_pressed));
-
- //layout_table->show_all();
-
- keyframe_tab_child=layout_table;
-
-
- layout_table->hide();
-
- return layout_table;
-}
-
-Gtk::Widget*
-CanvasView::create_layer_tree()
-{
- // Create the layer tree
- layer_tree=manage(new class LayerTree());
-
- // Set up the layer tree
- //layer_tree->set_model(layer_tree_store());
- layer_tree->set_time_adjustment(time_adjustment());
- layer_tree->show();
+// Gtk::Widget*
+// CanvasView::create_children_tree()
+// {
+// // Create the layer tree
+// children_tree=manage(new class ChildrenTree());
+//
+// // Set up the layer tree
+// //children_tree->set_model(children_tree_store());
+// if(children_tree)children_tree->set_time_adjustment(time_adjustment());
+// if(children_tree)children_tree->show();
+//
+// // Connect Signals
+// if(children_tree)children_tree->signal_edited_value().connect(sigc::mem_fun(*this, &studio::CanvasView::on_edited_value));
+// if(children_tree)children_tree->signal_user_click().connect(sigc::mem_fun(*this, &studio::CanvasView::on_children_user_click));
+// if(children_tree)children_tree->signal_waypoint_clicked().connect(sigc::mem_fun(*this, &studio::CanvasView::on_waypoint_clicked));
+// if(children_tree)children_tree->get_selection()->signal_changed().connect(SLOT_EVENT(EVENT_REFRESH_DUCKS));
+//
+// return children_tree;
+// }
- // Connect Signals
- layer_tree->signal_layer_toggle().connect(sigc::mem_fun(*this, &studio::CanvasView::on_layer_toggle));
- layer_tree->signal_edited_value().connect(sigc::mem_fun(*this, &studio::CanvasView::on_edited_value));
- layer_tree->signal_layer_user_click().connect(sigc::mem_fun(*this, &studio::CanvasView::on_layer_user_click));
- layer_tree->signal_param_user_click().connect(sigc::mem_fun(*this, &studio::CanvasView::on_children_user_click));
- layer_tree->signal_waypoint_clicked().connect(sigc::mem_fun(*this, &studio::CanvasView::on_waypoint_clicked));
- layer_tree->get_selection()->signal_changed().connect(SLOT_EVENT(EVENT_REFRESH_DUCKS));
+// Gtk::Widget*
+// CanvasView::create_keyframe_tree()
+// {
+// keyframe_tree=manage(new KeyframeTree());
+//
+// //keyframe_tree->get_selection()->set_mode(Gtk::SELECTION_MULTIPLE);
+// //keyframe_tree->show();
+// //keyframe_tree->set_model(keyframe_tree_store());
+// keyframe_tree->set_editable(true);
+// //keyframe_tree->signal_edited().connect(sigc::hide_return(sigc::mem_fun(*canvas_interface(), &synfigapp::CanvasInterface::update_keyframe)));
+//
+// keyframe_tree->signal_event().connect(sigc::mem_fun(*this, &studio::CanvasView::on_keyframe_tree_event));
+//
+// Gtk::ScrolledWindow *scroll_layer_tree = manage(new class Gtk::ScrolledWindow());
+// scroll_layer_tree->set_flags(Gtk::CAN_FOCUS);
+// scroll_layer_tree->set_policy(Gtk::POLICY_AUTOMATIC, Gtk::POLICY_AUTOMATIC);
+// scroll_layer_tree->add(*keyframe_tree);
+// scroll_layer_tree->set_shadow_type(Gtk::SHADOW_ETCHED_IN);
+// //scroll_layer_tree->show();
+//
+//
+// Gtk::Table *layout_table= manage(new Gtk::Table(1, 2, false));
+// layout_table->attach(*scroll_layer_tree, 0, 1, 0, 1, Gtk::EXPAND|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0);
+//
+// Gtk::Image *icon;
+// Gtk::IconSize iconsize(Gtk::IconSize::from_name("synfig-small_icon"));
+//
+// NEW_SMALL_BUTTON(button_add,"gtk-add",_("New Keyframe"));
+// NEW_SMALL_BUTTON(button_duplicate,"synfig-duplicate",_("Duplicate Keyframe"));
+// NEW_SMALL_BUTTON(button_delete,"gtk-delete",_("Delete Keyframe"));
+//
+// Gtk::HBox *hbox(manage(new Gtk::HBox()));
+// layout_table->attach(*hbox, 0, 1, 1, 2, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK, 0, 0);
+//
+// hbox->pack_start(*button_add,Gtk::PACK_SHRINK);
+// hbox->pack_start(*button_duplicate,Gtk::PACK_SHRINK);
+// hbox->pack_start(*button_delete,Gtk::PACK_SHRINK);
+//
+// /*
+// button_raise->set_relief(Gtk::RELIEF_HALF);
+// button_lower->set_relief(Gtk::RELIEF_HALF);
+// button_duplicate->set_relief(Gtk::RELIEF_HALF);
+// button_delete->set_relief(Gtk::RELIEF_HALF);
+// */
+//
+// button_add->signal_clicked().connect(sigc::mem_fun(*this, &studio::CanvasView::on_keyframe_add_pressed));
+// button_duplicate->signal_clicked().connect(sigc::mem_fun(*this, &studio::CanvasView::on_keyframe_duplicate_pressed));
+// button_delete->signal_clicked().connect(sigc::mem_fun(*this, &studio::CanvasView::on_keyframe_remove_pressed));
+//
+// //layout_table->show_all();
+//
+// keyframe_tab_child=layout_table;
+//
+//
+// layout_table->hide();
+//
+// return layout_table;
+// }
- layer_tree->hide();
- return layer_tree;
-}
+// Gtk::Widget*
+// CanvasView::create_layer_tree()
+// {
+// // Create the layer tree
+// printf("CanvasView::create_layer_tree()\n");
+// layer_tree=manage(new class LayerTree());
+//
+// // Set up the layer tree
+// //layer_tree->set_model(layer_tree_store());
+// layer_tree->set_time_adjustment(time_adjustment());
+// layer_tree->show();
+//
+// // Connect Signals
+// layer_tree->signal_layer_toggle().connect(sigc::mem_fun(*this, &studio::CanvasView::on_layer_toggle));
+// layer_tree->signal_edited_value().connect(sigc::mem_fun(*this, &studio::CanvasView::on_edited_value));
+// layer_tree->signal_layer_user_click().connect(sigc::mem_fun(*this, &studio::CanvasView::on_layer_user_click));
+// layer_tree->signal_param_user_click().connect(sigc::mem_fun(*this, &studio::CanvasView::on_children_user_click));
+// layer_tree->signal_waypoint_clicked().connect(sigc::mem_fun(*this, &studio::CanvasView::on_waypoint_clicked));
+// layer_tree->get_selection()->signal_changed().connect(SLOT_EVENT(EVENT_REFRESH_DUCKS));
+//
+// layer_tree->hide();
+// return layer_tree;
+// }
void
CanvasView::init_menus()