From 8259891a42336cbc839268d8beae4b456146d836 Mon Sep 17 00:00:00 2001 From: Nicolas Werner Date: Thu, 8 Jun 2023 23:24:32 +0200 Subject: [PATCH] Make settings combobox width dependent on content fixes #1164 --- resources/qml/CommunitiesList.qml | 5 ++--- resources/qml/pages/UserSettingsPage.qml | 1 + 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/resources/qml/CommunitiesList.qml b/resources/qml/CommunitiesList.qml index 24444ae6..81f0640e 100644 --- a/resources/qml/CommunitiesList.qml +++ b/resources/qml/CommunitiesList.qml @@ -147,10 +147,9 @@ Page { url: { if (model.avatarUrl.startsWith("mxc://")) return model.avatarUrl.replace("mxc://", "image://MxcImage/"); - else if (model.avatarUrl.length > 0) { - console.log("image://colorimage/" + model.avatarUrl + "?" + communityItem.unimportantText); + else if (model.avatarUrl.length > 0) return model.avatarUrl; - } else + else return ""; } width: avatarSize diff --git a/resources/qml/pages/UserSettingsPage.qml b/resources/qml/pages/UserSettingsPage.qml index 08581ac5..fa0f3898 100644 --- a/resources/qml/pages/UserSettingsPage.qml +++ b/resources/qml/pages/UserSettingsPage.qml @@ -99,6 +99,7 @@ Rectangle { model: r.model.values currentIndex: r.model.value onCurrentIndexChanged: r.model.value = currentIndex + implicitContentWidthPolicy: ComboBox.WidestTextWhenCompleted WheelHandler{} // suppress scrolling changing values }