diff options
author | Adrian Kummerlaender | 2015-08-04 22:01:53 +0200 |
---|---|---|
committer | Adrian Kummerlaender | 2015-08-04 22:01:53 +0200 |
commit | 55895c872412e062984908baacfac8e6363d36f4 (patch) | |
tree | cdd6cc875fb141b2a60ba136e235c422225f9cdf | |
parent | b563c10102f2211567daaa6570f54d312753408d (diff) | |
download | MetaTerm-55895c872412e062984908baacfac8e6363d36f4.tar MetaTerm-55895c872412e062984908baacfac8e6363d36f4.tar.gz MetaTerm-55895c872412e062984908baacfac8e6363d36f4.tar.bz2 MetaTerm-55895c872412e062984908baacfac8e6363d36f4.tar.lz MetaTerm-55895c872412e062984908baacfac8e6363d36f4.tar.xz MetaTerm-55895c872412e062984908baacfac8e6363d36f4.tar.zst MetaTerm-55895c872412e062984908baacfac8e6363d36f4.zip |
Increased overlay animation duration
This further discourages flickering during continuous terminal resize operations.
Overlay is now only enabled for resize operations after the terminal instantiation.
-rw-r--r-- | qml/EmbeddedTerminal.qml | 29 |
1 files changed, 21 insertions, 8 deletions
diff --git a/qml/EmbeddedTerminal.qml b/qml/EmbeddedTerminal.qml index 6d8b266..81814bb 100644 --- a/qml/EmbeddedTerminal.qml +++ b/qml/EmbeddedTerminal.qml @@ -79,6 +79,7 @@ Item { forceActiveFocus(); highlighter.select(); session.startShellProgram(); + overlay.enabled = true; } onTermGetFocus: highlighter.focus() @@ -89,24 +90,36 @@ Item { Rectangle { id: overlay + property bool enabled : false + function displayBriefly() { - animation.restart(); + if ( enabled ) { animation.restart() } } anchors.fill: parent opacity: 0 color: settings.overlayBackground - NumberAnimation { + SequentialAnimation { id: animation - target: overlay - property: "opacity" + ScriptAction { + script: overlay.opacity = 0.8 + } + + PauseAnimation { + duration: 500 + } + + NumberAnimation { + target: overlay + property: "opacity" - easing.type: Easing.InSine - duration: 500 - from: 0.8 - to: 0 + easing.type: Easing.InSine + duration: 500 + from: 0.8 + to: 0 + } } Text { |