fix(ionNavButtons): multiple ionNavButtons elements align correctly

Fixes #930

Uses a `<span>` now for each set buttons in the navbar, instead of a
`<div>`.  This means that the buttons will align correctly instead of
creating new lines for each set of buttons.
This commit is contained in:
Andy Joslin
2014-03-31 06:29:10 -06:00
parent f039fc26a1
commit 58de267171

View File

@@ -450,11 +450,11 @@ function($ionicViewService, $rootScope, $animate, $compile) {
navBarCtrl.rightButtonsElement :
navBarCtrl.leftButtonsElement;
//Put all of our inside buttons into their own div,
//Put all of our inside buttons into their own span,
//so we can remove them all when this element dies -
//even if the buttons have changed through an ng-repeat or the like,
//we just remove their div parent and they are gone.
var buttons = angular.element('<div>').append(content);
var buttons = angular.element('<span>').append(content);
//Compile buttons inside content so they have access to everything
//something inside content does (eg parent ionicScroll)