Signed-off-by: z00513345 <zhuchengfeng1@huawei.com>
This commit is contained in:
z00513345 2022-09-24 14:27:16 +08:00
parent f04d581df6
commit 88dbd53335
2 changed files with 11 additions and 10 deletions

View File

@ -326,6 +326,8 @@ struct PhotoBrowser {
if (currentPhoto == undefined) {
return;
}
this.toolMenuList = [];
this.getActionList(currentPhoto).then((list: Array<Action>) => {
if (this.pageFrom == Constants.ENTRY_FROM.CAMERA || this.pageFrom == Constants.ENTRY_FROM.CARD) {
this.menuList = [Action.GOTO_PHOTOS, Action.INFO];
} else if (this.pageFrom == Constants.ENTRY_FROM.RECYCLE) {
@ -333,9 +335,6 @@ struct PhotoBrowser {
} else {
this.menuList = [Action.INFO]
}
this.toolMenuList = [];
this.getActionList(currentPhoto).then((list: Array<Action>) => {
if (this.isHorizontal) {
this.menuList = this.menuList.concat(list);
} else {

View File

@ -362,8 +362,10 @@ export struct TimelinePage {
startTrace('onModeChange');
this.onModeChange();
finishTrace('onModeChange');
mediaObserver.registerObserver(this.dataObserver);
animateTo({ duration: Constants.DELETE_ANIMATE_DURATION }, () => this.timelineDataSource.dataRemove())
animateTo({
duration: Constants.DELETE_ANIMATE_DURATION,
onFinish: () => mediaObserver.registerObserver(this.dataObserver)
}, () => this.timelineDataSource.dataRemove())
}
onCopyStart(): void {