MOBILE-3636 core: Use start to watch splitview outlet on list manager
parent
5350f715a3
commit
5c56bf0635
|
@ -51,8 +51,7 @@ export class AddonBadgesUserBadgesPage implements AfterViewInit, OnDestroy {
|
||||||
async ngAfterViewInit(): Promise<void> {
|
async ngAfterViewInit(): Promise<void> {
|
||||||
await this.fetchInitialBadges();
|
await this.fetchInitialBadges();
|
||||||
|
|
||||||
this.badges.watchSplitViewOutlet(this.splitView);
|
this.badges.start(this.splitView);
|
||||||
this.badges.start();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -55,8 +55,12 @@ export abstract class CorePageItemsListManager<Item> {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Process page started operations.
|
* Process page started operations.
|
||||||
|
*
|
||||||
|
* @param splitView Split view component.
|
||||||
*/
|
*/
|
||||||
async start(): Promise<void> {
|
async start(splitView: CoreSplitViewComponent): Promise<void> {
|
||||||
|
this.watchSplitViewOutlet(splitView);
|
||||||
|
|
||||||
// Calculate current selected item.
|
// Calculate current selected item.
|
||||||
const route = CoreNavigator.instance.getCurrentRoute({ pageComponent: this.pageComponent });
|
const route = CoreNavigator.instance.getCurrentRoute({ pageComponent: this.pageComponent });
|
||||||
if (route !== null && route.firstChild) {
|
if (route !== null && route.firstChild) {
|
||||||
|
|
|
@ -63,8 +63,7 @@ export class CoreGradesCoursePage implements AfterViewInit, OnDestroy {
|
||||||
async ngAfterViewInit(): Promise<void> {
|
async ngAfterViewInit(): Promise<void> {
|
||||||
await this.fetchInitialGrades();
|
await this.fetchInitialGrades();
|
||||||
|
|
||||||
this.grades.watchSplitViewOutlet(this.splitView);
|
this.grades.start(this.splitView);
|
||||||
this.grades.start();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -42,8 +42,7 @@ export class CoreGradesCoursesPage implements OnDestroy, AfterViewInit {
|
||||||
async ngAfterViewInit(): Promise<void> {
|
async ngAfterViewInit(): Promise<void> {
|
||||||
await this.fetchInitialCourses();
|
await this.fetchInitialCourses();
|
||||||
|
|
||||||
this.courses.watchSplitViewOutlet(this.splitView);
|
this.courses.start(this.splitView);
|
||||||
this.courses.start();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -33,8 +33,7 @@ export class CoreSettingsIndexPage implements AfterViewInit, OnDestroy {
|
||||||
*/
|
*/
|
||||||
ngAfterViewInit(): void {
|
ngAfterViewInit(): void {
|
||||||
this.sections.setItems(CoreSettingsConstants.SECTIONS);
|
this.sections.setItems(CoreSettingsConstants.SECTIONS);
|
||||||
this.sections.watchSplitViewOutlet(this.splitView);
|
this.sections.start(this.splitView);
|
||||||
this.sections.start();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -62,8 +62,7 @@ export class CoreUserParticipantsPage implements OnInit, AfterViewInit, OnDestro
|
||||||
async ngAfterViewInit(): Promise<void> {
|
async ngAfterViewInit(): Promise<void> {
|
||||||
await this.fetchInitialParticipants();
|
await this.fetchInitialParticipants();
|
||||||
|
|
||||||
this.participants.watchSplitViewOutlet(this.splitView);
|
this.participants.start(this.splitView);
|
||||||
this.participants.start();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue