Skip to content

Commit

Permalink
Fix #2696 map rotation style for openlayers (#2820)
Browse files Browse the repository at this point in the history
* fix #2696 aligned style of map rotation tool for ol

* disable map rotation on openlayers
  • Loading branch information
MV88 authored and offtherailz committed Apr 20, 2018
1 parent 3ee6dbb commit a3d3cb0
Show file tree
Hide file tree
Showing 2 changed files with 41 additions and 1 deletion.
18 changes: 17 additions & 1 deletion web/client/localConfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,14 @@
"mobile": [{
"name": "Map",
"cfg": {
"mapOptions": {
"openlayers": {
"interactions": {
"pinchRotate": false,
"altShiftDragRotate": false
}
}
},
"tools": ["locate"]
}
}, "Version", "DrawerMenu",
Expand Down Expand Up @@ -195,6 +203,10 @@
"cfg": {
"mapOptions": {
"openlayers": {
"interactions": {
"pinchRotate": false,
"altShiftDragRotate": false
},
"attribution": {
"container": "#mapstore-map-footer-container"
}
Expand Down Expand Up @@ -349,8 +361,12 @@
"name": "Map",
"cfg": {
"tools": ["locate"],
"mapOptions": {
"mapOptions": {
"openlayers": {
"interactions": {
"pinchRotate": false,
"altShiftDragRotate": false
},
"attribution": {
"container": "#mapstore-map-footer-container"
}
Expand Down
24 changes: 24 additions & 0 deletions web/client/themes/default/less/ol.less
Original file line number Diff line number Diff line change
Expand Up @@ -115,3 +115,27 @@ div.ol-scale-line-inner {
border-top-color: #ffcc33;
}
}

.ol-rotate {
width: @square-btn-size;
height: @square-btn-size;
background: none;
margin-right: 7px;
.ol-rotate-reset {
box-shadow: -1px 1px 5px 1px #5e5e5e;
height: @square-btn-size;
width: @square-btn-size;
color: @ms2-color-text-primary;
background-color: @ms2-color-primary;
border-color: @btn-primary-border;
.ol-compass {
font-size: 36px;
}
}
.ol-rotate-reset:hover, .ol-rotate-reset:focus {
background-color: darken(@ms2-color-primary, 5%);
}
}
.ol-rotate:hover {
background: none;
}

0 comments on commit a3d3cb0

Please sign in to comment.