fix ibus focus losing behavior (#142)
This commit is contained in:
parent
5de495e43b
commit
0bb941e7fd
|
@ -48,6 +48,7 @@ CodeCompletionPopup::CodeCompletionPopup(QWidget *parent) :
|
||||||
setLayout(new QVBoxLayout());
|
setLayout(new QVBoxLayout());
|
||||||
layout()->addWidget(mListView);
|
layout()->addWidget(mListView);
|
||||||
layout()->setMargin(0);
|
layout()->setMargin(0);
|
||||||
|
mListView->setFocus();
|
||||||
|
|
||||||
mShowKeywords=true;
|
mShowKeywords=true;
|
||||||
mRecordUsage = false;
|
mRecordUsage = false;
|
||||||
|
@ -1111,11 +1112,6 @@ const QString &CodeCompletionPopup::memberPhrase() const
|
||||||
return mMemberPhrase;
|
return mMemberPhrase;
|
||||||
}
|
}
|
||||||
|
|
||||||
void CodeCompletionPopup::showEvent(QShowEvent *)
|
|
||||||
{
|
|
||||||
mListView->setFocus();
|
|
||||||
}
|
|
||||||
|
|
||||||
const PStatement &CodeCompletionPopup::currentScope() const
|
const PStatement &CodeCompletionPopup::currentScope() const
|
||||||
{
|
{
|
||||||
return mCurrentScope;
|
return mCurrentScope;
|
||||||
|
|
|
@ -194,7 +194,6 @@ private:
|
||||||
|
|
||||||
// QWidget interface
|
// QWidget interface
|
||||||
protected:
|
protected:
|
||||||
void showEvent(QShowEvent *event) override;
|
|
||||||
void hideEvent(QHideEvent *event) override;
|
void hideEvent(QHideEvent *event) override;
|
||||||
|
|
||||||
// QObject interface
|
// QObject interface
|
||||||
|
|
Loading…
Reference in New Issue