pulizia
[avrdudequi:avrdudequi.git] / avrdudequi.h
1 /***************************************************************************
2  *   Copyright (C) 2011 by Maurilio                                        *
3  *   mau_ri_tec@yahoo.it                                                   *
4  *                                                                         *
5  *   This program is free software; you can redistribute it and/or modify  *
6  *   it under the terms of the GNU General Public License as published by  *
7  *   the Free Software Foundation; either version 2 of the License, or     *
8  *   (at your option) any later version.                                   *
9  *                                                                         *
10  *   This program is distributed in the hope that it will be useful,       *
11  *   but WITHOUT ANY WARRANTY; without even the implied warranty of        *
12  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the         *
13  *   GNU General Public License for more details.                          *
14  *                                                                         *
15  *   You should have received a copy of the GNU General Public License     *
16  *   along with this program; if not, write to the                         *
17  *   Free Software Foundation, Inc.,                                       *
18  *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.             *
19  ***************************************************************************/
20
21 #ifndef AVRDUDEQUI_H
22 #define AVRDUDEQUI_H
23
24 #include <QMainWindow>
25 #include <QLabel>
26
27 #include "programmer.h"
28 #include "mcu.h"
29 #include "programmersettings.h"
30 #include "runprocessdialog.h"
31
32
33 namespace Ui {
34     class AvrDudeQui;
35 }
36
37 class AvrDudeQui : public QMainWindow
38 {
39     Q_OBJECT
40
41 public:
42     explicit AvrDudeQui(QWidget *parent = 0);
43     ~AvrDudeQui();
44
45 public slots:
46     void noEdit();
47     void populate();
48     void cBoxProgChanged(const QString &);
49     void cBoxMcuChanged(int idx);
50     void changeWidget(QWidget *mcuWidget);
51     void programmerDialog();
52     void writeData();
53     void readData();
54     void enableButtonWrite(bool);
55     void enableButtonRead(bool);
56     void loadHex();
57     void clearFlashEdit();
58     void operateModeChanged();
59
60 private:
61     Ui::AvrDudeQui *ui;
62     Programmer *theProgrammer;
63     Mcu *theMcu;
64     QWidget *oldMcuWidget;
65     QSize windowBaseSize;
66     QMap<QString, QString> *progData;
67     QString flashFileName;
68     int minimumStep;
69     void updateChange();
70
71 };
72
73
74 #endif // AVRDUDEQUI_H