Comment out unused code to make it clearer what code is used and what isn't.
authordooglus <dooglus@1f10aa63-cdf2-0310-b900-c93c546f37ac>
Tue, 1 Jan 2008 14:50:47 +0000 (14:50 +0000)
committerdooglus <dooglus@1f10aa63-cdf2-0310-b900-c93c546f37ac>
Tue, 1 Jan 2008 14:50:47 +0000 (14:50 +0000)
git-svn-id: http://svn.voria.com/code@1249 1f10aa63-cdf2-0310-b900-c93c546f37ac

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

index ab88fed..4cc713e 100644 (file)
@@ -1434,247 +1434,247 @@ CanvasView::init_menus()
 
 
 #if 0
-
-       //Test some key stuff
-
-       filemenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-save"),
-               hide_return(sigc::mem_fun(*get_instance().get(), &studio::Instance::save))));
-       filemenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-save-as"),sigc::hide_return(sigc::mem_fun(*get_instance(), &studio::Instance::dialog_save_as))));
-       filemenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-revert-to-saved"),hide_return(sigc::mem_fun(*get_instance().get(), &studio::Instance::safe_revert))));
-       filemenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
-
-       filemenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("synfig-cvs_add"),sigc::hide_return(sigc::mem_fun(*get_instance(), &studio::Instance::dialog_cvs_add))));
-       filemenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("synfig-cvs_update"),sigc::hide_return(sigc::mem_fun(*get_instance(), &studio::Instance::dialog_cvs_update))));
-       filemenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("synfig-cvs_commit"),sigc::hide_return(sigc::mem_fun(*get_instance(), &studio::Instance::dialog_cvs_commit))));
-
-       filemenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
-       filemenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Import..."),Gtk::AccelKey('I',Gdk::CONTROL_MASK),sigc::hide_return(sigc::mem_fun(*this, &studio::CanvasView::image_import))));
-       filemenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
-       filemenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Render"),Gtk::AccelKey("F9"),
-               sigc::mem_fun(render_settings,&studio::RenderSettings::present)
-       ));
-       filemenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Preview"),Gtk::AccelKey("F11"),
-               sigc::mem_fun(*this,&CanvasView::on_preview_option)
-       ));
-       filemenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Sound File"),
-               sigc::mem_fun(*this,&CanvasView::on_audio_option)
-       ));
-
-       filemenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
-       filemenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Options"),Gtk::AccelKey("F12"),
-               sigc::mem_fun(canvas_options,&studio::CanvasOptions::present)
-       ));
-       filemenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
-       filemenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Close View"),
-               sigc::hide_return(sigc::mem_fun(*this,&studio::CanvasView::close_view))
-       ));
-       filemenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Close Document"),
-               sigc::hide_return(sigc::mem_fun(*this,&studio::CanvasView::close_document))
-       ));
-
-       editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-undo"),Gtk::AccelKey('Z',Gdk::CONTROL_MASK),SLOT_EVENT(EVENT_UNDO)));
-       editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-redo"),Gtk::AccelKey('R',Gdk::CONTROL_MASK),SLOT_EVENT(EVENT_REDO)));
-       editmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
-       editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-cut"),NOT_IMPLEMENTED_SLOT));
-       editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-copy"),NOT_IMPLEMENTED_SLOT));
-       editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-paste"),NOT_IMPLEMENTED_SLOT));
-       editmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
-       editmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Select All Ducks"),Gtk::AccelKey('E',Gdk::CONTROL_MASK),sigc::mem_fun(*work_area,&studio::WorkArea::select_all_ducks)));
-       editmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Unselect All Layers"),Gtk::AccelKey('D',Gdk::CONTROL_MASK),sigc::mem_fun(*this,&CanvasView::on_unselect_layers)));
-       editmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
-
-       //editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-stop"),Gtk::AccelKey(GDK_Escape,static_cast<Gdk::ModifierType>(0)),sigc::hide_return(sigc::mem_fun(*this, &studio::CanvasView::stop))));
-       //editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-refresh"),Gtk::AccelKey('k',Gdk::CONTROL_MASK),sigc::hide_return(sigc::mem_fun(*this, &studio::CanvasView::on_refresh_pressed))));
-       editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-stop"),Gtk::AccelKey(GDK_Escape,static_cast<Gdk::ModifierType>(0)),SLOT_EVENT(EVENT_STOP)));
-       editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-refresh"),Gtk::AccelKey('k',Gdk::CONTROL_MASK),SLOT_EVENT(EVENT_REFRESH)));
-       editmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
-       editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-properties"),Gtk::AccelKey("F8"),
-               sigc::mem_fun(canvas_properties,&studio::CanvasProperties::present)
-       ));
-
-       build_new_layer_menu(newlayermenu);
-       layermenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("New"),newlayermenu));
-
-
-       {
-               synfigapp::Action::ParamList param_list;
-               param_list.add("canvas",Canvas::Handle(get_canvas()));
-               param_list.add("canvas_interface",canvas_interface());
-               add_actions_to_menu(&canvasmenu, param_list,synfigapp::Action::CATEGORY_CANVAS);
-       }
-
-
-       //canvasmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Keyframe Dialog"),sigc::mem_fun(keyframe_dialog,&studio::Dialog_Keyframe::present)));
-
-       // Duck Mask Menu
-       if(1)
-               {
-               duckmaskmenu.items().push_back(Gtk::Menu_Helpers::TearoffMenuElem());
-
-               duckmaskmenu.items().push_back(Gtk::Menu_Helpers::CheckMenuElem(_("Position Ducks"),Gtk::AccelKey('1',Gdk::MOD1_MASK)));
-               duck_mask_position=static_cast<Gtk::CheckMenuItem*>(&duckmaskmenu.items().back());
-               duck_mask_position->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_POSITION));
-               duck_mask_position->signal_toggled().connect(
-                       sigc::bind(
-                               sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask),
-                               Duck::TYPE_POSITION
-                       )
-               );
-
-               duckmaskmenu.items().push_back(Gtk::Menu_Helpers::CheckMenuElem(_("Vertex Ducks"),Gtk::AccelKey('2',Gdk::MOD1_MASK)));
-               duck_mask_vertex=static_cast<Gtk::CheckMenuItem*>(&duckmaskmenu.items().back());
-               duck_mask_vertex->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_VERTEX));
-               duck_mask_vertex->signal_toggled().connect(
-                       sigc::bind(
-                               sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask),
-                               Duck::TYPE_VERTEX
-                       )
-               );
-
-               duckmaskmenu.items().push_back(Gtk::Menu_Helpers::CheckMenuElem(_("Tangent Ducks"),Gtk::AccelKey('3',Gdk::MOD1_MASK)));
-               duck_mask_tangent=static_cast<Gtk::CheckMenuItem*>(&duckmaskmenu.items().back());
-               duck_mask_tangent->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_TANGENT));
-               duck_mask_tangent->signal_toggled().connect(
-                       sigc::bind(
-                               sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask),
-                               Duck::TYPE_TANGENT
-                       )
-               );
-
-               duckmaskmenu.items().push_back(Gtk::Menu_Helpers::CheckMenuElem(_("Radius Ducks"),Gtk::AccelKey('4',Gdk::MOD1_MASK)));
-               duck_mask_radius=static_cast<Gtk::CheckMenuItem*>(&duckmaskmenu.items().back());
-               duck_mask_radius->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_RADIUS));
-               duck_mask_radius->signal_toggled().connect(
-                       sigc::bind(
-                               sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask),
-                               Duck::TYPE_RADIUS
-                       )
-               );
-
-               duckmaskmenu.items().push_back(Gtk::Menu_Helpers::CheckMenuElem(_("Width Ducks"),Gtk::AccelKey('5',Gdk::MOD1_MASK)));
-               duck_mask_width=static_cast<Gtk::CheckMenuItem*>(&duckmaskmenu.items().back());
-               duck_mask_width->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_WIDTH));
-               duck_mask_width->signal_toggled().connect(
-                       sigc::bind(
-                               sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask),
-                               Duck::TYPE_WIDTH
-                       )
-               );
-
-               duckmaskmenu.items().push_back(Gtk::Menu_Helpers::CheckMenuElem(_("Angle Ducks"),Gtk::AccelKey('6',Gdk::MOD1_MASK)));
-               duck_mask_angle=static_cast<Gtk::CheckMenuItem*>(&duckmaskmenu.items().back());
-               duck_mask_angle->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_ANGLE));
-               duck_mask_angle->signal_toggled().connect(
-                       sigc::bind(
-                               sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask),
-                               Duck::TYPE_ANGLE
-                       )
-               );
-
-               viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("_Mask Ducks"),duckmaskmenu));
-       }
-
-       // Preview Quality Menu
-       if(1)
-       {
-               qualitymenu.items().push_back(Gtk::Menu_Helpers::TearoffMenuElem());
-               int i;
-               qualitymenu.items().push_back(Gtk::Menu_Helpers::MenuElem(strprintf(_("Use Parametric Renderer"),0),
-                       sigc::bind(
-                               sigc::mem_fun(*work_area, &studio::WorkArea::set_quality),
-                               0
-                       )
-               ));
-               for(i=1;i<=10;i++)
-               {
-                       qualitymenu.items().push_back(Gtk::Menu_Helpers::MenuElem(strprintf(_("Set Quality to %d"),i),Gtk::AccelKey('0'+(i%10),Gdk::CONTROL_MASK),
-                               sigc::bind(
-                                       sigc::mem_fun(*work_area, &studio::WorkArea::set_quality),
-                                       i
-                               )
-                       ));
-               }
-               viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Preview Quality"),qualitymenu));
-       }
-
-       viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::Stock::MEDIA_PLAY,
-               sigc::mem_fun(*this, &studio::CanvasView::play)));
-       viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("Flipbook Dialog"),
-               sigc::mem_fun(*preview_dialog, &studio::Dialog_Preview::present)));
-
-       viewmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
-
-       viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Toggle Grid Show"),Gtk::AccelKey('g',Gdk::CONTROL_MASK),
-               sigc::mem_fun(*work_area, &studio::WorkArea::toggle_grid)));
-       viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Toggle Grid Snap"),Gtk::AccelKey('l',Gdk::CONTROL_MASK),
-               sigc::mem_fun(*work_area, &studio::WorkArea::toggle_grid_snap)));
-       viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Toggle Guide Snap"),Gtk::AccelKey('k',Gdk::CONTROL_MASK),
-               sigc::mem_fun(*work_area, &studio::WorkArea::toggle_guide_snap)));
-       viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Toggle Low-Res"),Gtk::AccelKey('`',Gdk::CONTROL_MASK),
-               sigc::mem_fun(*work_area, &studio::WorkArea::toggle_low_resolution_flag)));
-
-       viewmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
-
-       viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-zoom-in"),Gtk::AccelKey('=',static_cast<Gdk::ModifierType>(0)),
-               sigc::mem_fun(*work_area, &studio::WorkArea::zoom_in)));
-       viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-zoom-out"),Gtk::AccelKey('-',static_cast<Gdk::ModifierType>(0)),
-               sigc::mem_fun(*work_area, &studio::WorkArea::zoom_out)));
-       viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-zoom-fit"),
-               sigc::mem_fun(*work_area, &studio::WorkArea::zoom_fit)));
-       viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-zoom-100"),Gtk::AccelKey('`',static_cast<Gdk::ModifierType>(0)),
-               sigc::mem_fun(*work_area, &studio::WorkArea::zoom_norm)));
-       viewmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
-
-       viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-zoom-in"),Gtk::AccelKey('+',static_cast<Gdk::ModifierType>(0)),
-               sigc::mem_fun(*this, &studio::CanvasView::time_zoom_in)));
-       viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-zoom-out"),Gtk::AccelKey('_',static_cast<Gdk::ModifierType>(0)),
-               sigc::mem_fun(*this, &studio::CanvasView::time_zoom_out)));
-
-       viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Jump to Next Keyframe"),Gtk::AccelKey(']',static_cast<Gdk::ModifierType>(0)),
-               sigc::mem_fun(*canvas_interface().get(), &synfigapp::CanvasInterface::jump_to_next_keyframe)));
-       viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Jump to Prev Keyframe"),Gtk::AccelKey('[',static_cast<Gdk::ModifierType>(0)),
-               sigc::mem_fun(*canvas_interface().get(), &synfigapp::CanvasInterface::jump_to_prev_keyframe)));
-
-       mainmenu.items().push_back(Gtk::Menu_Helpers::TearoffMenuElem());
-       mainmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("_File"),filemenu));
-       mainmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("_Edit"),editmenu));
-       mainmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("_View"),viewmenu));
-       mainmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("_Canvas"),canvasmenu));
-       mainmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("_Layer"),layermenu));
-
-       mainmenu.accelerate(*this);
-
-/*
-       {
-
-               trackmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("New Waypoint"),NOT_IMPLEMENTED_SLOT));
-               trackmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Delete Waypoint"),NOT_IMPLEMENTED_SLOT));
-               trackmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Export"),NOT_IMPLEMENTED_SLOT));
-               trackmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
-               trackmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Properties"),NOT_IMPLEMENTED_SLOT));
-       }
-*/
-       mainmenu.show();
-       filemenu.show();
-       editmenu.show();
-       canvasmenu.show();
-       layermenu.show();
-
-       keyframemenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-properties"),
-               sigc::mem_fun(*this,&studio::CanvasView::show_keyframe_dialog)
-       ));
-
-
-       get_accel_group()->unlock();
-
-       //Set the accelerator paths for all the menus
-       filemenu.set_accel_path("<synfig>/File");
-       editmenu.set_accel_path("<synfig>/Edit");
-       layermenu.set_accel_path("<synfig>/Layer");
-       //mainmenu.set_accel_path("<synfig-main>");
-       canvasmenu.set_accel_path("<synfig>/Canvas");
-       viewmenu.set_accel_path("<synfig>/View");
-       duckmaskmenu.set_accel_path("<synfig>/DuckMask");
+//
+//     //Test some key stuff
+//
+//     filemenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-save"),
+//             hide_return(sigc::mem_fun(*get_instance().get(), &studio::Instance::save))));
+//     filemenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-save-as"),sigc::hide_return(sigc::mem_fun(*get_instance(), &studio::Instance::dialog_save_as))));
+//     filemenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-revert-to-saved"),hide_return(sigc::mem_fun(*get_instance().get(), &studio::Instance::safe_revert))));
+//     filemenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
+//
+//     filemenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("synfig-cvs_add"),sigc::hide_return(sigc::mem_fun(*get_instance(), &studio::Instance::dialog_cvs_add))));
+//     filemenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("synfig-cvs_update"),sigc::hide_return(sigc::mem_fun(*get_instance(), &studio::Instance::dialog_cvs_update))));
+//     filemenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("synfig-cvs_commit"),sigc::hide_return(sigc::mem_fun(*get_instance(), &studio::Instance::dialog_cvs_commit))));
+//
+//     filemenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
+//     filemenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Import..."),Gtk::AccelKey('I',Gdk::CONTROL_MASK),sigc::hide_return(sigc::mem_fun(*this, &studio::CanvasView::image_import))));
+//     filemenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
+//     filemenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Render"),Gtk::AccelKey("F9"),
+//             sigc::mem_fun(render_settings,&studio::RenderSettings::present)
+//     ));
+//     filemenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Preview"),Gtk::AccelKey("F11"),
+//             sigc::mem_fun(*this,&CanvasView::on_preview_option)
+//     ));
+//     filemenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Sound File"),
+//             sigc::mem_fun(*this,&CanvasView::on_audio_option)
+//     ));
+//
+//     filemenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
+//     filemenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Options"),Gtk::AccelKey("F12"),
+//             sigc::mem_fun(canvas_options,&studio::CanvasOptions::present)
+//     ));
+//     filemenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
+//     filemenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Close View"),
+//             sigc::hide_return(sigc::mem_fun(*this,&studio::CanvasView::close_view))
+//     ));
+//     filemenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Close Document"),
+//             sigc::hide_return(sigc::mem_fun(*this,&studio::CanvasView::close_document))
+//     ));
+//
+//     editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-undo"),Gtk::AccelKey('Z',Gdk::CONTROL_MASK),SLOT_EVENT(EVENT_UNDO)));
+//     editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-redo"),Gtk::AccelKey('R',Gdk::CONTROL_MASK),SLOT_EVENT(EVENT_REDO)));
+//     editmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
+//     editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-cut"),NOT_IMPLEMENTED_SLOT));
+//     editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-copy"),NOT_IMPLEMENTED_SLOT));
+//     editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-paste"),NOT_IMPLEMENTED_SLOT));
+//     editmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
+//     editmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Select All Ducks"),Gtk::AccelKey('E',Gdk::CONTROL_MASK),sigc::mem_fun(*work_area,&studio::WorkArea::select_all_ducks)));
+//     editmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Unselect All Layers"),Gtk::AccelKey('D',Gdk::CONTROL_MASK),sigc::mem_fun(*this,&CanvasView::on_unselect_layers)));
+//     editmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
+//
+//     //editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-stop"),Gtk::AccelKey(GDK_Escape,static_cast<Gdk::ModifierType>(0)),sigc::hide_return(sigc::mem_fun(*this, &studio::CanvasView::stop))));
+//     //editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-refresh"),Gtk::AccelKey('k',Gdk::CONTROL_MASK),sigc::hide_return(sigc::mem_fun(*this, &studio::CanvasView::on_refresh_pressed))));
+//     editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-stop"),Gtk::AccelKey(GDK_Escape,static_cast<Gdk::ModifierType>(0)),SLOT_EVENT(EVENT_STOP)));
+//     editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-refresh"),Gtk::AccelKey('k',Gdk::CONTROL_MASK),SLOT_EVENT(EVENT_REFRESH)));
+//     editmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
+//     editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-properties"),Gtk::AccelKey("F8"),
+//             sigc::mem_fun(canvas_properties,&studio::CanvasProperties::present)
+//     ));
+//
+//     build_new_layer_menu(newlayermenu);
+//     layermenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("New"),newlayermenu));
+//
+//
+//     {
+//             synfigapp::Action::ParamList param_list;
+//             param_list.add("canvas",Canvas::Handle(get_canvas()));
+//             param_list.add("canvas_interface",canvas_interface());
+//             add_actions_to_menu(&canvasmenu, param_list,synfigapp::Action::CATEGORY_CANVAS);
+//     }
+//
+//
+//     //canvasmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Keyframe Dialog"),sigc::mem_fun(keyframe_dialog,&studio::Dialog_Keyframe::present)));
+//
+//     // Duck Mask Menu
+//     if(1)
+//             {
+//             duckmaskmenu.items().push_back(Gtk::Menu_Helpers::TearoffMenuElem());
+//
+//             duckmaskmenu.items().push_back(Gtk::Menu_Helpers::CheckMenuElem(_("Position Ducks"),Gtk::AccelKey('1',Gdk::MOD1_MASK)));
+//             duck_mask_position=static_cast<Gtk::CheckMenuItem*>(&duckmaskmenu.items().back());
+//             duck_mask_position->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_POSITION));
+//             duck_mask_position->signal_toggled().connect(
+//                     sigc::bind(
+//                             sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask),
+//                             Duck::TYPE_POSITION
+//                     )
+//             );
+//
+//             duckmaskmenu.items().push_back(Gtk::Menu_Helpers::CheckMenuElem(_("Vertex Ducks"),Gtk::AccelKey('2',Gdk::MOD1_MASK)));
+//             duck_mask_vertex=static_cast<Gtk::CheckMenuItem*>(&duckmaskmenu.items().back());
+//             duck_mask_vertex->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_VERTEX));
+//             duck_mask_vertex->signal_toggled().connect(
+//                     sigc::bind(
+//                             sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask),
+//                             Duck::TYPE_VERTEX
+//                     )
+//             );
+//
+//             duckmaskmenu.items().push_back(Gtk::Menu_Helpers::CheckMenuElem(_("Tangent Ducks"),Gtk::AccelKey('3',Gdk::MOD1_MASK)));
+//             duck_mask_tangent=static_cast<Gtk::CheckMenuItem*>(&duckmaskmenu.items().back());
+//             duck_mask_tangent->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_TANGENT));
+//             duck_mask_tangent->signal_toggled().connect(
+//                     sigc::bind(
+//                             sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask),
+//                             Duck::TYPE_TANGENT
+//                     )
+//             );
+//
+//             duckmaskmenu.items().push_back(Gtk::Menu_Helpers::CheckMenuElem(_("Radius Ducks"),Gtk::AccelKey('4',Gdk::MOD1_MASK)));
+//             duck_mask_radius=static_cast<Gtk::CheckMenuItem*>(&duckmaskmenu.items().back());
+//             duck_mask_radius->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_RADIUS));
+//             duck_mask_radius->signal_toggled().connect(
+//                     sigc::bind(
+//                             sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask),
+//                             Duck::TYPE_RADIUS
+//                     )
+//             );
+//
+//             duckmaskmenu.items().push_back(Gtk::Menu_Helpers::CheckMenuElem(_("Width Ducks"),Gtk::AccelKey('5',Gdk::MOD1_MASK)));
+//             duck_mask_width=static_cast<Gtk::CheckMenuItem*>(&duckmaskmenu.items().back());
+//             duck_mask_width->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_WIDTH));
+//             duck_mask_width->signal_toggled().connect(
+//                     sigc::bind(
+//                             sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask),
+//                             Duck::TYPE_WIDTH
+//                     )
+//             );
+//
+//             duckmaskmenu.items().push_back(Gtk::Menu_Helpers::CheckMenuElem(_("Angle Ducks"),Gtk::AccelKey('6',Gdk::MOD1_MASK)));
+//             duck_mask_angle=static_cast<Gtk::CheckMenuItem*>(&duckmaskmenu.items().back());
+//             duck_mask_angle->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_ANGLE));
+//             duck_mask_angle->signal_toggled().connect(
+//                     sigc::bind(
+//                             sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask),
+//                             Duck::TYPE_ANGLE
+//                     )
+//             );
+//
+//             viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("_Mask Ducks"),duckmaskmenu));
+//     }
+//
+//     // Preview Quality Menu
+//     if(1)
+//     {
+//             qualitymenu.items().push_back(Gtk::Menu_Helpers::TearoffMenuElem());
+//             int i;
+//             qualitymenu.items().push_back(Gtk::Menu_Helpers::MenuElem(strprintf(_("Use Parametric Renderer"),0),
+//                     sigc::bind(
+//                             sigc::mem_fun(*work_area, &studio::WorkArea::set_quality),
+//                             0
+//                     )
+//             ));
+//             for(i=1;i<=10;i++)
+//             {
+//                     qualitymenu.items().push_back(Gtk::Menu_Helpers::MenuElem(strprintf(_("Set Quality to %d"),i),Gtk::AccelKey('0'+(i%10),Gdk::CONTROL_MASK),
+//                             sigc::bind(
+//                                     sigc::mem_fun(*work_area, &studio::WorkArea::set_quality),
+//                                     i
+//                             )
+//                     ));
+//             }
+//             viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Preview Quality"),qualitymenu));
+//     }
+//
+//     viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::Stock::MEDIA_PLAY,
+//             sigc::mem_fun(*this, &studio::CanvasView::play)));
+//     viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("Flipbook Dialog"),
+//             sigc::mem_fun(*preview_dialog, &studio::Dialog_Preview::present)));
+//
+//     viewmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
+//
+//     viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Toggle Grid Show"),Gtk::AccelKey('g',Gdk::CONTROL_MASK),
+//             sigc::mem_fun(*work_area, &studio::WorkArea::toggle_grid)));
+//     viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Toggle Grid Snap"),Gtk::AccelKey('l',Gdk::CONTROL_MASK),
+//             sigc::mem_fun(*work_area, &studio::WorkArea::toggle_grid_snap)));
+//     viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Toggle Guide Snap"),Gtk::AccelKey('k',Gdk::CONTROL_MASK),
+//             sigc::mem_fun(*work_area, &studio::WorkArea::toggle_guide_snap)));
+//     viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Toggle Low-Res"),Gtk::AccelKey('`',Gdk::CONTROL_MASK),
+//             sigc::mem_fun(*work_area, &studio::WorkArea::toggle_low_resolution_flag)));
+//
+//     viewmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
+//
+//     viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-zoom-in"),Gtk::AccelKey('=',static_cast<Gdk::ModifierType>(0)),
+//             sigc::mem_fun(*work_area, &studio::WorkArea::zoom_in)));
+//     viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-zoom-out"),Gtk::AccelKey('-',static_cast<Gdk::ModifierType>(0)),
+//             sigc::mem_fun(*work_area, &studio::WorkArea::zoom_out)));
+//     viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-zoom-fit"),
+//             sigc::mem_fun(*work_area, &studio::WorkArea::zoom_fit)));
+//     viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-zoom-100"),Gtk::AccelKey('`',static_cast<Gdk::ModifierType>(0)),
+//             sigc::mem_fun(*work_area, &studio::WorkArea::zoom_norm)));
+//     viewmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
+//
+//     viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-zoom-in"),Gtk::AccelKey('+',static_cast<Gdk::ModifierType>(0)),
+//             sigc::mem_fun(*this, &studio::CanvasView::time_zoom_in)));
+//     viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-zoom-out"),Gtk::AccelKey('_',static_cast<Gdk::ModifierType>(0)),
+//             sigc::mem_fun(*this, &studio::CanvasView::time_zoom_out)));
+//
+//     viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Jump to Next Keyframe"),Gtk::AccelKey(']',static_cast<Gdk::ModifierType>(0)),
+//             sigc::mem_fun(*canvas_interface().get(), &synfigapp::CanvasInterface::jump_to_next_keyframe)));
+//     viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Jump to Prev Keyframe"),Gtk::AccelKey('[',static_cast<Gdk::ModifierType>(0)),
+//             sigc::mem_fun(*canvas_interface().get(), &synfigapp::CanvasInterface::jump_to_prev_keyframe)));
+//
+//     mainmenu.items().push_back(Gtk::Menu_Helpers::TearoffMenuElem());
+//     mainmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("_File"),filemenu));
+//     mainmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("_Edit"),editmenu));
+//     mainmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("_View"),viewmenu));
+//     mainmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("_Canvas"),canvasmenu));
+//     mainmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("_Layer"),layermenu));
+//
+//     mainmenu.accelerate(*this);
+//
+///*
+//     {
+//
+//             trackmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("New Waypoint"),NOT_IMPLEMENTED_SLOT));
+//             trackmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Delete Waypoint"),NOT_IMPLEMENTED_SLOT));
+//             trackmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Export"),NOT_IMPLEMENTED_SLOT));
+//             trackmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem());
+//             trackmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Properties"),NOT_IMPLEMENTED_SLOT));
+//     }
+//*/
+//     mainmenu.show();
+//     filemenu.show();
+//     editmenu.show();
+//     canvasmenu.show();
+//     layermenu.show();
+//
+//     keyframemenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-properties"),
+//             sigc::mem_fun(*this,&studio::CanvasView::show_keyframe_dialog)
+//     ));
+//
+//
+//     get_accel_group()->unlock();
+//
+//     //Set the accelerator paths for all the menus
+//     filemenu.set_accel_path("<synfig>/File");
+//     editmenu.set_accel_path("<synfig>/Edit");
+//     layermenu.set_accel_path("<synfig>/Layer");
+//     //mainmenu.set_accel_path("<synfig-main>");
+//     canvasmenu.set_accel_path("<synfig>/Canvas");
+//     viewmenu.set_accel_path("<synfig>/View");
+//     duckmaskmenu.set_accel_path("<synfig>/DuckMask");
 #endif
 }