mirror of
https://invent.kde.org/marcoa/shift-shell.git
synced 2026-04-26 14:23:09 +00:00
Port away from PlasmaCore and PlasmaExtras to Kirigami
See also: https://pointieststick.com/2023/06/14/call-to-action-easy-porting-opportunity-in-plasma/
This commit is contained in:
parent
1512717c0f
commit
127bbdf653
137 changed files with 709 additions and 726 deletions
|
|
@ -10,10 +10,10 @@ import QtQuick.Controls 2.15
|
|||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Window 2.2
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.plasma.private.nanoshell 2.0 as NanoShell
|
||||
import org.kde.plasma.private.mobileshell 1.0 as MobileShell
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import "../components" as Components
|
||||
|
||||
|
|
@ -81,7 +81,7 @@ Item {
|
|||
/**
|
||||
* At some point, even if the screen is technically portrait, if we have a ton of width it'd be best to just show the landscape mode.
|
||||
*/
|
||||
readonly property real largePortraitThreshold: PlasmaCore.Units.gridUnit * 35
|
||||
readonly property real largePortraitThreshold: Kirigami.Units.gridUnit * 35
|
||||
|
||||
enum Mode {
|
||||
Portrait = 0,
|
||||
|
|
@ -167,10 +167,10 @@ Item {
|
|||
|
||||
function updateState() {
|
||||
cancelAnimations();
|
||||
let openThreshold = PlasmaCore.Units.gridUnit;
|
||||
let openThreshold = Kirigami.Units.gridUnit;
|
||||
|
||||
if (root.offset <= 0) {
|
||||
// close immediately, so that we don't have to wait PlasmaCore.Units.longDuration
|
||||
// close immediately, so that we don't have to wait Kirigami.Units.longDuration
|
||||
root.visible = false;
|
||||
close();
|
||||
} else if (root.direction === MobileShell.Direction.None || !root.opened) {
|
||||
|
|
@ -206,7 +206,7 @@ Item {
|
|||
|
||||
PropertyAnimation on offset {
|
||||
id: closeAnim
|
||||
duration: PlasmaCore.Units.veryLongDuration
|
||||
duration: Kirigami.Units.veryLongDuration
|
||||
easing.type: Easing.OutExpo
|
||||
to: 0
|
||||
onFinished: {
|
||||
|
|
@ -216,14 +216,14 @@ Item {
|
|||
}
|
||||
PropertyAnimation on offset {
|
||||
id: openAnim
|
||||
duration: PlasmaCore.Units.veryLongDuration
|
||||
duration: Kirigami.Units.veryLongDuration
|
||||
easing.type: Easing.OutExpo
|
||||
to: contentContainerLoader.minimizedQuickSettingsOffset
|
||||
onFinished: root.opened = true
|
||||
}
|
||||
PropertyAnimation on offset {
|
||||
id: expandAnim
|
||||
duration: PlasmaCore.Units.veryLongDuration
|
||||
duration: Kirigami.Units.veryLongDuration
|
||||
easing.type: Easing.OutExpo
|
||||
to: contentContainerLoader.maximizedQuickSettingsOffset
|
||||
onFinished: root.opened = true;
|
||||
|
|
|
|||
|
|
@ -9,7 +9,6 @@ import QtQuick.Controls 2.15
|
|||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Window 2.2
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.plasma.private.nanoshell 2.0 as NanoShell
|
||||
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ import "quicksettings"
|
|||
/**
|
||||
* Root element that contains all of the ActionDrawer's contents, and is anchored to the screen.
|
||||
*/
|
||||
PlasmaCore.ColorScope {
|
||||
Item {
|
||||
id: root
|
||||
|
||||
required property var actionDrawer
|
||||
|
|
@ -37,18 +37,19 @@ PlasmaCore.ColorScope {
|
|||
readonly property real minWidthHeight: Math.min(root.width, root.height)
|
||||
readonly property real opacityValue: Math.max(0, Math.min(1, actionDrawer.offset / root.minimizedQuickSettingsOffset))
|
||||
|
||||
colorGroup: PlasmaCore.Theme.ViewColorGroup
|
||||
Kirigami.Theme.colorSet: Kirigami.Theme.View
|
||||
Kirigami.Theme.inherit: false
|
||||
|
||||
// fullscreen background
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
|
||||
// darken if there are notifications
|
||||
color: Qt.rgba(PlasmaCore.Theme.backgroundColor.r,
|
||||
PlasmaCore.Theme.backgroundColor.g,
|
||||
PlasmaCore.Theme.backgroundColor.b,
|
||||
color: Qt.rgba(Kirigami.Theme.backgroundColor.r,
|
||||
Kirigami.Theme.backgroundColor.g,
|
||||
Kirigami.Theme.backgroundColor.b,
|
||||
notificationWidget.hasNotifications ? 0.95 : 0.9)
|
||||
Behavior on color { ColorAnimation { duration: PlasmaCore.Units.longDuration } }
|
||||
Behavior on color { ColorAnimation { duration: Kirigami.Units.longDuration } }
|
||||
opacity: opacityValue
|
||||
}
|
||||
|
||||
|
|
@ -101,7 +102,7 @@ PlasmaCore.ColorScope {
|
|||
onBackgroundClicked: root.actionDrawer.close();
|
||||
|
||||
// don't allow notifications widget to get too wide
|
||||
Layout.maximumWidth: PlasmaCore.Units.gridUnit * 25
|
||||
Layout.maximumWidth: Kirigami.Units.gridUnit * 25
|
||||
Layout.fillHeight: true
|
||||
Layout.fillWidth: true
|
||||
Layout.topMargin: minWidthHeight * 0.02
|
||||
|
|
@ -137,7 +138,7 @@ PlasmaCore.ColorScope {
|
|||
left: parent.left
|
||||
top: clock.bottom
|
||||
bottom: isOnLargeScreen ? columnLayout.top : mediaWidget.top
|
||||
topMargin: PlasmaCore.Units.smallSpacing
|
||||
topMargin: Kirigami.Units.smallSpacing
|
||||
leftMargin: columnLayout.anchors.margins
|
||||
}
|
||||
|
||||
|
|
@ -147,7 +148,7 @@ PlasmaCore.ColorScope {
|
|||
|
||||
MediaControls.MediaControlsWidget {
|
||||
id: mediaWidget
|
||||
property real fullHeight: visible ? height + PlasmaCore.Units.smallSpacing * 6 : 0
|
||||
property real fullHeight: visible ? height + Kirigami.Units.smallSpacing * 6 : 0
|
||||
|
||||
y: isOnLargeScreen ? date.y - height + date.implicitHeight : date.y + date.implicitHeight + columnLayout.anchors.margins / 2
|
||||
|
||||
|
|
|
|||
|
|
@ -9,8 +9,8 @@ import QtQuick.Controls 2.15
|
|||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Window 2.2
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import "../components" as Components
|
||||
import "../widgets/notifications" as Notifications
|
||||
|
|
@ -19,7 +19,7 @@ import "quicksettings"
|
|||
/**
|
||||
* Root element that contains all of the ActionDrawer's contents, and is anchored to the screen.
|
||||
*/
|
||||
PlasmaCore.ColorScope {
|
||||
Item {
|
||||
id: root
|
||||
|
||||
required property var actionDrawer
|
||||
|
|
@ -32,7 +32,8 @@ PlasmaCore.ColorScope {
|
|||
// fully open position
|
||||
readonly property real maximizedQuickSettingsOffset: minimizedQuickSettingsOffset + quickSettings.maxAddedHeight
|
||||
|
||||
colorGroup: PlasmaCore.Theme.ViewColorGroup
|
||||
Kirigami.Theme.colorSet: Kirigami.Theme.View
|
||||
Kirigami.Theme.inherit: false
|
||||
|
||||
function applyMinMax(val) {
|
||||
return Math.max(0, Math.min(1, val));
|
||||
|
|
@ -42,11 +43,11 @@ PlasmaCore.ColorScope {
|
|||
Rectangle {
|
||||
anchors.fill: parent
|
||||
// darken if there are notifications
|
||||
color: Qt.rgba(PlasmaCore.Theme.backgroundColor.r,
|
||||
PlasmaCore.Theme.backgroundColor.g,
|
||||
PlasmaCore.Theme.backgroundColor.b,
|
||||
color: Qt.rgba(Kirigami.Theme.backgroundColor.r,
|
||||
Kirigami.Theme.backgroundColor.g,
|
||||
Kirigami.Theme.backgroundColor.b,
|
||||
0.95)
|
||||
Behavior on color { ColorAnimation { duration: PlasmaCore.Units.longDuration } }
|
||||
Behavior on color { ColorAnimation { duration: Kirigami.Units.longDuration } }
|
||||
opacity: Math.max(0, Math.min(1, actionDrawer.offset / root.minimizedQuickSettingsOffset))
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -83,7 +83,7 @@ Item {
|
|||
|
||||
RowLayout {
|
||||
id: brightnessRow
|
||||
spacing: PlasmaCore.Units.smallSpacing * 2
|
||||
spacing: Kirigami.Units.smallSpacing * 2
|
||||
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
|
|
@ -91,8 +91,8 @@ Item {
|
|||
|
||||
PlasmaCore.IconItem {
|
||||
Layout.alignment: Qt.AlignVCenter
|
||||
Layout.leftMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.preferredWidth: PlasmaCore.Units.iconSizes.smallMedium
|
||||
Layout.leftMargin: Kirigami.Units.smallSpacing
|
||||
Layout.preferredWidth: Kirigami.Units.iconSizes.smallMedium
|
||||
Layout.preferredHeight: width
|
||||
source: "low-brightness"
|
||||
}
|
||||
|
|
@ -123,8 +123,8 @@ Item {
|
|||
|
||||
PlasmaCore.IconItem {
|
||||
Layout.alignment: Qt.AlignVCenter
|
||||
Layout.rightMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.preferredWidth: PlasmaCore.Units.iconSizes.smallMedium
|
||||
Layout.rightMargin: Kirigami.Units.smallSpacing
|
||||
Layout.preferredWidth: Kirigami.Units.iconSizes.smallMedium
|
||||
Layout.preferredHeight: width
|
||||
source: "high-brightness"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -6,17 +6,17 @@
|
|||
|
||||
import QtQuick 2.15
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
Rectangle {
|
||||
id: handle
|
||||
|
||||
signal tapped()
|
||||
|
||||
implicitWidth: PlasmaCore.Units.gridUnit * 3
|
||||
implicitWidth: Kirigami.Units.gridUnit * 3
|
||||
implicitHeight: 3
|
||||
radius: height
|
||||
color: PlasmaCore.Theme.textColor
|
||||
color: Kirigami.Theme.textColor
|
||||
opacity: 0.5
|
||||
|
||||
TapHandler {
|
||||
|
|
|
|||
|
|
@ -10,9 +10,9 @@ import QtQuick.Controls 2.15
|
|||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Window 2.2
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.plasma.private.mobileshell.quicksettingsplugin as QS
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import "../../components" as Components
|
||||
import "../../components/util.js" as Util
|
||||
|
|
@ -41,8 +41,8 @@ Item {
|
|||
readonly property real fullHeight: fullView.implicitHeight
|
||||
|
||||
readonly property real intendedColumnWidth: 120
|
||||
readonly property real intendedMinimizedColumnWidth: PlasmaCore.Units.gridUnit * 3 + PlasmaCore.Units.largeSpacing
|
||||
readonly property real minimizedRowHeight: PlasmaCore.Units.gridUnit * 3 + PlasmaCore.Units.largeSpacing
|
||||
readonly property real intendedMinimizedColumnWidth: Kirigami.Units.gridUnit * 3 + Kirigami.Units.gridUnit
|
||||
readonly property real minimizedRowHeight: Kirigami.Units.gridUnit * 3 + Kirigami.Units.gridUnit
|
||||
|
||||
property real minimizedViewProgress: 0
|
||||
property real fullViewProgress: 1
|
||||
|
|
@ -110,9 +110,9 @@ Item {
|
|||
|
||||
BrightnessItem {
|
||||
id: brightnessItem
|
||||
Layout.bottomMargin: PlasmaCore.Units.smallSpacing * 2
|
||||
Layout.leftMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.rightMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.bottomMargin: Kirigami.Units.smallSpacing * 2
|
||||
Layout.leftMargin: Kirigami.Units.smallSpacing
|
||||
Layout.rightMargin: Kirigami.Units.smallSpacing
|
||||
Layout.fillWidth: true
|
||||
}
|
||||
}
|
||||
|
|
@ -139,8 +139,8 @@ Item {
|
|||
|
||||
implicitHeight: root.minimizedRowHeight
|
||||
implicitWidth: root.minimizedColumnWidth
|
||||
horizontalPadding: (width - PlasmaCore.Units.gridUnit * 3) / 2
|
||||
verticalPadding: (height - PlasmaCore.Units.gridUnit * 3) / 2
|
||||
horizontalPadding: (width - Kirigami.Units.gridUnit * 3) / 2
|
||||
verticalPadding: (height - Kirigami.Units.gridUnit * 3) / 2
|
||||
|
||||
contentItem: QuickSettingsMinimizedDelegate {
|
||||
restrictedPermissions: actionDrawer.restrictedPermissions
|
||||
|
|
@ -203,9 +203,9 @@ Item {
|
|||
id: indicatorLoader
|
||||
|
||||
Layout.alignment: Qt.AlignCenter
|
||||
Layout.topMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.leftMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.rightMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.topMargin: Kirigami.Units.smallSpacing
|
||||
Layout.leftMargin: Kirigami.Units.smallSpacing
|
||||
Layout.rightMargin: Kirigami.Units.smallSpacing
|
||||
|
||||
// Avoid wasting space when not loaded
|
||||
Layout.maximumHeight: active ? item.implicitHeight : 0
|
||||
|
|
@ -222,7 +222,7 @@ Item {
|
|||
implicitHeight: count > 1 ? 8 : 0
|
||||
|
||||
radius: parent.width / 2
|
||||
color: PlasmaCore.Theme.disabledTextColor
|
||||
color: Kirigami.Theme.disabledTextColor
|
||||
|
||||
opacity: index === currentIndex ? 0.95 : 0.45
|
||||
}
|
||||
|
|
@ -253,14 +253,14 @@ Item {
|
|||
position: 0.1
|
||||
|
||||
contentItem: Item {
|
||||
implicitWidth: PlasmaCore.Units.smallSpacing / 4
|
||||
implicitWidth: Kirigami.Units.smallSpacing / 4
|
||||
Rectangle {
|
||||
// shift over the indicator a bit to the right
|
||||
anchors.fill: parent
|
||||
anchors.leftMargin: 2
|
||||
anchors.rightMargin: -2
|
||||
|
||||
color: PlasmaCore.Theme.textColor
|
||||
color: Kirigami.Theme.textColor
|
||||
opacity: scrollIndicator.active ? 0.5 : 0
|
||||
|
||||
Behavior on opacity { NumberAnimation {} }
|
||||
|
|
@ -296,7 +296,7 @@ Item {
|
|||
Components.BaseItem {
|
||||
height: root.rowHeight
|
||||
width: root.columnWidth
|
||||
padding: PlasmaCore.Units.smallSpacing
|
||||
padding: Kirigami.Units.smallSpacing
|
||||
|
||||
contentItem: QuickSettingsFullDelegate {
|
||||
restrictedPermissions: actionDrawer.restrictedPermissions
|
||||
|
|
|
|||
|
|
@ -37,10 +37,10 @@ Components.BaseItem {
|
|||
property var iconItem
|
||||
|
||||
readonly property color enabledButtonBorderColor: Qt.darker(PlasmaCore.ColorScope.highlightColor, 1.25)
|
||||
readonly property color disabledButtonBorderColor: Kirigami.ColorUtils.tintWithAlpha(PlasmaCore.ColorScope.textColor, PlasmaCore.ColorScope.backgroundColor, 0.75)
|
||||
readonly property color enabledButtonColor: Kirigami.ColorUtils.tintWithAlpha(PlasmaCore.ColorScope.highlightColor, PlasmaCore.ColorScope.backgroundColor, 0.6)
|
||||
readonly property color enabledButtonPressedColor: Kirigami.ColorUtils.tintWithAlpha(PlasmaCore.ColorScope.highlightColor, PlasmaCore.ColorScope.backgroundColor, 0.4);
|
||||
readonly property color disabledButtonColor: PlasmaCore.Theme.backgroundColor
|
||||
readonly property color disabledButtonBorderColor: Kirigami.ColorUtils.tintWithAlpha(Kirigami.Theme.textColor, Kirigami.Theme.backgroundColor, 0.75)
|
||||
readonly property color enabledButtonColor: Kirigami.ColorUtils.tintWithAlpha(PlasmaCore.ColorScope.highlightColor, Kirigami.Theme.backgroundColor, 0.6)
|
||||
readonly property color enabledButtonPressedColor: Kirigami.ColorUtils.tintWithAlpha(PlasmaCore.ColorScope.highlightColor, Kirigami.Theme.backgroundColor, 0.4);
|
||||
readonly property color disabledButtonColor: Kirigami.Theme.backgroundColor
|
||||
readonly property color disabledButtonPressedColor: Qt.darker(disabledButtonColor, 1.1)
|
||||
|
||||
// scale animation on press
|
||||
|
|
|
|||
|
|
@ -45,7 +45,7 @@ Components.BaseItem {
|
|||
/**
|
||||
* Height of just the QuickSettings component in minimized mode.
|
||||
*/
|
||||
readonly property real minimizedQuickSettingsHeight: quickSettings.minimizedRowHeight + PlasmaCore.Units.gridUnit
|
||||
readonly property real minimizedQuickSettingsHeight: quickSettings.minimizedRowHeight + Kirigami.Units.gridUnit
|
||||
|
||||
/**
|
||||
* Progress of showing the full quick settings view from pinned.
|
||||
|
|
@ -53,10 +53,10 @@ Components.BaseItem {
|
|||
property real minimizedToFullProgress: 1
|
||||
|
||||
// we need extra padding if the background side border is enabled
|
||||
topPadding: PlasmaCore.Units.smallSpacing
|
||||
leftPadding: PlasmaCore.Units.smallSpacing
|
||||
rightPadding: PlasmaCore.Units.smallSpacing
|
||||
bottomPadding: PlasmaCore.Units.smallSpacing * 4
|
||||
topPadding: Kirigami.Units.smallSpacing
|
||||
leftPadding: Kirigami.Units.smallSpacing
|
||||
rightPadding: Kirigami.Units.smallSpacing
|
||||
bottomPadding: Kirigami.Units.smallSpacing * 4
|
||||
|
||||
background: KSvg.FrameSvgItem {
|
||||
enabledBorders: PlasmaCore.FrameSvg.BottomBorder
|
||||
|
|
@ -78,9 +78,9 @@ Components.BaseItem {
|
|||
StatusBar.StatusBar {
|
||||
id: statusBar
|
||||
Layout.fillWidth: true
|
||||
Layout.preferredHeight: Components.Constants.topPanelHeight + PlasmaCore.Units.gridUnit * 0.8
|
||||
Layout.preferredHeight: Components.Constants.topPanelHeight + Kirigami.Units.gridUnit * 0.8
|
||||
|
||||
colorGroup: PlasmaCore.Theme.NormalColorGroup
|
||||
colorGroup: Kirigami.Theme.Window
|
||||
backgroundColor: "transparent"
|
||||
showSecondRow: true
|
||||
showDropShadow: false
|
||||
|
|
@ -92,7 +92,7 @@ Components.BaseItem {
|
|||
QuickSettings {
|
||||
id: quickSettings
|
||||
Layout.preferredHeight: root.minimizedQuickSettingsHeight + root.addedHeight
|
||||
Layout.topMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.topMargin: Kirigami.Units.smallSpacing
|
||||
Layout.fillWidth: true
|
||||
|
||||
mode: QuickSettings.Pages
|
||||
|
|
@ -107,16 +107,16 @@ Components.BaseItem {
|
|||
id: mediaWidget
|
||||
property real fullHeight: height + Layout.topMargin
|
||||
Layout.fillWidth: true
|
||||
Layout.topMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.leftMargin: Kirigami.Units.largeSpacing
|
||||
Layout.rightMargin: Kirigami.Units.largeSpacing
|
||||
Layout.topMargin: Kirigami.Units.smallSpacing
|
||||
Layout.leftMargin: Kirigami.Units.gridUnit
|
||||
Layout.rightMargin: Kirigami.Units.gridUnit
|
||||
}
|
||||
|
||||
Handle {
|
||||
id: handle
|
||||
property real fullHeight: height + Layout.topMargin
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
Layout.topMargin: PlasmaCore.Units.smallSpacing * 2
|
||||
Layout.topMargin: Kirigami.Units.smallSpacing * 2
|
||||
|
||||
onTapped: {
|
||||
if (root.minimizedToFullProgress < 0.5) {
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ import "../../components" as Components
|
|||
QuickSettingsDelegate {
|
||||
id: root
|
||||
|
||||
padding: PlasmaCore.Units.smallSpacing * 2
|
||||
padding: Kirigami.Units.smallSpacing * 2
|
||||
iconItem: icon
|
||||
|
||||
// scale animation on press
|
||||
|
|
@ -34,14 +34,14 @@ QuickSettingsDelegate {
|
|||
anchors.right: parent.right
|
||||
height: parent.height
|
||||
|
||||
radius: PlasmaCore.Units.smallSpacing
|
||||
radius: Kirigami.Units.smallSpacing
|
||||
color: Qt.rgba(0, 0, 0, 0.075)
|
||||
}
|
||||
|
||||
// background color
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
radius: PlasmaCore.Units.smallSpacing
|
||||
radius: Kirigami.Units.smallSpacing
|
||||
border.width: 1
|
||||
border.color: root.enabled ? root.enabledButtonBorderColor : root.disabledButtonBorderColor
|
||||
color: {
|
||||
|
|
@ -74,14 +74,14 @@ QuickSettingsDelegate {
|
|||
id: icon
|
||||
anchors.top: parent.top
|
||||
anchors.left: parent.left
|
||||
implicitWidth: PlasmaCore.Units.iconSizes.small
|
||||
implicitWidth: Kirigami.Units.iconSizes.small
|
||||
implicitHeight: width
|
||||
source: root.icon
|
||||
}
|
||||
|
||||
ColumnLayout {
|
||||
id: column
|
||||
spacing: PlasmaCore.Units.smallSpacing
|
||||
spacing: Kirigami.Units.smallSpacing
|
||||
anchors.right: parent.right
|
||||
anchors.left: parent.left
|
||||
anchors.bottom: parent.bottom
|
||||
|
|
@ -90,7 +90,7 @@ QuickSettingsDelegate {
|
|||
Layout.fillWidth: true
|
||||
elide: Text.ElideRight
|
||||
text: root.text
|
||||
font.pointSize: PlasmaCore.Theme.defaultFont.pointSize * 0.75 // TODO base height off of size of delegate
|
||||
font.pointSize: Kirigami.Theme.defaultFont.pointSize * 0.75 // TODO base height off of size of delegate
|
||||
font.weight: Font.Bold
|
||||
}
|
||||
|
||||
|
|
@ -100,7 +100,7 @@ QuickSettingsDelegate {
|
|||
opacity: 0.6
|
||||
|
||||
Layout.fillWidth: true
|
||||
font.pointSize: PlasmaCore.Theme.defaultFont.pointSize * 0.75
|
||||
font.pointSize: Kirigami.Theme.defaultFont.pointSize * 0.75
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -33,14 +33,14 @@ QuickSettingsDelegate {
|
|||
anchors.right: parent.right
|
||||
height: parent.height
|
||||
|
||||
radius: PlasmaCore.Units.smallSpacing
|
||||
radius: Kirigami.Units.smallSpacing
|
||||
color: Qt.rgba(0, 0, 0, 0.075)
|
||||
}
|
||||
|
||||
// background
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
radius: PlasmaCore.Units.smallSpacing
|
||||
radius: Kirigami.Units.smallSpacing
|
||||
border.color: root.enabled ? root.enabledButtonBorderColor : root.disabledButtonBorderColor
|
||||
color: {
|
||||
if (root.enabled) {
|
||||
|
|
@ -71,7 +71,7 @@ QuickSettingsDelegate {
|
|||
PlasmaCore.IconItem {
|
||||
id: icon
|
||||
anchors.centerIn: parent
|
||||
implicitWidth: PlasmaCore.Units.iconSizes.smallMedium
|
||||
implicitWidth: Kirigami.Units.iconSizes.smallMedium
|
||||
implicitHeight: width
|
||||
source: root.icon
|
||||
}
|
||||
|
|
|
|||
|
|
@ -34,10 +34,10 @@ Components.BaseItem {
|
|||
readonly property real contentImplicitHeight: column.implicitHeight
|
||||
|
||||
// we need extra padding since the background side border is enabled
|
||||
topPadding: PlasmaCore.Units.smallSpacing * 4
|
||||
leftPadding: PlasmaCore.Units.smallSpacing * 4
|
||||
rightPadding: PlasmaCore.Units.smallSpacing * 4
|
||||
bottomPadding: PlasmaCore.Units.smallSpacing * 4
|
||||
topPadding: Kirigami.Units.smallSpacing * 4
|
||||
leftPadding: Kirigami.Units.smallSpacing * 4
|
||||
rightPadding: Kirigami.Units.smallSpacing * 4
|
||||
bottomPadding: Kirigami.Units.smallSpacing * 4
|
||||
|
||||
background: KSvg.FrameSvgItem {
|
||||
enabledBorders: PlasmaCore.FrameSvg.AllBorders
|
||||
|
|
@ -63,7 +63,7 @@ Components.BaseItem {
|
|||
Layout.preferredHeight: Kirigami.Units.gridUnit * 1.5
|
||||
Layout.maximumHeight: Kirigami.Units.gridUnit * 1.5
|
||||
|
||||
colorGroup: PlasmaCore.Theme.NormalColorGroup
|
||||
colorGroup: Kirigami.Theme.Window
|
||||
backgroundColor: "transparent"
|
||||
showSecondRow: false
|
||||
showDropShadow: false
|
||||
|
|
@ -82,7 +82,7 @@ Components.BaseItem {
|
|||
|
||||
Layout.alignment: Qt.AlignTop
|
||||
Layout.fillWidth: true
|
||||
Layout.maximumHeight: root.fullScreenHeight - root.topPadding - root.bottomPadding - statusBar.height - PlasmaCore.Units.smallSpacing
|
||||
Layout.maximumHeight: root.fullScreenHeight - root.topPadding - root.bottomPadding - statusBar.height - Kirigami.Units.smallSpacing
|
||||
Layout.maximumWidth: column.width
|
||||
|
||||
actionDrawer: root.actionDrawer
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
import QtQuick
|
||||
|
||||
import org.kde.plasma.core as PlasmaCore
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
import org.kde.plasma.private.mobileshell.shellsettingsplugin as ShellSettings
|
||||
|
||||
// NOTE: This is a singleton in the mobileshell library, so we need to be careful to
|
||||
|
|
@ -12,6 +12,6 @@ import org.kde.plasma.private.mobileshell.shellsettingsplugin as ShellSettings
|
|||
pragma Singleton
|
||||
|
||||
QtObject {
|
||||
readonly property real topPanelHeight: PlasmaCore.Units.gridUnit + PlasmaCore.Units.smallSpacing
|
||||
readonly property real bottomPanelHeight: ShellSettings.Settings.navigationPanelEnabled ? PlasmaCore.Units.gridUnit * 2 : 0
|
||||
readonly property real topPanelHeight: Kirigami.Units.gridUnit + Kirigami.Units.smallSpacing
|
||||
readonly property real bottomPanelHeight: ShellSettings.Settings.navigationPanelEnabled ? Kirigami.Units.gridUnit * 2 : 0
|
||||
}
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
import QtQuick 2.15
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
|
||||
/**
|
||||
|
|
@ -16,7 +16,7 @@ PlasmaComponents.Label {
|
|||
required property string inputText
|
||||
readonly property string filteredText: inputText.replace(/\n/g, ' ') // remove new line characters
|
||||
|
||||
property int interval: PlasmaCore.Units.longDuration
|
||||
property int interval: Kirigami.Units.longDuration
|
||||
|
||||
readonly property int charactersOverflow: Math.ceil((txtMeter.advanceWidth - root.width) / (txtMeter.advanceWidth / filteredText.length))
|
||||
property int step: 0
|
||||
|
|
@ -36,7 +36,7 @@ PlasmaComponents.Label {
|
|||
onTriggered: {
|
||||
if (paused) {
|
||||
if (step != 0) {
|
||||
interval = PlasmaCore.Units.veryLongDuration;
|
||||
interval = Kirigami.Units.veryLongDuration;
|
||||
step = 0;
|
||||
} else {
|
||||
interval = root.interval;
|
||||
|
|
@ -45,7 +45,7 @@ PlasmaComponents.Label {
|
|||
} else {
|
||||
step = (step + 1) % filteredText.length;
|
||||
if (step === charactersOverflow) {
|
||||
interval = PlasmaCore.Units.veryLongDuration * 3;
|
||||
interval = Kirigami.Units.veryLongDuration * 3;
|
||||
paused = true;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -93,7 +93,7 @@ MouseArea { // use mousearea to ensure clicks don't go behind
|
|||
|
||||
ParallelAnimation {
|
||||
id: parallelAnim
|
||||
property real animationDuration: PlasmaCore.Units.longDuration + PlasmaCore.Units.shortDuration
|
||||
property real animationDuration: Kirigami.Units.longDuration + Kirigami.Units.shortDuration
|
||||
|
||||
ScaleAnimator {
|
||||
target: background
|
||||
|
|
@ -153,7 +153,7 @@ MouseArea { // use mousearea to ensure clicks don't go behind
|
|||
properties: "opacity"
|
||||
from: 0
|
||||
to: 1
|
||||
duration: PlasmaCore.Units.longDuration
|
||||
duration: Kirigami.Units.longDuration
|
||||
easing.type: Easing.OutCubic
|
||||
}
|
||||
|
||||
|
|
@ -180,13 +180,13 @@ MouseArea { // use mousearea to ensure clicks don't go behind
|
|||
Item {
|
||||
id: iconParent
|
||||
anchors.centerIn: background
|
||||
width: PlasmaCore.Units.iconSizes.enormous
|
||||
width: Kirigami.Units.iconSizes.enormous
|
||||
height: width
|
||||
|
||||
PlasmaCore.IconItem {
|
||||
id: icon
|
||||
anchors.fill: parent
|
||||
colorGroup: PlasmaCore.Theme.ComplementaryColorGroup
|
||||
colorGroup: Kirigami.Theme.ComplementaryColorGroup
|
||||
}
|
||||
|
||||
MultiEffect {
|
||||
|
|
|
|||
|
|
@ -8,7 +8,6 @@
|
|||
import QtQuick
|
||||
import QtQuick.Layouts
|
||||
|
||||
import org.kde.plasma.core as PlasmaCore
|
||||
import org.kde.plasma.plasma5support as P5Support
|
||||
import org.kde.plasma.workspace.components as PW
|
||||
|
||||
|
|
|
|||
|
|
@ -8,7 +8,6 @@
|
|||
|
||||
import QtQuick 2.2
|
||||
import QtQuick.Layouts 1.4
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.bluezqt 1.0 as BluezQt
|
||||
|
||||
QtObject {
|
||||
|
|
|
|||
|
|
@ -4,7 +4,6 @@
|
|||
import QtQuick
|
||||
import QtQuick.Window
|
||||
|
||||
import org.kde.plasma.core as PlasmaCore
|
||||
import org.kde.plasma.plasmoid
|
||||
import org.kde.taskmanager as TaskManager
|
||||
|
||||
|
|
|
|||
|
|
@ -10,8 +10,8 @@ import QtQuick.Layouts
|
|||
import QtQuick.Window
|
||||
import QtQuick.Effects
|
||||
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
import org.kde.taskmanager 0.1 as TaskManager
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.kquickcontrolsaddons 2.0
|
||||
|
||||
import org.kde.plasma.private.mobileshell.state 1.0 as MobileShellState
|
||||
|
|
@ -120,7 +120,7 @@ Item {
|
|||
when: root.width < root.height
|
||||
PropertyChanges {
|
||||
target: icons
|
||||
buttonLength: Math.min(PlasmaCore.Units.gridUnit * 10, icons.height * 0.7 / 3)
|
||||
buttonLength: Math.min(Kirigami.Units.gridUnit * 10, icons.height * 0.7 / 3)
|
||||
}
|
||||
AnchorChanges {
|
||||
target: leftButton
|
||||
|
|
@ -160,7 +160,7 @@ Item {
|
|||
}
|
||||
PropertyChanges {
|
||||
target: rightCornerButton
|
||||
height: PlasmaCore.Units.gridUnit * 2
|
||||
height: Kirigami.Units.gridUnit * 2
|
||||
width: icons.width
|
||||
}
|
||||
}, State {
|
||||
|
|
@ -168,7 +168,7 @@ Item {
|
|||
when: root.width >= root.height
|
||||
PropertyChanges {
|
||||
target: icons
|
||||
buttonLength: Math.min(PlasmaCore.Units.gridUnit * 8, icons.width * 0.7 / 3)
|
||||
buttonLength: Math.min(Kirigami.Units.gridUnit * 8, icons.width * 0.7 / 3)
|
||||
}
|
||||
AnchorChanges {
|
||||
target: leftButton
|
||||
|
|
@ -209,7 +209,7 @@ Item {
|
|||
PropertyChanges {
|
||||
target: rightCornerButton
|
||||
height: parent.height
|
||||
width: PlasmaCore.Units.gridUnit * 2
|
||||
width: Kirigami.Units.gridUnit * 2
|
||||
}
|
||||
}
|
||||
]
|
||||
|
|
|
|||
|
|
@ -10,6 +10,7 @@ import QtQuick.Layouts
|
|||
import QtQuick.Controls as Controls
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
import org.kde.kquickcontrolsaddons 2.0
|
||||
|
||||
Controls.AbstractButton {
|
||||
|
|
@ -26,7 +27,7 @@ Controls.AbstractButton {
|
|||
radius: height/2
|
||||
anchors.fill: parent
|
||||
opacity: 0
|
||||
color: PlasmaCore.ColorScope.textColor
|
||||
color: Kirigami.Theme.textColor
|
||||
|
||||
// this way of calculating animations lets the animation fully complete before switching back (tap runs the full animation)
|
||||
property bool buttonHeld: button.pressed && button.enabled
|
||||
|
|
@ -49,7 +50,7 @@ Controls.AbstractButton {
|
|||
}
|
||||
NumberAnimation on opacity {
|
||||
id: opacityAnimator
|
||||
duration: PlasmaCore.Units.shortDuration
|
||||
duration: Kirigami.Units.shortDuration
|
||||
easing.type: Easing.InOutQuad
|
||||
onFinished: {
|
||||
// animate the state back
|
||||
|
|
@ -69,6 +70,6 @@ Controls.AbstractButton {
|
|||
fill: parent
|
||||
margins: Math.round((side - side * iconSizeFactor * 0.6) / 2)
|
||||
}
|
||||
colorGroup: PlasmaCore.ColorScope.colorGroup
|
||||
colorSet: Kirigami.Theme.colorSet
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -8,7 +8,6 @@
|
|||
import QtQuick 2.12
|
||||
import QtQuick.Layouts 1.15
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.plasma5support 2.0 as P5Support
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.plasma.private.mobileshell 1.0 as MobileShell
|
||||
|
|
@ -23,6 +22,6 @@ PlasmaComponents.Label {
|
|||
property bool is24HourTime: MobileShell.ShellUtil.isSystem24HourFormat
|
||||
|
||||
text: Qt.formatTime(source.data.Local.DateTime, is24HourTime ? "h:mm" : "h:mm ap")
|
||||
color: PlasmaCore.ColorScope.textColor
|
||||
color: Kirigami.Theme.textColor
|
||||
verticalAlignment: Qt.AlignVCenter
|
||||
}
|
||||
|
|
|
|||
|
|
@ -12,6 +12,8 @@ import QtQuick.Effects
|
|||
import QtQuick.Controls as Controls
|
||||
import QtQml.Models
|
||||
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.plasma5support 2.0 as P5Support
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
|
|
@ -57,7 +59,7 @@ Item {
|
|||
|
||||
readonly property real textPixelSize: 11
|
||||
readonly property real smallerTextPixelSize: 9
|
||||
readonly property real elementSpacing: PlasmaCore.Units.smallSpacing * 1.5
|
||||
readonly property real elementSpacing: Kirigami.Units.smallSpacing * 1.5
|
||||
|
||||
P5Support.DataSource {
|
||||
id: timeSource
|
||||
|
|
@ -97,18 +99,19 @@ Item {
|
|||
}
|
||||
|
||||
// screen top panel
|
||||
PlasmaCore.ColorScope {
|
||||
Item {
|
||||
id: icons
|
||||
z: 1
|
||||
colorGroup: root.colorGroup
|
||||
Kirigami.Theme.colorSet: root.Kirigami.Theme.colorSet
|
||||
Kirigami.Theme.inherit: false
|
||||
anchors.fill: parent
|
||||
|
||||
Controls.Control {
|
||||
id: control
|
||||
topPadding: PlasmaCore.Units.smallSpacing
|
||||
bottomPadding: PlasmaCore.Units.smallSpacing
|
||||
rightPadding: PlasmaCore.Units.smallSpacing * 3
|
||||
leftPadding: PlasmaCore.Units.smallSpacing * 3
|
||||
topPadding: Kirigami.Units.smallSpacing
|
||||
bottomPadding: Kirigami.Units.smallSpacing
|
||||
rightPadding: Kirigami.Units.smallSpacing * 3
|
||||
leftPadding: Kirigami.Units.smallSpacing * 3
|
||||
|
||||
anchors.fill: parent
|
||||
background: Rectangle {
|
||||
|
|
@ -116,7 +119,7 @@ Item {
|
|||
}
|
||||
|
||||
contentItem: ColumnLayout {
|
||||
spacing: PlasmaCore.Units.smallSpacing / 2
|
||||
spacing: Kirigami.Units.smallSpacing / 2
|
||||
|
||||
RowLayout {
|
||||
id: row
|
||||
|
|
@ -163,7 +166,7 @@ Item {
|
|||
// system indicators
|
||||
RowLayout {
|
||||
id: indicators
|
||||
Layout.leftMargin: PlasmaCore.Units.smallSpacing // applets have different spacing needs
|
||||
Layout.leftMargin: Kirigami.Units.smallSpacing // applets have different spacing needs
|
||||
Layout.fillHeight: true
|
||||
spacing: root.elementSpacing
|
||||
|
||||
|
|
|
|||
|
|
@ -6,6 +6,7 @@
|
|||
|
||||
import QtQuick 2.1
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
Item {
|
||||
id: taskIcon
|
||||
|
|
@ -28,7 +29,7 @@ Item {
|
|||
width: Math.min(parent.width, parent.height)
|
||||
height: width
|
||||
anchors.centerIn: parent
|
||||
colorGroup: PlasmaCore.ColorScope.colorGroup
|
||||
colorSet: Kirigami.Theme.colorSet
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
|
|
|
|||
|
|
@ -8,7 +8,8 @@
|
|||
import QtQuick 2.6
|
||||
import QtQuick.Layouts 1.4
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.plasma.workspace.components 2.0 as PW
|
||||
|
||||
|
|
@ -16,7 +17,7 @@ import "../../dataproviders" as DataProviders
|
|||
|
||||
RowLayout {
|
||||
readonly property var provider: DataProviders.BatteryInfo {}
|
||||
property real textPixelSize: PlasmaCore.Units.gridUnit * 0.6
|
||||
property real textPixelSize: Kirigami.Units.gridUnit * 0.6
|
||||
|
||||
visible: provider.isVisible
|
||||
|
||||
|
|
@ -37,7 +38,7 @@ RowLayout {
|
|||
text: i18n("%1%", provider.percent)
|
||||
Layout.alignment: Qt.AlignVCenter
|
||||
|
||||
color: PlasmaCore.ColorScope.textColor
|
||||
color: Kirigami.Theme.textColor
|
||||
font.pixelSize: textPixelSize
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -10,6 +10,7 @@ import QtQuick
|
|||
import QtQuick.Layouts
|
||||
|
||||
import org.kde.plasma.core as PlasmaCore
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
import org.kde.bluezqt as BluezQt
|
||||
|
||||
import "../../dataproviders" as DataProviders
|
||||
|
|
@ -20,7 +21,7 @@ PlasmaCore.IconItem {
|
|||
readonly property var provider: DataProviders.BluetoothInfo {}
|
||||
|
||||
source: "network-bluetooth" // provider.icon
|
||||
colorGroup: PlasmaCore.ColorScope.colorGroup
|
||||
colorSet: Kirigami.Theme.colorSet
|
||||
|
||||
visible: provider.isVisible
|
||||
}
|
||||
|
|
|
|||
|
|
@ -11,6 +11,7 @@ import QtQuick.Layouts
|
|||
import org.kde.plasma.core as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.plasma.networkmanagement 0.2 as PlasmaNM
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
PlasmaCore.IconItem {
|
||||
id: connectionIcon
|
||||
|
|
@ -39,7 +40,7 @@ PlasmaCore.IconItem {
|
|||
// implementation
|
||||
|
||||
source: icon
|
||||
colorGroup: PlasmaCore.ColorScope.colorGroup
|
||||
colorSet: Kirigami.Theme.colorSet
|
||||
|
||||
PlasmaComponents.BusyIndicator {
|
||||
id: connectingIndicator
|
||||
|
|
|
|||
|
|
@ -10,6 +10,7 @@ import QtQuick.Layouts
|
|||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import "../../dataproviders" as DataProviders
|
||||
|
||||
|
|
@ -22,14 +23,14 @@ Item {
|
|||
readonly property bool isInternetIndicatorMobileData: internetIndicator && internetIndicator.icon && internetIndicator.icon.startsWith('network-mobile-')
|
||||
|
||||
property bool showLabel: true
|
||||
property real textPixelSize: PlasmaCore.Units.gridUnit * 0.6
|
||||
property real textPixelSize: Kirigami.Units.gridUnit * 0.6
|
||||
|
||||
width: strengthIcon.width + label.width
|
||||
Layout.minimumWidth: strengthIcon.width + label.width
|
||||
|
||||
PlasmaCore.IconItem {
|
||||
id: strengthIcon
|
||||
colorGroup: PlasmaCore.ColorScope.colorGroup
|
||||
colorSet: Kirigami.Theme.colorSet
|
||||
anchors.left: parent.left
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
width: height
|
||||
|
|
@ -45,12 +46,12 @@ Item {
|
|||
id: label
|
||||
visible: showLabel
|
||||
width: visible ? implicitWidth : 0
|
||||
anchors.leftMargin: PlasmaCore.Units.smallSpacing
|
||||
anchors.leftMargin: Kirigami.Units.smallSpacing
|
||||
anchors.left: strengthIcon.right
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
|
||||
text: provider.label
|
||||
color: PlasmaCore.ColorScope.textColor
|
||||
color: Kirigami.Theme.textColor
|
||||
font.pixelSize: textPixelSize
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -11,6 +11,7 @@ import QtQuick.Layouts
|
|||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.private.volume 0.1
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import "../../dataproviders" as DataProviders
|
||||
|
||||
|
|
@ -20,7 +21,7 @@ PlasmaCore.IconItem {
|
|||
|
||||
source: provider.icon
|
||||
|
||||
colorGroup: PlasmaCore.ColorScope.colorGroup
|
||||
colorSet: Kirigami.Theme.colorSet
|
||||
|
||||
visible: provider.isVisible
|
||||
}
|
||||
|
|
|
|||
|
|
@ -10,9 +10,8 @@ import QtQuick.Layouts
|
|||
import QtQuick.Window
|
||||
import QtQuick.Controls as Controls
|
||||
|
||||
import org.kde.plasma.core as PlasmaCore
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.plasma.extras as PlasmaExtra
|
||||
import org.kde.kquickcontrolsaddons as KQCAddons
|
||||
|
||||
import org.kde.plasma.private.volume
|
||||
|
|
@ -53,17 +52,17 @@ ColumnLayout {
|
|||
|
||||
PopupCard {
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
Layout.bottomMargin: PlasmaCore.Units.largeSpacing
|
||||
Layout.bottomMargin: Kirigami.Units.gridUnit
|
||||
contentItem: ColumnLayout {
|
||||
anchors.rightMargin: PlasmaCore.Units.smallSpacing
|
||||
anchors.leftMargin: PlasmaCore.Units.smallSpacing
|
||||
anchors.rightMargin: Kirigami.Units.smallSpacing
|
||||
anchors.leftMargin: Kirigami.Units.smallSpacing
|
||||
|
||||
PlasmaExtra.Heading {
|
||||
Kirigami.Heading {
|
||||
level: 2
|
||||
text: i18n("Outputs")
|
||||
Layout.fillWidth: true
|
||||
Layout.topMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.leftMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.topMargin: Kirigami.Units.smallSpacing
|
||||
Layout.leftMargin: Kirigami.Units.smallSpacing
|
||||
}
|
||||
|
||||
Repeater {
|
||||
|
|
@ -73,7 +72,7 @@ ColumnLayout {
|
|||
model: paSinkFilterModel
|
||||
delegate: DeviceListItem {
|
||||
Layout.fillWidth: true
|
||||
Layout.margins: PlasmaCore.Units.smallSpacing
|
||||
Layout.margins: Kirigami.Units.smallSpacing
|
||||
type: "sink"
|
||||
onlyone: sinkView.count === 1
|
||||
}
|
||||
|
|
@ -83,17 +82,17 @@ ColumnLayout {
|
|||
|
||||
PopupCard {
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
Layout.bottomMargin: PlasmaCore.Units.largeSpacing
|
||||
Layout.bottomMargin: Kirigami.Units.gridUnit
|
||||
contentItem: ColumnLayout {
|
||||
anchors.rightMargin: PlasmaCore.Units.smallSpacing
|
||||
anchors.leftMargin: PlasmaCore.Units.smallSpacing
|
||||
anchors.rightMargin: Kirigami.Units.smallSpacing
|
||||
anchors.leftMargin: Kirigami.Units.smallSpacing
|
||||
|
||||
PlasmaExtra.Heading {
|
||||
Kirigami.Heading {
|
||||
level: 2
|
||||
text: i18n("Inputs")
|
||||
Layout.fillWidth: true
|
||||
Layout.topMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.leftMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.topMargin: Kirigami.Units.smallSpacing
|
||||
Layout.leftMargin: Kirigami.Units.smallSpacing
|
||||
}
|
||||
|
||||
Repeater {
|
||||
|
|
@ -103,7 +102,7 @@ ColumnLayout {
|
|||
model: paSourceFilterModel
|
||||
delegate: DeviceListItem {
|
||||
Layout.fillWidth: true
|
||||
Layout.margins: PlasmaCore.Units.smallSpacing
|
||||
Layout.margins: Kirigami.Units.smallSpacing
|
||||
type: "source"
|
||||
onlyone: sinkView.count === 1
|
||||
}
|
||||
|
|
@ -114,17 +113,17 @@ ColumnLayout {
|
|||
PopupCard {
|
||||
visible: sourceInputView.model.count + sourceMediaInputView.model.count !== 0
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
Layout.bottomMargin: PlasmaCore.Units.largeSpacing
|
||||
Layout.bottomMargin: Kirigami.Units.gridUnit
|
||||
contentItem: ColumnLayout {
|
||||
anchors.rightMargin: PlasmaCore.Units.smallSpacing
|
||||
anchors.leftMargin: PlasmaCore.Units.smallSpacing
|
||||
anchors.rightMargin: Kirigami.Units.smallSpacing
|
||||
anchors.leftMargin: Kirigami.Units.smallSpacing
|
||||
|
||||
PlasmaExtra.Heading {
|
||||
Kirigami.Heading {
|
||||
level: 2
|
||||
text: i18n("Playback Streams")
|
||||
Layout.fillWidth: true
|
||||
Layout.topMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.leftMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.topMargin: Kirigami.Units.smallSpacing
|
||||
Layout.leftMargin: Kirigami.Units.smallSpacing
|
||||
}
|
||||
|
||||
Repeater {
|
||||
|
|
@ -137,7 +136,7 @@ ColumnLayout {
|
|||
}
|
||||
delegate: StreamListItem {
|
||||
Layout.fillWidth: true
|
||||
Layout.margins: PlasmaCore.Units.smallSpacing
|
||||
Layout.margins: Kirigami.Units.smallSpacing
|
||||
width: sourceOutputView.width
|
||||
type: "sink-input"
|
||||
devicesModel: sourceView.model
|
||||
|
|
@ -155,7 +154,7 @@ ColumnLayout {
|
|||
|
||||
delegate: StreamListItem {
|
||||
Layout.fillWidth: true
|
||||
Layout.margins: PlasmaCore.Units.smallSpacing
|
||||
Layout.margins: Kirigami.Units.smallSpacing
|
||||
width: sourceOutputView.width
|
||||
type: "sink-input"
|
||||
devicesModel: sourceView.model
|
||||
|
|
@ -167,17 +166,17 @@ ColumnLayout {
|
|||
PopupCard {
|
||||
visible: sourceOutputView.model.count !== 0
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
Layout.bottomMargin: PlasmaCore.Units.largeSpacing
|
||||
Layout.bottomMargin: Kirigami.Units.gridUnit
|
||||
contentItem: ColumnLayout {
|
||||
anchors.rightMargin: PlasmaCore.Units.smallSpacing
|
||||
anchors.leftMargin: PlasmaCore.Units.smallSpacing
|
||||
anchors.rightMargin: Kirigami.Units.smallSpacing
|
||||
anchors.leftMargin: Kirigami.Units.smallSpacing
|
||||
|
||||
PlasmaExtra.Heading {
|
||||
Kirigami.Heading {
|
||||
level: 2
|
||||
text: i18n("Recording Streams")
|
||||
Layout.fillWidth: true
|
||||
Layout.topMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.leftMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.topMargin: Kirigami.Units.smallSpacing
|
||||
Layout.leftMargin: Kirigami.Units.smallSpacing
|
||||
}
|
||||
|
||||
Repeater {
|
||||
|
|
@ -190,7 +189,7 @@ ColumnLayout {
|
|||
}
|
||||
delegate: StreamListItem {
|
||||
Layout.fillWidth: true
|
||||
Layout.margins: PlasmaCore.Units.smallSpacing
|
||||
Layout.margins: Kirigami.Units.smallSpacing
|
||||
width: sourceOutputView.width
|
||||
type: "source-output"
|
||||
devicesModel: sourceView.model
|
||||
|
|
|
|||
|
|
@ -11,11 +11,11 @@ import QtQuick.Controls 2.15 as Controls
|
|||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Window 2.2
|
||||
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
import org.kde.ksvg 1.0 as KSvg
|
||||
import org.kde.kquickcontrolsaddons 2.0
|
||||
import org.kde.plasma.core 2.1 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.plasma.extras 2.0 as PlasmaExtra
|
||||
import org.kde.plasma.private.volume 0.1
|
||||
|
||||
import "icon.js" as Icon
|
||||
|
|
@ -37,12 +37,12 @@ Controls.ItemDelegate {
|
|||
|
||||
contentItem: RowLayout {
|
||||
id: row
|
||||
spacing: PlasmaCore.Units.smallSpacing
|
||||
spacing: Kirigami.Units.smallSpacing
|
||||
|
||||
PlasmaComponents.RadioButton {
|
||||
id: selectButton
|
||||
Layout.alignment: Qt.AlignTop
|
||||
Layout.topMargin: Math.round(row.height / 2 - implicitHeight - PlasmaCore.Units.smallSpacing / 2) // align with text
|
||||
Layout.topMargin: Math.round(row.height / 2 - implicitHeight - Kirigami.Units.smallSpacing / 2) // align with text
|
||||
checked: model.PulseObject.hasOwnProperty("default") ? model.PulseObject.default : false
|
||||
visible: (baseItem.type == "sink" && sinkView.model.count > 1) || (baseItem.type == "source" && sourceView.model.count > 1)
|
||||
onClicked: model.PulseObject.default = true
|
||||
|
|
@ -52,9 +52,9 @@ Controls.ItemDelegate {
|
|||
PlasmaCore.IconItem {
|
||||
id: clientIcon
|
||||
Layout.alignment: Qt.AlignVCenter
|
||||
Layout.rightMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.preferredWidth: PlasmaCore.Units.iconSizes.smallMedium
|
||||
Layout.preferredHeight: PlasmaCore.Units.iconSizes.smallMedium
|
||||
Layout.rightMargin: Kirigami.Units.smallSpacing
|
||||
Layout.preferredWidth: Kirigami.Units.iconSizes.smallMedium
|
||||
Layout.preferredHeight: Kirigami.Units.iconSizes.smallMedium
|
||||
visible: type === "sink-input" || type === "source-output"
|
||||
source: "unknown"
|
||||
onSourceChanged: {
|
||||
|
|
@ -67,11 +67,11 @@ Controls.ItemDelegate {
|
|||
ColumnLayout {
|
||||
Layout.alignment: Qt.AlignVCenter
|
||||
Layout.fillWidth: true
|
||||
spacing: PlasmaCore.Units.smallSpacing
|
||||
spacing: Kirigami.Units.smallSpacing
|
||||
|
||||
RowLayout {
|
||||
Layout.fillWidth: true
|
||||
spacing: PlasmaCore.Units.smallSpacing
|
||||
spacing: Kirigami.Units.smallSpacing
|
||||
Layout.alignment: Qt.AlignBottom
|
||||
|
||||
PlasmaComponents.Label {
|
||||
|
|
@ -84,7 +84,7 @@ Controls.ItemDelegate {
|
|||
|
||||
PlasmaComponents.ToolButton {
|
||||
Layout.alignment: Qt.AlignBottom
|
||||
Layout.bottomMargin: -PlasmaCore.Units.smallSpacing
|
||||
Layout.bottomMargin: -Kirigami.Units.smallSpacing
|
||||
icon.name: "application-menu"
|
||||
checkable: true
|
||||
checked: contextMenu.visible && contextMenu.visualParent === this
|
||||
|
|
@ -127,7 +127,7 @@ Controls.ItemDelegate {
|
|||
|
||||
RowLayout {
|
||||
Layout.fillWidth: true
|
||||
spacing: PlasmaCore.Units.smallSpacing
|
||||
spacing: Kirigami.Units.smallSpacing
|
||||
|
||||
// this slider was effectively copied from the source (linked at the top of the file)
|
||||
PlasmaComponents.Slider {
|
||||
|
|
@ -175,7 +175,7 @@ Controls.ItemDelegate {
|
|||
Behavior on width {
|
||||
NumberAnimation {
|
||||
id: animation
|
||||
duration: PlasmaCore.Units.shortDuration
|
||||
duration: Kirigami.Units.shortDuration
|
||||
easing.type: Easing.OutQuad
|
||||
}
|
||||
}
|
||||
|
|
@ -231,11 +231,11 @@ Controls.ItemDelegate {
|
|||
text: i18nc("volume percentage", "%1%", displayValue)
|
||||
color: {
|
||||
if (displayValue <= 100) {
|
||||
return PlasmaCore.Theme.textColor
|
||||
return Kirigami.Theme.textColor
|
||||
} else if (displayValue > 100 && displayValue <= 125) {
|
||||
return PlasmaCore.Theme.neutralTextColor
|
||||
return Kirigami.Theme.neutralTextColor
|
||||
} else {
|
||||
return PlasmaCore.Theme.negativeTextColor
|
||||
return Kirigami.Theme.negativeTextColor
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -9,18 +9,18 @@ import QtQuick.Controls as Controls
|
|||
import QtQuick.Layouts
|
||||
import QtQuick.Window
|
||||
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
import org.kde.ksvg 1.0 as KSvg
|
||||
import org.kde.plasma.core 2.1 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
|
||||
// capture presses on the audio applet so it doesn't close the overlay
|
||||
Controls.Control {
|
||||
id: content
|
||||
implicitWidth: Math.min(PlasmaCore.Units.gridUnit * 20, parent.width - PlasmaCore.Units.largeSpacing * 2)
|
||||
padding: PlasmaCore.Units.smallSpacing * 2
|
||||
implicitWidth: Math.min(Kirigami.Units.gridUnit * 20, parent.width - Kirigami.Units.gridUnit * 2)
|
||||
padding: Kirigami.Units.smallSpacing * 2
|
||||
background: KSvg.FrameSvgItem {
|
||||
imagePath: "widgets/background"
|
||||
anchors.margins: -PlasmaCore.Units.smallSpacing * 2
|
||||
anchors.margins: -Kirigami.Units.smallSpacing * 2
|
||||
anchors.fill: parent
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -11,10 +11,8 @@ import QtQuick.Controls as Controls
|
|||
import QtQuick.Layouts
|
||||
import QtQuick.Window
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.extras 2.0 as PlasmaExtra
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.plasma.extras 2.0 as PlasmaExtra
|
||||
import org.kde.plasma.private.nanoshell 2.0 as NanoShell
|
||||
import org.kde.plasma.private.mobileshell 1.0 as MobileShell
|
||||
import org.kde.plasma.private.mobileshell.state 1.0 as MobileShellState
|
||||
|
|
@ -99,24 +97,24 @@ NanoShell.FullScreenOverlay {
|
|||
// osd card
|
||||
PopupCard {
|
||||
id: osd
|
||||
Layout.topMargin: PlasmaCore.Units.largeSpacing
|
||||
Layout.topMargin: Kirigami.Units.gridUnit
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
|
||||
contentItem: RowLayout {
|
||||
id: containerLayout
|
||||
spacing: PlasmaCore.Units.smallSpacing
|
||||
spacing: Kirigami.Units.smallSpacing
|
||||
|
||||
anchors.leftMargin: PlasmaCore.Units.smallSpacing * 2
|
||||
anchors.rightMargin: PlasmaCore.Units.smallSpacing
|
||||
anchors.leftMargin: Kirigami.Units.smallSpacing * 2
|
||||
anchors.rightMargin: Kirigami.Units.smallSpacing
|
||||
|
||||
PlasmaComponents.ToolButton {
|
||||
icon.name: !audioInfo.paSinkModel.preferredSink || audioInfo.paSinkModel.preferredSink.muted ? "audio-volume-muted" : "audio-volume-high"
|
||||
text: !audioInfo.paSinkModel.preferredSink || audioInfo.paSinkModel.preferredSink.muted ? i18n("Unmute") : i18n("Mute")
|
||||
display: Controls.AbstractButton.IconOnly
|
||||
Layout.alignment: Qt.AlignVCenter
|
||||
Layout.preferredWidth: PlasmaCore.Units.iconSizes.medium
|
||||
Layout.preferredHeight: PlasmaCore.Units.iconSizes.medium
|
||||
Layout.rightMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.preferredWidth: Kirigami.Units.iconSizes.medium
|
||||
Layout.preferredHeight: Kirigami.Units.iconSizes.medium
|
||||
Layout.rightMargin: Kirigami.Units.smallSpacing
|
||||
onClicked: muteVolume()
|
||||
}
|
||||
|
||||
|
|
@ -124,11 +122,11 @@ NanoShell.FullScreenOverlay {
|
|||
id: volumeSlider
|
||||
Layout.fillWidth: true
|
||||
Layout.alignment: Qt.AlignVCenter
|
||||
Layout.rightMargin: PlasmaCore.Units.smallSpacing * 2
|
||||
Layout.rightMargin: Kirigami.Units.smallSpacing * 2
|
||||
value: window.volume
|
||||
from: 0
|
||||
to: 100
|
||||
Behavior on value { NumberAnimation { duration: PlasmaCore.Units.shortDuration } }
|
||||
Behavior on value { NumberAnimation { duration: Kirigami.Units.shortDuration } }
|
||||
}
|
||||
|
||||
// Get the width of a three-digit number so we can size the label
|
||||
|
|
@ -139,11 +137,11 @@ NanoShell.FullScreenOverlay {
|
|||
font: percentageLabel.font
|
||||
}
|
||||
|
||||
PlasmaExtra.Heading {
|
||||
Kirigami.Heading {
|
||||
id: percentageLabel
|
||||
Layout.preferredWidth: widestLabelSize.width
|
||||
Layout.alignment: Qt.AlignVCenter
|
||||
Layout.rightMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.rightMargin: Kirigami.Units.smallSpacing
|
||||
level: 3
|
||||
text: i18nc("Percentage value", "%1%", window.volume)
|
||||
|
||||
|
|
@ -154,11 +152,11 @@ NanoShell.FullScreenOverlay {
|
|||
// and plasma-pa:VolumeSlider.qml
|
||||
color: {
|
||||
if (volumeSlider.value <= 100) {
|
||||
return PlasmaCore.Theme.textColor
|
||||
return Kirigami.Theme.textColor
|
||||
} else if (volumeSlider.value > 100 && volumeSlider.value <= 125) {
|
||||
return PlasmaCore.Theme.neutralTextColor
|
||||
return Kirigami.Theme.neutralTextColor
|
||||
} else {
|
||||
return PlasmaCore.Theme.negativeTextColor
|
||||
return Kirigami.Theme.negativeTextColor
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -170,15 +168,15 @@ NanoShell.FullScreenOverlay {
|
|||
opacity: showFullApplet ? 1 : 0
|
||||
display: Controls.AbstractButton.IconOnly
|
||||
Layout.alignment: Qt.AlignVCenter
|
||||
Layout.preferredWidth: PlasmaCore.Units.iconSizes.medium
|
||||
Layout.preferredHeight: PlasmaCore.Units.iconSizes.medium
|
||||
Layout.rightMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.preferredWidth: Kirigami.Units.iconSizes.medium
|
||||
Layout.preferredHeight: Kirigami.Units.iconSizes.medium
|
||||
Layout.rightMargin: Kirigami.Units.smallSpacing
|
||||
|
||||
Behavior on opacity { NumberAnimation { duration: PlasmaCore.Units.shortDuration } }
|
||||
Behavior on opacity { NumberAnimation { duration: Kirigami.Units.shortDuration } }
|
||||
|
||||
onClicked: {
|
||||
let coords = mapToItem(flickable, 0, 0);
|
||||
MobileShellState.ShellDBusClient.openAppLaunchAnimation("audio-volume-high", i18n("Audio Settings"), coords.x, coords.y, PlasmaCore.Units.iconSizes.medium);
|
||||
MobileShellState.ShellDBusClient.openAppLaunchAnimation("audio-volume-high", i18n("Audio Settings"), coords.x, coords.y, Kirigami.Units.iconSizes.medium);
|
||||
MobileShell.ShellUtil.executeCommand("plasma-open-settings kcm_pulseaudio");
|
||||
}
|
||||
}
|
||||
|
|
@ -188,8 +186,8 @@ NanoShell.FullScreenOverlay {
|
|||
text: i18n("Toggle showing audio streams")
|
||||
display: Controls.AbstractButton.IconOnly
|
||||
Layout.alignment: Qt.AlignVCenter
|
||||
Layout.preferredWidth: PlasmaCore.Units.iconSizes.medium
|
||||
Layout.preferredHeight: PlasmaCore.Units.iconSizes.medium
|
||||
Layout.preferredWidth: Kirigami.Units.iconSizes.medium
|
||||
Layout.preferredHeight: Kirigami.Units.iconSizes.medium
|
||||
onClicked: {
|
||||
window.showFullApplet = !window.showFullApplet
|
||||
// don't autohide applet when full applet is shown
|
||||
|
|
@ -206,7 +204,7 @@ NanoShell.FullScreenOverlay {
|
|||
// other applet cards
|
||||
AudioApplet {
|
||||
id: applet
|
||||
Layout.topMargin: PlasmaCore.Units.largeSpacing
|
||||
Layout.topMargin: Kirigami.Units.gridUnit
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
Layout.preferredWidth: cards.width
|
||||
|
||||
|
|
@ -215,7 +213,7 @@ NanoShell.FullScreenOverlay {
|
|||
opacity: window.showFullApplet ? 1 : 0
|
||||
visible: opacity !== 0
|
||||
transform: Translate {
|
||||
y: window.showFullApplet ? 0 : -PlasmaCore.Units.gridUnit
|
||||
y: window.showFullApplet ? 0 : -Kirigami.Units.gridUnit
|
||||
Behavior on y { NumberAnimation {} }
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -62,7 +62,7 @@ Item {
|
|||
// emitted when an item on the ListView is triggered
|
||||
signal actionTriggered()
|
||||
|
||||
readonly property real closedContentY: PlasmaCore.Units.gridUnit * 5
|
||||
readonly property real closedContentY: Kirigami.Units.gridUnit * 5
|
||||
readonly property real openedContentY: 0
|
||||
readonly property real openFactor: Math.max(0, Math.min(1, 1 - flickable.contentY / closedContentY))
|
||||
readonly property bool isOpen: openFactor != 0
|
||||
|
|
@ -118,7 +118,7 @@ Item {
|
|||
|
||||
NumberAnimation on contentY {
|
||||
id: anim
|
||||
duration: PlasmaCore.Units.longDuration * 2
|
||||
duration: Kirigami.Units.longDuration * 2
|
||||
easing.type: Easing.OutQuad
|
||||
running: false
|
||||
onFinished: {
|
||||
|
|
@ -136,16 +136,16 @@ Item {
|
|||
Controls.Control {
|
||||
opacity: root.openFactor
|
||||
Layout.fillWidth: true
|
||||
Layout.maximumWidth: PlasmaCore.Units.gridUnit * 30
|
||||
Layout.maximumWidth: Kirigami.Units.gridUnit * 30
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
Layout.topMargin: PlasmaCore.Units.gridUnit
|
||||
Layout.leftMargin: PlasmaCore.Units.gridUnit
|
||||
Layout.rightMargin: PlasmaCore.Units.gridUnit
|
||||
Layout.topMargin: Kirigami.Units.gridUnit
|
||||
Layout.leftMargin: Kirigami.Units.gridUnit
|
||||
Layout.rightMargin: Kirigami.Units.gridUnit
|
||||
|
||||
leftPadding: PlasmaCore.Units.smallSpacing
|
||||
rightPadding: PlasmaCore.Units.smallSpacing
|
||||
topPadding: PlasmaCore.Units.smallSpacing
|
||||
bottomPadding: PlasmaCore.Units.smallSpacing
|
||||
leftPadding: Kirigami.Units.smallSpacing
|
||||
rightPadding: Kirigami.Units.smallSpacing
|
||||
topPadding: Kirigami.Units.smallSpacing
|
||||
bottomPadding: Kirigami.Units.smallSpacing
|
||||
|
||||
background: Item {
|
||||
|
||||
|
|
@ -162,8 +162,8 @@ Item {
|
|||
Rectangle {
|
||||
id: rectBackground
|
||||
anchors.fill: parent
|
||||
color: PlasmaCore.Theme.backgroundColor
|
||||
radius: PlasmaCore.Units.smallSpacing
|
||||
color: Kirigami.Theme.backgroundColor
|
||||
radius: Kirigami.Units.smallSpacing
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -189,7 +189,7 @@ Item {
|
|||
Controls.ScrollView {
|
||||
opacity: root.openFactor === 1 ? 1 : 0
|
||||
Behavior on opacity {
|
||||
NumberAnimation { duration: PlasmaCore.Units.shortDuration }
|
||||
NumberAnimation { duration: Kirigami.Units.shortDuration }
|
||||
}
|
||||
|
||||
Layout.fillWidth: true
|
||||
|
|
@ -199,7 +199,7 @@ Item {
|
|||
id: listView
|
||||
queryString: queryField.text
|
||||
clip: true
|
||||
PlasmaCore.ColorScope.colorGroup: PlasmaCore.Theme.NormalColorGroup
|
||||
Kirigami.Theme.colorSet: Kirigami.Theme.Window
|
||||
|
||||
highlight: activeFocus ? highlightComponent : null
|
||||
Component{
|
||||
|
|
@ -239,49 +239,49 @@ Item {
|
|||
anchors.fill: parent
|
||||
color: delegate.pressed ? Qt.rgba(255, 255, 255, 0.2) : (delegate.containsMouse ? Qt.rgba(255, 255, 255, 0.05) : "transparent")
|
||||
Behavior on color {
|
||||
ColorAnimation { duration: PlasmaCore.Units.shortDuration }
|
||||
ColorAnimation { duration: Kirigami.Units.shortDuration }
|
||||
}
|
||||
}
|
||||
|
||||
RowLayout {
|
||||
id: rowLayout
|
||||
height: PlasmaCore.Units.gridUnit * 3
|
||||
height: Kirigami.Units.gridUnit * 3
|
||||
anchors.top: parent.top
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.leftMargin: PlasmaCore.Units.largeSpacing
|
||||
anchors.rightMargin: PlasmaCore.Units.largeSpacing
|
||||
anchors.leftMargin: Kirigami.Units.gridUnit
|
||||
anchors.rightMargin: Kirigami.Units.gridUnit
|
||||
|
||||
Kirigami.Icon {
|
||||
Layout.alignment: Qt.AlignVCenter
|
||||
source: model.decoration
|
||||
implicitWidth: PlasmaCore.Units.iconSizes.medium
|
||||
implicitHeight: PlasmaCore.Units.iconSizes.medium
|
||||
implicitWidth: Kirigami.Units.iconSizes.medium
|
||||
implicitHeight: Kirigami.Units.iconSizes.medium
|
||||
}
|
||||
|
||||
ColumnLayout {
|
||||
Layout.fillWidth: true
|
||||
Layout.alignment: Qt.AlignVCenter
|
||||
spacing: PlasmaCore.Units.smallSpacing
|
||||
spacing: Kirigami.Units.smallSpacing
|
||||
|
||||
PlasmaComponents.Label {
|
||||
id: title
|
||||
Layout.fillWidth: true
|
||||
Layout.leftMargin: PlasmaCore.Units.smallSpacing * 2
|
||||
Layout.rightMargin: PlasmaCore.Units.largeSpacing
|
||||
Layout.leftMargin: Kirigami.Units.smallSpacing * 2
|
||||
Layout.rightMargin: Kirigami.Units.gridUnit
|
||||
|
||||
maximumLineCount: 1
|
||||
elide: Text.ElideRight
|
||||
text: typeof modelData !== "undefined" ? modelData : model.display
|
||||
color: "white"
|
||||
|
||||
font.pointSize: PlasmaCore.Theme.defaultFont.pointSize
|
||||
font.pointSize: Kirigami.Theme.defaultFont.pointSize
|
||||
}
|
||||
PlasmaComponents.Label {
|
||||
id: subtitle
|
||||
Layout.fillWidth: true
|
||||
Layout.leftMargin: PlasmaCore.Units.smallSpacing * 2
|
||||
Layout.rightMargin: PlasmaCore.Units.largeSpacing
|
||||
Layout.leftMargin: Kirigami.Units.smallSpacing * 2
|
||||
Layout.rightMargin: Kirigami.Units.gridUnit
|
||||
|
||||
maximumLineCount: 1
|
||||
elide: Text.ElideRight
|
||||
|
|
@ -289,7 +289,7 @@ Item {
|
|||
color: "white"
|
||||
opacity: 0.8
|
||||
|
||||
font.pointSize: Math.round(PlasmaCore.Theme.defaultFont.pointSize * 0.8)
|
||||
font.pointSize: Math.round(Kirigami.Theme.defaultFont.pointSize * 0.8)
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ import QtQuick
|
|||
import QtQuick.Effects
|
||||
import Qt5Compat.GraphicalEffects
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
Item {
|
||||
id: root
|
||||
|
|
@ -24,7 +24,7 @@ Item {
|
|||
anchors.centerIn: parent
|
||||
width: img.width
|
||||
height: img.height
|
||||
radius: PlasmaCore.Units.smallSpacing
|
||||
radius: Kirigami.Units.smallSpacing
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -7,7 +7,6 @@
|
|||
|
||||
import QtQuick
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.plasma5support 2.0 as P5Support
|
||||
|
||||
P5Support.DataSource {
|
||||
|
|
|
|||
|
|
@ -12,9 +12,7 @@ import QtQuick.Controls as QQC2
|
|||
import org.kde.kirigami as Kirigami
|
||||
|
||||
import org.kde.plasma.private.mobileshell.state 1.0 as MobileShellState
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents3
|
||||
import org.kde.plasma.extras 2.0 as PlasmaExtras
|
||||
|
||||
import "../../components" as Components
|
||||
|
||||
|
|
@ -25,8 +23,8 @@ Item {
|
|||
id: root
|
||||
visible: mpris2Source.hasPlayer
|
||||
|
||||
readonly property real padding: Kirigami.Units.largeSpacing + Kirigami.Units.smallSpacing
|
||||
readonly property real contentHeight: PlasmaCore.Units.gridUnit * 2 + PlasmaCore.Units.smallSpacing
|
||||
readonly property real padding: Kirigami.Units.gridUnit + Kirigami.Units.smallSpacing
|
||||
readonly property real contentHeight: Kirigami.Units.gridUnit * 2 + Kirigami.Units.smallSpacing
|
||||
implicitHeight: visible ? padding * 2 + contentHeight : 0
|
||||
|
||||
MediaControlsSource {
|
||||
|
|
@ -93,8 +91,9 @@ Item {
|
|||
imageSource: mpris2Source.albumArt(playerItem.source)
|
||||
}
|
||||
|
||||
contentItem: PlasmaCore.ColorScope {
|
||||
colorGroup: PlasmaCore.Theme.ComplementaryColorGroup
|
||||
contentItem: Item {
|
||||
Kirigami.Theme.colorSet: Kirigami.Theme.Complementary
|
||||
Kirigami.Theme.inherit: false
|
||||
width: playerItem.width - playerItem.leftPadding - playerItem.rightPadding
|
||||
|
||||
RowLayout {
|
||||
|
|
@ -117,7 +116,7 @@ Item {
|
|||
}
|
||||
|
||||
ColumnLayout {
|
||||
Layout.leftMargin: albumArt.visible ? Kirigami.Units.largeSpacing : 0
|
||||
Layout.leftMargin: albumArt.visible ? Kirigami.Units.gridUnit : 0
|
||||
Layout.fillWidth: true
|
||||
spacing: Kirigami.Units.smallSpacing
|
||||
|
||||
|
|
@ -126,7 +125,7 @@ Item {
|
|||
|
||||
inputText: mpris2Source.track(playerItem.source) || i18n("No media playing")
|
||||
textFormat: Text.PlainText
|
||||
font.pointSize: PlasmaCore.Theme.defaultFont.pointSize
|
||||
font.pointSize: Kirigami.Theme.defaultFont.pointSize
|
||||
color: "white"
|
||||
}
|
||||
|
||||
|
|
@ -136,7 +135,7 @@ Item {
|
|||
// if no artist is given, show player name instead
|
||||
inputText: mpris2Source.artist(playerItem.source) || modelData.application || ""
|
||||
textFormat: Text.PlainText
|
||||
font.pointSize: PlasmaCore.Theme.defaultFont.pointSize * 0.9
|
||||
font.pointSize: Kirigami.Theme.defaultFont.pointSize * 0.9
|
||||
opacity: 0.9
|
||||
color: "white"
|
||||
}
|
||||
|
|
@ -148,8 +147,8 @@ Item {
|
|||
|
||||
enabled: mpris2Source.canGoBack(playerItem.source)
|
||||
icon.name: LayoutMirroring.enabled ? "media-skip-forward" : "media-skip-backward"
|
||||
icon.width: PlasmaCore.Units.iconSizes.small
|
||||
icon.height: PlasmaCore.Units.iconSizes.small
|
||||
icon.width: Kirigami.Units.iconSizes.small
|
||||
icon.height: Kirigami.Units.iconSizes.small
|
||||
onClicked: mpris2Source.goPrevious(playerItem.source)
|
||||
visible: mpris2Source.canGoBack(playerItem.source) || mpris2Source.canGoNext(playerItem.source)
|
||||
Accessible.name: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Previous track")
|
||||
|
|
@ -160,8 +159,8 @@ Item {
|
|||
Layout.preferredWidth: height
|
||||
|
||||
icon.name: mpris2Source.isPlaying(playerItem.source) ? "media-playback-pause" : "media-playback-start"
|
||||
icon.width: PlasmaCore.Units.iconSizes.small
|
||||
icon.height: PlasmaCore.Units.iconSizes.small
|
||||
icon.width: Kirigami.Units.iconSizes.small
|
||||
icon.height: Kirigami.Units.iconSizes.small
|
||||
onClicked: mpris2Source.playPause(playerItem.source)
|
||||
Accessible.name: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Play or Pause media")
|
||||
}
|
||||
|
|
@ -172,8 +171,8 @@ Item {
|
|||
|
||||
enabled: mpris2Source.canGoBack(playerItem.source)
|
||||
icon.name: LayoutMirroring.enabled ? "media-skip-backward" : "media-skip-forward"
|
||||
icon.width: PlasmaCore.Units.iconSizes.small
|
||||
icon.height: PlasmaCore.Units.iconSizes.small
|
||||
icon.width: Kirigami.Units.iconSizes.small
|
||||
icon.height: Kirigami.Units.iconSizes.small
|
||||
onClicked: mpris2Source.goNext(playerItem.source)
|
||||
visible: mpris2Source.canGoBack(playerItem.source) || mpris2Source.canGoNext(playerItem.source)
|
||||
Accessible.name: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Next track")
|
||||
|
|
|
|||
|
|
@ -9,10 +9,8 @@ import QtQuick
|
|||
import QtQuick.Layouts
|
||||
import QtQuick.Window
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.plasma5support 2.0 as P5Support
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents3
|
||||
import org.kde.plasma.extras 2.0 as PlasmaExtras
|
||||
|
||||
import org.kde.notificationmanager 1.0 as NotificationManager
|
||||
|
||||
|
|
|
|||
|
|
@ -6,7 +6,6 @@ import QtQuick.Effects
|
|||
|
||||
import org.kde.kirigami 2.12 as Kirigami
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
|
||||
Item {
|
||||
|
|
@ -27,7 +26,7 @@ Item {
|
|||
onContentItemChanged: {
|
||||
contentItem.parent = contentParent;
|
||||
contentItem.anchors.fill = contentParent;
|
||||
contentItem.anchors.margins = Kirigami.Units.largeSpacing;
|
||||
contentItem.anchors.margins = Kirigami.Units.gridUnit;
|
||||
contentParent.children.push(contentItem);
|
||||
}
|
||||
|
||||
|
|
@ -35,7 +34,7 @@ Item {
|
|||
|
||||
NumberAnimation on dragOffset {
|
||||
id: dragAnim
|
||||
duration: PlasmaCore.Units.longDuration
|
||||
duration: Kirigami.Units.longDuration
|
||||
onFinished: {
|
||||
if (to !== 0) {
|
||||
root.dismissRequested();
|
||||
|
|
@ -52,7 +51,7 @@ Item {
|
|||
shadowEnabled: true
|
||||
shadowVerticalOffset: 1
|
||||
shadowOpacity: 0.5
|
||||
shadowColor: Qt.lighter(PlasmaCore.Theme.backgroundColor, 0.1)
|
||||
shadowColor: Qt.lighter(Kirigami.Theme.backgroundColor, 0.1)
|
||||
}
|
||||
|
||||
// shadow
|
||||
|
|
@ -63,8 +62,8 @@ Item {
|
|||
anchors.rightMargin: -1
|
||||
anchors.bottomMargin: -1
|
||||
|
||||
color: Qt.darker(PlasmaCore.Theme.backgroundColor, 1.3)
|
||||
radius: PlasmaCore.Units.smallSpacing
|
||||
color: Qt.darker(Kirigami.Theme.backgroundColor, 1.3)
|
||||
radius: Kirigami.Units.smallSpacing
|
||||
}
|
||||
|
||||
// card
|
||||
|
|
@ -76,8 +75,8 @@ Item {
|
|||
anchors.rightMargin: root.dragOffset < 0 ? -root.dragOffset : 0
|
||||
anchors.top: parent.top
|
||||
|
||||
color: (root.tapEnabled && mouseArea.pressed) ? Qt.darker(PlasmaCore.Theme.backgroundColor, 1.1) : PlasmaCore.Theme.backgroundColor
|
||||
radius: PlasmaCore.Units.smallSpacing
|
||||
color: (root.tapEnabled && mouseArea.pressed) ? Qt.darker(Kirigami.Theme.backgroundColor, 1.1) : Kirigami.Theme.backgroundColor
|
||||
radius: Kirigami.Units.smallSpacing
|
||||
implicitHeight: contentParent.implicitHeight
|
||||
clip: true
|
||||
|
||||
|
|
@ -127,7 +126,7 @@ Item {
|
|||
startActive = active;
|
||||
|
||||
if (!active) { // release event
|
||||
let threshold = PlasmaCore.Units.gridUnit * 5; // drag threshold
|
||||
let threshold = Kirigami.Units.gridUnit * 5; // drag threshold
|
||||
if (root.dragOffset > threshold) {
|
||||
dragAnim.to = root.width;
|
||||
} else if (root.dragOffset < -threshold) {
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@
|
|||
import QtQuick 2.15
|
||||
import QtQuick.Layouts 1.1
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
|
||||
Item {
|
||||
|
|
@ -22,14 +22,14 @@ Item {
|
|||
Flow {
|
||||
id: actionFlow
|
||||
width: parent.width
|
||||
spacing: PlasmaCore.Units.smallSpacing
|
||||
spacing: Kirigami.Units.smallSpacing
|
||||
layoutDirection: Qt.RightToLeft
|
||||
enabled: !replyLoader.active
|
||||
opacity: replyLoader.active ? 0 : 1
|
||||
|
||||
Behavior on opacity {
|
||||
NumberAnimation {
|
||||
duration: PlasmaCore.Units.longDuration
|
||||
duration: Kirigami.Units.longDuration
|
||||
easing.type: Easing.InOutQuad
|
||||
}
|
||||
}
|
||||
|
|
@ -88,13 +88,13 @@ Item {
|
|||
|
||||
Behavior on x {
|
||||
NumberAnimation {
|
||||
duration: PlasmaCore.Units.longDuration
|
||||
duration: Kirigami.Units.longDuration
|
||||
easing.type: Easing.InOutQuad
|
||||
}
|
||||
}
|
||||
Behavior on opacity {
|
||||
NumberAnimation {
|
||||
duration: PlasmaCore.Units.longDuration
|
||||
duration: Kirigami.Units.longDuration
|
||||
easing.type: Easing.InOutQuad
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -14,7 +14,6 @@ import org.kde.kirigami 2.12 as Kirigami
|
|||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.plasma5support 2.0 as P5Support
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.plasma.extras 2.0 as PlasmaExtras
|
||||
|
||||
import org.kde.notificationmanager 1.0 as NotificationManager
|
||||
|
||||
|
|
@ -39,15 +38,15 @@ RowLayout {
|
|||
property real timeout: 5000
|
||||
property real remainingTime: 0
|
||||
|
||||
spacing: PlasmaCore.Units.smallSpacing
|
||||
Layout.preferredHeight: Math.max(applicationNameLabel.implicitHeight, PlasmaCore.Units.iconSizes.small)
|
||||
spacing: Kirigami.Units.smallSpacing
|
||||
Layout.preferredHeight: Math.max(applicationNameLabel.implicitHeight, Kirigami.Units.iconSizes.small)
|
||||
|
||||
PlasmaCore.IconItem {
|
||||
id: applicationIconItem
|
||||
Layout.topMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.bottomMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.preferredWidth: PlasmaCore.Units.iconSizes.small
|
||||
Layout.preferredHeight: PlasmaCore.Units.iconSizes.small
|
||||
Layout.topMargin: Kirigami.Units.smallSpacing
|
||||
Layout.bottomMargin: Kirigami.Units.smallSpacing
|
||||
Layout.preferredWidth: Kirigami.Units.iconSizes.small
|
||||
Layout.preferredHeight: Kirigami.Units.iconSizes.small
|
||||
source: notificationHeading.applicationIconSource
|
||||
usesPlasmaTheme: false
|
||||
visible: valid
|
||||
|
|
@ -55,7 +54,7 @@ RowLayout {
|
|||
|
||||
PlasmaComponents.Label {
|
||||
id: applicationNameLabel
|
||||
Layout.leftMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.leftMargin: Kirigami.Units.smallSpacing
|
||||
Layout.fillWidth: true
|
||||
opacity: 0.6
|
||||
textFormat: Text.PlainText
|
||||
|
|
|
|||
|
|
@ -11,7 +11,6 @@ import QtQuick.Window 2.2
|
|||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.plasma.extras 2.0 as PlasmaExtras
|
||||
|
||||
import org.kde.notificationmanager 1.0 as NotificationManager
|
||||
|
||||
|
|
@ -33,8 +32,8 @@ BaseNotificationItem {
|
|||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
|
||||
PlasmaCore.ColorScope.colorGroup: PlasmaCore.Theme.HeaderColorGroup
|
||||
PlasmaCore.ColorScope.inherit: false
|
||||
Kirigami.Theme.colorSet: Kirigami.Theme.Header
|
||||
Kirigami.Theme.inherit: false
|
||||
|
||||
visible: !notificationItem.inGroup
|
||||
height: visible ? implicitHeight : 0
|
||||
|
|
@ -54,7 +53,7 @@ BaseNotificationItem {
|
|||
// notification
|
||||
NotificationCard {
|
||||
id: mainCard
|
||||
anchors.topMargin: notificationHeading.visible ? Kirigami.Units.largeSpacing : 0
|
||||
anchors.topMargin: notificationHeading.visible ? Kirigami.Units.gridUnit : 0
|
||||
anchors.top: notificationHeading.bottom
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
|
|
@ -71,7 +70,7 @@ BaseNotificationItem {
|
|||
// notification summary row
|
||||
RowLayout {
|
||||
Layout.fillWidth: true
|
||||
Layout.bottomMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.bottomMargin: Kirigami.Units.smallSpacing
|
||||
|
||||
// notification summary
|
||||
PlasmaComponents.Label {
|
||||
|
|
@ -101,7 +100,7 @@ BaseNotificationItem {
|
|||
// notification contents
|
||||
RowLayout {
|
||||
Layout.fillWidth: true
|
||||
spacing: PlasmaCore.Units.smallSpacing
|
||||
spacing: Kirigami.Units.smallSpacing
|
||||
|
||||
// notification text
|
||||
NotificationBodyLabel {
|
||||
|
|
@ -112,7 +111,7 @@ BaseNotificationItem {
|
|||
// HACK RichText does not allow to specify link color and since LineEdit
|
||||
// does not support StyledText, we have to inject some CSS to force the color,
|
||||
// cf. QTBUG-81463 and to some extent QTBUG-80354
|
||||
text: "<style>a { color: " + PlasmaCore.Theme.linkColor + "; }</style>" + notificationItem.body
|
||||
text: "<style>a { color: " + Kirigami.Theme.linkColor + "; }</style>" + notificationItem.body
|
||||
|
||||
// Cannot do text !== "" because RichText adds some HTML tags even when empty
|
||||
visible: notificationItem.body !== ""
|
||||
|
|
@ -121,10 +120,10 @@ BaseNotificationItem {
|
|||
// notification icon
|
||||
Item {
|
||||
id: iconContainer
|
||||
Layout.preferredWidth: PlasmaCore.Units.iconSizes.large
|
||||
Layout.preferredHeight: PlasmaCore.Units.iconSizes.large
|
||||
Layout.topMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.bottomMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.preferredWidth: Kirigami.Units.iconSizes.large
|
||||
Layout.preferredHeight: Kirigami.Units.iconSizes.large
|
||||
Layout.topMargin: Kirigami.Units.smallSpacing
|
||||
Layout.bottomMargin: Kirigami.Units.smallSpacing
|
||||
|
||||
visible: iconItem.active
|
||||
|
||||
|
|
@ -151,7 +150,7 @@ BaseNotificationItem {
|
|||
// thumbnails
|
||||
Loader {
|
||||
id: thumbnailStripLoader
|
||||
Layout.topMargin: Kirigami.Units.largeSpacing
|
||||
Layout.topMargin: Kirigami.Units.gridUnit
|
||||
Layout.fillWidth: true
|
||||
active: notificationItem.urls.length > 0
|
||||
visible: active
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@
|
|||
import QtQuick 2.8
|
||||
import QtQuick.Layouts 1.1
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents3
|
||||
|
||||
RowLayout {
|
||||
|
|
@ -24,7 +24,7 @@ RowLayout {
|
|||
property string buttonIconName
|
||||
property string buttonText
|
||||
|
||||
spacing: PlasmaCore.Units.smallSpacing
|
||||
spacing: Kirigami.Units.smallSpacing
|
||||
|
||||
function activate() {
|
||||
replyTextField.forceActiveFocus();
|
||||
|
|
|
|||
|
|
@ -9,10 +9,8 @@ import QtQuick 2.8
|
|||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Window 2.2
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.plasma5support 2.0 as P5Support
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.plasma.extras 2.0 as PlasmaExtras
|
||||
|
||||
import org.kde.notificationmanager 1.0 as NotificationManager
|
||||
|
||||
|
|
@ -47,7 +45,7 @@ PlasmaComponents.Label {
|
|||
ageLabel.agoText = Util.generateNotificationHeaderAgoText(time, jobState);
|
||||
}
|
||||
|
||||
font.pixelSize: PlasmaCore.Theme.defaultFont.pixelSize * 0.8
|
||||
font.pixelSize: Kirigami.Theme.defaultFont.pixelSize * 0.8
|
||||
|
||||
// the "n minutes ago" text, for jobs we show remaining time instead
|
||||
// updated periodically by a Timer hence this property with generate() function
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@ import Qt5Compat.GraphicalEffects
|
|||
|
||||
import org.kde.kirigami 2.12 as Kirigami
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.plasma5support 2.0 as P5Support
|
||||
import org.kde.plasma.private.mobileshell 1.0 as MobileShell
|
||||
import org.kde.plasma.private.mobileshell.shellsettingsplugin as ShellSettings
|
||||
|
|
@ -144,7 +143,7 @@ Item {
|
|||
|
||||
property var pendingNotificationWithAction
|
||||
|
||||
readonly property int animationDuration: ShellSettings.Settings.animationsEnabled ? PlasmaCore.Units.longDuration : 0
|
||||
readonly property int animationDuration: ShellSettings.Settings.animationsEnabled ? Kirigami.Units.longDuration : 0
|
||||
|
||||
// If a screen overflow occurs, fix height in order to maintain tool buttons in place.
|
||||
readonly property bool listOverflowing: contentItem.childrenRect.height + toolButtons.height + spacing >= root.height
|
||||
|
|
@ -159,7 +158,7 @@ Item {
|
|||
}
|
||||
|
||||
boundsBehavior: Flickable.StopAtBounds
|
||||
spacing: Kirigami.Units.largeSpacing
|
||||
spacing: Kirigami.Units.gridUnit
|
||||
|
||||
// TODO keyboard focus
|
||||
highlightMoveDuration: 0
|
||||
|
|
@ -173,7 +172,7 @@ Item {
|
|||
|
||||
PlasmaExtras.PlaceholderMessage {
|
||||
anchors.centerIn: parent
|
||||
width: parent.width - (PlasmaCore.Units.largeSpacing * 4)
|
||||
width: parent.width - (Kirigami.Units.gridUnit * 4)
|
||||
|
||||
text: i18n("Notification service not available")
|
||||
visible: list.count === 0 && !NotificationManager.Server.valid && historyModelType === NotificationsModelType.NotificationsModel
|
||||
|
|
@ -230,9 +229,9 @@ Item {
|
|||
|
||||
anchors {
|
||||
left: parent ? parent.left : undefined
|
||||
leftMargin: PlasmaCore.Units.largeSpacing
|
||||
leftMargin: Kirigami.Units.gridUnit
|
||||
right: parent ? parent.right : undefined
|
||||
rightMargin: PlasmaCore.Units.largeSpacing
|
||||
rightMargin: Kirigami.Units.gridUnit
|
||||
}
|
||||
|
||||
height: model.isGroup ? groupDelegate.height : notificationDelegate.height
|
||||
|
|
@ -263,7 +262,7 @@ Item {
|
|||
id: notificationDelegate
|
||||
|
||||
Column {
|
||||
spacing: PlasmaCore.Units.smallSpacing
|
||||
spacing: Kirigami.Units.smallSpacing
|
||||
|
||||
height: notificationItem.height + showMoreLoader.height
|
||||
|
||||
|
|
@ -354,7 +353,7 @@ Item {
|
|||
visible: list.listOverflowing
|
||||
height: 1
|
||||
opacity: 0.25
|
||||
color: PlasmaCore.Theme.textColor
|
||||
color: Kirigami.Theme.textColor
|
||||
}
|
||||
|
||||
RowLayout {
|
||||
|
|
@ -364,8 +363,8 @@ Item {
|
|||
top: spacer.bottom
|
||||
right: parent.right
|
||||
left: parent.left
|
||||
leftMargin: PlasmaCore.Units.largeSpacing
|
||||
rightMargin: PlasmaCore.Units.largeSpacing
|
||||
leftMargin: Kirigami.Units.gridUnit
|
||||
rightMargin: Kirigami.Units.gridUnit
|
||||
topMargin: list.spacing
|
||||
bottomMargin: list.spacing
|
||||
}
|
||||
|
|
|
|||
|
|
@ -8,9 +8,9 @@ import QtQuick
|
|||
import QtQuick.Layouts
|
||||
import QtQuick.Effects
|
||||
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents3
|
||||
import org.kde.plasma.extras 2.0 as PlasmaExtras
|
||||
import org.kde.plasma.private.mobileshell 1.0 as MobileShell
|
||||
|
||||
import org.kde.kquickcontrolsaddons 2.0 as KQCAddons
|
||||
|
|
@ -95,7 +95,7 @@ MouseArea {
|
|||
PlasmaCore.IconItem {
|
||||
anchors.centerIn: parent
|
||||
width: height
|
||||
height: PlasmaCore.Units.roundToIconSize(parent.height)
|
||||
height: Kirigami.Units.iconSizes.roundedIconSize(parent.height)
|
||||
usesPlasmaTheme: false
|
||||
source: !thumbnailer.busy && !thumbnailer.hasPreview ? thumbnailer.iconName : ""
|
||||
}
|
||||
|
|
@ -111,7 +111,7 @@ MouseArea {
|
|||
anchors {
|
||||
top: parent.top
|
||||
right: parent.right
|
||||
margins: PlasmaCore.Units.smallSpacing
|
||||
margins: Kirigami.Units.smallSpacing
|
||||
}
|
||||
Accessible.name: tooltip.text
|
||||
icon.name: "application-menu"
|
||||
|
|
|
|||
|
|
@ -8,8 +8,9 @@ import QtQuick 2.4
|
|||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Controls 2.3 as Controls
|
||||
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import org.kde.plasma.plasmoid 2.0
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.kquickcontrolsaddons 2.0
|
||||
|
||||
|
||||
|
|
@ -26,13 +27,13 @@ LauncherContainer {
|
|||
|
||||
Behavior on height {
|
||||
NumberAnimation {
|
||||
duration: PlasmaCore.Units.longDuration
|
||||
duration: Kirigami.Units.longDuration
|
||||
easing.type: Easing.InOutQuad
|
||||
}
|
||||
}
|
||||
Behavior on opacity {
|
||||
OpacityAnimator {
|
||||
duration: PlasmaCore.Units.longDuration * 4
|
||||
duration: Kirigami.Units.longDuration * 4
|
||||
easing.type: Easing.InOutQuad
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -8,7 +8,6 @@ import QtQuick 2.15
|
|||
import QtQuick.Layouts 1.15
|
||||
|
||||
import org.kde.taskmanager 0.1 as TaskManager
|
||||
import org.kde.plasma.core 2.1 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.plasma.private.mobileshell 1.0 as MobileShell
|
||||
|
||||
|
|
|
|||
|
|
@ -9,6 +9,8 @@ import QtQuick.Layouts 1.1
|
|||
import QtQuick.Controls 2.3 as Controls
|
||||
import Qt5Compat.GraphicalEffects
|
||||
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import org.kde.plasma.plasmoid 2.0
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PC3
|
||||
|
|
@ -60,7 +62,7 @@ ContainmentLayoutManager.ItemContainer {
|
|||
if (modelData.applicationRunning) {
|
||||
delegate.launch(0, 0, "", modelData.applicationName);
|
||||
} else {
|
||||
delegate.launch(delegate.x + (PlasmaCore.Units.smallSpacing * 2), delegate.y + (PlasmaCore.Units.smallSpacing * 2), icon.source, modelData.applicationName);
|
||||
delegate.launch(delegate.x + (Kirigami.Units.smallSpacing * 2), delegate.y + (Kirigami.Units.smallSpacing * 2), icon.source, modelData.applicationName);
|
||||
}
|
||||
|
||||
desktopModel.setMinimizedDelegate(index, delegate);
|
||||
|
|
@ -148,10 +150,10 @@ ContainmentLayoutManager.ItemContainer {
|
|||
ColumnLayout {
|
||||
anchors {
|
||||
fill: parent
|
||||
leftMargin: PlasmaCore.Units.smallSpacing * 2
|
||||
topMargin: PlasmaCore.Units.smallSpacing * 2
|
||||
rightMargin: PlasmaCore.Units.smallSpacing * 2
|
||||
bottomMargin: PlasmaCore.Units.smallSpacing * 2
|
||||
leftMargin: Kirigami.Units.smallSpacing * 2
|
||||
topMargin: Kirigami.Units.smallSpacing * 2
|
||||
rightMargin: Kirigami.Units.smallSpacing * 2
|
||||
bottomMargin: Kirigami.Units.smallSpacing * 2
|
||||
}
|
||||
spacing: 0
|
||||
|
||||
|
|
@ -160,7 +162,7 @@ ContainmentLayoutManager.ItemContainer {
|
|||
|
||||
Layout.alignment: Qt.AlignHCenter | Qt.AlignTop
|
||||
Layout.fillWidth: true
|
||||
Layout.minimumHeight: Math.min(PlasmaCore.Units.iconSizes.large, parent.height - delegate.reservedSpaceForLabel)
|
||||
Layout.minimumHeight: Math.min(Kirigami.Units.iconSizes.large, parent.height - delegate.reservedSpaceForLabel)
|
||||
Layout.preferredHeight: Layout.minimumHeight
|
||||
|
||||
usesPlasmaTheme: false
|
||||
|
|
@ -173,9 +175,9 @@ ContainmentLayoutManager.ItemContainer {
|
|||
}
|
||||
visible: model.applicationRunning
|
||||
radius: width
|
||||
width: PlasmaCore.Units.smallSpacing
|
||||
width: Kirigami.Units.smallSpacing
|
||||
height: width
|
||||
color: PlasmaCore.Theme.highlightColor
|
||||
color: Kirigami.Theme.highlightColor
|
||||
}
|
||||
|
||||
// darken effect when hovered/pressed
|
||||
|
|
@ -200,9 +202,9 @@ ContainmentLayoutManager.ItemContainer {
|
|||
Layout.fillWidth: true
|
||||
Layout.preferredHeight: delegate.reservedSpaceForLabel
|
||||
Layout.alignment: Qt.AlignTop
|
||||
Layout.topMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.leftMargin: -parent.anchors.leftMargin + PlasmaCore.Units.smallSpacing * 2
|
||||
Layout.rightMargin: -parent.anchors.rightMargin + PlasmaCore.Units.smallSpacing * 2
|
||||
Layout.topMargin: Kirigami.Units.smallSpacing
|
||||
Layout.leftMargin: -parent.anchors.leftMargin + Kirigami.Units.smallSpacing * 2
|
||||
Layout.rightMargin: -parent.anchors.rightMargin + Kirigami.Units.smallSpacing * 2
|
||||
|
||||
wrapMode: Text.WordWrap
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
|
|
@ -212,7 +214,7 @@ ContainmentLayoutManager.ItemContainer {
|
|||
|
||||
text: model.applicationName
|
||||
|
||||
font.pointSize: PlasmaCore.Theme.defaultFont.pointSize * 0.8
|
||||
font.pointSize: Kirigami.Theme.defaultFont.pointSize * 0.8
|
||||
font.weight: Font.Bold
|
||||
color: "white"
|
||||
|
||||
|
|
|
|||
|
|
@ -10,7 +10,6 @@ import QtQuick.Window 2.12
|
|||
import QtQuick.Layouts 1.1
|
||||
|
||||
import org.kde.plasma.plasmoid 2.0
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.draganddrop 2.0 as DragDrop
|
||||
|
||||
|
|
|
|||
|
|
@ -9,8 +9,9 @@ import QtQuick.Window 2.12
|
|||
import QtQuick.Layouts 1.1
|
||||
import Qt5Compat.GraphicalEffects
|
||||
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import org.kde.plasma.plasmoid 2.0
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.draganddrop 2.0 as DragDrop
|
||||
|
||||
|
|
@ -89,10 +90,10 @@ DragDrop.DropArea {
|
|||
|
||||
let scenePos = mapToItem(null, event.x, event.y);
|
||||
//SCROLL LEFT
|
||||
if (scenePos.x < PlasmaCore.Units.gridUnit) {
|
||||
if (scenePos.x < Kirigami.Units.gridUnit) {
|
||||
homeScreenPages.scrollLeft();
|
||||
//SCROLL RIGHT
|
||||
} else if (scenePos.x > homeScreenPages.width - PlasmaCore.Units.gridUnit) {
|
||||
} else if (scenePos.x > homeScreenPages.width - Kirigami.Units.gridUnit) {
|
||||
homeScreenPages.scrollRight();
|
||||
//DON't SCROLL
|
||||
} else {
|
||||
|
|
@ -194,10 +195,10 @@ DragDrop.DropArea {
|
|||
// Sets the containment in edit mode when we go in edit mode as well
|
||||
onEditModeChanged: plasmoid.editMode = editMode;
|
||||
|
||||
minimumItemWidth: PlasmaCore.Units.gridUnit * 3
|
||||
minimumItemWidth: Kirigami.Units.gridUnit * 3
|
||||
minimumItemHeight: minimumItemWidth
|
||||
|
||||
defaultItemWidth: PlasmaCore.Units.gridUnit * 6
|
||||
defaultItemWidth: Kirigami.Units.gridUnit * 6
|
||||
defaultItemHeight: defaultItemWidth
|
||||
|
||||
acceptsAppletCallback: function(applet, x, y) {
|
||||
|
|
@ -219,7 +220,7 @@ DragDrop.DropArea {
|
|||
id: metrics
|
||||
text: "M\nM"
|
||||
visible: false
|
||||
font.pointSize: PlasmaCore.Theme.defaultFont.pointSize * 0.9
|
||||
font.pointSize: Kirigami.Theme.defaultFont.pointSize * 0.9
|
||||
}
|
||||
LauncherRepeater {
|
||||
id: launcherRepeater
|
||||
|
|
|
|||
|
|
@ -9,8 +9,9 @@ import QtQuick 2.12
|
|||
import QtQuick.Window 2.12
|
||||
import QtQuick.Layouts 1.1
|
||||
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import org.kde.plasma.plasmoid 2.0
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.draganddrop 2.0 as DragDrop
|
||||
|
||||
|
|
@ -82,7 +83,7 @@ MobileShell.Flickable {
|
|||
repeat: true
|
||||
interval: 1500
|
||||
onTriggered: {
|
||||
homeScreenState.animateGoToPageIndex(Math.max(0, homeScreenState.currentPageIndex + (scrollRight ? 1 : -1)), PlasmaCore.Units.longDuration * 2);
|
||||
homeScreenState.animateGoToPageIndex(Math.max(0, homeScreenState.currentPageIndex + (scrollRight ? 1 : -1)), Kirigami.Units.longDuration * 2);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -94,8 +95,8 @@ MobileShell.Flickable {
|
|||
bottomMargin: mainFlickable.footer ? mainFlickable.footer.height : 0
|
||||
}
|
||||
|
||||
PlasmaCore.ColorScope.inherit: false
|
||||
PlasmaCore.ColorScope.colorGroup: PlasmaCore.Theme.ComplementaryColorGroup
|
||||
Kirigami.Theme.inherit: false
|
||||
Kirigami.Theme.colorSet: Kirigami.Theme.Complementary
|
||||
|
||||
parent: mainFlickable
|
||||
visible: count > 1
|
||||
|
|
@ -105,11 +106,11 @@ MobileShell.Flickable {
|
|||
|
||||
delegate: Rectangle {
|
||||
property bool isAddPageIndicator: index === pageIndicator.count-1 && mainFlickable.showAddPageIndicator
|
||||
implicitWidth: PlasmaCore.Units.gridUnit/2
|
||||
implicitWidth: Kirigami.Units.gridUnit/2
|
||||
implicitHeight: implicitWidth
|
||||
|
||||
radius: width
|
||||
color: isAddPageIndicator ? "transparent" : PlasmaCore.ColorScope.textColor
|
||||
color: isAddPageIndicator ? "transparent" : Kirigami.Theme.textColor
|
||||
|
||||
PlasmaComponents.Label {
|
||||
anchors.centerIn: parent
|
||||
|
|
@ -120,7 +121,7 @@ MobileShell.Flickable {
|
|||
opacity: index === pageIndicator.currentIndex ? 0.9 : pressed ? 0.7 : 0.5
|
||||
Behavior on opacity {
|
||||
OpacityAnimator {
|
||||
duration: PlasmaCore.Units.longDuration
|
||||
duration: Kirigami.Units.longDuration
|
||||
easing.type: Easing.InOutQuad
|
||||
}
|
||||
}
|
||||
|
|
@ -142,7 +143,7 @@ MobileShell.Flickable {
|
|||
id: scrollLeftIndicator
|
||||
anchors {
|
||||
left: parent.left
|
||||
leftMargin: PlasmaCore.Units.smallSpacing
|
||||
leftMargin: Kirigami.Units.smallSpacing
|
||||
}
|
||||
elementId: "left-arrow"
|
||||
}
|
||||
|
|
@ -150,7 +151,7 @@ MobileShell.Flickable {
|
|||
id: scrollRightIndicator
|
||||
anchors {
|
||||
right: parent.right
|
||||
rightMargin: PlasmaCore.Units.smallSpacing
|
||||
rightMargin: Kirigami.Units.smallSpacing
|
||||
}
|
||||
elementId: "right-arrow"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@
|
|||
|
||||
import QtQuick 2.15
|
||||
|
||||
import org.kde.plasma.core 2.1 as PlasmaCore
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import org.kde.plasma.private.mobileshell 1.0 as MobileShell
|
||||
|
||||
|
|
@ -311,7 +311,7 @@ QtObject {
|
|||
case HomeScreenState.SwipingPages: {
|
||||
// update pages position
|
||||
let currentPageIndexPosition = xPositionFromPageIndex(currentPageIndex);
|
||||
let duration = PlasmaCore.Units.longDuration * 2;
|
||||
let duration = Kirigami.Units.longDuration * 2;
|
||||
|
||||
if (xPosition < currentPageIndexPosition) {
|
||||
if (movingRight) {
|
||||
|
|
@ -409,7 +409,7 @@ QtObject {
|
|||
target: root
|
||||
property: "yPosition"
|
||||
to: appDrawerOpenYPosition
|
||||
duration: PlasmaCore.Units.longDuration * 2
|
||||
duration: Kirigami.Units.longDuration * 2
|
||||
easing.type: Easing.OutCubic
|
||||
|
||||
onFinished: {
|
||||
|
|
@ -422,7 +422,7 @@ QtObject {
|
|||
target: root
|
||||
property: "yPosition"
|
||||
to: pagesYPosition
|
||||
duration: PlasmaCore.Units.longDuration * 2
|
||||
duration: Kirigami.Units.longDuration * 2
|
||||
easing.type: Easing.OutCubic
|
||||
|
||||
onFinished: {
|
||||
|
|
|
|||
|
|
@ -8,8 +8,9 @@ import QtQuick 2.4
|
|||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Controls 2.3 as Controls
|
||||
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import org.kde.plasma.plasmoid 2.0
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.kquickcontrolsaddons 2.0
|
||||
|
||||
import org.kde.plasma.private.containmentlayoutmanager 1.0 as ContainmentLayoutManager
|
||||
|
|
@ -18,9 +19,9 @@ Item {
|
|||
id: root
|
||||
|
||||
readonly property int reservedSpaceForLabel: metrics.height
|
||||
readonly property int cellWidth: root.width / Math.floor(root.width / ((availableCellHeight - reservedSpaceForLabel) + PlasmaCore.Units.smallSpacing*4))
|
||||
readonly property int cellWidth: root.width / Math.floor(root.width / ((availableCellHeight - reservedSpaceForLabel) + Kirigami.Units.smallSpacing*4))
|
||||
readonly property int cellHeight: availableCellHeight
|
||||
property int availableCellHeight: PlasmaCore.Units.iconSizes.huge + reservedSpaceForLabel
|
||||
property int availableCellHeight: Kirigami.Units.iconSizes.huge + reservedSpaceForLabel
|
||||
|
||||
property ContainmentLayoutManager.AppletsLayout appletsLayout
|
||||
|
||||
|
|
@ -28,18 +29,18 @@ Item {
|
|||
property alias flow: applicationsFlow
|
||||
|
||||
implicitWidth: frame.implicitWidth
|
||||
implicitHeight: Math.max(PlasmaCore.Units.gridUnit*3, frame.implicitHeight)
|
||||
implicitHeight: Math.max(Kirigami.Units.gridUnit*3, frame.implicitHeight)
|
||||
|
||||
Controls.Label {
|
||||
id: metrics
|
||||
text: "M\nM"
|
||||
visible: false
|
||||
font.pointSize: PlasmaCore.Theme.defaultFont.pointSize * 0.9
|
||||
font.pointSize: Kirigami.Theme.defaultFont.pointSize * 0.9
|
||||
}
|
||||
|
||||
Item {
|
||||
id: spacer
|
||||
width: PlasmaCore.Units.gridUnit * 4
|
||||
width: Kirigami.Units.gridUnit * 4
|
||||
height: width
|
||||
}
|
||||
|
||||
|
|
@ -67,7 +68,7 @@ Item {
|
|||
|
||||
move: Transition {
|
||||
NumberAnimation {
|
||||
duration: PlasmaCore.Units.longDuration
|
||||
duration: Kirigami.Units.longDuration
|
||||
easing.type: Easing.InOutQuad
|
||||
properties: "x,y"
|
||||
}
|
||||
|
|
@ -76,7 +77,7 @@ Item {
|
|||
}
|
||||
Behavior on implicitWidth {
|
||||
NumberAnimation {
|
||||
duration: PlasmaCore.Units.longDuration
|
||||
duration: Kirigami.Units.longDuration
|
||||
easing.type: Easing.InOutQuad
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -10,7 +10,6 @@ import QtQuick.Controls 2.3 as Controls
|
|||
import Qt5Compat.GraphicalEffects
|
||||
|
||||
import org.kde.plasma.plasmoid 2.0
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.kquickcontrolsaddons 2.0
|
||||
|
||||
import org.kde.plasma.private.containmentlayoutmanager 1.0 as ContainmentLayoutManager
|
||||
|
|
@ -77,10 +76,10 @@ Repeater {
|
|||
var pos = plasmoid.fullRepresentationItem.mapFromItem(delegate, dragCenter.x, dragCenter.y);
|
||||
|
||||
//SCROLL LEFT
|
||||
if (pos.x < PlasmaCore.Units.gridUnit) {
|
||||
if (pos.x < Kirigami.Units.gridUnit) {
|
||||
launcherRepeater.scrollLeftRequested();
|
||||
//SCROLL RIGHT
|
||||
} else if (pos.x > homeScreenState.pageWidth - PlasmaCore.Units.gridUnit) {
|
||||
} else if (pos.x > homeScreenState.pageWidth - Kirigami.Units.gridUnit) {
|
||||
launcherRepeater.scrollRightRequested();
|
||||
//DON't SCROLL
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -9,8 +9,9 @@ import QtQuick.Window 2.12
|
|||
import QtQuick.Layouts 1.1
|
||||
import Qt5Compat.GraphicalEffects
|
||||
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import org.kde.plasma.plasmoid 2.0
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.draganddrop 2.0 as DragDrop
|
||||
|
||||
|
|
@ -68,10 +69,10 @@ ContainmentLayoutManager.BasicAppletContainer {
|
|||
var pos = plasmoid.fullRepresentationItem.mapFromItem(appletContainer, dragCenter.x, dragCenter.y);
|
||||
|
||||
//SCROLL LEFT
|
||||
if (pos.x < PlasmaCore.Units.gridUnit) {
|
||||
if (pos.x < Kirigami.Units.gridUnit) {
|
||||
launcherRepeater.scrollLeftRequested();
|
||||
//SCROLL RIGHT
|
||||
} else if (pos.x > screenWidth - PlasmaCore.Units.gridUnit) {
|
||||
} else if (pos.x > screenWidth - Kirigami.Units.gridUnit) {
|
||||
launcherRepeater.scrollRightRequested();
|
||||
//DON't SCROLL
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -10,9 +10,7 @@ import QtQuick.Layouts 1.1
|
|||
import QtQuick.Controls 2.15 as Controls
|
||||
|
||||
import org.kde.plasma.plasmoid 2.0
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PC3
|
||||
import org.kde.plasma.extras 2.0 as PlasmaExtra
|
||||
import org.kde.kirigami 2.10 as Kirigami
|
||||
|
||||
import org.kde.plasma.private.mobileshell 1.0 as MobileShell
|
||||
|
|
@ -41,9 +39,9 @@ Item {
|
|||
signal dragStarted
|
||||
|
||||
readonly property int reservedSpaceForLabel: metrics.height
|
||||
property int availableCellHeight: PlasmaCore.Units.iconSizes.huge + reservedSpaceForLabel
|
||||
property int availableCellHeight: Kirigami.Units.iconSizes.huge + reservedSpaceForLabel
|
||||
|
||||
readonly property real openFactor: factorNormalize(view.contentY / (PlasmaCore.Units.gridUnit * 10))
|
||||
readonly property real openFactor: factorNormalize(view.contentY / (Kirigami.Units.gridUnit * 10))
|
||||
|
||||
// height from top of screen that the drawer starts
|
||||
readonly property real drawerTopMargin: height - topPadding - bottomPadding - closedPositionOffset
|
||||
|
|
@ -63,7 +61,7 @@ Item {
|
|||
id: metrics
|
||||
text: "M\nM"
|
||||
visible: false
|
||||
font.pointSize: PlasmaCore.Theme.defaultFont.pointSize * 0.8
|
||||
font.pointSize: Kirigami.Theme.defaultFont.pointSize * 0.8
|
||||
font.weight: Font.Bold
|
||||
}
|
||||
|
||||
|
|
@ -137,7 +135,7 @@ Item {
|
|||
opacity: 0.6 * root.openFactor
|
||||
|
||||
// remove radius
|
||||
radius: view.contentY > (topMargin.height - PlasmaCore.Units.gridUnit) ? 0 : PlasmaCore.Units.gridUnit
|
||||
radius: view.contentY > (topMargin.height - Kirigami.Units.gridUnit) ? 0 : Kirigami.Units.gridUnit
|
||||
Behavior on radius {
|
||||
NumberAnimation { duration: Kirigami.Units.shortDuration; easing.type: Easing.InOutQuad }
|
||||
}
|
||||
|
|
|
|||
|
|
@ -7,17 +7,18 @@
|
|||
import QtQuick 2.12
|
||||
import QtQuick.Layouts 1.1
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.plasma.extras 2.0 as PlasmaExtra
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
PlasmaCore.ColorScope {
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
|
||||
Item {
|
||||
id: root
|
||||
|
||||
signal switchToListRequested()
|
||||
signal switchToGridRequested()
|
||||
|
||||
colorGroup: PlasmaCore.Theme.ComplementaryColorGroup
|
||||
Kirigami.Theme.colorSet: Kirigami.Theme.Complementary
|
||||
Kirigami.Theme.inherit: false
|
||||
|
||||
// HACK: Here only to steal inputs the would normally be delivered to home
|
||||
MouseArea {
|
||||
|
|
@ -25,13 +26,13 @@ PlasmaCore.ColorScope {
|
|||
}
|
||||
|
||||
RowLayout {
|
||||
anchors.topMargin: PlasmaCore.Units.smallSpacing
|
||||
anchors.leftMargin: PlasmaCore.Units.largeSpacing
|
||||
anchors.rightMargin: PlasmaCore.Units.largeSpacing
|
||||
anchors.topMargin: Kirigami.Units.smallSpacing
|
||||
anchors.leftMargin: Kirigami.Units.gridUnit
|
||||
anchors.rightMargin: Kirigami.Units.gridUnit
|
||||
anchors.fill: parent
|
||||
spacing: PlasmaCore.Units.smallSpacing
|
||||
spacing: Kirigami.Units.smallSpacing
|
||||
|
||||
PlasmaExtra.Heading {
|
||||
Kirigami.Heading {
|
||||
color: "white"
|
||||
level: 1
|
||||
text: i18n("Applications")
|
||||
|
|
@ -40,14 +41,14 @@ PlasmaCore.ColorScope {
|
|||
Item { Layout.fillWidth: true }
|
||||
PlasmaComponents.ToolButton {
|
||||
icon.name: "view-list-symbolic"
|
||||
implicitWidth: Math.round(PlasmaCore.Units.gridUnit * 2.1)
|
||||
implicitHeight: Math.round(PlasmaCore.Units.gridUnit * 2.1)
|
||||
implicitWidth: Math.round(Kirigami.Units.gridUnit * 2.1)
|
||||
implicitHeight: Math.round(Kirigami.Units.gridUnit * 2.1)
|
||||
onClicked: root.switchToListRequested()
|
||||
}
|
||||
PlasmaComponents.ToolButton {
|
||||
icon.name: "view-grid-symbolic"
|
||||
implicitWidth: Math.round(PlasmaCore.Units.gridUnit * 2.1)
|
||||
implicitHeight: Math.round(PlasmaCore.Units.gridUnit * 2.1)
|
||||
implicitWidth: Math.round(Kirigami.Units.gridUnit * 2.1)
|
||||
implicitHeight: Math.round(Kirigami.Units.gridUnit * 2.1)
|
||||
onClicked: root.switchToGridRequested()
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -9,8 +9,9 @@ import QtQuick 2.12
|
|||
import QtQuick.Window 2.12
|
||||
import QtQuick.Layouts 1.1
|
||||
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import org.kde.plasma.plasmoid 2.0
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
|
||||
Loader {
|
||||
|
|
@ -25,7 +26,7 @@ Loader {
|
|||
|
||||
property string appDrawerType: "gridview" // gridview/listview
|
||||
|
||||
readonly property real headerHeight: Math.round(PlasmaCore.Units.gridUnit * 3)
|
||||
readonly property real headerHeight: Math.round(Kirigami.Units.gridUnit * 3)
|
||||
|
||||
sourceComponent: appDrawerType === "gridview" ? gridViewDrawer : listViewDrawer
|
||||
|
||||
|
|
|
|||
|
|
@ -9,6 +9,8 @@ import QtQuick.Layouts 1.1
|
|||
import QtQuick.Controls 2.3 as Controls
|
||||
import Qt5Compat.GraphicalEffects
|
||||
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import org.kde.plasma.plasmoid 2.0
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
|
|
@ -35,7 +37,7 @@ MouseArea {
|
|||
if (model.applicationRunning) {
|
||||
delegate.launch(0, 0, "", model.applicationName, model.applicationStorageId);
|
||||
} else {
|
||||
delegate.launch(delegate.x + (PlasmaCore.Units.smallSpacing * 2), delegate.y + (PlasmaCore.Units.smallSpacing * 2), icon.source, model.applicationName, model.applicationStorageId);
|
||||
delegate.launch(delegate.x + (Kirigami.Units.smallSpacing * 2), delegate.y + (Kirigami.Units.smallSpacing * 2), icon.source, model.applicationName, model.applicationStorageId);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -124,7 +126,7 @@ MouseArea {
|
|||
}
|
||||
visible: model.applicationRunning
|
||||
radius: width
|
||||
width: PlasmaCore.Units.smallSpacing
|
||||
width: Kirigami.Units.smallSpacing
|
||||
height: width
|
||||
color: theme.highlightColor
|
||||
}
|
||||
|
|
@ -144,9 +146,9 @@ MouseArea {
|
|||
|
||||
Layout.fillWidth: true
|
||||
Layout.preferredHeight: delegate.reservedSpaceForLabel
|
||||
Layout.topMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.leftMargin: -parent.anchors.leftMargin + PlasmaCore.Units.smallSpacing
|
||||
Layout.rightMargin: -parent.anchors.rightMargin + PlasmaCore.Units.smallSpacing
|
||||
Layout.topMargin: Kirigami.Units.smallSpacing
|
||||
Layout.leftMargin: -parent.anchors.leftMargin + Kirigami.Units.smallSpacing
|
||||
Layout.rightMargin: -parent.anchors.rightMargin + Kirigami.Units.smallSpacing
|
||||
|
||||
wrapMode: Text.WordWrap
|
||||
maximumLineCount: 2
|
||||
|
|
|
|||
|
|
@ -10,6 +10,8 @@ import QtQuick.Layouts 1.1
|
|||
import QtQuick.Controls 2.3 as Controls
|
||||
import Qt5Compat.GraphicalEffects
|
||||
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import org.kde.plasma.plasmoid 2.0
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
|
|
@ -37,7 +39,7 @@ MouseArea {
|
|||
if (model.applicationRunning) {
|
||||
delegate.launch(0, 0, "", model.applicationName, model.applicationStorageId);
|
||||
} else {
|
||||
delegate.launch(delegate.x + (PlasmaCore.Units.smallSpacing * 2), delegate.y + (PlasmaCore.Units.smallSpacing * 2), icon.source, model.applicationName, model.applicationStorageId);
|
||||
delegate.launch(delegate.x + (Kirigami.Units.smallSpacing * 2), delegate.y + (Kirigami.Units.smallSpacing * 2), icon.source, model.applicationName, model.applicationStorageId);
|
||||
}
|
||||
}
|
||||
hoverEnabled: true
|
||||
|
|
@ -46,17 +48,17 @@ MouseArea {
|
|||
anchors.fill: parent
|
||||
color: delegate.pressed ? Qt.rgba(255, 255, 255, 0.2) : (delegate.containsMouse ? Qt.rgba(255, 255, 255, 0.05) : "transparent")
|
||||
Behavior on color {
|
||||
ColorAnimation { duration: PlasmaCore.Units.shortDuration }
|
||||
ColorAnimation { duration: Kirigami.Units.shortDuration }
|
||||
}
|
||||
}
|
||||
|
||||
RowLayout {
|
||||
anchors {
|
||||
fill: parent
|
||||
leftMargin: PlasmaCore.Units.smallSpacing * 2
|
||||
topMargin: PlasmaCore.Units.smallSpacing
|
||||
rightMargin: PlasmaCore.Units.smallSpacing * 2
|
||||
bottomMargin: PlasmaCore.Units.smallSpacing
|
||||
leftMargin: Kirigami.Units.smallSpacing * 2
|
||||
topMargin: Kirigami.Units.smallSpacing
|
||||
rightMargin: Kirigami.Units.smallSpacing * 2
|
||||
bottomMargin: Kirigami.Units.smallSpacing
|
||||
}
|
||||
spacing: 0
|
||||
|
||||
|
|
@ -79,7 +81,7 @@ MouseArea {
|
|||
}
|
||||
visible: model.applicationRunning
|
||||
radius: width
|
||||
width: PlasmaCore.Units.smallSpacing
|
||||
width: Kirigami.Units.smallSpacing
|
||||
height: width
|
||||
color: theme.highlightColor
|
||||
}
|
||||
|
|
@ -91,8 +93,8 @@ MouseArea {
|
|||
|
||||
Layout.fillWidth: true
|
||||
wrapMode: Text.WordWrap
|
||||
Layout.leftMargin: PlasmaCore.Units.smallSpacing * 2
|
||||
Layout.rightMargin: PlasmaCore.Units.largeSpacing
|
||||
Layout.leftMargin: Kirigami.Units.smallSpacing * 2
|
||||
Layout.rightMargin: Kirigami.Units.gridUnit
|
||||
maximumLineCount: 1
|
||||
elide: Text.ElideRight
|
||||
|
||||
|
|
|
|||
|
|
@ -10,9 +10,7 @@ import QtQuick.Layouts 1.1
|
|||
import QtQuick.Controls 2.15 as Controls
|
||||
|
||||
import org.kde.plasma.plasmoid 2.0
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PC3
|
||||
import org.kde.plasma.extras 2.0 as PlasmaExtra
|
||||
import org.kde.kirigami 2.10 as Kirigami
|
||||
|
||||
import org.kde.plasma.private.mobileshell 1.0 as MobileShell
|
||||
|
|
@ -39,7 +37,7 @@ AbstractAppDrawer {
|
|||
leftMargin: horizontalMargin
|
||||
rightMargin: horizontalMargin
|
||||
|
||||
cellWidth: effectiveContentWidth / Math.min(Math.floor(effectiveContentWidth / (PlasmaCore.Units.iconSizes.huge + Kirigami.Units.largeSpacing * 2)), 8)
|
||||
cellWidth: effectiveContentWidth / Math.min(Math.floor(effectiveContentWidth / (Kirigami.Units.iconSizes.huge + Kirigami.Units.gridUnit * 2)), 8)
|
||||
cellHeight: cellWidth + root.reservedSpaceForLabel
|
||||
|
||||
readonly property int columns: Math.floor(effectiveContentWidth / cellWidth)
|
||||
|
|
@ -89,11 +87,11 @@ AbstractAppDrawer {
|
|||
enabled: true
|
||||
Behavior on opacity {
|
||||
OpacityAnimator {
|
||||
duration: PlasmaCore.Units.longDuration * 2
|
||||
duration: Kirigami.Units.longDuration * 2
|
||||
easing.type: Easing.InOutQuad
|
||||
}
|
||||
}
|
||||
implicitWidth: PlasmaCore.Units.smallSpacing
|
||||
implicitWidth: Kirigami.Units.smallSpacing
|
||||
contentItem: Rectangle {
|
||||
radius: width/2
|
||||
color: Qt.rgba(1, 1, 1, 0.3)
|
||||
|
|
|
|||
|
|
@ -10,9 +10,7 @@ import QtQuick.Layouts 1.1
|
|||
import QtQuick.Controls 2.15 as Controls
|
||||
|
||||
import org.kde.plasma.plasmoid 2.0
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PC3
|
||||
import org.kde.plasma.extras 2.0 as PlasmaExtra
|
||||
import org.kde.kirigami 2.10 as Kirigami
|
||||
|
||||
import org.kde.plasma.private.mobileshell 1.0 as MobileShell
|
||||
|
|
@ -31,7 +29,7 @@ AbstractAppDrawer {
|
|||
|
||||
interactive: root.homeScreenState.appDrawerInteractive
|
||||
|
||||
property int delegateHeight: PlasmaCore.Units.gridUnit * 3
|
||||
property int delegateHeight: Kirigami.Units.gridUnit * 3
|
||||
|
||||
model: Folio.ApplicationListModel
|
||||
|
||||
|
|
@ -75,11 +73,11 @@ AbstractAppDrawer {
|
|||
enabled: true
|
||||
Behavior on opacity {
|
||||
OpacityAnimator {
|
||||
duration: PlasmaCore.Units.longDuration * 2
|
||||
duration: Kirigami.Units.longDuration * 2
|
||||
easing.type: Easing.InOutQuad
|
||||
}
|
||||
}
|
||||
implicitWidth: PlasmaCore.Units.smallSpacing
|
||||
implicitWidth: Kirigami.Units.smallSpacing
|
||||
contentItem: Rectangle {
|
||||
radius: width/2
|
||||
color: Qt.rgba(1, 1, 1, 0.3)
|
||||
|
|
|
|||
|
|
@ -9,8 +9,9 @@ import QtQuick 2.15
|
|||
import QtQuick.Window 2.15
|
||||
import QtQuick.Layouts 1.1
|
||||
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import org.kde.plasma.plasmoid 2.0
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
|
||||
import org.kde.plasma.private.mobileshell 1.0 as MobileShell
|
||||
|
|
@ -59,7 +60,7 @@ ContainmentItem {
|
|||
id: homeScreen
|
||||
|
||||
onResetHomeScreenPosition: {
|
||||
folioHomeScreen.homeScreenState.animateGoToPageIndex(0, PlasmaCore.Units.longDuration);
|
||||
folioHomeScreen.homeScreenState.animateGoToPageIndex(0, Kirigami.Units.longDuration);
|
||||
folioHomeScreen.homeScreenState.closeAppDrawer();
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -8,6 +8,7 @@
|
|||
import QtQuick 2.0
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.ksvg 1.0 as KSvg
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
PlasmaCore.ToolTipArea {
|
||||
id: button
|
||||
|
|
@ -21,7 +22,7 @@ PlasmaCore.ToolTipArea {
|
|||
property alias elementId: icon.elementId
|
||||
property QtObject action
|
||||
property bool backgroundVisible: false
|
||||
property int iconSize: PlasmaCore.Units.iconSizes.large
|
||||
property int iconSize: Kirigami.Units.iconSizes.large
|
||||
property int pressedOffset: 1
|
||||
property bool checked: false
|
||||
property bool toggle: false
|
||||
|
|
@ -37,7 +38,7 @@ PlasmaCore.ToolTipArea {
|
|||
|
||||
Behavior on opacity {
|
||||
NumberAnimation {
|
||||
duration: PlasmaCore.Units.longDuration
|
||||
duration: Kirigami.Units.longDuration
|
||||
easing.type: Easing.InOutQuad
|
||||
}
|
||||
}
|
||||
|
|
@ -95,7 +96,7 @@ PlasmaCore.ToolTipArea {
|
|||
id: actionText
|
||||
text: button.text
|
||||
style: Text.Outline
|
||||
color: PlasmaCore.Theme.textColor
|
||||
color: Kirigami.Theme.textColor
|
||||
styleColor: Qt.rgba(1,1,1,0.4)
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
}
|
||||
|
|
|
|||
|
|
@ -7,8 +7,9 @@
|
|||
import QtQuick 2.12
|
||||
import QtQuick.Layouts 1.1
|
||||
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import org.kde.plasma.plasmoid 2.0
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.ksvg 1.0 as KSvg
|
||||
|
||||
|
|
@ -21,7 +22,7 @@ ContainmentLayoutManager.ConfigOverlayWithHandles {
|
|||
signal requestRemoveTrigger
|
||||
signal requestEditModeClose
|
||||
|
||||
readonly property int iconSize: PlasmaCore.Units.iconSizes.medium
|
||||
readonly property int iconSize: Kirigami.Units.iconSizes.medium
|
||||
KSvg.Svg {
|
||||
id: configIconsSvg
|
||||
imagePath: "widgets/configuration-icons"
|
||||
|
|
@ -45,7 +46,7 @@ ContainmentLayoutManager.ConfigOverlayWithHandles {
|
|||
property: "scale"
|
||||
from: 1
|
||||
to: 0
|
||||
duration: PlasmaCore.Units.longDuration
|
||||
duration: Kirigami.Units.longDuration
|
||||
easing.type: Easing.InOutQuad
|
||||
}
|
||||
ScriptAction {
|
||||
|
|
@ -65,7 +66,7 @@ ContainmentLayoutManager.ConfigOverlayWithHandles {
|
|||
|
||||
RowLayout {
|
||||
id: layout
|
||||
spacing: PlasmaCore.Units.largeSpacing
|
||||
spacing: Kirigami.Units.gridUnit
|
||||
anchors {
|
||||
fill: parent
|
||||
topMargin: parent.margins.top
|
||||
|
|
|
|||
|
|
@ -9,8 +9,9 @@ import QtQuick.Layouts 1.1
|
|||
import QtQuick.Controls 2.3 as Controls
|
||||
import Qt5Compat.GraphicalEffects
|
||||
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import org.kde.plasma.plasmoid 2.0
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PC3
|
||||
import org.kde.kquickcontrolsaddons 2.0
|
||||
|
||||
|
|
@ -54,7 +55,7 @@ PC3.RoundButton {
|
|||
property: "scale"
|
||||
from: 1
|
||||
to: 0
|
||||
duration: PlasmaCore.Units.longDuration
|
||||
duration: Kirigami.Units.longDuration
|
||||
easing.type: Easing.InOutQuad
|
||||
}
|
||||
ScriptAction {
|
||||
|
|
@ -70,7 +71,7 @@ PC3.RoundButton {
|
|||
id: removeButtonScaleAnim
|
||||
target: removeButton
|
||||
property: "scale"
|
||||
duration: PlasmaCore.Units.longDuration
|
||||
duration: Kirigami.Units.longDuration
|
||||
easing.type: Easing.InOutQuad
|
||||
}
|
||||
ScriptAction {
|
||||
|
|
|
|||
|
|
@ -5,12 +5,12 @@
|
|||
*/
|
||||
|
||||
import QtQuick 2.15
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
Item {
|
||||
Behavior on opacity {
|
||||
OpacityAnimator {
|
||||
duration: PlasmaCore.Units.longDuration * 2
|
||||
duration: Kirigami.Units.longDuration * 2
|
||||
easing.type: Easing.InOutQuad
|
||||
}
|
||||
}
|
||||
|
|
@ -20,8 +20,8 @@ Item {
|
|||
left: parent.left
|
||||
right: parent.right
|
||||
bottom: parent.bottom
|
||||
leftMargin: PlasmaCore.Units.gridUnit + root.leftPadding
|
||||
rightMargin: PlasmaCore.Units.gridUnit + root.rightPadding
|
||||
leftMargin: Kirigami.Units.gridUnit + root.leftPadding
|
||||
rightMargin: Kirigami.Units.gridUnit + root.rightPadding
|
||||
}
|
||||
height: 1
|
||||
gradient: Gradient {
|
||||
|
|
|
|||
|
|
@ -9,8 +9,9 @@ import QtQuick.Window 2.12
|
|||
import QtQuick.Layouts 1.1
|
||||
import Qt5Compat.GraphicalEffects
|
||||
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import org.kde.plasma.plasmoid 2.0
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.draganddrop 2.0 as DragDrop
|
||||
|
||||
|
|
@ -24,7 +25,7 @@ MouseArea {
|
|||
property real factor: 0
|
||||
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
height: PlasmaCore.Units.iconSizes.smallMedium
|
||||
height: Kirigami.Units.iconSizes.smallMedium
|
||||
signal openRequested
|
||||
signal closeRequested
|
||||
|
||||
|
|
@ -35,7 +36,7 @@ MouseArea {
|
|||
Item {
|
||||
anchors.centerIn: parent
|
||||
|
||||
width: PlasmaCore.Units.iconSizes.smallMedium
|
||||
width: Kirigami.Units.iconSizes.smallMedium
|
||||
height: width
|
||||
|
||||
Rectangle {
|
||||
|
|
|
|||
|
|
@ -6,8 +6,8 @@
|
|||
|
||||
import QtQuick 2.4
|
||||
import Qt5Compat.GraphicalEffects
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.ksvg 1.0 as KSvg
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
KSvg.SvgItem {
|
||||
id: scrollIndicator
|
||||
|
|
@ -18,10 +18,10 @@ KSvg.SvgItem {
|
|||
opacity: 0
|
||||
svg: KSvg.Svg {
|
||||
imagePath: "widgets/arrows"
|
||||
colorGroup: PlasmaCore.Theme.ComplementaryColorGroup
|
||||
colorGroup: Kirigami.Theme.ComplementaryColorGroup
|
||||
}
|
||||
elementId: "left-arrow"
|
||||
width: PlasmaCore.Units.iconSizes.large
|
||||
width: Kirigami.Units.iconSizes.large
|
||||
height: width
|
||||
layer.enabled: true
|
||||
layer.effect: DropShadow {
|
||||
|
|
@ -34,7 +34,7 @@ KSvg.SvgItem {
|
|||
}
|
||||
Behavior on opacity {
|
||||
OpacityAnimator {
|
||||
duration: PlasmaCore.Units.longDuration * 2
|
||||
duration: Kirigami.Units.longDuration * 2
|
||||
easing.type: Easing.InOutQuad
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -5,8 +5,8 @@ import QtQuick
|
|||
import QtQuick.Layouts
|
||||
import QtQuick.Controls
|
||||
|
||||
import org.kde.plasma.core as PlasmaCore
|
||||
import org.kde.plasma.plasma5support 2.0 as P5Support
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import org.kde.plasma.private.mobileshell as MobileShell
|
||||
|
||||
|
|
@ -36,7 +36,7 @@ ColumnLayout {
|
|||
}
|
||||
|
||||
Label {
|
||||
Layout.topMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.topMargin: Kirigami.Units.smallSpacing
|
||||
Layout.fillWidth: true
|
||||
|
||||
horizontalAlignment: Text.AlignLeft
|
||||
|
|
|
|||
|
|
@ -8,7 +8,6 @@ import QtQuick.Effects
|
|||
|
||||
import org.kde.plasma.core as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.plasma.extras 2.0 as PlasmaExtras
|
||||
import org.kde.kquickcontrolsaddons 2.0
|
||||
|
||||
import org.kde.plasma.private.containmentlayoutmanager 1.0 as ContainmentLayoutManager
|
||||
|
|
@ -71,7 +70,7 @@ Item {
|
|||
if (application.running) {
|
||||
launchAppWithAnim(0, 0, "", applicationName, applicationStorageId);
|
||||
} else {
|
||||
launchAppWithAnim(delegate.x + (PlasmaCore.Units.smallSpacing * 2), delegate.y + (PlasmaCore.Units.smallSpacing * 2), delegate.applicationIcon, applicationName, applicationStorageId);
|
||||
launchAppWithAnim(delegate.x + (Kirigami.Units.smallSpacing * 2), delegate.y + (Kirigami.Units.smallSpacing * 2), delegate.applicationIcon, applicationName, applicationStorageId);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -198,10 +197,10 @@ Item {
|
|||
id: rowLayout
|
||||
anchors {
|
||||
fill: parent
|
||||
leftMargin: PlasmaCore.Units.smallSpacing * 2
|
||||
topMargin: PlasmaCore.Units.smallSpacing
|
||||
rightMargin: PlasmaCore.Units.smallSpacing * 2
|
||||
bottomMargin: PlasmaCore.Units.smallSpacing
|
||||
leftMargin: Kirigami.Units.smallSpacing * 2
|
||||
topMargin: Kirigami.Units.smallSpacing
|
||||
rightMargin: Kirigami.Units.smallSpacing * 2
|
||||
bottomMargin: Kirigami.Units.smallSpacing
|
||||
}
|
||||
spacing: 0
|
||||
|
||||
|
|
@ -222,15 +221,15 @@ Item {
|
|||
textFormat: Text.MarkdownText
|
||||
|
||||
Layout.fillWidth: true
|
||||
Layout.leftMargin: PlasmaCore.Units.smallSpacing * 2
|
||||
Layout.rightMargin: PlasmaCore.Units.largeSpacing
|
||||
Layout.leftMargin: Kirigami.Units.smallSpacing * 2
|
||||
Layout.rightMargin: Kirigami.Units.gridUnit
|
||||
wrapMode: Text.WordWrap
|
||||
maximumLineCount: 1
|
||||
elide: Text.ElideRight
|
||||
|
||||
text: delegate.isFolder ? delegate.folderName : delegate.applicationName
|
||||
|
||||
font.pointSize: PlasmaCore.Theme.defaultFont.pointSize
|
||||
font.pointSize: Kirigami.Theme.defaultFont.pointSize
|
||||
font.weight: Font.Bold
|
||||
color: "white"
|
||||
|
||||
|
|
@ -265,9 +264,9 @@ Item {
|
|||
Item {
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
anchors.margins: PlasmaCore.Units.smallSpacing
|
||||
anchors.margins: Kirigami.Units.smallSpacing
|
||||
color: Qt.rgba(255, 255, 255, 0.2)
|
||||
radius: PlasmaCore.Units.smallSpacing
|
||||
radius: Kirigami.Units.smallSpacing
|
||||
opacity: delegate.dragFolderAnimationProgress
|
||||
}
|
||||
|
||||
|
|
@ -291,9 +290,9 @@ Item {
|
|||
}
|
||||
visible: application ? application.running : false
|
||||
radius: width
|
||||
width: PlasmaCore.Units.smallSpacing
|
||||
width: Kirigami.Units.smallSpacing
|
||||
height: width
|
||||
color: PlasmaCore.Theme.highlightColor
|
||||
color: Kirigami.Theme.highlightColor
|
||||
}
|
||||
|
||||
layer.enabled: true
|
||||
|
|
@ -314,9 +313,9 @@ Item {
|
|||
Rectangle {
|
||||
id: rect
|
||||
anchors.fill: parent
|
||||
anchors.margins: PlasmaCore.Units.smallSpacing
|
||||
anchors.margins: Kirigami.Units.smallSpacing
|
||||
color: Qt.rgba(255, 255, 255, 0.2)
|
||||
radius: PlasmaCore.Units.smallSpacing
|
||||
radius: Kirigami.Units.smallSpacing
|
||||
|
||||
transform: Scale {
|
||||
origin.x: rect.width / 2
|
||||
|
|
@ -329,17 +328,17 @@ Item {
|
|||
Grid {
|
||||
id: grid
|
||||
anchors.fill: parent
|
||||
anchors.margins: PlasmaCore.Units.smallSpacing * 2
|
||||
anchors.margins: Kirigami.Units.smallSpacing * 2
|
||||
columns: 2
|
||||
spacing: PlasmaCore.Units.smallSpacing
|
||||
spacing: Kirigami.Units.smallSpacing
|
||||
|
||||
property var previews: model.folder.appPreviews
|
||||
|
||||
Repeater {
|
||||
model: grid.previews
|
||||
delegate: Kirigami.Icon {
|
||||
implicitWidth: (grid.width - PlasmaCore.Units.smallSpacing) / 2
|
||||
implicitHeight: (grid.width - PlasmaCore.Units.smallSpacing) / 2
|
||||
implicitWidth: (grid.width - Kirigami.Units.smallSpacing) / 2
|
||||
implicitHeight: (grid.width - Kirigami.Units.smallSpacing) / 2
|
||||
source: modelData.icon
|
||||
|
||||
layer.enabled: true
|
||||
|
|
|
|||
|
|
@ -6,8 +6,6 @@ import QtQuick.Controls as QQC2
|
|||
import QtQuick.Layouts
|
||||
import QtQml.Models
|
||||
|
||||
import org.kde.plasma.core as PlasmaCore
|
||||
import org.kde.plasma.extras as PlasmaExtras
|
||||
import org.kde.plasma.components 3.0 as PC3
|
||||
import org.kde.draganddrop as DragDrop
|
||||
|
||||
|
|
@ -60,7 +58,7 @@ MobileShell.GridView {
|
|||
|
||||
header: MobileShell.BaseItem {
|
||||
topPadding: Math.round(root.height * 0.2)
|
||||
bottomPadding: PlasmaCore.Units.largeSpacing
|
||||
bottomPadding: Kirigami.Units.gridUnit
|
||||
// leftPadding: root.leftMargin
|
||||
// rightPadding: root.rightMargin
|
||||
implicitWidth: root.width
|
||||
|
|
@ -261,7 +259,7 @@ MobileShell.GridView {
|
|||
|
||||
ColumnLayout {
|
||||
id: placeholder
|
||||
spacing: PlasmaCore.Units.gridUnit
|
||||
spacing: Kirigami.Units.gridUnit
|
||||
visible: root.count == 0
|
||||
opacity: 0.9
|
||||
|
||||
|
|
@ -276,13 +274,13 @@ MobileShell.GridView {
|
|||
Kirigami.Icon {
|
||||
id: icon
|
||||
Layout.alignment: Qt.AlignBottom | Qt.AlignHCenter
|
||||
implicitWidth: PlasmaCore.Units.iconSizes.large
|
||||
implicitWidth: Kirigami.Units.iconSizes.large
|
||||
implicitHeight: width
|
||||
source: "arrow-left"
|
||||
color: "white"
|
||||
}
|
||||
|
||||
PlasmaExtras.Heading {
|
||||
Kirigami.Heading {
|
||||
Layout.fillWidth: true
|
||||
Layout.maximumWidth: placeholder.width * 0.75
|
||||
Layout.alignment: Qt.AlignTop | Qt.AlignHCenter
|
||||
|
|
|
|||
|
|
@ -6,8 +6,6 @@ import QtQuick.Controls 2.15 as QQC2
|
|||
import QtQuick.Layouts 1.1
|
||||
import QtQml.Models 2.15
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.extras 2.0 as PlasmaExtras
|
||||
import org.kde.plasma.components 3.0 as PC3
|
||||
import org.kde.draganddrop 2.0 as DragDrop
|
||||
|
||||
|
|
@ -22,7 +20,7 @@ Item {
|
|||
required property bool interactive
|
||||
required property var searchWidget
|
||||
|
||||
readonly property real twoColumnThreshold: PlasmaCore.Units.gridUnit * 16
|
||||
readonly property real twoColumnThreshold: Kirigami.Units.gridUnit * 16
|
||||
readonly property bool twoColumn: root.width / 2 > twoColumnThreshold
|
||||
|
||||
readonly property real cellWidth: twoColumn ? (root.width - leftMargin - rightMargin) / 2 : (root.width - leftMargin - rightMargin)
|
||||
|
|
@ -30,7 +28,7 @@ Item {
|
|||
|
||||
readonly property real leftMargin: Math.round(width * 0.1)
|
||||
readonly property real rightMargin: Math.round(width * 0.1)
|
||||
readonly property real delegateHeight: Math.round(PlasmaCore.Units.gridUnit * 3)
|
||||
readonly property real delegateHeight: Math.round(Kirigami.Units.gridUnit * 3)
|
||||
|
||||
property bool folderShown: false
|
||||
|
||||
|
|
@ -85,7 +83,7 @@ Item {
|
|||
root.openFolder();
|
||||
}
|
||||
|
||||
property real translateX: openFolderProgress * -PlasmaCore.Units.gridUnit
|
||||
property real translateX: openFolderProgress * -Kirigami.Units.gridUnit
|
||||
transform: Translate { x: favoritesGrid.translateX }
|
||||
opacity: 1 - openFolderProgress
|
||||
visible: opacity !== 0
|
||||
|
|
@ -115,7 +113,7 @@ Item {
|
|||
onOpenConfigureRequested: root.openConfigureRequested()
|
||||
onCloseRequested: root.closeFolder()
|
||||
|
||||
property real translateX: (1 - openProgress) * PlasmaCore.Units.gridUnit
|
||||
property real translateX: (1 - openProgress) * Kirigami.Units.gridUnit
|
||||
transform: Translate { x: folderGrid.translateX }
|
||||
opacity: openProgress
|
||||
visible: opacity !== 0
|
||||
|
|
@ -136,7 +134,7 @@ Item {
|
|||
|
||||
// when dragged
|
||||
onTranslationChanged: {
|
||||
let moveAmount = Math.max(0, translation.x) / (PlasmaCore.Units.gridUnit * 5);
|
||||
let moveAmount = Math.max(0, translation.x) / (Kirigami.Units.gridUnit * 5);
|
||||
folderGrid.openProgress = 1 - Math.min(1, Math.max(0, moveAmount));
|
||||
isClosing = translation.x > oldTranslationX;
|
||||
oldTranslationX = translation.x;
|
||||
|
|
|
|||
|
|
@ -7,8 +7,6 @@ import QtQuick.Layouts
|
|||
import QtQuick.Effects
|
||||
import QtQml.Models
|
||||
|
||||
import org.kde.plasma.core as PlasmaCore
|
||||
import org.kde.plasma.extras as PlasmaExtras
|
||||
import org.kde.plasma.components 3.0 as PC3
|
||||
import org.kde.draganddrop as DragDrop
|
||||
|
||||
|
|
@ -37,7 +35,7 @@ MobileShell.GridView {
|
|||
|
||||
header: MobileShell.BaseItem {
|
||||
topPadding: Math.round(root.height * 0.2)
|
||||
bottomPadding: PlasmaCore.Units.largeSpacing
|
||||
bottomPadding: Kirigami.Units.gridUnit
|
||||
leftPadding: 0
|
||||
rightPadding: 0
|
||||
implicitWidth: root.width
|
||||
|
|
@ -109,14 +107,14 @@ MobileShell.GridView {
|
|||
|
||||
contentItem: RowLayout {
|
||||
id: rowLayout
|
||||
spacing: PlasmaCore.Units.smallSpacing * 2
|
||||
spacing: Kirigami.Units.smallSpacing * 2
|
||||
|
||||
// close folder button
|
||||
MouseArea {
|
||||
id: button
|
||||
Layout.alignment: Qt.AlignVCenter
|
||||
implicitHeight: PlasmaCore.Units.iconSizes.small + PlasmaCore.Units.largeSpacing
|
||||
implicitWidth: PlasmaCore.Units.iconSizes.small + PlasmaCore.Units.largeSpacing
|
||||
implicitHeight: Kirigami.Units.iconSizes.small + Kirigami.Units.gridUnit
|
||||
implicitWidth: Kirigami.Units.iconSizes.small + Kirigami.Units.gridUnit
|
||||
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
onClicked: root.closeRequested()
|
||||
|
|
@ -131,8 +129,8 @@ MobileShell.GridView {
|
|||
// button icon
|
||||
Kirigami.Icon {
|
||||
anchors.centerIn: parent
|
||||
implicitHeight: PlasmaCore.Units.iconSizes.small
|
||||
implicitWidth: PlasmaCore.Units.iconSizes.small
|
||||
implicitHeight: Kirigami.Units.iconSizes.small
|
||||
implicitWidth: Kirigami.Units.iconSizes.small
|
||||
isMask: true
|
||||
color: 'white'
|
||||
source: 'arrow-left'
|
||||
|
|
|
|||
|
|
@ -11,7 +11,6 @@ import QtQuick.Controls as Controls
|
|||
|
||||
import org.kde.plasma.core as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.plasma.extras as PlasmaExtras
|
||||
import org.kde.kquickcontrolsaddons
|
||||
|
||||
import org.kde.plasma.private.mobileshell as MobileShell
|
||||
|
|
@ -48,7 +47,7 @@ MouseArea {
|
|||
if (application.running) {
|
||||
delegate.launch(0, 0, "", application.name, application.storageId);
|
||||
} else {
|
||||
delegate.launch(delegate.x + (PlasmaCore.Units.smallSpacing * 2), delegate.y + (PlasmaCore.Units.smallSpacing * 2), icon.source, application.name, application.storageId);
|
||||
delegate.launch(delegate.x + (Kirigami.Units.smallSpacing * 2), delegate.y + (Kirigami.Units.smallSpacing * 2), icon.source, application.name, application.storageId);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -155,7 +154,7 @@ MouseArea {
|
|||
}
|
||||
visible: application.running
|
||||
radius: width
|
||||
width: PlasmaCore.Units.smallSpacing
|
||||
width: Kirigami.Units.smallSpacing
|
||||
height: width
|
||||
color: theme.highlightColor
|
||||
}
|
||||
|
|
@ -181,9 +180,9 @@ MouseArea {
|
|||
|
||||
Layout.fillWidth: true
|
||||
Layout.preferredHeight: delegate.reservedSpaceForLabel
|
||||
Layout.topMargin: PlasmaCore.Units.smallSpacing
|
||||
Layout.leftMargin: -parent.anchors.leftMargin + PlasmaCore.Units.smallSpacing
|
||||
Layout.rightMargin: -parent.anchors.rightMargin + PlasmaCore.Units.smallSpacing
|
||||
Layout.topMargin: Kirigami.Units.smallSpacing
|
||||
Layout.leftMargin: -parent.anchors.leftMargin + Kirigami.Units.smallSpacing
|
||||
Layout.rightMargin: -parent.anchors.rightMargin + Kirigami.Units.smallSpacing
|
||||
|
||||
wrapMode: Text.WordWrap
|
||||
maximumLineCount: 2
|
||||
|
|
|
|||
|
|
@ -7,9 +7,7 @@ import QtQuick 2.15
|
|||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Controls 2.15 as Controls
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PC3
|
||||
import org.kde.plasma.extras 2.0 as PlasmaExtras
|
||||
import org.kde.kirigami 2.10 as Kirigami
|
||||
|
||||
import org.kde.plasma.private.mobileshell 1.0 as MobileShell
|
||||
|
|
@ -37,7 +35,7 @@ MobileShell.GridView {
|
|||
readonly property int reservedSpaceForLabel: metrics.height
|
||||
readonly property real effectiveContentWidth: width - leftMargin - rightMargin
|
||||
|
||||
cellWidth: gridView.effectiveContentWidth / Math.min(Math.floor(effectiveContentWidth / (PlasmaCore.Units.iconSizes.huge + Kirigami.Units.largeSpacing * 2)), 8)
|
||||
cellWidth: gridView.effectiveContentWidth / Math.min(Math.floor(effectiveContentWidth / (Kirigami.Units.iconSizes.huge + Kirigami.Units.gridUnit * 2)), 8)
|
||||
cellHeight: cellWidth + reservedSpaceForLabel
|
||||
|
||||
property int columns: Math.floor(effectiveContentWidth / cellWidth)
|
||||
|
|
@ -58,9 +56,9 @@ MobileShell.GridView {
|
|||
|
||||
header: MobileShell.BaseItem {
|
||||
implicitWidth: gridView.effectiveContentWidth
|
||||
topPadding: PlasmaCore.Units.largeSpacing + Math.round(gridView.height * 0.1)
|
||||
bottomPadding: PlasmaCore.Units.largeSpacing
|
||||
leftPadding: PlasmaCore.Units.smallSpacing
|
||||
topPadding: Kirigami.Units.gridUnit + Math.round(gridView.height * 0.1)
|
||||
bottomPadding: Kirigami.Units.gridUnit
|
||||
leftPadding: Kirigami.Units.smallSpacing
|
||||
|
||||
contentItem: PC3.Label {
|
||||
color: "white"
|
||||
|
|
@ -74,7 +72,7 @@ MobileShell.GridView {
|
|||
id: metrics
|
||||
text: "M\nM"
|
||||
visible: false
|
||||
font.pointSize: PlasmaCore.Theme.defaultFont.pointSize * 0.85
|
||||
font.pointSize: Kirigami.Theme.defaultFont.pointSize * 0.85
|
||||
font.weight: Font.Bold
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -7,8 +7,6 @@ import QtQuick.Layouts
|
|||
import QtQuick.Window
|
||||
|
||||
import org.kde.plasma.plasmoid
|
||||
import org.kde.plasma.core as PlasmaCore
|
||||
import org.kde.plasma.extras as PlasmaExtras
|
||||
import org.kde.plasma.components 3.0 as PC3
|
||||
import org.kde.draganddrop as DragDrop
|
||||
|
||||
|
|
|
|||
|
|
@ -6,8 +6,8 @@ import QtQuick.Window
|
|||
import QtQuick.Layouts
|
||||
|
||||
import org.kde.plasma.plasmoid
|
||||
import org.kde.plasma.core as PlasmaCore
|
||||
import org.kde.plasma.components 3.0 as PlasmaComponents
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import org.kde.plasma.private.mobileshell as MobileShell
|
||||
import org.kde.plasma.private.mobileshell.state as MobileShellState
|
||||
|
|
@ -57,7 +57,7 @@ ContainmentItem {
|
|||
anchors.fill: parent
|
||||
z: -1
|
||||
Behavior on color {
|
||||
ColorAnimation { duration: PlasmaCore.Units.longDuration }
|
||||
ColorAnimation { duration: Kirigami.Units.longDuration }
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -32,7 +32,7 @@ ContainmentItem {
|
|||
Binding {
|
||||
target: Plasmoid.Window.window // assumed to be plasma-workspace "PanelView" component
|
||||
property: "thickness"
|
||||
value: PlasmaCore.Units.gridUnit + PlasmaCore.Units.smallSpacing
|
||||
value: Kirigami.Units.gridUnit + Kirigami.Units.smallSpacing
|
||||
}
|
||||
|
||||
//BEGIN API implementation
|
||||
|
|
@ -78,7 +78,7 @@ ContainmentItem {
|
|||
anchors.fill: parent
|
||||
|
||||
showDropShadow: !root.showingApp
|
||||
colorGroup: root.showingApp ? PlasmaCore.Theme.HeaderColorGroup : PlasmaCore.Theme.ComplementaryColorGroup
|
||||
colorGroup: root.showingApp ? Kirigami.Theme.HeaderColorGroup : Kirigami.Theme.ComplementaryColorGroup
|
||||
backgroundColor: !root.showingApp ? "transparent" : root.backgroundColor
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -6,7 +6,6 @@ import QtQuick.Layouts
|
|||
import QtQuick.Window
|
||||
|
||||
import org.kde.plasma.plasmoid
|
||||
import org.kde.plasma.core as PlasmaCore
|
||||
import org.kde.plasma.workspace.keyboardlayout as Keyboards
|
||||
|
||||
import org.kde.plasma.private.mobileshell as MobileShell
|
||||
|
|
@ -22,8 +21,8 @@ MobileShell.NavigationPanel {
|
|||
// - opaque if an app is shown or vkbd is shown
|
||||
// - translucent if the task switcher is open
|
||||
// - transparent if on the homescreen
|
||||
backgroundColor: (Keyboards.KWinVirtualKeyboard.visible || opaqueBar) ? PlasmaCore.ColorScope.backgroundColor : "transparent";
|
||||
foregroundColorGroup: opaqueBar ? PlasmaCore.Theme.NormalColorGroup : PlasmaCore.Theme.ComplementaryColorGroup
|
||||
backgroundColor: (Keyboards.KWinVirtualKeyboard.visible || opaqueBar) ? Kirigami.Theme.backgroundColor : "transparent";
|
||||
foregroundColorGroup: opaqueBar ? Kirigami.Theme.Window : Kirigami.Theme.ComplementaryColorGroup
|
||||
shadow: !opaqueBar
|
||||
|
||||
TaskManager.VirtualDesktopInfo {
|
||||
|
|
|
|||
|
|
@ -6,6 +6,8 @@ import QtQuick 2.4
|
|||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Window 2.15
|
||||
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
|
||||
import org.kde.taskmanager 0.1 as TaskManager
|
||||
import org.kde.plasma.plasmoid 2.0
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
|
|
@ -35,7 +37,7 @@ ContainmentItem {
|
|||
readonly property bool inLandscape: Screen.width > Screen.height;
|
||||
readonly property bool isInLandscapeNavPanelMode: inLandscape && ShellSettings.Settings.navigationPanelEnabled
|
||||
|
||||
readonly property real navigationPanelHeight: PlasmaCore.Units.gridUnit * 2
|
||||
readonly property real navigationPanelHeight: Kirigami.Units.gridUnit * 2
|
||||
|
||||
readonly property real intendedWindowThickness: navigationPanelHeight
|
||||
readonly property real intendedWindowLength: isInLandscapeNavPanelMode ? Screen.height : Screen.width
|
||||
|
|
@ -105,11 +107,12 @@ ContainmentItem {
|
|||
// only opaque if there are no maximized windows on this screen
|
||||
readonly property bool opaqueBar: WindowPlugin.WindowMaximizedTracker.showingWindow
|
||||
|
||||
PlasmaCore.ColorScope {
|
||||
Item {
|
||||
anchors.fill: parent
|
||||
|
||||
// contrasting colour
|
||||
colorGroup: opaqueBar ? PlasmaCore.Theme.NormalColorGroup : PlasmaCore.Theme.ComplementaryColorGroup
|
||||
Kirigami.Theme.colorSet: opaqueBar ? Kirigami.Theme.Window : Kirigami.Theme.Complementary
|
||||
Kirigami.Theme.inherit: false
|
||||
|
||||
// load appropriate system navigation component
|
||||
Loader {
|
||||
|
|
|
|||
|
|
@ -33,7 +33,7 @@ Item {
|
|||
anchors {
|
||||
fill: parent
|
||||
topMargin: Kirigami.Units.gridUnit
|
||||
bottomMargin: Kirigami.Units.largeSpacing
|
||||
bottomMargin: Kirigami.Units.gridUnit
|
||||
}
|
||||
width: root.width
|
||||
spacing: Kirigami.Units.gridUnit
|
||||
|
|
|
|||
|
|
@ -6,7 +6,6 @@ import QtQuick.Controls 2.15
|
|||
import QtQuick.Layouts 1.15
|
||||
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.kirigamiaddons.labs.mobileform 0.1 as MobileForm
|
||||
import org.kde.plasma.mobileinitialstart.prepare 1.0 as Prepare
|
||||
import org.kde.plasma.plasma5support 2.0 as P5Support
|
||||
|
|
|
|||
|
|
@ -6,7 +6,6 @@ import QtQuick.Controls 2.15
|
|||
import QtQuick.Layouts 1.15
|
||||
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.kirigamiaddons.labs.mobileform 0.1 as MobileForm
|
||||
import org.kde.plasma.mobileinitialstart.time 1.0 as Time
|
||||
|
||||
|
|
@ -20,7 +19,7 @@ Item {
|
|||
anchors {
|
||||
fill: parent
|
||||
topMargin: Kirigami.Units.gridUnit
|
||||
bottomMargin: Kirigami.Units.largeSpacing
|
||||
bottomMargin: Kirigami.Units.gridUnit
|
||||
}
|
||||
|
||||
width: root.width
|
||||
|
|
@ -78,10 +77,10 @@ Item {
|
|||
|
||||
header: Control {
|
||||
width: listView.width
|
||||
leftPadding: Kirigami.Units.largeSpacing
|
||||
rightPadding: Kirigami.Units.largeSpacing
|
||||
topPadding: Kirigami.Units.largeSpacing
|
||||
bottomPadding: Kirigami.Units.largeSpacing
|
||||
leftPadding: Kirigami.Units.gridUnit
|
||||
rightPadding: Kirigami.Units.gridUnit
|
||||
topPadding: Kirigami.Units.gridUnit
|
||||
bottomPadding: Kirigami.Units.gridUnit
|
||||
|
||||
contentItem: Kirigami.SearchField {
|
||||
id: searchField
|
||||
|
|
|
|||
|
|
@ -43,7 +43,7 @@ Kirigami.PromptDialog {
|
|||
|
||||
ColumnLayout {
|
||||
id: column
|
||||
spacing: Kirigami.Units.largeSpacing
|
||||
spacing: Kirigami.Units.gridUnit
|
||||
|
||||
PasswordField {
|
||||
id: passwordField
|
||||
|
|
|
|||
|
|
@ -6,7 +6,6 @@ import QtQuick 2.15
|
|||
import QtQuick.Layouts 1.15
|
||||
import QtQuick.Controls 2.15 as Controls
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.plasma.networkmanagement 0.2 as PlasmaNM
|
||||
import org.kde.kirigami 2.2 as Kirigami
|
||||
import org.kde.kirigamiaddons.labs.mobileform 0.1 as MobileForm
|
||||
|
|
@ -48,7 +47,7 @@ MobileForm.AbstractFormDelegate {
|
|||
}
|
||||
|
||||
contentItem: RowLayout {
|
||||
spacing: Kirigami.Units.largeSpacing
|
||||
spacing: Kirigami.Units.gridUnit
|
||||
|
||||
Item {
|
||||
Layout.preferredWidth: Kirigami.Units.gridUnit
|
||||
|
|
@ -61,7 +60,7 @@ MobileForm.AbstractFormDelegate {
|
|||
svg: KSvg.Svg {
|
||||
multipleImages: true
|
||||
imagePath: "icons/network"
|
||||
colorGroup: PlasmaCore.ColorScope.colorGroup
|
||||
colorSet: Kirigami.Theme.colorSet
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -7,7 +7,6 @@ import QtQuick.Controls 2.15
|
|||
import QtQuick.Layouts 1.15
|
||||
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.kirigamiaddons.labs.mobileform 0.1 as MobileForm
|
||||
import org.kde.plasma.networkmanagement 0.2 as PlasmaNM
|
||||
import org.kde.plasma.mobileinitialstart.wifi 1.0 as WiFi
|
||||
|
|
@ -54,7 +53,7 @@ Item {
|
|||
ColumnLayout {
|
||||
anchors.fill: parent
|
||||
anchors.topMargin: Kirigami.Units.gridUnit
|
||||
anchors.bottomMargin: Kirigami.Units.largeSpacing
|
||||
anchors.bottomMargin: Kirigami.Units.gridUnit
|
||||
width: root.width
|
||||
spacing: Kirigami.Units.gridUnit
|
||||
|
||||
|
|
@ -95,7 +94,7 @@ Item {
|
|||
|
||||
Kirigami.PlaceholderMessage {
|
||||
anchors.centerIn: parent
|
||||
width: parent.width - (Kirigami.Units.largeSpacing * 4)
|
||||
width: parent.width - (Kirigami.Units.gridUnit * 4)
|
||||
visible: !enabledConnections.wirelessEnabled
|
||||
text: i18n("Wi-Fi is disabled")
|
||||
icon.name: "network-wireless-disconnected"
|
||||
|
|
|
|||
|
|
@ -67,7 +67,7 @@ Item {
|
|||
|
||||
ColumnLayout {
|
||||
opacity: root.contentOpacity
|
||||
spacing: Kirigami.Units.largeSpacing
|
||||
spacing: Kirigami.Units.gridUnit
|
||||
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.left: parent.left
|
||||
|
|
@ -93,8 +93,8 @@ Item {
|
|||
anchors.right: parent.right
|
||||
anchors.margins: Kirigami.Units.gridUnit
|
||||
|
||||
topPadding: Kirigami.Units.largeSpacing
|
||||
bottomPadding: Kirigami.Units.largeSpacing
|
||||
topPadding: Kirigami.Units.gridUnit
|
||||
bottomPadding: Kirigami.Units.gridUnit
|
||||
leftPadding: Kirigami.Units.gridUnit
|
||||
rightPadding: Kirigami.Units.gridUnit
|
||||
|
||||
|
|
|
|||
|
|
@ -5,7 +5,6 @@ import QtQuick 2.15
|
|||
import QtQuick.Controls 2.15
|
||||
import QtQuick.Layouts 1.15
|
||||
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
import org.kde.kirigami 2.20 as Kirigami
|
||||
import org.kde.plasma.private.mobileshell 1.0 as MobileShell
|
||||
|
||||
|
|
@ -123,7 +122,7 @@ Kirigami.Page {
|
|||
|
||||
height: Kirigami.Units.gridUnit * 1.25
|
||||
|
||||
colorGroup: PlasmaCore.Theme.ComplementaryColorGroup
|
||||
colorGroup: Kirigami.Theme.ComplementaryColorGroup
|
||||
backgroundColor: "transparent"
|
||||
|
||||
showSecondRow: false
|
||||
|
|
@ -287,8 +286,8 @@ Kirigami.Page {
|
|||
Layout.leftMargin: Kirigami.Units.gridUnit
|
||||
Layout.bottomMargin: Kirigami.Units.gridUnit
|
||||
|
||||
topPadding: Kirigami.Units.largeSpacing
|
||||
bottomPadding: Kirigami.Units.largeSpacing
|
||||
topPadding: Kirigami.Units.gridUnit
|
||||
bottomPadding: Kirigami.Units.gridUnit
|
||||
leftPadding: Kirigami.Units.gridUnit
|
||||
rightPadding: Kirigami.Units.gridUnit
|
||||
|
||||
|
|
@ -305,8 +304,8 @@ Kirigami.Page {
|
|||
Layout.rightMargin: Kirigami.Units.gridUnit
|
||||
Layout.bottomMargin: Kirigami.Units.gridUnit
|
||||
|
||||
topPadding: Kirigami.Units.largeSpacing
|
||||
bottomPadding: Kirigami.Units.largeSpacing
|
||||
topPadding: Kirigami.Units.gridUnit
|
||||
bottomPadding: Kirigami.Units.gridUnit
|
||||
leftPadding: Kirigami.Units.gridUnit
|
||||
rightPadding: Kirigami.Units.gridUnit
|
||||
|
||||
|
|
@ -322,8 +321,8 @@ Kirigami.Page {
|
|||
Layout.rightMargin: Kirigami.Units.gridUnit
|
||||
Layout.bottomMargin: Kirigami.Units.gridUnit
|
||||
|
||||
topPadding: Kirigami.Units.largeSpacing
|
||||
bottomPadding: Kirigami.Units.largeSpacing
|
||||
topPadding: Kirigami.Units.gridUnit
|
||||
bottomPadding: Kirigami.Units.gridUnit
|
||||
leftPadding: Kirigami.Units.gridUnit
|
||||
rightPadding: Kirigami.Units.gridUnit
|
||||
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ Kirigami.ScrollablePage {
|
|||
MessagesList {
|
||||
visible: count != 0
|
||||
Layout.fillWidth: true
|
||||
Layout.margins: Kirigami.Units.largeSpacing
|
||||
Layout.margins: Kirigami.Units.gridUnit
|
||||
model: kcm.messages
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ ColumnLayout {
|
|||
model: root.model
|
||||
|
||||
delegate: Kirigami.InlineMessage {
|
||||
Layout.bottomMargin: Kirigami.Units.largeSpacing
|
||||
Layout.bottomMargin: Kirigami.Units.gridUnit
|
||||
Layout.fillWidth: true
|
||||
visible: true
|
||||
text: modelData.message
|
||||
|
|
|
|||
|
|
@ -60,7 +60,7 @@ Kirigami.ScrollablePage {
|
|||
|
||||
MobileForm.FormCard {
|
||||
Layout.fillWidth: true
|
||||
Layout.topMargin: Kirigami.Units.largeSpacing
|
||||
Layout.topMargin: Kirigami.Units.gridUnit
|
||||
|
||||
contentItem: ColumnLayout {
|
||||
spacing: 0
|
||||
|
|
|
|||
|
|
@ -29,7 +29,7 @@ Controls.Dialog {
|
|||
|
||||
header: Item {
|
||||
transform: Translate { y: dialog.translateY }
|
||||
implicitHeight: heading.implicitHeight + Kirigami.Units.largeSpacing * 2
|
||||
implicitHeight: heading.implicitHeight + Kirigami.Units.gridUnit * 2
|
||||
|
||||
Kirigami.Heading {
|
||||
id: heading
|
||||
|
|
@ -38,7 +38,7 @@ Controls.Dialog {
|
|||
elide: Text.ElideRight
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.leftMargin: Kirigami.Units.largeSpacing
|
||||
anchors.leftMargin: Kirigami.Units.gridUnit
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
|
||||
// use tooltip for long text that is elided
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ Kirigami.ScrollablePage {
|
|||
anchors.centerIn: parent
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.margins: Kirigami.Units.largeSpacing
|
||||
anchors.margins: Kirigami.Units.gridUnit
|
||||
visible: profileListView.count === 0
|
||||
text: i18n("No APNs configured")
|
||||
icon.name: "globe"
|
||||
|
|
@ -52,14 +52,14 @@ Kirigami.ScrollablePage {
|
|||
id: messagesList
|
||||
visible: count != 0
|
||||
Layout.fillWidth: true
|
||||
Layout.margins: Kirigami.Units.largeSpacing
|
||||
Layout.margins: Kirigami.Units.gridUnit
|
||||
model: kcm.messages
|
||||
}
|
||||
|
||||
Kirigami.InlineMessage {
|
||||
id: cannotFindWarning
|
||||
Layout.margins: visible ? Kirigami.Units.largeSpacing : 0
|
||||
Layout.topMargin: visible && !messagesList.visible ? Kirigami.Units.largeSpacing : 0
|
||||
Layout.margins: visible ? Kirigami.Units.gridUnit : 0
|
||||
Layout.topMargin: visible && !messagesList.visible ? Kirigami.Units.gridUnit : 0
|
||||
Layout.fillWidth: true
|
||||
|
||||
visible: false
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ Kirigami.ScrollablePage {
|
|||
|
||||
MessagesList {
|
||||
Layout.fillWidth: true
|
||||
Layout.margins: Kirigami.Units.largeSpacing
|
||||
Layout.margins: Kirigami.Units.gridUnit
|
||||
model: kcm.messages
|
||||
}
|
||||
|
||||
|
|
@ -92,8 +92,8 @@ Kirigami.ScrollablePage {
|
|||
}
|
||||
|
||||
Kirigami.Separator {
|
||||
Layout.leftMargin: Kirigami.Units.largeSpacing
|
||||
Layout.rightMargin: Kirigami.Units.largeSpacing
|
||||
Layout.leftMargin: Kirigami.Units.gridUnit
|
||||
Layout.rightMargin: Kirigami.Units.gridUnit
|
||||
Layout.fillWidth: true
|
||||
opacity: (!disableSimLockButton.controlHovered && !changePinButton.controlHovered) ? 0.5 : 0
|
||||
}
|
||||
|
|
@ -118,7 +118,7 @@ Kirigami.ScrollablePage {
|
|||
id: unlockPinDialog
|
||||
title: i18n("Unlock SIM")
|
||||
standardButtons: Controls.Dialog.Ok | Controls.Dialog.Cancel
|
||||
padding: Kirigami.Units.largeSpacing
|
||||
padding: Kirigami.Units.gridUnit
|
||||
|
||||
onAccepted: sim.sendPin(unlockPinCurPin.text)
|
||||
|
||||
|
|
@ -138,7 +138,7 @@ Kirigami.ScrollablePage {
|
|||
id: changePinDialog
|
||||
title: i18n("Change SIM PIN")
|
||||
standardButtons: isValid ? Controls.Dialog.Ok | Controls.Dialog.Cancel : Controls.Dialog.Cancel
|
||||
padding: Kirigami.Units.largeSpacing
|
||||
padding: Kirigami.Units.gridUnit
|
||||
|
||||
property bool isValid: changePinNewPin.text == changePinConfirmPin.text &&
|
||||
changePinNewPin.text.length >= 4 && changePinNewPin.text.length <= 8 // SIM PINs are between 4-8 digits
|
||||
|
|
@ -186,7 +186,7 @@ Kirigami.ScrollablePage {
|
|||
id: removePinDialog
|
||||
title: i18n("Remove SIM PIN")
|
||||
standardButtons: Controls.Dialog.Ok | Controls.Dialog.Cancel
|
||||
padding: Kirigami.Units.largeSpacing
|
||||
padding: Kirigami.Units.gridUnit
|
||||
|
||||
onAccepted: sim.togglePinEnabled(removePinCurPin.text);
|
||||
|
||||
|
|
@ -203,7 +203,7 @@ Kirigami.ScrollablePage {
|
|||
id: createPinDialog
|
||||
title: i18n("Add SIM PIN")
|
||||
standardButtons: isValid ? Controls.Dialog.Ok | Controls.Dialog.Cancel : Controls.Dialog.Cancel
|
||||
padding: Kirigami.Units.largeSpacing
|
||||
padding: Kirigami.Units.gridUnit
|
||||
|
||||
property bool isValid: createPinNewPin.text == createPinConfirmPin.text &&
|
||||
createPinNewPin.text.length >= 4 && createPinNewPin.text.length <= 8 // SIM PINs are between 4-8 digits
|
||||
|
|
|
|||
|
|
@ -47,8 +47,8 @@ Kirigami.ScrollablePage {
|
|||
|
||||
Kirigami.InlineMessage {
|
||||
Layout.fillWidth: true
|
||||
Layout.margins: Kirigami.Units.largeSpacing
|
||||
Layout.bottomMargin: visible && !messagesList.visible ? Kirigami.Units.largeSpacing : 0
|
||||
Layout.margins: Kirigami.Units.gridUnit
|
||||
Layout.bottomMargin: visible && !messagesList.visible ? Kirigami.Units.gridUnit : 0
|
||||
visible: !simEnabled
|
||||
type: Kirigami.MessageType.Error
|
||||
text: qsTr("This SIM slot is empty, a SIM card needs to be inserted in order for it to be used.")
|
||||
|
|
@ -57,7 +57,7 @@ Kirigami.ScrollablePage {
|
|||
MessagesList {
|
||||
id: messagesList
|
||||
Layout.fillWidth: true
|
||||
Layout.margins: Kirigami.Units.largeSpacing
|
||||
Layout.margins: Kirigami.Units.gridUnit
|
||||
model: kcm.messages
|
||||
}
|
||||
|
||||
|
|
@ -123,7 +123,7 @@ Kirigami.ScrollablePage {
|
|||
|
||||
MobileForm.FormCard {
|
||||
Layout.fillWidth: true
|
||||
Layout.topMargin: Kirigami.Units.largeSpacing
|
||||
Layout.topMargin: Kirigami.Units.gridUnit
|
||||
|
||||
contentItem: ColumnLayout {
|
||||
spacing: 0
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ KCM.SimpleKCM {
|
|||
anchors.centerIn: parent
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.margins: Kirigami.Units.largeSpacing
|
||||
anchors.margins: Kirigami.Units.gridUnit
|
||||
|
||||
visible: !enabledConnections.wwanHwEnabled || !availableDevices.modemDeviceAvailable || !kcm.modemFound
|
||||
icon.name: "auth-sim-missing"
|
||||
|
|
@ -59,7 +59,7 @@ KCM.SimpleKCM {
|
|||
|
||||
MessagesList {
|
||||
Layout.fillWidth: true
|
||||
Layout.margins: Kirigami.Units.largeSpacing
|
||||
Layout.margins: Kirigami.Units.gridUnit
|
||||
model: kcm.messages
|
||||
}
|
||||
|
||||
|
|
@ -124,7 +124,7 @@ KCM.SimpleKCM {
|
|||
|
||||
MobileForm.FormCard {
|
||||
Layout.fillWidth: true
|
||||
Layout.topMargin: Kirigami.Units.largeSpacing
|
||||
Layout.topMargin: Kirigami.Units.gridUnit
|
||||
|
||||
contentItem: ColumnLayout {
|
||||
spacing: 0
|
||||
|
|
@ -142,8 +142,8 @@ KCM.SimpleKCM {
|
|||
|
||||
Kirigami.Separator {
|
||||
visible: model.index !== 0
|
||||
Layout.leftMargin: Kirigami.Units.largeSpacing
|
||||
Layout.rightMargin: Kirigami.Units.largeSpacing
|
||||
Layout.leftMargin: Kirigami.Units.gridUnit
|
||||
Layout.rightMargin: Kirigami.Units.gridUnit
|
||||
Layout.fillWidth: true
|
||||
opacity: (!(model.index && repeater.itemAt(model.index - 1).controlHovered) && !simDelegate.controlHovered) ? 0.5 : 0
|
||||
}
|
||||
|
|
|
|||
|
|
@ -57,7 +57,7 @@ SimpleKCM {
|
|||
|
||||
MobileForm.FormCard {
|
||||
Layout.fillWidth: true
|
||||
Layout.topMargin: Kirigami.Units.largeSpacing
|
||||
Layout.topMargin: Kirigami.Units.gridUnit
|
||||
|
||||
contentItem: ColumnLayout {
|
||||
spacing: 0
|
||||
|
|
|
|||
|
|
@ -57,7 +57,7 @@ KCM.SimpleKCM {
|
|||
|
||||
MobileForm.FormCard {
|
||||
Layout.fillWidth: true
|
||||
Layout.topMargin: Kirigami.Units.largeSpacing
|
||||
Layout.topMargin: Kirigami.Units.gridUnit
|
||||
|
||||
contentItem: ColumnLayout {
|
||||
spacing: 0
|
||||
|
|
@ -103,7 +103,7 @@ KCM.SimpleKCM {
|
|||
|
||||
MobileForm.FormCard {
|
||||
Layout.fillWidth: true
|
||||
Layout.topMargin: Kirigami.Units.largeSpacing
|
||||
Layout.topMargin: Kirigami.Units.gridUnit
|
||||
|
||||
contentItem: ColumnLayout {
|
||||
spacing: 0
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@ Kirigami.ScrollablePage {
|
|||
contentItem: RowLayout {
|
||||
Kirigami.ListItemDragHandle {
|
||||
visible: qsDelegate.isEnabled
|
||||
Layout.rightMargin: Kirigami.Units.largeSpacing
|
||||
Layout.rightMargin: Kirigami.Units.gridUnit
|
||||
listItem: qsDelegate
|
||||
listView: qsDelegate.parent ? qsDelegate.parent.parentView : null
|
||||
onMoveRequested: savedQuickSettings.enabledModel.moveRow(oldIndex, newIndex)
|
||||
|
|
@ -42,7 +42,7 @@ Kirigami.ScrollablePage {
|
|||
|
||||
visible: iconAvailable
|
||||
source: model ? model.icon : ""
|
||||
Layout.rightMargin: iconAvailable ? Kirigami.Units.largeSpacing : 0
|
||||
Layout.rightMargin: iconAvailable ? Kirigami.Units.gridUnit : 0
|
||||
implicitWidth: iconAvailable ? Kirigami.Units.iconSizes.small : 0
|
||||
implicitHeight: iconAvailable ? Kirigami.Units.iconSizes.small : 0
|
||||
}
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue