diff options
author | David Robillard <d@drobilla.net> | 2015-08-29 04:00:54 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2015-08-29 04:00:54 +0000 |
commit | 67dea1f9cf0dbce6be323949557eab3254dc3592 (patch) | |
tree | aade64be34c81221c87fb6c46f3945d7d9262001 | |
parent | 177056dd73054d020ba4e6dae393850d779ac7e5 (diff) | |
download | ingen-67dea1f9cf0dbce6be323949557eab3254dc3592.tar.gz ingen-67dea1f9cf0dbce6be323949557eab3254dc3592.tar.bz2 ingen-67dea1f9cf0dbce6be323949557eab3254dc3592.zip |
Avoid map::emplace to accomodate old GCC.
git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@5714 a436a847-0d15-0410-975c-d299462d15a1
-rw-r--r-- | src/gui/NodeMenu.cpp | 14 | ||||
-rw-r--r-- | src/server/EventWriter.cpp | 9 | ||||
-rw-r--r-- | src/server/LV2Plugin.cpp | 5 | ||||
-rw-r--r-- | src/server/events/Get.cpp | 8 |
4 files changed, 18 insertions, 18 deletions
diff --git a/src/gui/NodeMenu.cpp b/src/gui/NodeMenu.cpp index 0acce065..7d1d3274 100644 --- a/src/gui/NodeMenu.cpp +++ b/src/gui/NodeMenu.cpp @@ -218,13 +218,13 @@ NodeMenu::on_save_preset_activated() const std::string real_path = Glib::build_filename(dirname, bundle, file); const std::string real_uri = Glib::filename_to_uri(real_path); - Resource::Properties props; - props.emplace(_app->uris().rdf_type, - _app->uris().pset_Preset); - props.emplace(_app->uris().rdfs_label, - _app->forge().alloc(basename)); - props.emplace(_app->uris().lv2_prototype, - _app->forge().alloc_uri(block()->uri())); + Resource::Properties props{ + { _app->uris().rdf_type, + _app->uris().pset_Preset }, + { _app->uris().rdfs_label, + _app->forge().alloc(basename) }, + { _app->uris().lv2_prototype, + _app->forge().alloc_uri(block()->uri()) }}; _app->interface()->put(Raul::URI(real_uri), props); } } diff --git a/src/server/EventWriter.cpp b/src/server/EventWriter.cpp index 6c04c73d..1f225d6e 100644 --- a/src/server/EventWriter.cpp +++ b/src/server/EventWriter.cpp @@ -126,12 +126,11 @@ EventWriter::set_property(const Raul::URI& uri, const Raul::URI& predicate, const Atom& value) { - Resource::Properties remove; - remove.emplace(predicate, - _engine.world()->uris().patch_wildcard.urid); + Resource::Properties remove{ + { predicate, _engine.world()->uris().patch_wildcard.urid }}; + + Resource::Properties add{{ predicate, value }}; - Resource::Properties add; - add.emplace(predicate, value); _engine.enqueue_event( new Events::Delta(_engine, _respondee, _request_id, now(), Events::Delta::Type::SET, Resource::Graph::DEFAULT, diff --git a/src/server/LV2Plugin.cpp b/src/server/LV2Plugin.cpp index b1f7de73..5e0dc609 100644 --- a/src/server/LV2Plugin.cpp +++ b/src/server/LV2Plugin.cpp @@ -114,8 +114,9 @@ LV2Plugin::load_presets() if (labels) { const LilvNode* label = lilv_nodes_get_first(labels); - _presets.emplace(Raul::URI(lilv_node_as_uri(preset)), - lilv_node_as_string(label)); + _presets.insert( + std::make_pair(Raul::URI(lilv_node_as_uri(preset)), + lilv_node_as_string(label))); lilv_nodes_free(labels); } else { diff --git a/src/server/events/Get.cpp b/src/server/events/Get.cpp index 185f275a..6d49657d 100644 --- a/src/server/events/Get.cpp +++ b/src/server/events/Get.cpp @@ -118,10 +118,10 @@ Get::Response::put_preset(const URIs& uris, const Raul::URI& preset, const std::string& label) { - Resource::Properties props; - props.emplace(uris.rdf_type, uris.pset_Preset.urid); - props.emplace(uris.rdfs_label, uris.forge.alloc(label)); - props.emplace(uris.lv2_appliesTo, uris.forge.make_urid(plugin)); + Resource::Properties props{ + { uris.rdf_type, uris.pset_Preset.urid }, + { uris.rdfs_label, uris.forge.alloc(label) }, + { uris.lv2_appliesTo, uris.forge.make_urid(plugin) }}; put(preset, props); } |