Skip to content

Commit

Permalink
fix(ios): page isRunningLayout (#10078)
Browse files Browse the repository at this point in the history
  • Loading branch information
edusperoni authored and NathanWalker committed Nov 9, 2022
1 parent 0552a3a commit 6f1a5d1
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions packages/core/ui/page/index.ios.ts
Expand Up @@ -74,9 +74,10 @@ class UIViewControllerImpl extends UIViewController {

public isBackstackSkipped: boolean;
public isBackstackCleared: boolean;
private _isRunningLayout = 0;
// this is initialized in initWithOwner since the constructor doesn't run on native classes
private _isRunningLayout: number;
private get isRunningLayout() {
return this._isRunningLayout === 0;
return this._isRunningLayout !== 0;
}
private startRunningLayout() {
this._isRunningLayout++;
Expand All @@ -96,6 +97,7 @@ class UIViewControllerImpl extends UIViewController {
public static initWithOwner(owner: WeakRef<Page>): UIViewControllerImpl {
const controller = <UIViewControllerImpl>UIViewControllerImpl.new();
controller._owner = owner;
controller._isRunningLayout = 0;

return controller;
}
Expand Down

0 comments on commit 6f1a5d1

Please sign in to comment.