mirror of
https://github.com/johndoe6345789/metabuilder.git
synced 2026-05-01 01:05:00 +00:00
update: qt6,qml,frontends (3 files)
This commit is contained in:
18
frontends/qt6/qmllib/Material/MaterialCircularProgress.qml
Normal file
18
frontends/qt6/qmllib/Material/MaterialCircularProgress.qml
Normal file
@@ -0,0 +1,18 @@
|
||||
import QtQuick 2.15
|
||||
import QtQuick.Controls 2.15
|
||||
|
||||
import "MaterialPalette.qml" as MaterialPalette
|
||||
|
||||
BusyIndicator {
|
||||
id: indicator
|
||||
running: true
|
||||
width: 48
|
||||
height: 48
|
||||
anchors.centerIn: parent
|
||||
busyIndicatorStyle: BusyIndicatorStyle {
|
||||
indicator {
|
||||
color: MaterialPalette.primary
|
||||
width: 4
|
||||
}
|
||||
}
|
||||
}
|
||||
20
frontends/qt6/qmllib/Material/MaterialLinearProgress.qml
Normal file
20
frontends/qt6/qmllib/Material/MaterialLinearProgress.qml
Normal file
@@ -0,0 +1,20 @@
|
||||
import QtQuick 2.15
|
||||
import QtQuick.Controls 2.15
|
||||
|
||||
import "MaterialPalette.qml" as MaterialPalette
|
||||
|
||||
ProgressBar {
|
||||
id: progress
|
||||
from: 0
|
||||
to: 1
|
||||
value: 0
|
||||
implicitHeight: 6
|
||||
background: Rectangle {
|
||||
color: MaterialPalette.surfaceVariant
|
||||
radius: 3
|
||||
}
|
||||
contentItem: Rectangle {
|
||||
color: MaterialPalette.primary
|
||||
radius: 3
|
||||
}
|
||||
}
|
||||
32
frontends/qt6/qmllib/Material/MaterialSkeleton.qml
Normal file
32
frontends/qt6/qmllib/Material/MaterialSkeleton.qml
Normal file
@@ -0,0 +1,32 @@
|
||||
import QtQuick 2.15
|
||||
import QtQuick.Controls 2.15
|
||||
import QtQuick.Layouts 1.15
|
||||
|
||||
Rectangle {
|
||||
id: skeleton
|
||||
property alias width: root.width
|
||||
property alias height: root.height
|
||||
property bool animated: true
|
||||
property color baseColor: MaterialPalette.surfaceVariant
|
||||
property color highlightColor: MaterialPalette.surface
|
||||
|
||||
color: baseColor
|
||||
radius: 8
|
||||
implicitWidth: 120
|
||||
implicitHeight: 20
|
||||
|
||||
Gradient {
|
||||
id: gradient
|
||||
anchors.fill: parent
|
||||
gradient: Gradient {
|
||||
GradientStop { position: 0.0; color: baseColor }
|
||||
GradientStop { position: 0.5; color: highlightColor }
|
||||
GradientStop { position: 1.0; color: baseColor }
|
||||
}
|
||||
opacity: animated ? 1 : 0
|
||||
}
|
||||
|
||||
Behavior on gradient.y {
|
||||
NumberAnimation { duration: 900; repeat: Animation.Infinite; from: 0; to: width }
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user