summary refs log tree commit diff
path: root/resources/qml/Avatar.qml
diff options
context:
space:
mode:
Diffstat (limited to 'resources/qml/Avatar.qml')
-rw-r--r--resources/qml/Avatar.qml12
1 files changed, 10 insertions, 2 deletions
diff --git a/resources/qml/Avatar.qml b/resources/qml/Avatar.qml
index a248114d..6217d70a 100644
--- a/resources/qml/Avatar.qml
+++ b/resources/qml/Avatar.qml
@@ -64,8 +64,16 @@ AbstractButton {
         } else {
             return "";
         }
-        sourceSize.height: avatar.height * Screen.devicePixelRatio
-        sourceSize.width: avatar.width * Screen.devicePixelRatio
+        sourceSize.height: if (!avatar.url.startsWith('image://MxcImage/') && avatar.url.endsWith('.svg')){
+            return avatar.height
+        } else {
+            return avatar.height * Screen.devicePixelRatio
+        }
+        sourceSize.width: if (!avatar.url.startsWith('image://MxcImage/') && avatar.url.endsWith('.svg')){
+            return avatar.width
+        } else {
+            return avatar.width * Screen.devicePixelRatio
+        }
     }
     Rectangle {
         id: onlineIndicator