diff options
| author | John Smith <john.smith7545@yahoo.com> | 2012-09-02 04:24:45 +0000 |
|---|---|---|
| committer | John Smith <john.smith7545@yahoo.com> | 2012-09-02 04:24:45 +0000 |
| commit | b3f55760cbb99bd4cc96d86eae8068e724d0abe9 (patch) | |
| tree | 6dbb9d360e31f5c7cc50f651d69927d549962ba8 /src/interface.cpp | |
| parent | Fix for 747998 : Align unit menu in Rows Columns dialog (diff) | |
| download | inkscape-b3f55760cbb99bd4cc96d86eae8068e724d0abe9.tar.gz inkscape-b3f55760cbb99bd4cc96d86eae8068e724d0abe9.zip | |
Fix for 273539 : Add Group action to the context menu
(bzr r11640)
Diffstat (limited to '')
| -rw-r--r-- | src/interface.cpp | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/interface.cpp b/src/interface.cpp index 71be84f59..b10ba3077 100644 --- a/src/interface.cpp +++ b/src/interface.cpp @@ -1887,6 +1887,17 @@ void ContextMenu::MakeItemMenu (void) } mi->show(); append(*mi); + + /* Group */ + mi = manage(new Gtk::MenuItem(_("_Group"),1)); + mi->signal_activate().connect(sigc::mem_fun(*this, &ContextMenu::ActivateGroup)); + if (_desktop->selection->isEmpty() || _desktop->selection->single()) { + mi->set_sensitive(FALSE); + } else { + mi->set_sensitive(TRUE); + } + mi->show(); + append(*mi); } void ContextMenu::SelectSameFillStroke(void) @@ -1979,6 +1990,11 @@ void ContextMenu::MakeGroupMenu(void) append(*mi); } +void ContextMenu::ActivateGroup(void) +{ + sp_selection_group(_desktop); +} + void ContextMenu::ActivateUngroup(void) { GSList *children = NULL; |
