Make the new bindingContext parameter optional.

This commit is contained in:
Rossen Hristov
2016-07-19 13:22:52 +03:00
parent 39050861f3
commit ffec9c3ad6
2 changed files with 3 additions and 3 deletions

View File

@ -200,7 +200,7 @@ export class Page extends ContentView implements dts.Page {
}; };
} }
public onNavigatingTo(context: any, isBackNavigation: boolean, bindingContext: any) { public onNavigatingTo(context: any, isBackNavigation: boolean, bindingContext?: any) {
this._navigationContext = context; this._navigationContext = context;
//https://github.com/NativeScript/NativeScript/issues/731 //https://github.com/NativeScript/NativeScript/issues/731

View File

@ -227,9 +227,9 @@ declare module "ui/page" {
* A method called before navigating to the page. * A method called before navigating to the page.
* @param context - The data passed to the page through the NavigationEntry.context property. * @param context - The data passed to the page through the NavigationEntry.context property.
* @param isBackNavigation - True if the Page is being navigated from using the Frame.goBack() method, false otherwise. * @param isBackNavigation - True if the Page is being navigated from using the Frame.goBack() method, false otherwise.
* @param bindingContext - An object to become the binding context of the page navigating to. * @param bindingContext - An object to become the binding context of the page navigating to. Optional.
*/ */
onNavigatingTo(context: any, isBackNavigation: boolean, bindingContext: any): void; onNavigatingTo(context: any, isBackNavigation: boolean, bindingContext?: any): void;
/** /**
* A method called after navigated to the page. * A method called after navigated to the page.