summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--src/ChatPage.cc3
-rw-r--r--src/TextInputWidget.cc2
2 files changed, 2 insertions, 3 deletions
diff --git a/src/ChatPage.cc b/src/ChatPage.cc
index db911972..33f98af3 100644
--- a/src/ChatPage.cc
+++ b/src/ChatPage.cc
@@ -192,8 +192,7 @@ void ChatPage::updateTopBarAvatar(const QString &roomid, const QPixmap &img)
 	if (current_room_.id() != roomid)
 		return;
 
-	QIcon icon(img);
-	this->top_bar_->updateRoomAvatar(icon);
+	top_bar_->updateRoomAvatar(img.toImage());
 }
 
 void ChatPage::updateOwnProfileInfo(const QUrl &avatar_url, const QString &display_name)
diff --git a/src/TextInputWidget.cc b/src/TextInputWidget.cc
index ec92e77d..dedd3a81 100644
--- a/src/TextInputWidget.cc
+++ b/src/TextInputWidget.cc
@@ -66,7 +66,7 @@ TextInputWidget::TextInputWidget(QWidget *parent)
 
 void TextInputWidget::onSendButtonClicked()
 {
-	auto msg_text = input_->text();
+	auto msg_text = input_->text().trimmed();
 
 	if (msg_text.isEmpty())
 		return;