Skip to content

Commit

Permalink
Update scope on map resize event. Trigger resize on gmMap initializat…
Browse files Browse the repository at this point in the history
…ion.
  • Loading branch information
dylanfprice committed Jul 20, 2013
1 parent a715cd1 commit b3a742e
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/directives/gmMap.js
Expand Up @@ -121,6 +121,7 @@
controller.addMapListener('zoom_changed', updateScope);
controller.addMapListener('center_changed', updateScope);
controller.addMapListener('bounds_changed', updateScope);
controller.addMapListener('resize', updateScope);

if (hasCenter) {
scope.$watch('gmCenter', function (newValue, oldValue) {
Expand Down Expand Up @@ -158,6 +159,8 @@
controller.mapTrigger('resize');
}
});

controller.mapTrigger('resize');
}


Expand Down

0 comments on commit b3a742e

Please sign in to comment.