Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Use route props first when determining route title
When invoking Actions.refresh({title: 'Changed'}), the call to
super.render() in ExNavigationBar calls back into getTitle() on
ExRouteAdapter to determine the title to display in the navigation bar
This patch first checks the provided props before falling back to the
previous behavior.
  • Loading branch information
Joe O'Pecko committed Mar 5, 2016
commit a790262d55ac9cc060ed5c07faa5fa5e75636786
5 changes: 3 additions & 2 deletions ExRouter.js
Original file line number Diff line number Diff line change
Expand Up @@ -82,8 +82,9 @@ export class ExRouteAdapter {
}

getTitle() {
debug("TITLE ="+this.route.title+" for route="+this.route.name);
return this.title || "";
const title = this.route.props.title || this.title || "";
debug("TITLE ="+title+" for route="+this.route.name);
return title;
}

getBackButtonTitle(navigator, index, state){
Expand Down