Skip to content

Commit

Permalink
Update map contrast color when changing basemaps.
Browse files Browse the repository at this point in the history
  • Loading branch information
kring committed Jun 1, 2016
1 parent 10810ca commit 54148bb
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions lib/ReactViews/Map/Panels/SettingPanel.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,11 @@ const SettingPanel = React.createClass({
selectBaseMap(baseMap, event) {
event.stopPropagation();
this.props.terria.baseMap = baseMap.catalogItem;
this.props.terria.baseMapContrastColor = baseMap.contrastColor;

// We store the user's chosen basemap for future use, but it's up to the instance to decide
// whether to use that at start up.
this.props.terria.setLocalProperty('basemap', baseMap.catalogItem.name);
},

mouseEnterBaseMap(baseMap) {
Expand Down

0 comments on commit 54148bb

Please sign in to comment.