mirror of
https://invent.kde.org/marcoa/shift-shell.git
synced 2026-04-26 14:23:09 +00:00
let LauncherRepeater know about thefavorite strip
This commit is contained in:
parent
ee6f80de62
commit
66bf27b9e4
4 changed files with 14 additions and 11 deletions
|
|
@ -91,7 +91,7 @@ ContainmentLayoutManager.ItemContainer {
|
|||
if (modelData.applicationRunning) {
|
||||
delegate.launch(0, 0, "", modelData.applicationName);
|
||||
} else {
|
||||
delegate.launch(delegate.x + (units.smallSpacing * 2), delegate.y + (units.smallSpacing * 2), icon.source, modelData.applicationName);
|
||||
delegate.launch(delegate.x + (PlasmaCore.Units.smallSpacing * 2), delegate.y + (PlasmaCore.Units.smallSpacing * 2), icon.source, modelData.applicationName);
|
||||
}
|
||||
|
||||
plasmoid.nativeInterface.applicationListModel.setMinimizedDelegate(index, delegate);
|
||||
|
|
@ -102,10 +102,10 @@ ContainmentLayoutManager.ItemContainer {
|
|||
ColumnLayout {
|
||||
anchors {
|
||||
fill: parent
|
||||
leftMargin: units.smallSpacing * 2
|
||||
topMargin: units.smallSpacing * 2
|
||||
rightMargin: units.smallSpacing * 2
|
||||
bottomMargin: units.smallSpacing * 2
|
||||
leftMargin: PlasmaCore.Units.smallSpacing * 2
|
||||
topMargin: PlasmaCore.Units.smallSpacing * 2
|
||||
rightMargin: PlasmaCore.Units.smallSpacing * 2
|
||||
bottomMargin: PlasmaCore.Units.smallSpacing * 2
|
||||
}
|
||||
spacing: 0
|
||||
|
||||
|
|
@ -114,7 +114,7 @@ ContainmentLayoutManager.ItemContainer {
|
|||
|
||||
Layout.alignment: Qt.AlignHCenter | Qt.AlignTop
|
||||
Layout.fillWidth: true
|
||||
Layout.minimumHeight: Math.min(units.iconSizes.large, parent.height - delegate.reservedSpaceForLabel)
|
||||
Layout.minimumHeight: Math.min(PlasmaCore.Units.iconSizes.large, parent.height - delegate.reservedSpaceForLabel)
|
||||
Layout.preferredHeight: Layout.minimumHeight
|
||||
|
||||
usesPlasmaTheme: false
|
||||
|
|
@ -127,7 +127,7 @@ ContainmentLayoutManager.ItemContainer {
|
|||
}
|
||||
visible: model.applicationRunning
|
||||
radius: width
|
||||
width: units.smallSpacing
|
||||
width: PlasmaCore.Units.smallSpacing
|
||||
height: width
|
||||
color: theme.highlightColor
|
||||
}
|
||||
|
|
@ -145,8 +145,8 @@ ContainmentLayoutManager.ItemContainer {
|
|||
Layout.preferredHeight: delegate.reservedSpaceForLabel
|
||||
wrapMode: Text.WordWrap
|
||||
Layout.alignment: Qt.AlignTop
|
||||
Layout.leftMargin: -parent.anchors.leftMargin + units.smallSpacing
|
||||
Layout.rightMargin: -parent.anchors.rightMargin + units.smallSpacing
|
||||
Layout.leftMargin: -parent.anchors.leftMargin + PlasmaCore.Units.smallSpacing
|
||||
Layout.rightMargin: -parent.anchors.rightMargin + PlasmaCore.Units.smallSpacing
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
verticalAlignment: Text.AlignTop
|
||||
maximumLineCount: 2
|
||||
|
|
|
|||
|
|
@ -32,6 +32,8 @@ DragDrop.DropArea {
|
|||
|
||||
property alias appletsLayout: appletsLayout
|
||||
|
||||
property FavoriteStrip favoriteStrip
|
||||
|
||||
Connections {
|
||||
target: plasmoid
|
||||
function onEditModeChanged() {
|
||||
|
|
@ -199,7 +201,7 @@ DragDrop.DropArea {
|
|||
cellWidth: appletsLayout.cellWidth
|
||||
cellHeight: appletsLayout.cellHeight
|
||||
appletsLayout: appletsLayout
|
||||
favoriteStrip: favoriteStrip
|
||||
favoriteStrip: dropArea.favoriteStrip
|
||||
onScrollLeftRequested: mainFlickable.scrollLeft()
|
||||
onScrollRightRequested: mainFlickable.scrollRight()
|
||||
onStopScrollRequested: mainFlickable.stopScroll()
|
||||
|
|
|
|||
|
|
@ -42,7 +42,7 @@ Repeater {
|
|||
Binding {
|
||||
target: delegate
|
||||
property: "height"
|
||||
value: Math.min(parent.height, launcherRepeater.cellHeight)
|
||||
value: Math.min(delegate.parent.height, launcherRepeater.cellHeight)
|
||||
}
|
||||
parent: parentFromLocation
|
||||
reservedSpaceForLabel: metrics.height
|
||||
|
|
|
|||
|
|
@ -114,6 +114,7 @@ FocusScope {
|
|||
Launcher.HomeScreenContents {
|
||||
id: homeScreenContents
|
||||
width: mainFlickable.width * 100
|
||||
favoriteStrip: favoriteStrip
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue