JGirault has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/311145

Change subject: Double click on map opens full screen at same position
......................................................................

Double click on map opens full screen at same position

Bug: T145877
Change-Id: I3df519be1bfb9aa802b399037ab6479271f77a45
---
M modules/box/Map.js
M modules/mapframe/mapframe.js
2 files changed, 3 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Kartographer 
refs/changes/45/311145/1

diff --git a/modules/box/Map.js b/modules/box/Map.js
index 50ec8a8..587b5b6 100644
--- a/modules/box/Map.js
+++ b/modules/box/Map.js
@@ -545,7 +545,7 @@
                        this.doWhenReady( function () {
 
                                var map = this.options.link ? this : 
this.fullScreenMap;
-                               position = position || this._initialPosition;
+                               position = position || this.getMapPosition();
 
                                if ( map && map._updatingHash ) {
                                        // Skip - there is nothing to do.
diff --git a/modules/mapframe/mapframe.js b/modules/mapframe/mapframe.js
index 37e502e..3aa3b95 100644
--- a/modules/mapframe/mapframe.js
+++ b/modules/mapframe/mapframe.js
@@ -133,6 +133,8 @@
                                                center: [ +latitude, +longitude 
],
                                                zoom: +zoom
                                        };
+                               } else {
+                                       position = map.getInitialMapPosition();
                                }
 
                                map.openFullScreen( position );

-- 
To view, visit https://gerrit.wikimedia.org/r/311145
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I3df519be1bfb9aa802b399037ab6479271f77a45
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Kartographer
Gerrit-Branch: master
Gerrit-Owner: JGirault <julien.inbox.w...@gmail.com>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to