diff options
Diffstat (limited to 'include/widgets')
| -rw-r--r-- | include/widgets/InputLine.hpp | 40 | ||||
| -rw-r--r-- | include/widgets/WebViewStack.hpp | 6 |
2 files changed, 5 insertions, 41 deletions
diff --git a/include/widgets/InputLine.hpp b/include/widgets/InputLine.hpp deleted file mode 100644 index a382ff8..0000000 --- a/include/widgets/InputLine.hpp +++ /dev/null @@ -1,40 +0,0 @@ -#pragma once - -#include <QBoxLayout> -#include <QLabel> -#include <QLineEdit> -#include <QWidget> -#include <QtCore> - -#include "completion/Adapter.hpp" -#include "utils.hpp" - -class InputLine : public QWidget { - Q_OBJECT - -public: - InputLine(QString defaultInput = "", QWidget *parentNode = nullptr); - - void setInputFocus(bool focussed); - bool isInputFocussed(); - void setAdapter(Adapter *adapter); - - DELEGATE(input, hasFocus, isInputFocussed) - DELEGATE(input, setText, setInputText) - DELEGATE(input, text, getInputText) - DELEGATE(promptPrefix, text, prompt) - -signals: - void submitted(QString text); - void cancelled(); - -protected: - void keyPressEvent(QKeyEvent *event) override; - void emitSubmit(); - -private: - QLineEdit *input; - QLabel *promptPrefix; - Adapter *adapterInstance = nullptr; - QVBoxLayout *layout; -}; diff --git a/include/widgets/WebViewStack.hpp b/include/widgets/WebViewStack.hpp index c315251..e5b7ecc 100644 --- a/include/widgets/WebViewStack.hpp +++ b/include/widgets/WebViewStack.hpp @@ -5,11 +5,15 @@ #include <sys/types.h> #include "Configuration.hpp" -#include "completion/TabsModel.hpp" #include "widgets/WebView.hpp" enum OpenType { OpenUrl, OpenUrlInTab, OpenUrlInBgTab, OpenUrlInWindow }; +struct Tab { + QString url; + QString title; +}; + class WebViewStack : public QWidget { Q_OBJECT |
