From 6a83281e2a2bcd96814635fa11971e82f14ae0d4 Mon Sep 17 00:00:00 2001 From: roemhildtg Date: Mon, 25 Apr 2016 08:46:27 -0500 Subject: [PATCH] Switch style setter to use dojo/dom-style --- viewer/js/gis/dijit/Directions.js | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/viewer/js/gis/dijit/Directions.js b/viewer/js/gis/dijit/Directions.js index 9ae0f36fe..88fcbac5d 100644 --- a/viewer/js/gis/dijit/Directions.js +++ b/viewer/js/gis/dijit/Directions.js @@ -12,8 +12,9 @@ define([ 'esri/geometry/Point', 'esri/SpatialReference', 'dojo/topic', - 'dojo/i18n!./Directions/nls/resource' -], function (declare, _WidgetBase, _TemplatedMixin, Directions, template, lang, Menu, MenuItem, PopupMenuItem, MenuSeparator, Point, SpatialReference, topic, i18n) { + 'dojo/i18n!./Directions/nls/resource', + 'dojo/dom-style' +], function (declare, _WidgetBase, _TemplatedMixin, Directions, template, lang, Menu, MenuItem, PopupMenuItem, MenuSeparator, Point, SpatialReference, topic, i18n, domStyle) { return declare([_WidgetBase, _TemplatedMixin], { templateString: template, @@ -27,12 +28,14 @@ define([ //temp fix for 3.12 and 3.13 map click button. if (this.directions._activateButton) { - this.directions._activateButton.style.display = 'none'; + domStyle.set(this.directions._activateButton, 'display', 'none'); } else if (this.directions._activateButtonNode) { - this.directions._activateButtonNode.style.display = 'none'; - this.directions._addDestinationNode.style['float'] = 'inherit'; - this.directions._optionsButtonNode.style['float'] = 'inherit'; - this.directions._optionsButtonNode.style.marginRight = '5px'; + domStyle.set(this.directions._activateButtonNode, 'display', 'none'); + domStyle.set(this.directions._addDestinationNode, 'float', 'inherit'); + domStyle.set(this.directions._optionsButtonNode, { + 'float': 'inherit', + marginRight: '5px' + }); } if (this.mapRightClickMenu) {