Skip to content
Snippets Groups Projects
Commit 95d5f014 authored by Brandon Bergren's avatar Brandon Bergren
Browse files

Forward port missing changes from 1.1.2.39 (7/24/2008 11:13 PM):

Make getMap a bit more user friendly by allowing passing widget ids.
parent c467df33
No related branches found
No related tags found
No related merge requests found
...@@ -24,7 +24,17 @@ ...@@ -24,7 +24,17 @@
* Be a good GMap citizen! Remember to send change()s after modifying variables! * Be a good GMap citizen! Remember to send change()s after modifying variables!
*/ */
getMap: function (mapid) { getMap: function (mapid) {
return maps[mapid]; if (maps[mapid]) {
return maps[mapid];
}
else {
// Perhaps the user passed a widget id instead?
mapid = mapid.split('-').slice(1, -1).join('-');
if (maps[mapid]) {
return maps[mapid];
}
}
return false;
}, },
unloadMap: function (mapid) { unloadMap: function (mapid) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment