Last active
January 2, 2016 00:38
-
-
Save unjust/8224428 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
MM.NavBarView = Meetup.Meetbone.View.subclass({ | |
init: function() { | |
var self = this; | |
MM.$Events.on("shown.modalView", function(e, view) { | |
if (view.navbar) { | |
//TODO:navbar should we clean up navbar_config | |
//// not sure why this is nested | |
var newModel = view.navbar["navbar_config"]; | |
// set a title with view's fallback | |
if (!newModel.title && view.title) { | |
newModel.title = view.title; | |
} | |
newModel.isModal = true; | |
self.model.set(newModel); | |
} | |
}); | |
this.model.on("set.model", this.render, this); | |
}, | |
model: new Meetup.Meetbone.Model({}), | |
template: Meetup.MustacheTemplates.mobile.navBarDetail | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment