summaryrefslogtreecommitdiffstats
path: root/src/libs/gui
diff options
context:
space:
mode:
Diffstat (limited to 'src/libs/gui')
-rw-r--r--src/libs/gui/LoadPluginWindow.cpp13
1 files changed, 9 insertions, 4 deletions
diff --git a/src/libs/gui/LoadPluginWindow.cpp b/src/libs/gui/LoadPluginWindow.cpp
index fddb1396..f0754cb9 100644
--- a/src/libs/gui/LoadPluginWindow.cpp
+++ b/src/libs/gui/LoadPluginWindow.cpp
@@ -278,10 +278,15 @@ void
LoadPluginWindow::plugin_selection_changed()
{
Gtk::TreeModel::iterator iter = _selection->get_selected();
- Gtk::TreeModel::Row row = *iter;
- boost::shared_ptr<PluginModel> p = row.get_value(_plugins_columns._col_plugin_model);
- _plugin_name_offset = _patch->child_name_offset(p->default_node_name());
- _node_name_entry->set_text(generate_module_name(_plugin_name_offset));
+ if (iter) {
+ Gtk::TreeModel::Row row = *iter;
+ boost::shared_ptr<PluginModel> p = row.get_value(_plugins_columns._col_plugin_model);
+ _plugin_name_offset = _patch->child_name_offset(p->default_node_name());
+ _node_name_entry->set_text(generate_module_name(_plugin_name_offset));
+ } else {
+ _plugin_name_offset = 0;
+ _node_name_entry->set_text("");
+ }
}