BALL 1.5.0
Loading...
Searching...
No Matches
fileObserver.h
Go to the documentation of this file.
1// -*- Mode: C++; tab-width: 2; -*-
2// vi: set ts=2:
3//
4
5#ifndef BALL_VIEW_WIDGETS_FILEOBSERVER_H
6#define BALL_VIEW_WIDGETS_FILEOBSERVER_H
7
8#ifndef BALL_VIEW_WIDGETS_DOCKWIDGET_H
10#endif
11
12#include <QtCore/QTimer>
13#include <QtCore/QDateTime>
14
15class QAction;
16
17namespace BALL
18{
19 namespace VIEW
20 {
35 : public DockWidget
36 {
37 Q_OBJECT
38
39 public:
40
42
43
44 FileObserver(QWidget *parent = 0, const char *name = 0);
45
47 virtual ~FileObserver();
48
49 //
50 virtual void initializeWidget(MainControl& main_control);
51
52 //
53 virtual void checkMenu(MainControl& main_control);
54
56 void setFileName(String filename);
57
60
63
64 public Q_SLOTS:
65
67 void updateFile();
68
70 void start();
71
73 void stop();
74
76 void chooseFile();
77
78 protected:
79
81
82 QTimer timer_;
84 QDateTime last_vis_time_;
85 };
86
87} } // namespaces
88
89#endif // BALL_VIEW_WIDGETS_FILEOBSERVER_H
#define BALL_VIEW_EXPORT
DockWidget(QWidget *parent, const char *title=0)
Use this constructor!
void stop()
Stop the observation.
virtual void checkMenu(MainControl &main_control)
FileObserver(QWidget *parent=0, const char *name=0)
void setUpdateInterval(Size msec)
Set the update interval in milli seconds.
String getFileName() const
void chooseFile()
Choose a file and start the observer.
void start()
Start the observation.
void updateFile()
Look for updates in the file.
virtual void initializeWidget(MainControl &main_control)
void setFileName(String filename)
Set the name of the molecular file to be observed.
#define BALL_EMBEDDABLE(TYPE, BASE)
Definition embeddable.h:31
BALL_SIZE_TYPE Size