andre@609: /* Copyright (C) 2014 by Bundesamt für Sicherheit in der Informationstechnik
andre@609:  * Software engineering by Intevation GmbH
andre@609:  *
andre@609:  * This file is Free Software under the GNU GPL (v>=2)
andre@609:  * and comes with ABSOLUTELY NO WARRANTY!
andre@609:  * See LICENSE.txt for details. */
andre@609: #ifndef PROCESSWAITDIALOG_H
andre@609: #define PROCESSWAITDIALOG_H
andre@609: 
andre@609: #include <QDialog>
andre@609: #include <QStringList>
andre@609: 
emanuel@1053: /** 
emanuel@1053:  * @file processwaitdialog.h
emanuel@1053:  * @brief Dialog to show that some processes need to be closed
andre@609:  *
andre@609:  * This dialog informs about processes that are still running and
andre@609:  * need to be closed.
andre@609:  */
andre@609: 
andre@609: class ProcessWaitDialog : public QDialog
andre@609: {
andre@609:     Q_OBJECT
andre@609: 
andre@609: public:
andre@609:     /** @brief create the dialog
andre@609:      *
andre@609:      * The dialog is modal and will stay open until no more processes
andre@609:      * with names from processnames exist.
andre@609:      *
andre@609:      * @param[in] parent the parent dialog
andre@609:      * @param[in] processNames the names of the processes to wait for.
andre@609:      */
andre@609:     ProcessWaitDialog(QWidget *parent, const QStringList& processNames);
andre@609: 
andre@609: private slots:
andre@609: 
andre@609:     /** @brief update the process list */
andre@609:     void updateProcesses();
andre@609: 
andre@609: private:
andre@609: 
andre@609:     QListWidget *mProcessList;
andre@609:     const QStringList mProcessNames;
andre@609: };
andre@609: 
andre@609: #endif // PROCESSWAITDIALOG_H