diff --git a/js/MapProperties.js b/js/MapProperties.js
index 8e656d61..a7832aab 100644
--- a/js/MapProperties.js
+++ b/js/MapProperties.js
@@ -7,6 +7,7 @@ class MapProperties {
this.mapModes = ["Linear", "Expression"];
this.mapProtocols = ["UDP", "TCP"];
this.boundaryIcons = ["none", "right", "left", "mute", "clamp", "wrap"];
+ this.cachedProperty = { "key": null, "value": null };
$(this.container).append(
"
"+
"");
- // init the view
- $('#container').empty();
- tooltip = new Tooltip();
- viewManager = new ViewManager(document.getElementById('container'), database,
- tooltip);
-
// init the top menu
$('#TopMenuWrapper').empty()
saverLoader = new SaverLoader(document.getElementById("TopMenuWrapper"),
@@ -83,6 +77,12 @@ function init() {
netSelector = new NetworkSelector(document.getElementById("TopMenuWrapper"),
database, viewManager);
+ // init the view
+ $('#container').empty();
+ tooltip = new Tooltip();
+ viewManager = new ViewManager(document.getElementById('container'), database,
+ tooltip);
+
// init controller
initMonitorCommands();
initViewCommands();
@@ -259,7 +259,7 @@ function initViewCommands()
// allows anyone to call updateMapProperties by triggering an event on #container
function initMapPropertiesCommands() {
- // asks the view for the selected maps and updates the edit bar
+ // asks the database for the selected maps and updates the edit bar
$("#container").on("updateMapProperties", function(e) {
mapProperties.updateMapProperties();
});
@@ -268,6 +268,11 @@ function initMapPropertiesCommands() {
$("#container").on("updateMapPropertiesFor", function(e, key) {
mapProperties.updateMapPropertiesFor(key);
});
+
+ // send out any partially-edited properties when maps are deselected
+ $("#container").on("sendCachedProperty", function(e) {
+ mapProperties.sendCachedProperty();
+ });
}
function select_obj(obj) {