mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-11-05 13:26:48 +08:00
chore: cleanup
This commit is contained in:
@@ -46,7 +46,7 @@ import { profile } from '../../../profiling';
|
||||
import { topmost } from '../../frame/frame-stack';
|
||||
import { screen } from '../../../platform';
|
||||
import { AndroidActivityBackPressedEventData, android as androidApp } from '../../../application';
|
||||
import { device } from '../../../platform';
|
||||
import { Device } from '../../../platform';
|
||||
import lazy from '../../../utils/lazy';
|
||||
|
||||
export * from './view-common';
|
||||
@@ -59,7 +59,7 @@ const statePressed = 16842919; // android.R.attr.state_pressed
|
||||
const stateEnabled = 16842910; // android.R.attr.state_enabled
|
||||
const styleAnimationDialog = 16973826; // android.R.style.Animation_Dialog
|
||||
|
||||
const sdkVersion = lazy(() => parseInt(device.sdkVersion));
|
||||
const sdkVersion = lazy(() => parseInt(Device.sdkVersion));
|
||||
|
||||
const modalMap = new Map<number, DialogOptions>();
|
||||
|
||||
@@ -389,7 +389,7 @@ export class View extends ViewCommon {
|
||||
return manager;
|
||||
}
|
||||
|
||||
@profile()
|
||||
@profile
|
||||
public onLoaded() {
|
||||
this._manager = null;
|
||||
this._rootManager = null;
|
||||
@@ -397,7 +397,7 @@ export class View extends ViewCommon {
|
||||
this.setOnTouchListener();
|
||||
}
|
||||
|
||||
@profile()
|
||||
@profile
|
||||
public onUnloaded() {
|
||||
if (this.touchListenerIsSet) {
|
||||
this.touchListenerIsSet = false;
|
||||
@@ -516,7 +516,7 @@ export class View extends ViewCommon {
|
||||
}
|
||||
}
|
||||
|
||||
@profile()
|
||||
@profile
|
||||
public requestLayout(): void {
|
||||
super.requestLayout();
|
||||
if (this.nativeViewProtected) {
|
||||
|
||||
@@ -80,7 +80,7 @@ export class View extends ViewCommon implements ViewDefinition {
|
||||
}
|
||||
}
|
||||
|
||||
@profile()
|
||||
@profile
|
||||
public layout(left: number, top: number, right: number, bottom: number, setFrame = true): void {
|
||||
const { boundsChanged, sizeChanged } = this._setCurrentLayoutBounds(left, top, right, bottom);
|
||||
if (setFrame) {
|
||||
@@ -118,7 +118,7 @@ export class View extends ViewCommon implements ViewDefinition {
|
||||
this._privateFlags |= PFLAG_MEASURED_DIMENSION_SET;
|
||||
}
|
||||
|
||||
@profile()
|
||||
@profile
|
||||
public onMeasure(widthMeasureSpec: number, heightMeasureSpec: number): void {
|
||||
const view = this.nativeViewProtected;
|
||||
const width = layout.getMeasureSpecSize(widthMeasureSpec);
|
||||
|
||||
Reference in New Issue
Block a user