Commit 0670efbd authored by Marco Martin's avatar Marco Martin

restore krunner

fix icons sizes when dragged around
parent b31b6289
......@@ -53,7 +53,7 @@ Rectangle {
clip: true
imagePath: "widgets/background"
enabledBorders: PlasmaCore.FrameSvg.BottomBorder
height: childrenRect.height + fixedMargins.top/2 + fixedMargins.bottom
height: Math.min(krunner.height, childrenRect.height + fixedMargins.top/2 + fixedMargins.bottom)
Behavior on height {
NumberAnimation {
duration: units.longDuration
......@@ -71,7 +71,7 @@ Rectangle {
}
ColumnLayout {
height: Qt.inputMethod.keyboardRectangle.height > 0 ? (Math.min(implicitHeight, Qt.inputMethod.keyboardRectangle.y - plasmoid.availableScreenRect.y)) : implicitHeight
height: Qt.inputMethod.keyboardRectangle.height > 0 ? (Math.min(implicitHeight, background.height, Qt.inputMethod.keyboardRectangle.y - plasmoid.availableScreenRect.y)) : implicitHeight
anchors {
left: parent.left
right: parent.right
......
......@@ -37,8 +37,8 @@ ContainmentLayoutManager.ItemContainer {
property var modelData: typeof model !== "undefined" ? model : null
Layout.minimumWidth: availableCellWidth
Layout.minimumHeight: availableCellHeight
Layout.minimumWidth: launcherGrid.cellWidth
Layout.minimumHeight: launcherGrid.cellHeight
leftPadding: units.smallSpacing * 2
topPadding: units.smallSpacing * 2
......@@ -72,8 +72,8 @@ ContainmentLayoutManager.ItemContainer {
dragCenterY = dragCenter.y;
launcherDragManager.dragItem(delegate, dragCenter.x, dragCenter.y);
delegate.height = availableCellHeight;
delegate.width = availableCellWidth;
delegate.width = launcherGrid.cellWidth;
delegate.height = launcherGrid.cellHeight;
var pos = plasmoid.fullRepresentationItem.mapFromItem(delegate, dragCenter.x, dragCenter.y);
//SCROLL UP
......@@ -108,7 +108,7 @@ ContainmentLayoutManager.ItemContainer {
Layout.alignment: Qt.AlignHCenter | Qt.AlignTop
Layout.fillWidth: true
Layout.preferredHeight: parent.height - root.reservedSpaceForLabel
Layout.minimumHeight: parent.height - root.reservedSpaceForLabel
source: modelData ? modelData.ApplicationIconRole : ""
scale: root.reorderingApps && dragDelegate && !dragging ? 0.6 : 1
......@@ -132,9 +132,9 @@ ContainmentLayoutManager.ItemContainer {
maximumLineCount: 2
elide: Text.ElideRight
text: model.ApplicationNameRole + " "+model.ApplicationLocationRole
text: model.ApplicationNameRole
font.pixelSize: theme.defaultFont.pixelSize
color: model.ApplicationLocationRole == ApplicationListModel.Desktop ? "white" : "black"//PlasmaCore.Theme.textColor
color: model.ApplicationLocationRole == ApplicationListModel.Desktop ? "white" : theme.textColor
layer.enabled: model.ApplicationLocationRole == ApplicationListModel.Desktop
layer.effect: DropShadow {
......
......@@ -32,6 +32,7 @@ LauncherContainer {
readonly property int count: flow.width / launcherGrid.cellWidth
flow.flow: Flow.TopToBottom
favoriteStrip: root
visible: plasmoid.nativeInterface.applicationListModel.favoriteCount > 0 || plasmoid.editMode
......
......@@ -39,6 +39,8 @@ LauncherContainer {
readonly property int cellWidth: root.flow.width / Math.floor(root.flow.width / ((availableCellHeight - reservedSpaceForLabel) + units.smallSpacing*4))
readonly property int cellHeight: availableCellHeight
launcherGrid: root
frame.width: width
Repeater {
......
......@@ -127,7 +127,8 @@ Text {
id: mainFlickable
anchors {
fill: parent
// bottomMargin: favoriteStrip.height
topMargin: plasmoid.availableScreenRect.y + krunner.inputHeight
bottomMargin: root.height - plasmoid.availableScreenRect.height - topMargin
}
bottomMargin: favoriteStrip.height
......@@ -146,6 +147,7 @@ Text {
ColumnLayout {
id: flickableContents
width: parent.width
DragDrop.DropArea {
Layout.fillWidth: true
Layout.preferredHeight: mainFlickable.height //TODO: multiple widgets pages
......@@ -253,7 +255,18 @@ Text {
}
appletsLayout: appletsLayout
launcherGrid: launcher
y: Math.max(0, root.height - height - mainFlickable.contentY)
y: Math.max(krunner.inputHeight, root.height - height - mainFlickable.contentY)
}
KRunner {
id: krunner
z: 998
anchors {
top: parent.top
left: parent.left
right: parent.right
topMargin: plasmoid.availableScreenRect.y
}
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment