diff options
| author | Felix (xq) Queißner <git@mq32.de> | 2020-06-19 17:55:04 +0200 |
|---|---|---|
| committer | Felix (xq) Queißner <git@mq32.de> | 2020-06-19 17:55:04 +0200 |
| commit | e716a44604dcfe0ed57d278cd4d2597bf328de03 (patch) | |
| tree | b0ddb57cbca3c4031cf8741690d78bd808e42090 /src/browsertab.hpp | |
| parent | 1eec0c9fa22e86225691e7892e9219e7d17d5c42 (diff) | |
| download | kristall-e716a44604dcfe0ed57d278cd4d2597bf328de03.tar.gz | |
Fixes non-updating status bar, fixes bug in the mime parser.
Diffstat (limited to 'src/browsertab.hpp')
| -rw-r--r-- | src/browsertab.hpp | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/src/browsertab.hpp b/src/browsertab.hpp index cc18d28..47a9871 100644 --- a/src/browsertab.hpp +++ b/src/browsertab.hpp @@ -17,12 +17,25 @@ #include "protocolhandler.hpp" +#include "mimeparser.hpp" + namespace Ui { class BrowserTab; } class MainWindow; +struct DocumentStats +{ + int loading_time = 0; // in ms + MimeType mime_type; + qint64 file_size = 0; + + bool isValid() const { + return mime_type.isValid(); + } +}; + class BrowserTab : public QWidget { Q_OBJECT @@ -57,7 +70,7 @@ public: signals: void titleChanged(QString const & title); void locationChanged(QUrl const & url); - void fileLoaded(qint64 fileSize, QString const & mime, int msec); + void fileLoaded(DocumentStats const & stats); private slots: void on_url_bar_returnPressed(); @@ -140,6 +153,8 @@ public: CryptoIdentity current_identitiy; bool is_internal_location; + + DocumentStats current_stats; }; #endif // BROWSERTAB_HPP |
