summaryrefslogtreecommitdiffstats
path: root/src/gui
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2012-08-12 16:29:52 +0000
committerDavid Robillard <d@drobilla.net>2012-08-12 16:29:52 +0000
commite63caf72f320ab683de6378ff6f2944890054cbf (patch)
tree047727bf3fa5b5de5d9f32c9ea65169924ab64ce /src/gui
parent21b1e2e485d9fa954ca742965d000f3273fcb862 (diff)
downloadingen-e63caf72f320ab683de6378ff6f2944890054cbf.tar.gz
ingen-e63caf72f320ab683de6378ff6f2944890054cbf.tar.bz2
ingen-e63caf72f320ab683de6378ff6f2944890054cbf.zip
Remove redundant Path::is_valid_name and Path::nameify.
git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@4671 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/LoadPluginWindow.cpp4
-rw-r--r--src/gui/NewSubpatchWindow.cpp4
2 files changed, 4 insertions, 4 deletions
diff --git a/src/gui/LoadPluginWindow.cpp b/src/gui/LoadPluginWindow.cpp
index cac404df..5042423d 100644
--- a/src/gui/LoadPluginWindow.cpp
+++ b/src/gui/LoadPluginWindow.cpp
@@ -133,7 +133,7 @@ LoadPluginWindow::name_changed()
// Toggle add button sensitivity according name legality
if (_selection->get_selected_rows().size() == 1) {
string name = _node_name_entry->get_text();
- if (!Path::is_valid_name(name)) {
+ if (!Symbol::is_valid(name)) {
_add_button->property_sensitive() = false;
} else if (_app->store()->find_child(_patch, name)) {
_add_button->property_sensitive() = false;
@@ -344,7 +344,7 @@ LoadPluginWindow::load_plugin(const Gtk::TreeModel::iterator& iter)
dialog.run();
} else {
- Path path = _patch->path().base() + Path::nameify(name);
+ Path path = _patch->path().child(Symbol::symbolify(name));
Resource::Properties props = _initial_data;
props.insert(make_pair(uris.rdf_type,
uris.ingen_Node));
diff --git a/src/gui/NewSubpatchWindow.cpp b/src/gui/NewSubpatchWindow.cpp
index e03f7d9b..7f3eab46 100644
--- a/src/gui/NewSubpatchWindow.cpp
+++ b/src/gui/NewSubpatchWindow.cpp
@@ -75,7 +75,7 @@ void
NewSubpatchWindow::name_changed()
{
string name = _name_entry->get_text();
- if (!Path::is_valid_name(name)) {
+ if (!Symbol::is_valid(name)) {
_message_label->set_text("Name contains invalid characters.");
_ok_button->property_sensitive() = false;
} else if (_app->store()->find(_patch->path().base() + name)
@@ -94,7 +94,7 @@ NewSubpatchWindow::name_changed()
void
NewSubpatchWindow::ok_clicked()
{
- const Path path = _patch->path().base() + Path::nameify(_name_entry->get_text());
+ const Path path = _patch->path().child(Symbol::symbolify(_name_entry->get_text()));
const uint32_t poly = _poly_spinbutton->get_value_as_int();
// Create patch