From 1470dc06a30e4b7da141da3c104e517b90ebe74e Mon Sep 17 00:00:00 2001 From: jared Date: Fri, 17 Jul 2020 23:46:24 +0800 Subject: [PATCH] update image size --- .../Contents/Animation/Circle.qml | 8 +- .../Contents/Animation/Cleavage.qml | 16 ++-- .../TaoQuickShow/Contents/Animation/Cross.qml | 9 ++- .../Contents/Animation/Diagonal.qml | 16 ++-- .../Contents/Animation/Dissolve.qml | 8 +- .../TaoQuickShow/Contents/Animation/Enter.qml | 45 +++++++----- .../TaoQuickShow/Contents/Animation/Grad.qml | 16 ++-- .../Contents/Animation/Louver.qml | 16 ++-- .../Contents/Animation/Rhombus.qml | 8 +- .../Contents/Animation/Square.qml | 8 +- .../TaoQuickShow/Contents/Animation/Wheel.qml | 12 +-- mkspecs/features/taoVersion.prf | 73 +++++++++---------- .../EffectComponent/Animation/ASlowEnter.qml | 2 +- 13 files changed, 123 insertions(+), 114 deletions(-) diff --git a/examples/TaoQuickShow/Contents/Animation/Circle.qml b/examples/TaoQuickShow/Contents/Animation/Circle.qml index 599b041..35999a7 100644 --- a/examples/TaoQuickShow/Contents/Animation/Circle.qml +++ b/examples/TaoQuickShow/Contents/Animation/Circle.qml @@ -15,15 +15,15 @@ Item { spacing: 40 ACircle { id: s1 - width: 460 - height: 280 + width: 250 + height: 375 dir: ASquare.Direct.FromInner effectSource.sourceItem: src } ACircle { id: s2 - width: 460 - height: 280 + width: 250 + height: 375 dir: ASquare.Direct.FromOuter effectSource.sourceItem: src } diff --git a/examples/TaoQuickShow/Contents/Animation/Cleavage.qml b/examples/TaoQuickShow/Contents/Animation/Cleavage.qml index c35a81c..3e2ab86 100644 --- a/examples/TaoQuickShow/Contents/Animation/Cleavage.qml +++ b/examples/TaoQuickShow/Contents/Animation/Cleavage.qml @@ -17,29 +17,29 @@ Item { spacing: 40 ACleavage { id: s1 - width: 460 - height: 280 + width: 250 + height: 375 dir: ACleavage.Direct.HorizonToInner effectSource.sourceItem: src } ACleavage { id: s2 - width: 460 - height: 280 + width: 250 + height: 375 dir: ACleavage.Direct.HorizonToOuter effectSource.sourceItem: src } ACleavage { id: s3 - width: 460 - height: 280 + width: 250 + height: 375 dir: ACleavage.Direct.VerticalToInner effectSource.sourceItem: src } ACleavage { id: s4 - width: 460 - height: 280 + width: 250 + height: 375 dir: ACleavage.Direct.VerticalToOuter effectSource.sourceItem: src } diff --git a/examples/TaoQuickShow/Contents/Animation/Cross.qml b/examples/TaoQuickShow/Contents/Animation/Cross.qml index af55e01..c6a1c57 100644 --- a/examples/TaoQuickShow/Contents/Animation/Cross.qml +++ b/examples/TaoQuickShow/Contents/Animation/Cross.qml @@ -13,17 +13,18 @@ Item { anchors.centerIn: parent columns: 2 spacing: 40 + ACross { id: s1 - width: 460 - height: 280 + width: 250 + height: 375 dir: ASquare.Direct.FromInner effectSource.sourceItem: src } ACross { id: s2 - width: 460 - height: 280 + width: 250 + height: 375 dir: ASquare.Direct.FromOuter effectSource.sourceItem: src } diff --git a/examples/TaoQuickShow/Contents/Animation/Diagonal.qml b/examples/TaoQuickShow/Contents/Animation/Diagonal.qml index 13e578b..f19ec6e 100644 --- a/examples/TaoQuickShow/Contents/Animation/Diagonal.qml +++ b/examples/TaoQuickShow/Contents/Animation/Diagonal.qml @@ -15,29 +15,29 @@ Item { spacing: 40 ADiagonal { id: d1 - width: 460 - height: 280 + width: 250 + height: 375 dir: ADiagonal.Direct.FromLeftTop effectSource.sourceItem: src } ADiagonal { id: d2 - width: 460 - height: 280 + width: 250 + height: 375 dir: ADiagonal.Direct.FromRightBottom effectSource.sourceItem: src } ADiagonal { id: d3 - width: 460 - height: 280 + width: 250 + height: 375 dir: ADiagonal.Direct.FromRightTop effectSource.sourceItem: src } ADiagonal { id: d4 - width: 460 - height: 280 + width: 250 + height: 375 dir: ADiagonal.Direct.FromLeftBottom effectSource.sourceItem: src } diff --git a/examples/TaoQuickShow/Contents/Animation/Dissolve.qml b/examples/TaoQuickShow/Contents/Animation/Dissolve.qml index 3a68da9..9b4c428 100644 --- a/examples/TaoQuickShow/Contents/Animation/Dissolve.qml +++ b/examples/TaoQuickShow/Contents/Animation/Dissolve.qml @@ -24,16 +24,16 @@ Item { spacing: 40 ADissolve { id: a1 - width: 460 - height: 280 + width: 250 + height: 375 duration: 1800 effectSource.sourceItem: src dissolveSource.sourceItem: dissolveSrc1 } ADissolve { id: a2 - width: 460 - height: 280 + width: 250 + height: 375 duration: 1800 effectSource.sourceItem: src dissolveSource.sourceItem: dissolveSrc2 diff --git a/examples/TaoQuickShow/Contents/Animation/Enter.qml b/examples/TaoQuickShow/Contents/Animation/Enter.qml index ed4455d..202f9af 100644 --- a/examples/TaoQuickShow/Contents/Animation/Enter.qml +++ b/examples/TaoQuickShow/Contents/Animation/Enter.qml @@ -4,18 +4,6 @@ import TaoQuick 1.0 import "qrc:/TaoQuick" Item { anchors.fill: parent - ASlowEnter { - id: a1 - width: 320 - height: 216 - x: (parent.width - width) / 2 - targetY: parent.height / 2 - dir: ASlowEnter.Direct.FromBottom - Image { - anchors.fill: parent - source: imgPath + "Effect/baby.jpg" - } - } ASlowEnter { id: a2 width: 320 @@ -28,11 +16,32 @@ Item { source: imgPath + "Effect/baby.jpg" } } + Rectangle { + width: 320 + height: 216 + anchors.centerIn: parent + border.width: 1 + border.color: "red" + color: "transparent" + } + ASlowEnter { + id: a1 + width: 320 + height: 216 + x: (parent.width - width) / 2 + targetY: parent.height / 2 + dir: ASlowEnter.Direct.FromBottom + Image { + anchors.fill: parent + source: imgPath + "Effect/baby.jpg" + } + } + ASlowEnter { id: a3 width: 320 height: 216 - targetX: parent.width / 2 - width * 1.5 + targetX: (parent.width - width) / 2 - width y: (parent.height - height) / 2 dir: ASlowEnter.Direct.FromLeft Image { @@ -44,7 +53,7 @@ Item { id: a4 width: 320 height: 216 - targetX: parent.width / 2 + width / 2 + targetX: parent.width - (parent.width - width)/2 y: (parent.height - height) / 2 dir: ASlowEnter.Direct.FromRight Image { @@ -54,10 +63,10 @@ Item { } ParallelAnimation { id: ani - ScriptAction{ script: {a1.animation.restart()} } - ScriptAction{ script: {a2.animation.restart()} } - ScriptAction{ script: {a3.animation.restart()} } - ScriptAction{ script: {a4.animation.restart()} } + ScriptAction{ script: {a1.animation.start()} } + ScriptAction{ script: {a2.animation.start()} } + ScriptAction{ script: {a3.animation.start()} } + ScriptAction{ script: {a4.animation.start()} } } Component.onCompleted: { ani.restart() diff --git a/examples/TaoQuickShow/Contents/Animation/Grad.qml b/examples/TaoQuickShow/Contents/Animation/Grad.qml index d88545d..8302788 100644 --- a/examples/TaoQuickShow/Contents/Animation/Grad.qml +++ b/examples/TaoQuickShow/Contents/Animation/Grad.qml @@ -16,31 +16,31 @@ Item { spacing: 40 AGrad { id: g1 - width: 460 - height: 280 + width: 250 + height: 375 effectSource.sourceItem: src } AGrad { id: g2 - width: 460 - height: 280 + width: 250 + height: 375 dir: ASlowEnter.Direct.FromRight effectSource.sourceItem: src } AGrad { id: g3 - width: 460 - height: 280 + width: 250 + height: 375 dir: ASlowEnter.Direct.FromTop effectSource.sourceItem: src } AGrad { id: g4 dir: ASlowEnter.Direct.FromBottom - width: 460 - height: 280 + width: 250 + height: 375 effectSource.sourceItem: src } diff --git a/examples/TaoQuickShow/Contents/Animation/Louver.qml b/examples/TaoQuickShow/Contents/Animation/Louver.qml index 08dfa27..441ac00 100644 --- a/examples/TaoQuickShow/Contents/Animation/Louver.qml +++ b/examples/TaoQuickShow/Contents/Animation/Louver.qml @@ -16,28 +16,28 @@ Item { ALouver { id: l1 - width: 460 - height: 280 + width: 250 + height: 375 effectSource.sourceItem: src } ALouver { id: l2 - width: 460 - height: 280 + width: 250 + height: 375 dir: ALouver.Direct.HorizonReverse effectSource.sourceItem: src } ALouver { id: l3 - width: 460 - height: 280 + width: 250 + height: 375 dir: ALouver.Direct.Vertical effectSource.sourceItem: src } ALouver { id: l4 - width: 460 - height: 280 + width: 250 + height: 375 dir: ALouver.Direct.VerticalReverse effectSource.sourceItem: src } diff --git a/examples/TaoQuickShow/Contents/Animation/Rhombus.qml b/examples/TaoQuickShow/Contents/Animation/Rhombus.qml index eba070b..9fcd252 100644 --- a/examples/TaoQuickShow/Contents/Animation/Rhombus.qml +++ b/examples/TaoQuickShow/Contents/Animation/Rhombus.qml @@ -16,15 +16,15 @@ Item { ARhombus { id: l1 - width: 460 - height: 280 + width: 250 + height: 375 dir: ARhombus.Direct.FromInner effectSource.sourceItem: src } ARhombus { id: l2 - width: 460 - height: 280 + width: 250 + height: 375 dir: ARhombus.Direct.FromOuter effectSource.sourceItem: src } diff --git a/examples/TaoQuickShow/Contents/Animation/Square.qml b/examples/TaoQuickShow/Contents/Animation/Square.qml index a6b7b6f..2401e7e 100644 --- a/examples/TaoQuickShow/Contents/Animation/Square.qml +++ b/examples/TaoQuickShow/Contents/Animation/Square.qml @@ -15,15 +15,15 @@ Item { spacing: 40 ASquare { id: s1 - width: 460 - height: 280 + width: 250 + height: 375 dir: ASquare.Direct.FromInner effectSource.sourceItem: src } ASquare { id: s2 - width: 460 - height: 280 + width: 250 + height: 375 dir: ASquare.Direct.FromOuter effectSource.sourceItem: src } diff --git a/examples/TaoQuickShow/Contents/Animation/Wheel.qml b/examples/TaoQuickShow/Contents/Animation/Wheel.qml index c5d7e49..cf3fac1 100644 --- a/examples/TaoQuickShow/Contents/Animation/Wheel.qml +++ b/examples/TaoQuickShow/Contents/Animation/Wheel.qml @@ -15,22 +15,22 @@ Item { spacing: 40 AWheel { id: s1 - width: 460 - height: 280 + width: 250 + height: 375 dir: AWheel.Direct.Clockwise effectSource.sourceItem: src } AWheel { id: s2 - width: 460 - height: 280 + width: 250 + height: 375 dir: AWheel.Direct.CounterClockwise effectSource.sourceItem: src } ASector { id: s3 - width: 460 - height: 280 + width: 250 + height: 375 effectSource.sourceItem: src } } diff --git a/mkspecs/features/taoVersion.prf b/mkspecs/features/taoVersion.prf index 02de757..95964b3 100644 --- a/mkspecs/features/taoVersion.prf +++ b/mkspecs/features/taoVersion.prf @@ -1,42 +1,41 @@ -build_pass { - !exists(TaoVersionDefined) { - TaoVersionDefined=1 +!exists(TaoVersionDefined) { + TaoVersionDefined=1 - TAO_VERSION_TAG = 1.0 + TAO_VERSION_TAG = 1.0 - # current commit hash - REVISION=$$system("git rev-parse HEAD") - REVISION=$$str_member($${REVISION}, 0, $$num_add(10, -1)) - isEmpty(REVISION) { - REVISION = 0000000000 - } + # current commit hash + REVISION=$$system("git rev-parse HEAD") + REVISION=$$str_member($${REVISION}, 0, $$num_add(10, -1)) + isEmpty(REVISION) { + REVISION = 0000000000 + } - # last tag - Ver=$$system("git describe --abbrev=0 --tags") - isEmpty(Ver) { - Ver=0.0.0 - } - VerList =$$split(Ver, .) - MAJ = $$take_first(VerList) - MIN = $$take_first(VerList) - PAT = $$take_first(VerList) - equals(TEMPLATE, lib) { - CONFIG += skip_target_version_ext - VER_MAJ = $${MAJ} - VER_MIN = $${MIN} - VER_PAT = $${PAT} - VERSION = $${Ver} - } - !exists(TaoDefined) { - TaoDefined=1 - DEFINES += TaoREVISION=$${REVISION} - DEFINES += TaoREVISIONSTR=\"\\\"$${REVISION}\\\"\" - DEFINES += TaoVer=\"\\\"$${Ver}\\\"\" - DEFINES += TaoMAJ=$${MAJ} - DEFINES += TaoMIN=$${MIN} - DEFINES += TaoPAT=$${PAT} - DEFINES += TaoDATETIME=\"\\\"$${_DATE_}\\\"\" - DEFINES += TaoCompilerVendor=\"\\\"$${QT_VERSION} $${QMAKE_PLATFORM} $${QMAKE_COMPILER} $${QMAKE_TARGET.arch}\\\"\" - } + # last tag + Ver=$$system("git describe --abbrev=0 --tags") + isEmpty(Ver) { + Ver=0.0.0 + } + VerList =$$split(Ver, .) + MAJ = $$take_first(VerList) + MIN = $$take_first(VerList) + PAT = $$take_first(VerList) + equals(TEMPLATE, lib) { + CONFIG += skip_target_version_ext + VER_MAJ = $${MAJ} + VER_MIN = $${MIN} + VER_PAT = $${PAT} + VERSION = $${Ver} + } + !exists(TaoDefined) { + TaoDefined=1 + DEFINES += TaoREVISION=$${REVISION} + DEFINES += TaoREVISIONSTR=\"\\\"$${REVISION}\\\"\" + DEFINES += TaoVer=\"\\\"$${Ver}\\\"\" + DEFINES += TaoMAJ=$${MAJ} + DEFINES += TaoMIN=$${MIN} + DEFINES += TaoPAT=$${PAT} + DEFINES += TaoDATETIME=\"\\\"$${_DATE_}\\\"\" + DEFINES += TaoCompilerVendor=\"\\\"$${QT_VERSION} $${QMAKE_PLATFORM} $${QMAKE_COMPILER} $${QMAKE_TARGET.arch}\\\"\" } } + diff --git a/src/TaoQuick/TaoQuick/EffectComponent/Animation/ASlowEnter.qml b/src/TaoQuick/TaoQuick/EffectComponent/Animation/ASlowEnter.qml index 4b5e65c..7668c04 100644 --- a/src/TaoQuick/TaoQuick/EffectComponent/Animation/ASlowEnter.qml +++ b/src/TaoQuick/TaoQuick/EffectComponent/Animation/ASlowEnter.qml @@ -30,6 +30,6 @@ Item { to: __toList[dir] duration: r.duration loops: 1 - alwaysRunToEnd: true +// alwaysRunToEnd: true } }