2021-09-06 07:11:19 +00:00
|
|
|
import { Component } from '@angular/core';
|
2024-04-24 16:44:06 +00:00
|
|
|
import { TranslateService } from '@ngx-translate/core';
|
2018-08-19 20:37:53 +00:00
|
|
|
|
2018-08-22 20:04:41 +00:00
|
|
|
import { OpenLPService } from '../../openlp.service';
|
2019-11-07 18:02:26 +00:00
|
|
|
import { PageTitleService } from '../../page-title.service';
|
2021-09-06 07:11:19 +00:00
|
|
|
import { SlideListItem } from './slide-list/slide-list.component';
|
2018-08-19 20:37:53 +00:00
|
|
|
|
|
|
|
@Component({
|
2019-10-06 00:28:36 +00:00
|
|
|
selector: 'openlp-slides',
|
|
|
|
templateUrl: './slides.component.html',
|
2024-04-24 16:44:06 +00:00
|
|
|
styleUrl: './slides.component.scss',
|
2018-08-19 20:37:53 +00:00
|
|
|
})
|
|
|
|
|
2021-09-06 07:11:19 +00:00
|
|
|
export class SlidesComponent {
|
2024-04-24 16:44:06 +00:00
|
|
|
constructor(
|
|
|
|
protected pageTitleService: PageTitleService,
|
|
|
|
protected openlpService: OpenLPService,
|
|
|
|
private translateService: TranslateService) {
|
|
|
|
this.translateService.get('SLIDES').subscribe(res => {
|
|
|
|
this.pageTitleService.changePageTitle(res);
|
|
|
|
});
|
2018-08-19 20:37:53 +00:00
|
|
|
}
|
|
|
|
|
2021-09-06 07:11:19 +00:00
|
|
|
onSlideSelected(item: SlideListItem) {
|
|
|
|
this.openlpService.setSlide(item.index).subscribe();
|
2018-08-19 20:37:53 +00:00
|
|
|
}
|
|
|
|
}
|