mirror of
https://github.com/Chatterino/chatterino2.git
synced 2024-11-13 19:49:51 +01:00
Add clear button to settings search bar (#3403)
Co-authored-by: pajlada <rasmus.karlsson@pajlada.com>
This commit is contained in:
parent
5938e00508
commit
f64047d5ea
|
@ -38,6 +38,7 @@
|
||||||
- Minor: Show picked outcome in prediction badges. (#3357)
|
- Minor: Show picked outcome in prediction badges. (#3357)
|
||||||
- Minor: Add support for Emoji in IRC (#3354)
|
- Minor: Add support for Emoji in IRC (#3354)
|
||||||
- Minor: Moved `/live` logs to its own subdirectory. (Logs from before this change will still be available in `Channels -> live`). (#3393)
|
- Minor: Moved `/live` logs to its own subdirectory. (Logs from before this change will still be available in `Channels -> live`). (#3393)
|
||||||
|
- Minor: Added clear button to settings search bar. (#3403)
|
||||||
- Minor: Added autocompletion for default Twitch commands starting with the dot (e.g. `.mods` which does the same as `/mods`). (#3144)
|
- Minor: Added autocompletion for default Twitch commands starting with the dot (e.g. `.mods` which does the same as `/mods`). (#3144)
|
||||||
- Minor: Sorted usernames in `Users joined/parted` messages alphabetically. (#3421)
|
- Minor: Sorted usernames in `Users joined/parted` messages alphabetically. (#3421)
|
||||||
- Minor: Mod list, VIP list, and Users joined/parted messages are now searchable. (#3426)
|
- Minor: Mod list, VIP list, and Users joined/parted messages are now searchable. (#3426)
|
||||||
|
|
BIN
resources/buttons/clearSearch.png
Normal file
BIN
resources/buttons/clearSearch.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 278 B |
|
@ -15,6 +15,7 @@
|
||||||
<file>buttons/addSplitDark.png</file>
|
<file>buttons/addSplitDark.png</file>
|
||||||
<file>buttons/ban.png</file>
|
<file>buttons/ban.png</file>
|
||||||
<file>buttons/banRed.png</file>
|
<file>buttons/banRed.png</file>
|
||||||
|
<file>buttons/clearSearch.png</file>
|
||||||
<file>buttons/copyDark.png</file>
|
<file>buttons/copyDark.png</file>
|
||||||
<file>buttons/copyDark.svg</file>
|
<file>buttons/copyDark.svg</file>
|
||||||
<file>buttons/copyLight.png</file>
|
<file>buttons/copyLight.png</file>
|
||||||
|
|
|
@ -17,6 +17,7 @@ Resources2::Resources2()
|
||||||
this->buttons.addSplitDark = QPixmap(":/buttons/addSplitDark.png");
|
this->buttons.addSplitDark = QPixmap(":/buttons/addSplitDark.png");
|
||||||
this->buttons.ban = QPixmap(":/buttons/ban.png");
|
this->buttons.ban = QPixmap(":/buttons/ban.png");
|
||||||
this->buttons.banRed = QPixmap(":/buttons/banRed.png");
|
this->buttons.banRed = QPixmap(":/buttons/banRed.png");
|
||||||
|
this->buttons.clearSearch = QPixmap(":/buttons/clearSearch.png");
|
||||||
this->buttons.copyDark = QPixmap(":/buttons/copyDark.png");
|
this->buttons.copyDark = QPixmap(":/buttons/copyDark.png");
|
||||||
this->buttons.copyLight = QPixmap(":/buttons/copyLight.png");
|
this->buttons.copyLight = QPixmap(":/buttons/copyLight.png");
|
||||||
this->buttons.menuDark = QPixmap(":/buttons/menuDark.png");
|
this->buttons.menuDark = QPixmap(":/buttons/menuDark.png");
|
||||||
|
|
|
@ -24,6 +24,7 @@ public:
|
||||||
QPixmap addSplitDark;
|
QPixmap addSplitDark;
|
||||||
QPixmap ban;
|
QPixmap ban;
|
||||||
QPixmap banRed;
|
QPixmap banRed;
|
||||||
|
QPixmap clearSearch;
|
||||||
QPixmap copyDark;
|
QPixmap copyDark;
|
||||||
QPixmap copyLight;
|
QPixmap copyLight;
|
||||||
QPixmap menuDark;
|
QPixmap menuDark;
|
||||||
|
|
|
@ -86,6 +86,9 @@ void SettingsDialog::initUi()
|
||||||
.emplace<QLineEdit>()
|
.emplace<QLineEdit>()
|
||||||
.assign(&this->ui_.search);
|
.assign(&this->ui_.search);
|
||||||
edit->setPlaceholderText("Find in settings... (Ctrl+F by default)");
|
edit->setPlaceholderText("Find in settings... (Ctrl+F by default)");
|
||||||
|
edit->setClearButtonEnabled(true);
|
||||||
|
edit->findChild<QAbstractButton *>()->setIcon(
|
||||||
|
QPixmap(":/buttons/clearSearch.png"));
|
||||||
|
|
||||||
QObject::connect(edit.getElement(), &QLineEdit::textChanged, this,
|
QObject::connect(edit.getElement(), &QLineEdit::textChanged, this,
|
||||||
&SettingsDialog::filterElements);
|
&SettingsDialog::filterElements);
|
||||||
|
|
Loading…
Reference in a new issue