Fix word backspacing not closing/updating colon emote picker (#2781)

Co-authored-by: Paweł <zneix@zneix.eu>
This commit is contained in:
James Upjohn 2021-05-16 02:24:46 +12:00 committed by GitHub
parent 860cc89e14
commit 7c4c797dbc
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 9 additions and 0 deletions

View file

@ -12,6 +12,7 @@
- Bugfix: `Login expired` message no longer highlights all tabs. (#2735)
- Bugfix: Fix a deadlock that would occur during user badge loading. (#1704, #2756)
- Bugfix: Tabbing in `Select a channel to open` is now consistent. (#1797)
- Bugfix: Fix Ctrl + Backspace not closing colon emote picker. (#2780)
- Bugfix: Approving/denying AutoMod messages works again. (#2779)
- Dev: Migrated AutoMod approve/deny endpoints to Helix. (#2779)

View file

@ -86,6 +86,8 @@ void SplitInput::initLayout()
app->fonts->getFont(FontStyle::ChatMedium, this->scale()));
QObject::connect(this->ui_.textEdit, &QTextEdit::cursorPositionChanged,
this, &SplitInput::onCursorPositionChanged);
QObject::connect(this->ui_.textEdit, &QTextEdit::textChanged, this,
&SplitInput::onTextChanged);
this->managedConnections_.push_back(app->fonts->fontChanged.connect([=]() {
this->ui_.textEdit->setFont(
@ -447,6 +449,11 @@ void SplitInput::installKeyPressedEvent()
});
}
void SplitInput::onTextChanged()
{
this->updateColonMenu();
}
void SplitInput::onCursorPositionChanged()
{
this->updateColonMenu();

View file

@ -46,6 +46,7 @@ private:
void initLayout();
void installKeyPressedEvent();
void onCursorPositionChanged();
void onTextChanged();
void updateEmoteButton();
void updateColonMenu();
void showColonMenu(const QString &text);