Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. Incomplete page display in QtWebkit when using javascript instead of mouse flick
Forum Updated to NodeBB v4.3 + New Features

Incomplete page display in QtWebkit when using javascript instead of mouse flick

Scheduled Pinned Locked Moved QML and Qt Quick
1 Posts 1 Posters 1.0k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • N Offline
    N Offline
    nizeguy
    wrote on last edited by
    #1

    in QtWebkit when the page loads, if i do : Component.onCompleted :
    idWebView.flick(0,-300); OR if i set contentY ; i get to a
    blank(non-filled) part of the page. Is this a QtWebkit bug or am i
    doing something wrong?

    If i flick it with the mouse it's ok, its just that when trying to
    flick using javascript it does not work.
    Can anybody help or point to the bug tracker that tracks this issue ?

    Thanks.
    @
    /usr/local/Qt-5.0.0/bin/qmlscene WebloaderScroller_test.qml

    import QtQuick 2.0
    import QtWebKit 3.0
    import QtWebKit.experimental 1.0

    Item{
    id:the_webloader
    objectName: "the_webloader"
    width:800
    height:600
    WebView {
    id:idWebView
    anchors.fill:parent;
    smooth: true
    Component.onCompleted: url= "http://reddit.com"
    flickDeceleration : 200; maximumFlickVelocity : 500
    boundsBehavior :Flickable.StopAtBounds

        onContentHeightChanged: console.log("contentHeight: ", contentHeight);
    }
    
    Rectangle{
        id:downArrow;
        color:"red"
        width:100
        height:100
        MouseArea{
            anchors.fill:parent
            onClicked: {
                idWebView.flick(0,-300);
    //            idWebView.contentY = Math.min (idWebView.contentY +
    

    idWebView.height/2 , idWebView.contentHeight-idWebView.height);
    // idWebView.reload();
    }
    }
    anchors{
    top:the_webloader.top;
    left:the_webloader.left;
    }}
    }
    @

    1 Reply Last reply
    0

    • Login

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Get Qt Extensions
    • Unsolved