More header bar hacking stuff

This commit is contained in:
Max Lynch
2013-09-26 22:46:01 -05:00
parent 64a5e2b435
commit fb18b29aa2
4 changed files with 45 additions and 38 deletions

View File

@ -8,13 +8,21 @@ ionic.views.HeaderBar = function(opts) {
ionic.views.NavBar.prototype = {
resizeTitle: function() {
var e,
children = this.el.children,
index = Array.prototype.indexOf.call(children, this.el);
var e;
var j;
var children = this.el.children;
for(var i = 0; i < index; i++) {
var title;
var titleWidth;
for(var i = 0; j = children.length; i < j; i++) {
e = children[i];
if(/h\d/.test(e.nodeName.toLowerCase())) {
title = e;
}
}
titleWidth = title.offsetWidth;
}
};
})(window.ionic);