1
0
mirror of https://github.com/jaredtao/TaoQuick.git synced 2025-01-19 20:22:56 +08:00

update folder

This commit is contained in:
jared 2020-10-14 13:47:57 +08:00
parent 133fdbf0c3
commit df7fa7b768
21 changed files with 45 additions and 176 deletions

View File

@ -5,20 +5,16 @@
<file>Qml/Page/ContentPage.qml</file>
<file>Qml/Page/TitlePage.qml</file>
<file>Qml/Page/NotifyBox.qml</file>
<file>Qml/Splash.qml</file>
<file>Qml/MainPage.qml</file>
<file>Qml/Page/ContentData.qml</file>
<file>Qml/Page/AboutDialog.qml</file>
<file>Qml/Page/Biz/Background.qml</file>
<file>Qml/Page/Biz/LangBtn.qml</file>
<file>Qml/Page/Biz/SkinBtn.qml</file>
<file>Qml/TBusyIndicator.qml</file>
<file>Qml/Page/Biz/CompDetail.qml</file>
<file>Qml/Page/Biz/CompCard.qml</file>
<file>Qml/Page/Biz/TText.qml</file>
<file>Qml/Page/Biz/CircleText.qml</file>
<file>Qml/Page/Biz/CloseBtn.qml</file>
<file>Qml/Page/Biz/CompBtn.qml</file>
<file>Qml/Page/Biz/BackBtn.qml</file>
<file>Qml/Biz/BackBtn.qml</file>
<file>Qml/Biz/CircleText.qml</file>
<file>Qml/Biz/CloseBtn.qml</file>
<file>Qml/Biz/CompBtn.qml</file>
<file>Qml/Biz/CompCard.qml</file>
<file>Qml/Biz/CompDetail.qml</file>
<file>Qml/Biz/LangBtn.qml</file>
<file>Qml/Biz/SkinBtn.qml</file>
<file>Qml/Biz/TText.qml</file>
</qresource>
</RCC>

View File

@ -0,0 +1,10 @@
import QtQuick 2.9
import TaoQuick 1.0
CusButton_Image {
width: 48
height: 48
btnImgUrl: imgPath + (containsMouse ? "Common/left_hovered.png" : "Common/left.png")
}

View File

