Improve user messaging during initialization
- We first show a localized loading message. - If initialization takes longer than a certain threshold, we show a different ‘optimization’ message. - If initialization is below the threshold the message change is canceled right before the regular loading screen.
This commit is contained in:
parent
add19aa732
commit
dede0f1e25
2 changed files with 5 additions and 1 deletions
|
@ -961,7 +961,7 @@
|
|||
<span class='dot'></span>
|
||||
<span class='dot'></span>
|
||||
</div>
|
||||
<div class='message'>Loading...</div>
|
||||
<div class='message'></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
|
|
@ -17,6 +17,7 @@
|
|||
const { IdleDetector, MessageDataMigrator } = Signal.Workflow;
|
||||
const { Errors, Message } = window.Signal.Types;
|
||||
const { upgradeMessageSchema } = window.Signal.Migrations;
|
||||
const { Views } = window.Signal;
|
||||
|
||||
// Implicitly used in `indexeddb-backbonejs-adapter`:
|
||||
// https://github.com/signalapp/Signal-Desktop/blob/4033a9f8137e62ed286170ed5d4941982b1d3a64/components/indexeddb-backbonejs-adapter/backbone-indexeddb.js#L569
|
||||
|
@ -74,6 +75,8 @@
|
|||
return accountManager;
|
||||
};
|
||||
|
||||
const cancelInitializationMessage = Views.Initialization.setMessage();
|
||||
console.log('Start IndexedDB migrations');
|
||||
storage.fetch();
|
||||
|
||||
|
||||
|
@ -163,6 +166,7 @@
|
|||
connect(true);
|
||||
});
|
||||
|
||||
cancelInitializationMessage();
|
||||
var appView = window.owsDesktopApp.appView = new Whisper.AppView({el: $('body')});
|
||||
|
||||
Whisper.WallClockListener.init(Whisper.events);
|
||||
|
|
Loading…
Add table
Reference in a new issue