Changeset View
Changeset View
Standalone View
Standalone View
containments/desktop/package/contents/ui/main.qml
Show All 34 Lines | |||||
35 | 35 | | |||
36 | FolderViewDropArea { | 36 | FolderViewDropArea { | ||
37 | id: root | 37 | id: root | ||
38 | objectName: isFolder ? "folder" : "desktop" | 38 | objectName: isFolder ? "folder" : "desktop" | ||
39 | 39 | | |||
40 | width: isPopup ? undefined : preferredWidth(false) // for the initial size when placed on the desktop | 40 | width: isPopup ? undefined : preferredWidth(false) // for the initial size when placed on the desktop | ||
41 | Layout.minimumWidth: preferredWidth(true) | 41 | Layout.minimumWidth: preferredWidth(true) | ||
42 | Layout.preferredWidth: isPopup ? preferredWidth(false) : 0 // for the popup size to change at runtime when view mode changes | 42 | Layout.preferredWidth: isPopup ? preferredWidth(false) : 0 // for the popup size to change at runtime when view mode changes | ||
43 | Plasmoid.switchWidth: preferredWidth(true) | 43 | Plasmoid.switchWidth: isPopup ? units.iconSizeHints.panel : preferredWidth(true) | ||
44 | 44 | | |||
45 | height: isPopup ? undefined : preferredHeight(false) | 45 | height: isPopup ? undefined : preferredHeight(false) | ||
46 | Layout.minimumHeight: preferredHeight(true) | 46 | Layout.minimumHeight: preferredHeight(true) | ||
47 | Layout.preferredHeight: isPopup ? preferredHeight(false) : 0 | 47 | Layout.preferredHeight: isPopup ? preferredHeight(false) : 0 | ||
48 | Plasmoid.switchHeight: preferredHeight(true) | 48 | Plasmoid.switchHeight: isPopup ? units.iconSizeHints.panel : preferredHeight(true) | ||
49 | 49 | | |||
50 | LayoutMirroring.enabled: Qt.application.layoutDirection === Qt.RightToLeft | 50 | LayoutMirroring.enabled: Qt.application.layoutDirection === Qt.RightToLeft | ||
51 | LayoutMirroring.childrenInherit: true | 51 | LayoutMirroring.childrenInherit: true | ||
52 | 52 | | |||
53 | property bool isFolder: (plasmoid.pluginName == "org.kde.plasma.folder") | 53 | property bool isFolder: (plasmoid.pluginName == "org.kde.plasma.folder") | ||
54 | property bool isContainment: ("containmentType" in plasmoid) | 54 | property bool isContainment: ("containmentType" in plasmoid) | ||
55 | property bool isPopup: (plasmoid.location != PlasmaCore.Types.Floating) | 55 | property bool isPopup: (plasmoid.location != PlasmaCore.Types.Floating) | ||
56 | property bool useListViewMode: isPopup && plasmoid.configuration.viewMode === 0 | 56 | property bool useListViewMode: isPopup && plasmoid.configuration.viewMode === 0 | ||
▲ Show 20 Lines • Show All 527 Lines • Show Last 20 Lines |