Skip to content

Commit f7a4420

Browse files
author
Kiet Ly Chan
committed
MOBILE-3249 components: Hide delete menu item while downloading
1 parent 1411ef0 commit f7a4420

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/core/course/providers/helper.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -815,6 +815,11 @@ export class CoreCourseHelperProvider {
815815
}
816816
}
817817

818+
if (moduleInfo.status == CoreConstants.DOWNLOADING) {
819+
// Set this to 0 to prevent "remove file" option showing up while downloading.
820+
instance.size = 0;
821+
}
822+
818823
if (typeof instance.contextMenuStatusObserver == 'undefined' && component) {
819824
instance.contextMenuStatusObserver = this.eventsProvider.on(CoreEventsProvider.PACKAGE_STATUS_CHANGED, (data) => {
820825
if (data.componentId == module.id && data.component == component) {

0 commit comments

Comments
 (0)