summaryrefslogtreecommitdiffstats
path: root/src/progs/ingenuity/PatchPortModule.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/progs/ingenuity/PatchPortModule.cpp')
-rw-r--r--src/progs/ingenuity/PatchPortModule.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/progs/ingenuity/PatchPortModule.cpp b/src/progs/ingenuity/PatchPortModule.cpp
index 369a04b1..8843882b 100644
--- a/src/progs/ingenuity/PatchPortModule.cpp
+++ b/src/progs/ingenuity/PatchPortModule.cpp
@@ -51,8 +51,8 @@ PatchPortModule::PatchPortModule(PatchCanvas* canvas, CountedPtr<PortModel> port
resize();
- const Atom& x_atom = port->get_metadata("module-x");
- const Atom& y_atom = port->get_metadata("module-y");
+ const Atom& x_atom = port->get_metadata("ingenuity:canvas-x");
+ const Atom& y_atom = port->get_metadata("ingenuity:canvas-y");
if (x_atom && y_atom && x_atom.type() == Atom::FLOAT && y_atom.type() == Atom::FLOAT) {
move_to(x_atom.get_float(), y_atom.get_float());
@@ -73,13 +73,13 @@ PatchPortModule::store_location()
const float x = static_cast<float>(property_x());
const float y = static_cast<float>(property_y());
- const Atom& existing_x = m_port->get_metadata("module-x");
- const Atom& existing_y = m_port->get_metadata("module-y");
+ const Atom& existing_x = m_port->get_metadata("ingenuity:canvas-x");
+ const Atom& existing_y = m_port->get_metadata("ingenuity:canvas-y");
if (existing_x.type() != Atom::FLOAT || existing_y.type() != Atom::FLOAT
|| existing_x.get_float() != x || existing_y.get_float() != y) {
- App::instance().engine()->set_metadata(m_port->path(), "module-x", Atom(x));
- App::instance().engine()->set_metadata(m_port->path(), "module-y", Atom(y));
+ App::instance().engine()->set_metadata(m_port->path(), "ingenuity:canvas-x", Atom(x));
+ App::instance().engine()->set_metadata(m_port->path(), "ingenuity:canvas-y", Atom(y));
}
}
@@ -87,9 +87,9 @@ PatchPortModule::store_location()
void
PatchPortModule::metadata_update(const string& key, const Atom& value)
{
- if (key == "module-x" && value.type() == Atom::FLOAT)
+ if (key == "ingenuity:canvas-x" && value.type() == Atom::FLOAT)
move_to(value.get_float(), property_y());
- else if (key == "module-y" && value.type() == Atom::FLOAT)
+ else if (key == "ingenuity:canvas-y" && value.type() == Atom::FLOAT)
move_to(property_x(), value.get_float());
}