- Implemented autocompletion for the QtSearchView. - Added: MessageFinishedParsing that will be dispatched by the Project after the parsing step is done. - Moved the initial MessageActivateToken from the Project to the Application. - Added getNamesForNodesWithNamePrefix() to GraphAccess.
29 lines
572 B
C++
29 lines
572 B
C++
#ifndef QT_EDIT_BOX_H
|
|
#define QT_EDIT_BOX_H
|
|
|
|
#include <functional>
|
|
|
|
#include <QLineEdit>
|
|
|
|
class QtEditBox: public QLineEdit
|
|
{
|
|
Q_OBJECT
|
|
|
|
public:
|
|
QtEditBox(QWidget *parent);
|
|
~QtEditBox();
|
|
|
|
void setCallbackOnReturnPressed(std::function<void(void)> callback);
|
|
void setCallbackOnTextEdited(std::function<void(const std::string&)> callback);
|
|
|
|
private slots:
|
|
void slotOnReturnPressed();
|
|
void slotOnTextEdited(const QString& text);
|
|
|
|
private:
|
|
std::function<void(void)> m_onReturnPressed;
|
|
std::function<void(const std::string&)> m_onTextEdited;
|
|
};
|
|
|
|
#endif // QT_EDIT_BOX_H
|