Classified ads
tclPrograms.h
Go to the documentation of this file.
1 /* -*-C++-*- -*-coding: utf-8-unix;-*-
2  Classified Ads is Copyright (c) Antti Järvinen 2015-2017.
3 
4  This file is part of Classified Ads.
5 
6  Classified Ads is free software; you can redistribute it and/or
7  modify it under the terms of the GNU Lesser General Public
8  License as published by the Free Software Foundation; either
9  version 2.1 of the License, or (at your option) any later version.
10 
11  Classified Ads is distributed in the hope that it will be useful,
12  but WITHOUT ANY WARRANTY; without even the implied warranty of
13  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14  Lesser General Public License for more details.
15 
16  You should have received a copy of the GNU Lesser General Public
17  License along with Classified Ads; if not, write to the Free Software
18  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19 */
20 
21 #ifndef CA_TCLPROGRAMLISTING_DIALOG_H
22 #define CA_TCLPROGRAMLISTING_DIALOG_H
23 
24 #include <QDialog>
25 #include <QStandardItemModel>
26 #include "../mcontroller.h"
27 #include "../ui_tclPrograms.h"
28 
29 class QAbstractButton ;
30 
34 class TclProgramsDialog : public QDialog {
35  Q_OBJECT
36 
37 public:
41  TclProgramsDialog(QWidget *aParent,
42  MController& aController );
45 public slots:
50  void tclProgramStarted() ;
55  void tclProgramStopped() ;
56 private slots:
60  void evalButtonPressed() ;
64  void saveButtonPressed() ;
68  void discardButtonPressed() ;
72  void dialogButtonClicked(QAbstractButton *aButton) ;
76  void programInListActivated(const QModelIndex & aIndex) ;
80  void editorModificationChanged ( bool aChanged );
81 signals:
83  const QString& aExplanation) ;
87  void evalScript(QString aScript, QString* aWindowTitle) ;
88 private:
91  QStandardItemModel iProgramListingModel ;
92  QAbstractButton* iEvalButton ;
93  QAbstractButton* iDeleteButton ;
100 };
101 
102 #endif
void evalButtonPressed()
void tclProgramStopped()
QAbstractButton * iDeleteButton
Definition: tclPrograms.h:93
void programInListActivated(const QModelIndex &aIndex)
QStandardItemModel iProgramListingModel
Definition: tclPrograms.h:91
TclProgramsDialog(QWidget *aParent, MController &aController)
void editorModificationChanged(bool aChanged)
void tclProgramStarted()
bool iIsProgramSaved
Definition: tclPrograms.h:98
MController & iController
Definition: tclPrograms.h:90
Hash is class that carries 160-bit digest.
Definition: hash.h:38
CAErrorSituation
Definition: mcontroller.h:57
QString iEvalButtonStopText
Definition: tclPrograms.h:95
Hash iFingerPrintOfCurrentProgram
Definition: tclPrograms.h:97
Pure-virtual interface class for controller. This is spammed across parties needing access to applica...
Definition: mcontroller.h:48
bool iIsProgramRunning
Definition: tclPrograms.h:99
Ui_tclProgramsDialog ui
Definition: tclPrograms.h:89
Definition: ui_tclPrograms.h:27
void dialogButtonClicked(QAbstractButton *aButton)
QAbstractButton * iEvalButton
Definition: tclPrograms.h:92
void saveButtonPressed()
class for displaying listing of stored TCL scripts
Definition: tclPrograms.h:34
void discardButtonPressed()
QString iEvalButtonStartText
Definition: tclPrograms.h:94
QString iNameOfCurrentProgram
Definition: tclPrograms.h:96
void error(MController::CAErrorSituation aError, const QString &aExplanation)
void evalScript(QString aScript, QString *aWindowTitle)