← Back to team overview

ubuntu-webapps-bugs team mailing list archive

[Bug 1574517] [NEW] Ubuntu.Web doesn't support WebViewLoadRequest

 

Public bug reported:

I'd like to implement a fallback site when loading failed. According to
the docs QML should support a loadingChanged-signal [1] and a
WebViewLoadRequest [2] which results in a minimal example like this:

                onLoadingChanged: {
                     if (loadRequest.status === WebLoadStatus.Started) {
                         console.log("loading")
                    } else if (loadRequest.status === WebLoadStatus.Succeeded) {
                         console.log("loading succeeded")
                    } else if (loadRequest.status === WebLoadStatus.Failed) {
                        // If loading failed, fallback a local html file
                         console.log("loading failed")
                    }
                }

Unfortunately this doesn't work / is not implemented (yet?) in Ubuntu
WebView (Ubuntu.Web 0.2) [3]. I got a reference error "loadRequest is
not defined"


[1] http://doc.qt.io/qt-5/qml-qtwebview-webview.html#loadingChanged-signal
[2] http://doc.qt.io/qt-5/qml-qtwebview-webviewloadrequest.html
[3] https://developer.ubuntu.com/api/apps/qml/sdk-15.04.5/Ubuntu.Web.WebView/

** Affects: oxide
     Importance: Undecided
         Status: New


** Tags: loadrequest onloadingchanged webloadstatus webview

-- 
You received this bug notification because you are a member of Ubuntu
WebApps bug tracking, which is subscribed to Oxide.
https://bugs.launchpad.net/bugs/1574517

Title:
  Ubuntu.Web doesn't support WebViewLoadRequest

Status in Oxide:
  New

Bug description:
  I'd like to implement a fallback site when loading failed. According
  to the docs QML should support a loadingChanged-signal [1] and a
  WebViewLoadRequest [2] which results in a minimal example like this:

                  onLoadingChanged: {
                       if (loadRequest.status === WebLoadStatus.Started) {
                           console.log("loading")
                      } else if (loadRequest.status === WebLoadStatus.Succeeded) {
                           console.log("loading succeeded")
                      } else if (loadRequest.status === WebLoadStatus.Failed) {
                          // If loading failed, fallback a local html file
                           console.log("loading failed")
                      }
                  }

  Unfortunately this doesn't work / is not implemented (yet?) in Ubuntu
  WebView (Ubuntu.Web 0.2) [3]. I got a reference error "loadRequest is
  not defined"

  
  [1] http://doc.qt.io/qt-5/qml-qtwebview-webview.html#loadingChanged-signal
  [2] http://doc.qt.io/qt-5/qml-qtwebview-webviewloadrequest.html
  [3] https://developer.ubuntu.com/api/apps/qml/sdk-15.04.5/Ubuntu.Web.WebView/

To manage notifications about this bug go to:
https://bugs.launchpad.net/oxide/+bug/1574517/+subscriptions


Follow ups