summaryrefslogtreecommitdiffstats
path: root/src/frame.h
diff options
context:
space:
mode:
authorMavridis Philippe <[email protected]>2021-01-13 19:26:24 +0200
committerMavridis Philippe <[email protected]>2021-01-13 19:26:24 +0200
commit8c20dc919f7d54eb48fb60f39ba5e1d466a70763 (patch)
tree44d89f278d5dd066603e5ab9c0b270bc8eb4ad51 /src/frame.h
downloadklamav-8c20dc919f7d54eb48fb60f39ba5e1d466a70763.tar.gz
klamav-8c20dc919f7d54eb48fb60f39ba5e1d466a70763.zip
Initial commit
Signed-off-by: Mavridis Philippe <[email protected]>
Diffstat (limited to 'src/frame.h')
-rw-r--r--src/frame.h75
1 files changed, 75 insertions, 0 deletions
diff --git a/src/frame.h b/src/frame.h
new file mode 100644
index 0000000..813db1e
--- /dev/null
+++ b/src/frame.h
@@ -0,0 +1,75 @@
+/***************************************************************************
+ * Copyright (C) 2004 by Sashmit Bhaduri *
+ * *
+ * Licensed under GPL. *
+ ***************************************************************************/
+
+#ifndef FRAME_H
+#define FRAME_H
+
+#include <kparts/part.h>
+
+#include <qobject.h>
+
+namespace KPIM
+{
+ class ProgressItem;
+}
+
+namespace KlamAV
+{
+
+ class Frame : public QObject
+ {
+ Q_OBJECT
+
+ public:
+ Frame(QObject *parent, KParts::ReadOnlyPart *part, QWidget *w, const QString& tit, bool watch=true);
+ ~Frame();
+
+ enum {Idle, Started, Completed, Canceled};
+
+ KParts::ReadOnlyPart *part() const;
+ QWidget *widget() const;
+ const QString title() const;
+ const QString caption() const;
+ int state() const;
+ int progress() const;
+ const QString statusText() const;
+
+ public slots:
+ void setStarted();
+ void setCanceled(const QString &);
+ void setCompleted();
+ void setState(int);
+ void setProgress(int);
+ void setCaption(const QString &);
+ void setTitle(const QString &);
+ void setStatusText(const QString &);
+
+ signals:
+ void captionChanged(const QString &);
+ void started();
+ void canceled(const QString &);
+ void completed();
+ void loadingProgress(int);
+ void statusText(const QString &);
+
+ private:
+ KParts::ReadOnlyPart *m_part;
+ QWidget *m_widget;
+ QString m_title;
+ QString m_caption;
+ int m_state;
+ int m_progress;
+ QString m_statusText;
+ QString m_progressId;
+ KPIM::ProgressItem *m_progressItem;
+ };
+}
+
+#endif
+
+
+// vim: set et ts=4 sts=4 sw=4: