mirror of
https://invent.kde.org/marcoa/shift-shell.git
synced 2026-08-04 10:44:46 +00:00
port away from mobilecomponents
This commit is contained in:
parent
9ae7d849a8
commit
5aa20872d5
4 changed files with 139 additions and 126 deletions
|
|
@ -21,7 +21,6 @@ import QtQuick 2.0
|
||||||
import QtQuick.Layouts 1.1
|
import QtQuick.Layouts 1.1
|
||||||
import QtQuick.Window 2.2
|
import QtQuick.Window 2.2
|
||||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||||
import org.kde.plasma.mobilecomponents 0.2
|
|
||||||
import org.kde.plasma.private.mobileshell 2.0
|
import org.kde.plasma.private.mobileshell 2.0
|
||||||
|
|
||||||
FullScreenPanel {
|
FullScreenPanel {
|
||||||
|
|
|
||||||
|
|
@ -23,7 +23,6 @@ import QtQuick.Window 2.2
|
||||||
import org.kde.taskmanager 0.1 as TaskManager
|
import org.kde.taskmanager 0.1 as TaskManager
|
||||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||||
import org.kde.plasma.components 2.0 as PlasmaComponents
|
import org.kde.plasma.components 2.0 as PlasmaComponents
|
||||||
import org.kde.plasma.mobilecomponents 0.2
|
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
id: delegate
|
id: delegate
|
||||||
|
|
|
||||||
|
|
@ -23,7 +23,6 @@ import QtQuick.Window 2.2
|
||||||
import org.kde.taskmanager 0.1 as TaskManager
|
import org.kde.taskmanager 0.1 as TaskManager
|
||||||
import org.kde.plasma.core 2.1 as PlasmaCore
|
import org.kde.plasma.core 2.1 as PlasmaCore
|
||||||
import org.kde.plasma.components 2.0 as PlasmaComponents
|
import org.kde.plasma.components 2.0 as PlasmaComponents
|
||||||
import org.kde.plasma.mobilecomponents 0.2
|
|
||||||
import org.kde.plasma.private.mobileshell 2.0
|
import org.kde.plasma.private.mobileshell 2.0
|
||||||
|
|
||||||
FullScreenPanel {
|
FullScreenPanel {
|
||||||
|
|
|
||||||
|
|
@ -26,6 +26,7 @@ import org.kde.plasma.core 2.0 as PlasmaCore
|
||||||
import org.kde.plasma.extras 2.0 as PlasmaExtras
|
import org.kde.plasma.extras 2.0 as PlasmaExtras
|
||||||
import org.kde.kquickcontrolsaddons 2.0
|
import org.kde.kquickcontrolsaddons 2.0
|
||||||
import org.kde.plasma.mobilecomponents 0.2 as MobileComponents
|
import org.kde.plasma.mobilecomponents 0.2 as MobileComponents
|
||||||
|
import org.kde.kirigami 2.2 as Kirigami
|
||||||
|
|
||||||
import QtQuick.Window 2.1
|
import QtQuick.Window 2.1
|
||||||
import QtQuick.Layouts 1.1
|
import QtQuick.Layouts 1.1
|
||||||
|
|
@ -38,6 +39,8 @@ Rectangle {
|
||||||
signal closed()
|
signal closed()
|
||||||
property alias containment: widgetExplorer.containment
|
property alias containment: widgetExplorer.containment
|
||||||
|
|
||||||
|
Component.onCompleted: splitDrawer.contentX = typeSelector.width
|
||||||
|
|
||||||
MouseArea {
|
MouseArea {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
drag.filterChildren: true
|
drag.filterChildren: true
|
||||||
|
|
@ -135,12 +138,23 @@ Rectangle {
|
||||||
//view: desktop
|
//view: desktop
|
||||||
onShouldClose: removeAnim.running = true;
|
onShouldClose: removeAnim.running = true;
|
||||||
}
|
}
|
||||||
MobileComponents.SplitDrawer {
|
Flickable {
|
||||||
id: splitDrawer
|
id: splitDrawer
|
||||||
visible: true
|
visible: true
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
contentItem: PlasmaExtras.ScrollArea {
|
clip: true
|
||||||
|
contentWidth: mainRow.width
|
||||||
|
contentHeight: height
|
||||||
|
Row {
|
||||||
|
id: mainRow
|
||||||
|
height: splitDrawer.height
|
||||||
|
PlasmaExtras.ScrollArea {
|
||||||
|
id: typeSelector
|
||||||
|
anchors {
|
||||||
|
top: parent.top
|
||||||
|
bottom: parent.bottom
|
||||||
|
}
|
||||||
|
width: units.gridUnit * 10
|
||||||
ListView {
|
ListView {
|
||||||
model: widgetExplorer.filterModel
|
model: widgetExplorer.filterModel
|
||||||
delegate: PlasmaComponents.ListItem {
|
delegate: PlasmaComponents.ListItem {
|
||||||
|
|
@ -163,9 +177,11 @@ Rectangle {
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
anchors {
|
anchors {
|
||||||
fill: parent
|
top: parent.top
|
||||||
margins: units.smallSpacing
|
bottom: parent.bottom
|
||||||
}
|
}
|
||||||
|
width: splitDrawer.width
|
||||||
|
|
||||||
spacing: units.smallSpacing
|
spacing: units.smallSpacing
|
||||||
|
|
||||||
PlasmaExtras.Title {
|
PlasmaExtras.Title {
|
||||||
|
|
@ -280,7 +296,7 @@ Rectangle {
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
Component.onCompleted: {
|
Component.onCompleted: {
|
||||||
main.getWidgetsButton = getWidgetsButton
|
main.getWidgetsButton = getWidgetsButton
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue