1
0
mirror of https://github.com/qTox/qTox.git synced 2024-03-22 14:00:36 +08:00

style: use css files for toxId

This commit is contained in:
TriKriSta 2019-03-31 17:57:17 +03:00
parent 19f5df0a91
commit d1715500f7
4 changed files with 10 additions and 1 deletions

View File

@ -105,6 +105,7 @@
<file>themes/dark/fileTransferInstance/filetransferWidget.css</file> <file>themes/dark/fileTransferInstance/filetransferWidget.css</file>
<file>themes/dark/genericChatForm/genericChatForm.css</file> <file>themes/dark/genericChatForm/genericChatForm.css</file>
<file>themes/dark/acceptCall/acceptCall.svg</file> <file>themes/dark/acceptCall/acceptCall.svg</file>
<file>themes/dark/addFriendForm/toxId.css</file>
<file>themes/dark/rejectCall/rejectCall.svg</file> <file>themes/dark/rejectCall/rejectCall.svg</file>
<file>themes/dark/notificationEdge/notificationEdge.css</file> <file>themes/dark/notificationEdge/notificationEdge.css</file>
<file>themes/dark/loginScreen/loginScreen.css</file> <file>themes/dark/loginScreen/loginScreen.css</file>
@ -169,6 +170,7 @@
<file>themes/default/fileTransferInstance/filetransferWidget.css</file> <file>themes/default/fileTransferInstance/filetransferWidget.css</file>
<file>themes/default/genericChatForm/genericChatForm.css</file> <file>themes/default/genericChatForm/genericChatForm.css</file>
<file>themes/default/acceptCall/acceptCall.svg</file> <file>themes/default/acceptCall/acceptCall.svg</file>
<file>themes/default/addFriendForm/toxId.css</file>
<file>themes/default/rejectCall/rejectCall.svg</file> <file>themes/default/rejectCall/rejectCall.svg</file>
<file>img/login_logo.svg</file> <file>img/login_logo.svg</file>
<file>themes/default/notificationEdge/notificationEdge.css</file> <file>themes/default/notificationEdge/notificationEdge.css</file>

View File

@ -25,6 +25,7 @@
#include "src/widget/contentlayout.h" #include "src/widget/contentlayout.h"
#include "src/widget/gui.h" #include "src/widget/gui.h"
#include "src/widget/tool/croppinglabel.h" #include "src/widget/tool/croppinglabel.h"
#include "src/widget/style.h"
#include "src/widget/translator.h" #include "src/widget/translator.h"
#include <QApplication> #include <QApplication>
#include <QClipboard> #include <QClipboard>
@ -294,7 +295,7 @@ void AddFriendForm::onIdChanged(const QString& id)
isValidId ? QStringLiteral("%1 (%2)") : QStringLiteral("%1 <font color='red'>(%2)</font>"); isValidId ? QStringLiteral("%1 (%2)") : QStringLiteral("%1 <font color='red'>(%2)</font>");
toxIdLabel.setText(labelText.arg(toxIdText, toxIdComment)); toxIdLabel.setText(labelText.arg(toxIdText, toxIdComment));
toxId.setStyleSheet(isValidOrEmpty ? QStringLiteral("") toxId.setStyleSheet(isValidOrEmpty ? QStringLiteral("")
: QStringLiteral("QLineEdit { background-color: #FFC1C1; }")); : Style::getStylesheet("addFriendForm/toxId.css"));
toxId.setToolTip(isValidOrEmpty ? QStringLiteral("") : tr("Invalid Tox ID format")); toxId.setToolTip(isValidOrEmpty ? QStringLiteral("") : tr("Invalid Tox ID format"));
sendButton.setEnabled(isValidId); sendButton.setEnabled(isValidId);

View File

@ -0,0 +1,3 @@
QLineEdit {
background-color: #8a3f3a;
}

View File

@ -0,0 +1,3 @@
QLineEdit {
background-color: #FFC1C1;
}