mirror of
https://github.com/sensebox/blockly-app
synced 2025-06-08 01:35:52 +02:00
locking slides
This commit is contained in:
parent
96e4d215f6
commit
5b6b1ee568
2 changed files with 9 additions and 10 deletions
|
@ -72,7 +72,7 @@
|
||||||
</ion-slide>
|
</ion-slide>
|
||||||
<!-- OTA Manual -->
|
<!-- OTA Manual -->
|
||||||
<ion-slide id="manual-slide">
|
<ion-slide id="manual-slide">
|
||||||
<ion-grid *ngIf="manual">
|
<ion-grid *ngIf="modus==='manual'">
|
||||||
<ion-row align-items-center>
|
<ion-row align-items-center>
|
||||||
<ion-col col-12 col-md-6>
|
<ion-col col-12 col-md-6>
|
||||||
<img class="tutorial_gif" src="../../assets/imgs/ota_modus.gif" />
|
<img class="tutorial_gif" src="../../assets/imgs/ota_modus.gif" />
|
||||||
|
@ -92,7 +92,7 @@
|
||||||
</ion-col>
|
</ion-col>
|
||||||
</ion-row>
|
</ion-row>
|
||||||
</ion-grid>
|
</ion-grid>
|
||||||
<ion-grid *ngIf="automatic">
|
<ion-grid *ngIf="modus === 'automatic' ">
|
||||||
<ion-row align-items-center>
|
<ion-row align-items-center>
|
||||||
<ion-col col-12 col-md-6>
|
<ion-col col-12 col-md-6>
|
||||||
<ol style="text-align: left">
|
<ol style="text-align: left">
|
||||||
|
|
|
@ -47,12 +47,11 @@ export class OtaWizardPage implements OnInit, OnDestroy {
|
||||||
private sketch = ''
|
private sketch = ''
|
||||||
private compiledSketch: ArrayBuffer = undefined
|
private compiledSketch: ArrayBuffer = undefined
|
||||||
private hiddenSlides: OtaSlides[] = []
|
private hiddenSlides: OtaSlides[] = []
|
||||||
private modus = "manual"
|
// private modus = "manual"
|
||||||
private log: LoggingProvider
|
private log: LoggingProvider
|
||||||
private slideHistory: string[] = [OtaSlides[OtaSlides.Intro]] // for debug info in logs
|
private slideHistory: string[] = [OtaSlides[OtaSlides.Intro]] // for debug info in logs
|
||||||
private counts = { compile: 0, connect: 0, upload: 0 }
|
private counts = { compile: 0, connect: 0, upload: 0 }
|
||||||
private manual = false;
|
private modus;
|
||||||
private automatic = false;
|
|
||||||
private wifiSlideHidden = false;
|
private wifiSlideHidden = false;
|
||||||
constructor(
|
constructor(
|
||||||
private network: Network,
|
private network: Network,
|
||||||
|
@ -136,14 +135,14 @@ export class OtaWizardPage implements OnInit, OnDestroy {
|
||||||
}
|
}
|
||||||
showAutomatic() {
|
showAutomatic() {
|
||||||
this.hideSlide(OtaSlides.WifiSelection);
|
this.hideSlide(OtaSlides.WifiSelection);
|
||||||
this.automatic = true;
|
this.modus = "automatic";
|
||||||
this.manual = false;
|
this.slides.lockSwipeToNext(false);
|
||||||
this.slides.slideNext()
|
this.slides.slideNext()
|
||||||
}
|
}
|
||||||
|
|
||||||
showManual() {
|
showManual() {
|
||||||
this.manual = true;
|
this.modus = "manual";
|
||||||
this.automatic = false;
|
this.slides.lockSwipeToNext(false);
|
||||||
this.slides.slideNext()
|
this.slides.slideNext()
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -160,10 +159,10 @@ export class OtaWizardPage implements OnInit, OnDestroy {
|
||||||
// call logic for each slide
|
// call logic for each slide
|
||||||
onSlideChange() {
|
onSlideChange() {
|
||||||
this.slideHistory.push(OtaSlides[this.currentSlide])
|
this.slideHistory.push(OtaSlides[this.currentSlide])
|
||||||
console.log(this.currentSlide)
|
|
||||||
switch (this.currentSlide) {
|
switch (this.currentSlide) {
|
||||||
case OtaSlides.Intro:
|
case OtaSlides.Intro:
|
||||||
case OtaSlides.Intro2:
|
case OtaSlides.Intro2:
|
||||||
|
if(this.modus == undefined) this.slides.lockSwipeToNext(true);
|
||||||
break
|
break
|
||||||
case OtaSlides.Intro3:
|
case OtaSlides.Intro3:
|
||||||
break
|
break
|
||||||
|
|
Loading…
Add table
Reference in a new issue