Skip to content

Instantly share code, notes, and snippets.

@penk
Created April 24, 2019 05:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save penk/9d30ed26f61f3a6bce4fd275121b5eab to your computer and use it in GitHub Desktop.
Save penk/9d30ed26f61f3a6bce4fd275121b5eab to your computer and use it in GitHub Desktop.
import QtQuick 2.0
import QtQuick.Window 2.0
import QtWebEngine 1.0
import QtQuick.VirtualKeyboard 2.2
import QtQuick.VirtualKeyboard.Settings 2.2
Window {
width: Screen.width
height: Screen.height
visible: true
WebEngineView {
anchors.fill: parent
url: "https://www.youtube.com"
}
InputPanel {
id: inputPanel
z: 89
y: parent.height
anchors.left: parent.left
anchors.right: parent.right
states: State {
name: "visible"
when: inputPanel.active
PropertyChanges {
target: inputPanel
y: parent.height - inputPanel.height
}
}
transitions: Transition {
id: inputPanelTransition
from: ""
to: "visible"
reversible: true
enabled: !VirtualKeyboardSettings.fullScreenMode
ParallelAnimation {
NumberAnimation {
properties: "y"
duration: 250
easing.type: Easing.InOutQuad
}
}
}
Binding {
target: InputContext
property: "animating"
value: inputPanelTransition.running
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment