aboutsummaryrefslogtreecommitdiffstats
path: root/support/hololens/ServoApp/BrowserPage.cpp
diff options
context:
space:
mode:
authorPaul Rouget <me@paulrouget.com>2019-10-29 08:25:50 +0100
committerPaul Rouget <me@paulrouget.com>2019-10-29 08:25:50 +0100
commit50929d7992692364f9c9bcdf60ce75a240c3b60c (patch)
treec0c2aabcc4e997cc55edc860cddec04edece4733 /support/hololens/ServoApp/BrowserPage.cpp
parentf78ca5794a905dca45f479ac5bca6975b93b64ab (diff)
downloadservo-50929d7992692364f9c9bcdf60ce75a240c3b60c.tar.gz
servo-50929d7992692364f9c9bcdf60ce75a240c3b60c.zip
Add a loading indicator in transient mode
Diffstat (limited to 'support/hololens/ServoApp/BrowserPage.cpp')
-rw-r--r--support/hololens/ServoApp/BrowserPage.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/support/hololens/ServoApp/BrowserPage.cpp b/support/hololens/ServoApp/BrowserPage.cpp
index 558b403a43d..61341dfcc29 100644
--- a/support/hololens/ServoApp/BrowserPage.cpp
+++ b/support/hololens/ServoApp/BrowserPage.cpp
@@ -28,14 +28,17 @@ void BrowserPage::BindServoEvents() {
forwardButton().IsEnabled(forward);
});
servoControl().OnLoadStarted([=] {
- throbber().IsActive(true);
+ urlbarLoadingIndicator().IsActive(true);
+ transientLoadingIndicator().IsIndeterminate(true);
+
reloadButton().IsEnabled(false);
reloadButton().Visibility(Visibility::Collapsed);
stopButton().IsEnabled(true);
stopButton().Visibility(Visibility::Visible);
});
servoControl().OnLoadEnded([=] {
- throbber().IsActive(false);
+ urlbarLoadingIndicator().IsActive(false);
+ transientLoadingIndicator().IsIndeterminate(false);
reloadButton().IsEnabled(true);
reloadButton().Visibility(Visibility::Visible);
stopButton().IsEnabled(false);
@@ -65,6 +68,8 @@ void BrowserPage::SetTransientMode(bool transient) {
servoControl().SetTransientMode(transient);
navigationBar().Visibility(transient ? Visibility::Collapsed
: Visibility::Visible);
+ transientLoadingIndicator().Visibility(transient ? Visibility::Visible
+ : Visibility::Collapsed);
}
void BrowserPage::SetArgs(hstring args) { servoControl().SetArgs(args); }