1. Apr 15, 2014
  2. Apr 14, 2014
  3. Apr 10, 2014
    • Pierre Rossi's avatar
      Fix an false positive assertion with context menu · 777c0934
      Pierre Rossi authored
      
      Due to the asynchronous nature of context menu events in chromium,
      we need to filter out the Qt generated events, and rely of what comes
      back from the chromium side. We keep a flag to ensure we're always
      in a consistent state, but the part re-setting it in QWEView went missing.
      This simply re-adds it together with initializing it to false upon view
      construction.
      
      Change-Id: I5d187faf93742898c96a1951b7dc477ce1b3f5bd
      Reviewed-by: default avatarPeter Varga <pvarga@inf.u-szeged.hu>
      777c0934
  4. Apr 08, 2014
  5. Mar 31, 2014
  6. Mar 21, 2014
    • Jocelyn Turcotte's avatar
      Base load signals on Blink loader events · f06cb10c
      Jocelyn Turcotte authored
      
      This mainly remove the use of the LoadingStateChanged callback, which
      is tied to DidStartLoading and DidStopLoading.
      Those signals are handled from the browser process side, also wrapping
      the time where the render process is initialized. We can't rely on
      those signals for loadStarted, but afterward rely on the Blink loader
      for loadFinished. We must use the same source for both.
      
      Instead only rely on Blink callbacks ultimately related to network
      events. This gives us a behavior closer to QtWebKit.
      
      The major compromise that this forces us to to accept is that
      loadStarted is now triggered asynchronously. This will basically break
      anything expecting loadStarted to be emitted synchronously from the
      load method.
      
      This also adjust autotests to get a few more passing.
      
      Initial-patch-by: default avatarPierre Rossi <pierre.rossi@digia.com>
      Change-Id: Ib6c0170df891d1b7f8ed4dc1d483985523e267dc
      Reviewed-by: default avatarPierre Rossi <pierre.rossi@gmail.com>
      Reviewed-by: default avatarSimon Hausmann <simon.hausmann@digia.com>
      f06cb10c
  7. Mar 14, 2014
    • Pierre Rossi's avatar
      Tooltip support. · 38b5dc5f
      Pierre Rossi authored
      
      Basic tooltip support for widgets relying on the existing QToolTip
      mechanism.
      Left unimplemented on the Qt Quick side for now since ToolTip support
      is still very much a work in progress there.
      
      Change-Id: Ia4bfd715a224e0cbc147c8860e131d1545cebe1e
      Reviewed-by: default avatarJocelyn Turcotte <jocelyn.turcotte@digia.com>
      38b5dc5f
  8. Feb 28, 2014
    • Jocelyn Turcotte's avatar
      Add HTTP and proxy authentication signals directly to QWebEnginePage · 970ccc7f
      Jocelyn Turcotte authored
      
      This allows handling calls that would be signaled by QNetworkAccessManager
      in QtWebKit.
      This pulls QtNetwork as a dependency of the QtWebEngineWidgets module
      to be able to use QAuthenticator, but isn't required otherwise.
      
      Only the request URL is available in the case of HTTP authentication
      (no access to HTTP request headers that the QNetworkReply would allow)
      and only the proxy host name in the case case of proxy authentication.
      
      This keeps the API synchronous the same way, as QtWebKit did, in
      favor of source compatibility at the cost of requiring a modal
      dialog, even though the implementation doesn't require it.
      
      Change-Id: I9e021def38e6107c9e66d2de8f86bd0328d543df
      Reviewed-by: default avatarMichael Bruning <michael.bruning@digia.com>
      970ccc7f
  9. Feb 21, 2014
  10. Feb 20, 2014
  11. Feb 13, 2014
  12. Feb 12, 2014
  13. Feb 11, 2014
    • Zoltan Arvai's avatar
      Fix WebEngineWidgets api build on Windows · 8bd101c4
      Zoltan Arvai authored
      
      MSVC doesn't know __func__ so it needs to be defined.
      Also eliminate some unused variable warning.
      
      Change-Id: Ia42e411c0af8425a71faf99a87dbc0affac53015
      Reviewed-by: default avatarAndras Becsi <andras.becsi@digia.com>
      8bd101c4
    • Zeno Albisser's avatar
      Implement requestFullscreen for QQuickWebEngineView. · fcd08904
      Zeno Albisser authored
      
      This patch adds a property isFullScreen and a signal
      fullScreenRequested to QQuickWebEngineViewExperimental.
      The signal fullScreenRequested is emitted when some web content
      requests fullscreen through the javascript API.
      The property isFullScreen is supposed to be set
      programmatically when the view is being shown fullscreen.
      This information is then available to the WebContentsDelegateQt
      when checking if the fullscreen request has been accepted.
      
      Change-Id: I04cbb45f263a188d26cc87d70ac53b0fbab63936
      Reviewed-by: default avatarJocelyn Turcotte <jocelyn.turcotte@digia.com>
      fcd08904
  14. Feb 10, 2014
  15. Jan 30, 2014
  16. Jan 22, 2014
    • Jocelyn Turcotte's avatar
      Clear callbacks with an empty value on page destruction · 6fb392ee
      Jocelyn Turcotte authored
      
      The current implementation offers no way to cancel async requests.
      This means that normal applications could easily allow callbacks
      to dereference a destroyed object unless they use a smart pointer
      within the callback function object.
      
      This patch will empty the pending callback list by calling each of
      them with an empty value. This will at least allow applications to
      cover the cases where the page is expected to have a shorter or equal
      lifetime than objects referenced in the callback.
      
      Change-Id: Ia9fc556b03f5d83f904a0ff4b05dc9e440ea488c
      Reviewed-by: default avatarPierre Rossi <pierre.rossi@gmail.com>
      6fb392ee
    • Jocelyn Turcotte's avatar
      Implement QWebEnginePage::toHtml and toPlainText · 1fcd7970
      Jocelyn Turcotte authored
      
      Those methods are now made asynchronous and need to be given a
      callback to handle the result.
      
      Update the code in the browser and fancybrowser examples using
      std::bind when using C++11 or tr1::bind with C++03 (which should be
      available with compilers on platforms that we support).
      
      Add a (currently failing) earlyToHtml test to make sure that an empty
      page doesn't crash because of a possibly incomplete attachment of
      the QtRenderViewObserver.
      
      Change-Id: I3ab7cb6f25b91b584dd80df5e4e9ad1e3214348e
      Reviewed-by: default avatarPierre Rossi <pierre.rossi@gmail.com>
      1fcd7970
    • Jocelyn Turcotte's avatar
      Refactor the callback mechanism used by runJavaScript · 6d760436
      Jocelyn Turcotte authored
      
      This prepares the way for other API made async like toHtml and
      toPlainText.
      
      Use a callback class with an implicit templated constructor to carry
      the functor across the API boundary and avoid the intermediate helper
      method as the ABI that we have to maintain.
      
      Also pass the callback result through WebContentsAdapterClient using
      a bookkeeping ID instead of transferring the callback to
      WebContentsAdapter. This will allow other calls, which might not
      already allow passing a callback functor, to use a consisten way
      of carrying back the result to the top API layer.
      
      Change-Id: Ia923767b9c1021a108c26da17d4c41878ef7cb95
      Reviewed-by: default avatarPierre Rossi <pierre.rossi@gmail.com>
      6d760436
    • Jocelyn Turcotte's avatar
      Implement QWebEnginePage::setHtml and setContent · e6b846f3
      Jocelyn Turcotte authored
      
      Load a generated data: URL to carry the data.
      
      This is not as efficient as it could be but the behavior matches and
      this should be fine for now.
      
      Change-Id: I26ad2e5976025a3044fb03f066074ce6dd34e575
      Reviewed-by: default avatarPierre Rossi <pierre.rossi@gmail.com>
      e6b846f3
  17. Jan 17, 2014
  18. Jan 15, 2014
    • Pierre Rossi's avatar
      JS dialogs in QtQuick · 6f5850dd
      Pierre Rossi authored
      
      Refactor JavaScriptDialogManagerQt to support a Qt Quick dialogs
      friendly approach.
      Qt Quick dialogs are still missing a prompt, so we use a "handmade"
      one. This should be solved before 5.3 though.
      
      Change-Id: I965df66837b2e81d6e4618a8da1167a37661c26e
      Reviewed-by: default avatarJocelyn Turcotte <jocelyn.turcotte@digia.com>
      6f5850dd
    • Pierre Rossi's avatar
      [Widgets] wire the file pickers · c34b7218
      Pierre Rossi authored
      
      Introduce a new version of chooseFiles in QWebEnginePage.
      The existing API in WebKit1 seemed a bit dusty in any case (multiple
      only supported via extensions).
      
      Changes are:
        * oldFile becomes oldFiles, so that we could at a later stage expose
          the already selected files in the "multiple" case.
        * a type is introduced, for now limited to multiple selection, but
          over time, we might consider additions such as directory upload.
      
      Change-Id: I14cfea64ce95e892a0a1877c8cb914c5a421409f
      Reviewed-by: default avatarJocelyn Turcotte <jocelyn.turcotte@digia.com>
      c34b7218