diff --git a/containments/homescreen/package/contents/ui/AppletsArea.qml b/containments/homescreen/package/contents/ui/AppletsArea.qml index 50744511..98b93eae 100644 --- a/containments/homescreen/package/contents/ui/AppletsArea.qml +++ b/containments/homescreen/package/contents/ui/AppletsArea.qml @@ -237,6 +237,7 @@ MouseArea { model: plasmoid.nativeInterface.applicationListModel delegate: HomeLauncher { maximumLineCount: 1 + iconSize: root.iconSize } move: Transition { diff --git a/containments/homescreen/package/contents/ui/HomeLauncher.qml b/containments/homescreen/package/contents/ui/HomeLauncher.qml index f6cec7a5..18c3ffe7 100644 --- a/containments/homescreen/package/contents/ui/HomeLauncher.qml +++ b/containments/homescreen/package/contents/ui/HomeLauncher.qml @@ -1,13 +1,14 @@ -import QtQuick 2.0 +import QtQuick 2.5 import org.kde.plasma.core 2.0 as PlasmaCore import org.kde.kio 1.0 as Kio import org.kde.plasma.components 2.0 as PlasmaComponents -Item { +Column { id: delegateRoot width: applicationsView.cellWidth height: applicationsView.cellHeight + property int iconSize property var modelData: model property bool isDropTarget: delegateRoot != dragDelegate && root.reorderingApps && applicationsView.dragData && applicationsView.dragData.ApplicationStorageIdRole == modelData.ApplicationStorageIdRole property alias maximumLineCount: label.maximumLineCount @@ -16,12 +17,9 @@ Item { PlasmaCore.IconItem { id: icon - anchors { - centerIn: parent - verticalCenterOffset: -theme.mSize(theme.defaultFont).height - } - width: parent.height - label.height - height: width + anchors.horizontalCenter: parent.horizontalCenter + width: delegateRoot.iconSize + height: delegateRoot.iconSize source: modelData.ApplicationIconRole scale: root.reorderingApps && applicationsView.dragData && applicationsView.dragData.ApplicationStorageIdRole != modelData.ApplicationStorageIdRole ? 0.6 : 1 Behavior on scale { @@ -36,11 +34,8 @@ Item { id: label visible: text.length > 0 - anchors { - top: icon.bottom - left: icon.left - right: icon.right - } + anchors.horizontalCenter: parent.horizontalCenter + width: icon.width wrapMode: Text.WordWrap horizontalAlignment: Qt.AlignHCenter diff --git a/containments/homescreen/package/contents/ui/main.qml b/containments/homescreen/package/contents/ui/main.qml index 1cde648e..b78e3869 100644 --- a/containments/homescreen/package/contents/ui/main.qml +++ b/containments/homescreen/package/contents/ui/main.qml @@ -34,7 +34,8 @@ Item { //BEGIN properties property Item toolBox property alias appletsSpace: applicationsView.headerItem - property int buttonHeight: units.iconSizes.large + units.gridUnit * 2 + readonly property int iconSize: units.iconSizes.large + property int buttonHeight: dragDelegate.height property bool reorderingApps: false property var layoutManager: LayoutManager //END properties @@ -431,6 +432,7 @@ Item { z: 999 property int xTarget property int yTarget + iconSize: root.iconSize Behavior on opacity { ParallelAnimation { @@ -496,6 +498,7 @@ Item { //clip: true delegate: HomeLauncher { visible: index > 3 + iconSize: root.iconSize } header: AppletsArea {} footer: Item {