Krita is a free and open source cross-platform application that offers an end-to-end solution for creating digital art files from scratch built on the KDE and Qt frameworks.
C++
/*
* SPDX-FileCopyrightText: 2021 Alvin Wong <[email protected]>
*
* SPDX-License-Identifier: GPL-3.0-or-later
*/
#include <KisPopupSelfActivatingLineEdit.h>
KisPopupSelfActivatingLineEdit::KisPopupSelfActivatingLineEdit(QWidget *parent)
: QLineEdit(parent)
{
}
KisPopupSelfActivatingLineEdit::~KisPopupSelfActivatingLineEdit()
{
}
void KisPopupSelfActivatingLineEdit::focusInEvent(QFocusEvent *e)
{
QWidget *w = window();
if (w->windowType() == Qt::Popup) {
w->activateWindow();
}
QLineEdit::focusInEvent(e);
}