Signed-off-by: liujuan <liujuan76@h-partners.com>

Changes to be committed:
This commit is contained in:
liujuan 2024-05-30 16:21:20 +08:00
parent 93c50834ac
commit dc71f3528a
16 changed files with 67 additions and 66 deletions

View File

@ -16,17 +16,17 @@ import { Constants } from './Constants';
@Observed
export class TabItem {
name: Resource;
iconResource: Resource;
iconSelectedResource: Resource;
iconDefault: Resource = $r('sys.color.ohos_id_color_bottom_tab_icon_off');
iconSelected: Resource | null = null;
textColorDefault: Resource = $r('sys.color.ohos_id_color_text_primary');
textColorSelected: Resource = $r('sys.color.ohos_id_color_bottom_tab_text_on');
textFamilyDefault: Resource = $r('sys.string.ohos_id_text_font_family_medium');
textFamilySelected: Resource = $r('sys.string.ohos_id_text_font_family_medium');
isSelected: boolean;
componentKey: string;
public name: Resource;
public iconResource: Resource;
public iconSelectedResource: Resource;
public iconDefault: Resource = $r('sys.color.ohos_id_color_bottom_tab_icon_off');
public iconSelected: Resource | null = null;
public textColorDefault: Resource = $r('sys.color.ohos_id_color_text_primary');
public textColorSelected: Resource = $r('sys.color.ohos_id_color_bottom_tab_text_on');
public textFamilyDefault: Resource = $r('sys.string.ohos_id_text_font_family_medium');
public textFamilySelected: Resource = $r('sys.string.ohos_id_text_font_family_medium');
public isSelected: boolean;
public componentKey: string;
constructor(name: Resource, iconResource: Resource, iconSelectedResource: Resource,
isSelected: boolean, textColorDefault: Resource, componentKey: string) {
@ -59,14 +59,14 @@ export class TabItem {
// For Album Set
@Observed
export class TabItemWithText {
name: Resource;
isSelected: boolean;
textSizeDefault: Resource = $r('sys.float.ohos_id_text_size_body1');
textSizeSelected: Resource = $r('sys.float.ohos_id_text_size_sub_title2');
textWeightDefault: FontWeight = FontWeight.Regular;
textWeightSelected: FontWeight = FontWeight.Medium;
textColorDefault: Resource = $r('sys.color.ohos_id_color_bottom_tab_text_off');
textColorSelected: Resource = $r('app.color.color_system_highlight');
public name: Resource;
public isSelected: boolean;
public textSizeDefault: Resource = $r('sys.float.ohos_id_text_size_body1');
public textSizeSelected: Resource = $r('sys.float.ohos_id_text_size_sub_title2');
public textWeightDefault: FontWeight = FontWeight.Regular;
public textWeightSelected: FontWeight = FontWeight.Medium;
public textColorDefault: Resource = $r('sys.color.ohos_id_color_bottom_tab_text_off');
public textColorSelected: Resource = $r('app.color.color_system_highlight');
constructor(name: Resource, isSelected: boolean) {
this.name = name;

View File

@ -21,8 +21,8 @@ import { Action } from '../browserOperation/Action';
import { ActionBarMode } from '../browserOperation/ActionBarMode';
export class MenuItem {
value?: string;
action?: () => void;
public value?: string;
public action?: () => void;
}
@Component

View File

@ -22,8 +22,8 @@ const TAG: string = 'common_CancelOperationDialog';
@Observed
export class CancelParam {
continueFunc: Function = (): void => {};
cancelFunc: Function = (): void => {};
public continueFunc: Function = (): void => {};
public cancelFunc: Function = (): void => {};
}
@CustomDialog

View File

@ -21,8 +21,8 @@ const TAG: string = 'common_CopyOrMoveDialog';
@Observed
export class OperateParam {
moveFunc: Function = (): void => {};
copyFunc: Function = (): void => {};
public moveFunc: Function = (): void => {};
public copyFunc: Function = (): void => {};
}
@CustomDialog

View File

@ -21,9 +21,9 @@ const TAG: string = 'common_DeleteProgressDialog';
@Observed
export class DeleteProgressParam {
currentCount: number = 0;
totalCount: number = 0;
message?: Resource
public currentCount: number = 0;
public totalCount: number = 0;
public message?: Resource
}
@CustomDialog

View File

@ -24,16 +24,16 @@ const TAG: string = 'common_DetailsDialog';
@Observed
export class MediaDetails {
mediaType: number = 0;
height: number = 0;
width: number = 0;
size: number = 0;
duration: number = 0;
title: string = '';
dateTaken: number = 0;
uri: string = '';
displayName: string = '';
dateModified: number = 0;
public mediaType: number = 0;
public height: number = 0;
public width: number = 0;
public size: number = 0;
public duration: number = 0;
public title: string = '';
public dateTaken: number = 0;
public uri: string = '';
public displayName: string = '';
public dateModified: number = 0;
}
@CustomDialog

View File

@ -22,8 +22,8 @@ const TAG: string = 'common_DownloadCancelOperationDialog';
@Observed
export class CancelParam {
continueFunc: Function = (): void => {};
cancelFunc: Function = (): void => {};
public continueFunc: Function = (): void => {};
public cancelFunc: Function = (): void => {};
}
@CustomDialog

View File

@ -19,7 +19,7 @@ import { Constants } from '../../model/common/Constants';
@Observed
export class EditExitDialogCallback {
discardCallback: Function = (): void => {};
public discardCallback: Function = (): void => {};
}
@CustomDialog

View File

@ -22,8 +22,8 @@ const TAG: string = 'common_MultiSelectDialog';
@Observed
export class MultiSelectDetails {
count: number = 0;
size: number = 0;
public count: number = 0;
public size: number = 0;
}
@CustomDialog

View File

@ -22,8 +22,8 @@ const TAG: string = 'common_ProgressDialog';
@Observed
export class ProgressParam {
cancelFunc: Function = (): void => {};
operationType: string = '';
public cancelFunc: Function = (): void => {};
public operationType: string = '';
}
@CustomDialog

View File

@ -21,9 +21,9 @@ const TAG: string = 'common_RemoveProgressDialog';
@Observed
export class RemoveProgressParam {
currentCount: number = 0;
totalCount: number = 0;
message?: Resource
public currentCount: number = 0;
public totalCount: number = 0;
public message?: Resource
}
@CustomDialog

View File

@ -20,8 +20,8 @@ import { Constants } from '../../model/common/Constants';
@Observed
export class SaveDialogCallback {
saveAsNewCallback: Function = (): void => {};
replaceOriginalCallback: Function = (): void => {};
public saveAsNewCallback: Function = (): void => {};
public replaceOriginalCallback: Function = (): void => {};
}
@Extend(Text)

View File

@ -36,17 +36,17 @@ export interface ActionInfo {
}
export class ActionButtonInfo {
src?: Resource;
isActive: boolean;
isDoubleClicked: boolean;
actionID?: number;
text: Resource | null = null;
mode: number = 0;
height: Resource | null = null;
width: Resource | null = null;
color: Resource | null = null;
uri: string = '';
componentKey: string;
public src?: Resource;
public isActive: boolean;
public isDoubleClicked: boolean;
public actionID?: number;
public text: Resource | null = null;
public mode: number = 0;
public height: Resource | null = null;
public width: Resource | null = null;
public color: Resource | null = null;
public uri: string = '';
public componentKey: string;
constructor(action: ActionInfo) {
this.src = action.src == undefined ? undefined : action.src;

View File

@ -17,8 +17,8 @@ import { ActionButtonInfo } from './MainMenuInfo';
import { Constants } from '@ohos/common';
export class RefreshActionMenu {
isChanged: number;
menuArray: Array<ActionButtonInfo>;
public isChanged: number;
public menuArray: Array<ActionButtonInfo>;
constructor(isChanged: number, menuArray: Array<ActionButtonInfo>) {
this.isChanged = isChanged;

View File

@ -727,8 +727,8 @@ export struct TimelinePage {
item: item.mediaItem,
mPosition: item.viewIndex,
isSelected: this.isSelectedMode ?
this.mSelectManager.isItemSelected((item.mediaItem as MediaItem).uri as string, item.viewIndex) :
false,
this.mSelectManager.isItemSelected((item.mediaItem as MediaItem).uri as string,
item.viewIndex) : false,
pageName: Constants.PHOTO_TRANSITION_TIMELINE,
onMenuClicked: (action: Action): void => this.onMenuClicked(action),
onMenuClickedForSingleItem: (action: Action, currentPhoto: MediaItem): void =>

View File

@ -144,7 +144,8 @@ export struct SelectPhotoBrowserView {
} else if (this.pageFrom == Constants.ENTRY_FROM.DISTRIBUTED) {
this.dataSource.setDeviceId(param.deviceId);
}
this.dataSource.setAlbumDataSource(AppStorage.get<MediaDataSource>(Constants.APP_KEY_PHOTO_BROWSER) as MediaDataSource);
this.dataSource.setAlbumDataSource(
AppStorage.get<MediaDataSource>(Constants.APP_KEY_PHOTO_BROWSER) as MediaDataSource);
if (this.isMultiPick == true && this.selectManager) {
this.selectedCount = this.selectManager.getSelectedCount();
}