File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -203,7 +203,7 @@ export abstract class ViewCommon extends ViewBase implements ViewDefinition {
203203 return false ;
204204 }
205205
206- public _onBackPressed ( ) : boolean {
206+ public onBackPressed ( ) : boolean {
207207 return false ;
208208 }
209209
Original file line number Diff line number Diff line change @@ -115,7 +115,7 @@ function initializeDialogFragment() {
115115 } ;
116116 view . notify ( args ) ;
117117
118- if ( ! args . cancel && ! view . _onBackPressed ( ) ) {
118+ if ( ! args . cancel && ! view . onBackPressed ( ) ) {
119119 super . onBackPressed ( ) ;
120120 }
121121 }
Original file line number Diff line number Diff line change @@ -678,10 +678,11 @@ export abstract class View extends ViewBase {
678678 * @private
679679 */
680680 _onLivesync ( ) : boolean ;
681+
681682 /**
682- * @private
683+ * Derived classes can override this method to handle Android back button press.
683684 */
684- _onBackPressed ( ) : boolean ;
685+ onBackPressed ( ) : boolean ;
685686 /**
686687 * @private
687688 */
Original file line number Diff line number Diff line change @@ -249,7 +249,7 @@ export class Frame extends FrameBase {
249249 }
250250 }
251251
252- public _onBackPressed ( ) : boolean {
252+ public onBackPressed ( ) : boolean {
253253 if ( this . canGoBack ( ) ) {
254254 this . goBack ( ) ;
255255 return true ;
@@ -884,7 +884,7 @@ class ActivityCallbacksImplementation implements AndroidActivityCallbacks {
884884 } ;
885885 view . notify ( viewArgs ) ;
886886
887- if ( ! viewArgs . cancel && ! view . _onBackPressed ( ) ) {
887+ if ( ! viewArgs . cancel && ! view . onBackPressed ( ) ) {
888888 callSuper = true ;
889889 }
890890 }
Original file line number Diff line number Diff line change @@ -510,10 +510,10 @@ export class TabView extends TabViewBase {
510510 super . disposeNativeView ( ) ;
511511 }
512512
513- public _onBackPressed ( ) : boolean {
513+ public onBackPressed ( ) : boolean {
514514 const currentView = this . _selectedView ;
515515 if ( currentView ) {
516- return currentView . _onBackPressed ( ) ;
516+ return currentView . onBackPressed ( ) ;
517517 }
518518
519519 return false ;
You can’t perform that action at this time.
0 commit comments