@@ -1,8 +1,13 | |||||
1 | #include "binaryfilewidget.h" |
|
1 | #include "binaryfilewidget.h" | |
2 | #include "ui_binaryfilewidget.h" |
|
2 | #include "ui_binaryfilewidget.h" | |
3 | #include "qtablewidgetintitem.h" |
|
3 | #include "qtablewidgetintitem.h" | |
|
4 | #if QT_VERSION >= 0x050000 | |||
4 | #include <QtWidgets/QTableWidget> |
|
5 | #include <QtWidgets/QTableWidget> | |
5 | #include <QtWidgets/QFileDialog> |
|
6 | #include <QtWidgets/QFileDialog> | |
|
7 | #else | |||
|
8 | #include <QTableWidget> | |||
|
9 | #include <QFileDialog> | |||
|
10 | #endif | |||
6 | #include "srecfile.h" |
|
11 | #include "srecfile.h" | |
7 |
|
12 | |||
8 | binaryFileWidget::binaryFileWidget(QWidget *parent) : |
|
13 | binaryFileWidget::binaryFileWidget(QWidget *parent) : |
@@ -21,10 +21,13 | |||||
21 | ----------------------------------------------------------------------------*/ |
|
21 | ----------------------------------------------------------------------------*/ | |
22 | #ifndef ABSTRACTBINFILE_H |
|
22 | #ifndef ABSTRACTBINFILE_H | |
23 | #define ABSTRACTBINFILE_H |
|
23 | #define ABSTRACTBINFILE_H | |
24 |
|
24 | #if QT_VERSION >= 0x050000 | ||
25 | #include <QtCore/QObject> |
|
25 | #include <QtCore/QObject> | |
26 | #include <QtWidgets/QWidget> |
|
26 | #include <QtWidgets/QWidget> | |
27 |
|
27 | #else | ||
|
28 | #include <QObject> | |||
|
29 | #include <QWidget> | |||
|
30 | #endif | |||
28 | class codeFragment |
|
31 | class codeFragment | |
29 | { |
|
32 | { | |
30 | public: |
|
33 | public: |
@@ -489,7 +489,9 QString ElfFile::getABI() | |||||
489 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_TRU64)return "Compaq TRU64 UNIX"; |
|
489 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_TRU64)return "Compaq TRU64 UNIX"; | |
490 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_MODESTO)return " Novell Modesto"; |
|
490 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_MODESTO)return " Novell Modesto"; | |
491 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_OPENBSD)return "OpenBSD"; |
|
491 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_OPENBSD)return "OpenBSD"; | |
|
492 | #ifdef ELFOSABI_ARM_AEABI | |||
492 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_ARM_AEABI)return "ARM EABI"; |
|
493 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_ARM_AEABI)return "ARM EABI"; | |
|
494 | #endif | |||
493 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_ARM)return "ARM"; |
|
495 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_ARM)return "ARM"; | |
494 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_STANDALONE)return "Standalone (embedded) application"; |
|
496 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_STANDALONE)return "Standalone (embedded) application"; | |
495 | } |
|
497 | } |
@@ -21,8 +21,13 | |||||
21 | ----------------------------------------------------------------------------*/ |
|
21 | ----------------------------------------------------------------------------*/ | |
22 | #include "elffilewidget.h" |
|
22 | #include "elffilewidget.h" | |
23 | #include "ui_elffilewidget.h" |
|
23 | #include "ui_elffilewidget.h" | |
|
24 | #if QT_VERSION >= 0x050000 | |||
24 | #include <QtWidgets/QTableWidgetItem> |
|
25 | #include <QtWidgets/QTableWidgetItem> | |
25 | #include <QtWidgets/QFileDialog> |
|
26 | #include <QtWidgets/QFileDialog> | |
|
27 | #else | |||
|
28 | #include <QTableWidgetItem> | |||
|
29 | #include <QFileDialog> | |||
|
30 | #endif | |||
26 | #include "qhexedit.h" |
|
31 | #include "qhexedit.h" | |
27 | #include "qtablewidgetintitem.h" |
|
32 | #include "qtablewidgetintitem.h" | |
28 | #include "../srec/srecfile.h" |
|
33 | #include "../srec/srecfile.h" |
@@ -22,9 +22,14 | |||||
22 | #ifndef ELFFILEWIDGET_H |
|
22 | #ifndef ELFFILEWIDGET_H | |
23 | #define ELFFILEWIDGET_H |
|
23 | #define ELFFILEWIDGET_H | |
24 |
|
24 | |||
|
25 | #if QT_VERSION >= 0x050000 | |||
25 | #include <QtWidgets/QWidget> |
|
26 | #include <QtWidgets/QWidget> | |
|
27 | #include <QtWidgets/QAction> | |||
|
28 | #else | |||
|
29 | #include <QWidget> | |||
|
30 | #include <QAction> | |||
|
31 | #endif | |||
26 | #include "elffile.h" |
|
32 | #include "elffile.h" | |
27 | #include <QtWidgets/QAction> |
|
|||
28 | #include <qhexedit.h> |
|
33 | #include <qhexedit.h> | |
29 |
|
34 | |||
30 | namespace Ui { |
|
35 | namespace Ui { |
@@ -22,15 +22,26 | |||||
22 | #ifndef ELFINFOWDGT_H |
|
22 | #ifndef ELFINFOWDGT_H | |
23 | #define ELFINFOWDGT_H |
|
23 | #define ELFINFOWDGT_H | |
24 |
|
24 | |||
|
25 | #if QT_VERSION >= 0x050000 | |||
25 | #include <QtWidgets/QWidget> |
|
26 | #include <QtWidgets/QWidget> | |
26 | #include "elfparser.h" |
|
|||
27 | #include <QtWidgets/QVBoxLayout> |
|
27 | #include <QtWidgets/QVBoxLayout> | |
28 | #include <QtWidgets/QHBoxLayout> |
|
28 | #include <QtWidgets/QHBoxLayout> | |
29 | #include <QtWidgets/QLabel> |
|
29 | #include <QtWidgets/QLabel> | |
30 | #include <QtWidgets/QTextEdit> |
|
30 | #include <QtWidgets/QTextEdit> | |
31 | #include <QtWidgets/QTableWidget> |
|
31 | #include <QtWidgets/QTableWidget> | |
|
32 | #include <QtWidgets/QSplitter> | |||
|
33 | #else | |||
|
34 | #include <QWidget> | |||
|
35 | #include <QVBoxLayout> | |||
|
36 | #include <QHBoxLayout> | |||
|
37 | #include <QLabel> | |||
|
38 | #include <QTextEdit> | |||
|
39 | #include <QTableWidget> | |||
|
40 | #include <QSplitter> | |||
|
41 | #endif | |||
|
42 | ||||
|
43 | #include "elfparser.h" | |||
32 | #include <qhexedit.h> |
|
44 | #include <qhexedit.h> | |
33 | #include <QtWidgets/QSplitter> |
|
|||
34 |
|
45 | |||
35 | class elfInfoWdgt : public QWidget |
|
46 | class elfInfoWdgt : public QWidget | |
36 | { |
|
47 | { |
@@ -163,7 +163,9 QString elfparser::getABI() | |||||
163 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_TRU64)return "Compaq TRU64 UNIX"; |
|
163 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_TRU64)return "Compaq TRU64 UNIX"; | |
164 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_MODESTO)return " Novell Modesto"; |
|
164 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_MODESTO)return " Novell Modesto"; | |
165 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_OPENBSD)return "OpenBSD"; |
|
165 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_OPENBSD)return "OpenBSD"; | |
|
166 | #ifdef ELFOSABI_ARM_AEABI | |||
166 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_ARM_AEABI)return "ARM EABI"; |
|
167 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_ARM_AEABI)return "ARM EABI"; | |
|
168 | #endif | |||
167 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_ARM)return "ARM"; |
|
169 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_ARM)return "ARM"; | |
168 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_STANDALONE)return "Standalone (embedded) application"; |
|
170 | if(this->ehdr.e_ident[EI_OSABI]==ELFOSABI_STANDALONE)return "Standalone (embedded) application"; | |
169 | } |
|
171 | } |
@@ -1,5 +1,6 | |||||
1 | #include "filelist.h" |
|
1 | #include "filelist.h" | |
2 | #include <QMimeData> |
|
2 | #include <QMimeData> | |
|
3 | #include <QUrl> | |||
3 |
|
4 | |||
4 | FileList::FileList(QWidget *parent) : |
|
5 | FileList::FileList(QWidget *parent) : | |
5 | QTableWidget(parent) |
|
6 | QTableWidget(parent) |
@@ -23,7 +23,11 | |||||
23 | #include "ui_srecfilewidget.h" |
|
23 | #include "ui_srecfilewidget.h" | |
24 | #include <QTableWidgetItem> |
|
24 | #include <QTableWidgetItem> | |
25 | #include <qtablewidgetintitem.h> |
|
25 | #include <qtablewidgetintitem.h> | |
|
26 | #if QT_VERSION >= 0x050000 | |||
26 | #include <QtWidgets/QFileDialog> |
|
27 | #include <QtWidgets/QFileDialog> | |
|
28 | #else | |||
|
29 | #include <QFileDialog> | |||
|
30 | #endif | |||
27 | #include "binaryfile.h" |
|
31 | #include "binaryfile.h" | |
28 |
|
32 | |||
29 | srecFileWidget::srecFileWidget(QWidget *parent) : |
|
33 | srecFileWidget::srecFileWidget(QWidget *parent) : |
General Comments 0
You need to be logged in to leave comments.
Login now