Remove step 1 of previous setup flow, replaced by choice screen

FREEBIE
pull/749/head
Scott Nonnenberg 8 years ago
parent ba347744ff
commit ff1cb3598d
No known key found for this signature in database
GPG Key ID: A4931C09644C654B

@ -646,23 +646,6 @@
</script> </script>
<script type='text/x-tmpl-mustache' id='install_flow_template'> <script type='text/x-tmpl-mustache' id='install_flow_template'>
<div id='step1' class='step hidden'>
<div class='inner'>
<div class='step-body'>
<img id='signal-icon' src='images/icon_250.png'/>
<h1>{{ installWelcome }}</h1>
<p>{{ installTagline }}</p>
</div>
<div class='nav'>
<div> <a class='button step2'>{{ installGetStartedButton }}</a> </div>
<div class='dot-container'>
<span class='dot step1 selected'></span>
<span class='dot step2'></span>
<span class='dot step3'></span>
</div>
</div>
</div>
</div>
<div id='step2' class='step hidden'> <div id='step2' class='step hidden'>
<div class='inner'> <div class='inner'>

@ -44,7 +44,7 @@
} }
this.$('#device-name').val(deviceName); this.$('#device-name').val(deviceName);
this.$('#step1').show(); this.$('#step2').show();
this.connect(); this.connect();
this.on('disconnected', this.reconnect); this.on('disconnected', this.reconnect);
@ -63,6 +63,10 @@
).catch(this.handleDisconnect.bind(this)); ).catch(this.handleDisconnect.bind(this));
}, },
handleDisconnect: function(e) { handleDisconnect: function(e) {
if (this.canceled) {
return;
}
if (e.message === 'websocket closed') { if (e.message === 'websocket closed') {
this.showConnectionError(); this.showConnectionError();
this.trigger('disconnected'); this.trigger('disconnected');
@ -78,11 +82,15 @@
events: function() { events: function() {
return { return {
'click .error-dialog .ok': 'connect', 'click .error-dialog .ok': 'connect',
'click .step1': this.selectStep.bind(this, 1), 'click .step1': 'onCancel',
'click .step2': this.selectStep.bind(this, 2), 'click .step2': this.selectStep.bind(this, 2),
'click .step3': this.selectStep.bind(this, 3) 'click .step3': this.selectStep.bind(this, 3)
}; };
}, },
onCancel: function() {
this.canceled = true;
this.trigger('cancel');
},
clearQR: function() { clearQR: function() {
this.$('#qr').text(i18n("installConnecting")); this.$('#qr').text(i18n("installConnecting"));
}, },

Loading…
Cancel
Save