@ -3,11 +3,9 @@ import QtQuick 2.9
import TaoQuick 1.0
TTextBtn {
CusButton {
id: root
textColor: gConfig.textColor
textItem.font.pixelSize: gConfig.fontPixel
textItem.font.family: gConfig.fontFamily
Image {
anchors {

View File

@ -26,6 +26,7 @@ CusButton_Image {
text: qsTr(modelData)
backgroundColor: trans.currentLang === modelData ? gConfig.themeColor :( containsMouse ? "lightgray" : pop.barColor)
textColor: gConfig.textColor
borderWidth: 0
radius: 4
onClicked: {
// pop.hide()

View File

@ -1,6 +1,7 @@
import QtQuick 2.0
import QtQuick.Controls 2.0
Text {
import TaoQuick 1.0
BasicText {
font {
pixelSize: gConfig.fontPixel
family: gConfig.fontFamily

View File

@ -1,35 +0,0 @@
import QtQuick 2.9
import "./Page"
import TaoQuick 1.0
Item {
anchors.fill: parent
ContentData {
id: gConfig
objectName: "gConfig"
}
AboutDialog {
id: aboutDialog
}
TitlePage {
id: titlePage
width: rootView.width
height: 60
color: gConfig.themeColor
}
ContentPage {
id: contentPage
color: gConfig.background
anchors {
top: titlePage.bottom
bottom: parent.bottom
left: titlePage.left
right: titlePage.right
}
}
NotifyBox {
id: notifyBox
}
}

View File

@ -17,9 +17,13 @@ Popup {
color: gConfig.themeColor
border.width: 1
border.color: gConfig.reserverColor
TMoveArea {
MoveArea {
anchors.fill: parent
control: root
onMove: {
root.x += xOffset
root.y += yOffset
}
}
Image {
id: img
@ -28,13 +32,13 @@ Popup {
anchors.verticalCenter: parent.verticalCenter
source: imgPath + "logo/milk.png"
}
TTextBtn {
CusButton {
id: closeBtn
text: qsTr("Close")
width: 80
height: 38
radius: 8
color: containsPress ? Qt.darker(gConfig.background, 1.2) : (containsMouse ? Qt.lighter(gConfig.background, 1.2) : gConfig.background)
backgroundColor: containsPress ? Qt.darker(gConfig.background, 1.2) : (containsMouse ? Qt.lighter(gConfig.background, 1.2) : gConfig.background)
textColor: gConfig.textColor
anchors.horizontalCenter: parent.horizontalCenter
anchors.bottom: parent.bottom

View File

@ -1,10 +0,0 @@
import QtQuick 2.9
import TaoQuick 1.0
TImageBtn {
width: 48
height: 48
imageUrl: imgPath + (containsMouse ? "Common/left_hovered.png" : "Common/left.png")
}

View File

@ -1,8 +0,0 @@
import QtQuick 2.9
import QtQuick.Controls 2.2
import TaoQuick 1.0
Rectangle {
id: root
}

View File

@ -2,7 +2,7 @@ import QtQuick 2.9
import QtQuick.Controls 2.2
import TaoQuick 1.0
import "Biz"
import "../Biz"
Background {
id: background
readonly property string defaultTitle: "Component List"

View File

@ -1,7 +1,7 @@
import QtQuick 2.9
import QtQuick.Controls 2.2
import TaoQuick 1.0
import "./Biz"
import "../Biz"
Rectangle {
Row {
anchors.left: parent.left

View File

@ -1,18 +0,0 @@
import QtQuick 2.9
import QtQuick.Controls 2.2
Item {
width: 1024
height: 768
opacity: 1.0
Behavior on opacity {
NumberAnimation { duration: 500 }
}
TBusyIndicator {
id: control
running: true
anchors.centerIn: parent
width: 160
height: 160
durationPerCycle: 2000
}
}

View File

@ -1,62 +0,0 @@
import QtQuick 2.9
import QtQuick.Controls 2.2
BusyIndicator {
id: control
width: 64
height: 64
property color busyColor: "#008b8b"
property int busyRadius: 5
property int busyCount: 6
property int durationPerCycle: 1500
contentItem: Item {
width: control.width
height: control.height
Item {
id: item
width: parent.width
height: parent.height
opacity: control.running ? 1 : 0
Behavior on opacity {
OpacityAnimator {
duration: 250
}
}
RotationAnimator {
target: item
running: control.visible && control.running
from: 0
to: 360
loops: Animation.Infinite
duration: durationPerCycle
}
Repeater {
id: repeater
model: busyCount
Rectangle {
x: item.width / 2 - width / 2
y: item.height / 2 - height / 2
implicitWidth: busyRadius * 2
implicitHeight: busyRadius * 2
radius: busyRadius
color: busyColor
transform: [
Translate {
y: -Math.min(item.width, item.height) * 0.5 + busyRadius
},
Rotation {
angle: index / repeater.count * 360
origin.x: busyRadius
origin.y: busyRadius
}
]
}
}
}
}
}

View File

@ -1,6 +1,5 @@
import QtQuick 2.9
import QtQuick.Controls 2.2
import QtGraphicalEffects 1.0
import TaoQuick 1.0
import "./Page"
@ -8,16 +7,24 @@ Item {
id: rootItem
width: 1440
height: 900
ContentData {
id: gConfig
objectName: "gConfig"
}
AboutDialog {
id: aboutDialog
}
TitlePage {
id: title
width: parent.width
height: 60
color: gConfig.themeColor
}
NotifyBox {
id: notifyBox
}
Rectangle {
id: content
width: parent.width
@ -32,22 +39,5 @@ Item {
top: parent.top
}
}
CusButton_Blue {
text: qsTr("hello")
x: 80
y: 200
width: 120
height: 30
}
CusButton_Blue {
anchors.centerIn: parent
text: qsTr("Chinese")
}
}
DropShadow {
source: rootItem
radius: 8
color: "#007acc"
}
}

View File

@ -7,12 +7,14 @@ MouseArea {
property int lastX: 0
property int lastY: 0
property var control: parent //control parentxy
hoverEnabled: true
signal move(real xOffset, real yOffset)
onContainsPressChanged: {
if (containsPress) {
cursorShape = Qt.SizeAllCursor
lastX = mouseX
lastY = mouseY
} else {
cursorShape = Qt.ArrowCursor
}
}
onPositionChanged: {

View File

@ -13,7 +13,7 @@ Button {
property alias tipTimeout: toolTip.timeout
property bool containsMouse: hovered
property bool containsPressed: pressed
property bool containsPress: pressed
property color backgroundColorNormal
property color backgroundColorHovered
property color backgroundColorPressed