mirror of
https://gitee.com/openharmony/applications_permission_manager
synced 2024-11-26 20:50:48 +00:00
commit
08f4e185c9
@ -4,13 +4,14 @@
|
||||
"app": {
|
||||
"bundleName": "com.ohos.permissionmanager",
|
||||
"vendor": "example",
|
||||
"versionCode": 1000064,
|
||||
"versionName": "1.6.4",
|
||||
"versionCode": 1000065,
|
||||
"versionName": "1.6.5",
|
||||
"icon": "$media:app_icon",
|
||||
"label": "$string:app_name",
|
||||
"minAPIVersion": 12,
|
||||
"targetAPIVersion": 12,
|
||||
"distributedNotificationEnabled": true,
|
||||
"apiReleaseType": "Beta5"
|
||||
"apiReleaseType": "Beta5",
|
||||
"configuration": "$profile:configuration"
|
||||
}
|
||||
}
|
||||
|
@ -16,13 +16,14 @@
|
||||
"app": {
|
||||
"bundleName": "com.ohos.permissionmanager",
|
||||
"vendor": "example",
|
||||
"versionCode": 1000064,
|
||||
"versionName": "1.6.4",
|
||||
"versionCode": 1000065,
|
||||
"versionName": "1.6.5",
|
||||
"icon": "$media:app_icon",
|
||||
"label": "$string:app_name",
|
||||
"minAPIVersion": 12,
|
||||
"targetAPIVersion": 12,
|
||||
"distributedNotificationEnabled": true,
|
||||
"apiReleaseType": "Beta5"
|
||||
"apiReleaseType": "Beta5",
|
||||
"configuration": "$profile:configuration"
|
||||
}
|
||||
}
|
||||
|
6
AppScope/resources/base/profile/configuration.json
Normal file
6
AppScope/resources/base/profile/configuration.json
Normal file
@ -0,0 +1,6 @@
|
||||
{
|
||||
"configuration": {
|
||||
"fontSizeScale": "followSystem",
|
||||
"fontSizeMaxScale": "2"
|
||||
}
|
||||
}
|
@ -135,6 +135,7 @@ export default class Constants {
|
||||
public static DIVIDER_MARGIN_RIGHT_PERMISSION = 52;
|
||||
public static DIVIDER_MARGIN_RIGHT_APPLICATION = 68;
|
||||
public static DIALOG_TITLE_MAX_SCALE = 2;
|
||||
public static DIALOG_TEXT_MAX_SCALE = 3.2;
|
||||
|
||||
// application-secondary, authority-secondary
|
||||
public static FLEX_MARGIN_TOP = 8;
|
||||
|
@ -278,7 +278,7 @@ export function setAvoidArea(proxy: uiExtensionHost.UIExtensionHostWindowProxy)
|
||||
export function getFontSizeScale(): number {
|
||||
const FONT_SIZE_SCALE_PARAM = 'persist.sys.font_scale_for_user0';
|
||||
let fontSizeScale = Number.parseFloat(systemParameterEnhance.getSync(FONT_SIZE_SCALE_PARAM, '1'));
|
||||
return fontSizeScale;
|
||||
return fontSizeScale >= Constants.DIALOG_TITLE_MAX_SCALE ? Constants.DIALOG_TITLE_MAX_SCALE : fontSizeScale;
|
||||
}
|
||||
|
||||
export function getLimitFontSize(
|
||||
|
@ -89,8 +89,8 @@ struct dialogPlusPage {
|
||||
Column() {
|
||||
if ((this.initStatus != Constants.INIT_NEED_TO_WAIT) && this.verify()) {
|
||||
Image(this.currentGroup().icon)
|
||||
.width(Constants.DIALOG_ICON_WIDTH * getFontSizeScale())
|
||||
.height(Constants.DIALOG_ICON_HEIGHT * getFontSizeScale())
|
||||
.width(Constants.DIALOG_ICON_WIDTH)
|
||||
.height(Constants.DIALOG_ICON_HEIGHT)
|
||||
.fillColor($r('sys.color.ohos_id_color_text_primary'))
|
||||
.margin({ top: Constants.DIALOG_ICON_MARGIN_TOP })
|
||||
if (this.grantGroups.length > 1) {
|
||||
@ -162,6 +162,7 @@ struct dialogPlusPage {
|
||||
.textAlign(TextAlign.Start)
|
||||
.fontColor($r('sys.color.font_primary'))
|
||||
.fontSize($r('sys.float.Body_L'))
|
||||
.maxFontScale(Constants.DIALOG_TEXT_MAX_SCALE)
|
||||
.margin({
|
||||
left: Constants.DIALOG_DESP_MARGIN_LEFT,
|
||||
right: Constants.DIALOG_DESP_MARGIN_RIGHT,
|
||||
|
@ -102,8 +102,9 @@ struct SecurityDialog {
|
||||
Column() {
|
||||
Column() {
|
||||
SymbolGlyph($r('sys.symbol.person_shield_fill'))
|
||||
.constraintSize({ minWidth: Constants.SECURITY_ICON_WIDTH, minHeight: Constants.SECURITY_ICON_HEIGHT })
|
||||
.fontSize(Constants.FONT_SIZE_28)
|
||||
.width(Constants.SECURITY_ICON_WIDTH)
|
||||
.height(Constants.SECURITY_ICON_HEIGHT)
|
||||
.fontSize(Constants.FONT_SIZE_28 / getFontSizeScale())
|
||||
.fontColor([$r('sys.color.brand')])
|
||||
.border({
|
||||
width: Constants.BORDER_WIDTH_1,
|
||||
@ -112,14 +113,9 @@ struct SecurityDialog {
|
||||
})
|
||||
.padding(Constants.PADDING_10)
|
||||
Image(this.securityParams[this.index].icon)
|
||||
.width(Constants.IMAGE_LENGTH_20 * getFontSizeScale())
|
||||
.height(Constants.IMAGE_LENGTH_20 * getFontSizeScale())
|
||||
.position({
|
||||
x: (Constants.FONT_SIZE_28 - Constants.IMAGE_LENGTH_20) * getFontSizeScale() +
|
||||
Constants.PADDING_10 * Constants.PADDING_TWICE,
|
||||
y: (Constants.FONT_SIZE_28 - Constants.IMAGE_LENGTH_20) * getFontSizeScale() +
|
||||
Constants.PADDING_10 * Constants.PADDING_TWICE
|
||||
})
|
||||
.width(Constants.IMAGE_LENGTH_20)
|
||||
.height(Constants.IMAGE_LENGTH_20)
|
||||
.position({ x: Constants.IMAGE_POSITION_28, y: Constants.IMAGE_POSITION_28 })
|
||||
}
|
||||
.backgroundColor($r('app.color.icon_bg'))
|
||||
.borderRadius($r('sys.float.ohos_id_corner_radius_default_m'))
|
||||
@ -158,6 +154,7 @@ struct SecurityDialog {
|
||||
.fontColor($r('sys.color.font_primary'))
|
||||
.fontSize($r('sys.float.Body_L'))
|
||||
.lineHeight(Constants.TEXT_SMALL_LINE_HEIGHT)
|
||||
.maxFontScale(Constants.DIALOG_TEXT_MAX_SCALE)
|
||||
}
|
||||
}
|
||||
.clip(true)
|
||||
|
Loading…
Reference in New Issue
Block a user