From 2affb1ab5672f8ad39c4ff96856980f07cd9b003 Mon Sep 17 00:00:00 2001 From: David Edmundson Date: Fri, 23 Dec 2016 13:28:32 +0000 Subject: [PATCH] Recheck which representation we should using in setPreferredRepresentation Summary: Appmenu quite neatly has a config option for which should be the preferred representation, which is needed as both things are quite viable in a panel and can't be done automatically. AppletQuickItem needs to update which representation to use when this is set at runtime. We already check on every single geometry change, so one extra check won't have a huge impact. Test Plan: Appmenu changes dynamically All other applets (both compact and normal) still seem fine Reviewers: #plasma, mart Reviewed By: mart Subscribers: plasma-devel Tags: #plasma Differential Revision: https://phabricator.kde.org/D3794 --- src/plasmaquick/appletquickitem.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/plasmaquick/appletquickitem.cpp b/src/plasmaquick/appletquickitem.cpp index e1df7c670..844aab9a1 100644 --- a/src/plasmaquick/appletquickitem.cpp +++ b/src/plasmaquick/appletquickitem.cpp @@ -692,6 +692,7 @@ void AppletQuickItem::setPreferredRepresentation(QQmlComponent *component) d->preferredRepresentation = component; emit preferredRepresentationChanged(component); + d->compactRepresentationCheck(); } bool AppletQuickItem::isExpanded() const