diff --git a/containment/package/contents/ui/applet/Communicator.qml b/containment/package/contents/ui/applet/Communicator.qml index 9d0f18ca5..4c1b70bc0 100644 --- a/containment/package/contents/ui/applet/Communicator.qml +++ b/containment/package/contents/ui/applet/Communicator.qml @@ -156,7 +156,8 @@ Item{ target: appletRootItem property: "lattePalette" when: disableLatteSideColoring && appletCanUseLattePalette - value: dock && dock.visibility ? dock.visibility.touchingWindowScheme : null + value: colorizerManagerLoader + //value: dock && dock.visibility ? dock.visibility.touchingWindowScheme : null } //! END OF BINDINGS diff --git a/containment/package/contents/ui/main.qml b/containment/package/contents/ui/main.qml index 60fabe663..efe9eca8d 100644 --- a/containment/package/contents/ui/main.qml +++ b/containment/package/contents/ui/main.qml @@ -118,8 +118,9 @@ DragDrop.DropArea { && dock.visibility.existsWindowMaximized readonly property bool hasExpandedApplet: plasmoid.applets.some(function (item) { - return (item.status >= PlasmaCore.Types.NeedsAttentionStatus && item.pluginName !== root.plasmoidName - && item.status !== PlasmaCore.Types.HiddenStatus); + return (item.status >= PlasmaCore.Types.NeedsAttentionStatus && item.status !== PlasmaCore.Types.HiddenStatus + && item.pluginName !== root.plasmoidName + && item.pluginName !== "org.kde.activeWindowControl"); }) readonly property bool hasUserSpecifiedBackground: (dock && dock.managedLayout && dock.managedLayout.background.startsWith("/")) ? @@ -1831,6 +1832,31 @@ DragDrop.DropArea { return Qt.rgba(theme.backgroundColor.r, theme.backgroundColor.g, theme.backgroundColor.b, 1); //remove any transparency } + //! new TEMPORARY options to pass palette to applets + //! UNTIL Latte produces two different color schemes files (LIGHT / DARK) + //! to be passed to applets etc... + + readonly property color textColor: applyColor + readonly property color highlightColor: theme.highlightColor + readonly property color highlightedTextColor: theme.highlightedTextColor + readonly property color backgroundColor: { + if (forceSolidnessAndColorize && dock.visibility.touchingWindowScheme) { + return dock.visibility.touchingWindowScheme.backgroundColor; + } + + if (currentBackgroundLuminas>=0) { + var textAbs = Math.abs(themeTextColorLuma - currentBackgroundLuminas); + var backAbs = Math.abs(themeBackgroundColorLuma - currentBackgroundLuminas); + + if (textAbs > backAbs) { + return Qt.rgba(theme.backgroundColor.r, theme.backgroundColor.g, theme.backgroundColor.b , 1); //remove any transparency + } + } + + return Qt.rgba(theme.textColor.r, theme.textColor.g, theme.textColor.b, 1); //remove any transparency + } + + sourceComponent: Colorizer.Manager{} }