修改 device type

Signed-off-by: zhouhongli2023 <zhouhongli5@huawei.com>
This commit is contained in:
zhouhongli2023 2024-07-10 17:12:02 +08:00
parent da46bdbace
commit ffddd7a4c7

View File

@ -18,7 +18,6 @@ import HiLog from './HiLog';
const TAG = 'DeviceUtil';
export default class DeviceUtil {
private static readonly DEVICE_TYPE = deviceInfo.deviceType;
constructor() {
}
@ -32,13 +31,9 @@ export default class DeviceUtil {
* liteWearableLightweight intelligent wearable
* smartVisionSmart Vision Devices
*/
static getDeviceType(): string {
HiLog.i(TAG, 'deviceType is ' + this.DEVICE_TYPE)
return this.DEVICE_TYPE;
}
static isTablet(): boolean{
let deviceType = DeviceUtil.getDeviceType()
return deviceType === 'tablet';
let curBp = AppStorage.get('curBp');
return curBp === 'tablet';
}
}
}