| 1 | #ifndef XMLTOOLSINTERFACE_H | 
 
 
 
 
 | 2 | #define XMLTOOLSINTERFACE_H | 
 
 
 
 
 | 3 |  | 
 
 
 
 
 | 4 | #include <QMainWindow> | 
 
 
 
 
 | 5 | #include <QClipboard> | 
 
 
 
 
 | 6 | #include <QProcess> | 
 
 
 
 
 | 7 | #include <QScrollBar> | 
 
 
 
 
 | 8 | #include <QDragEnterEvent> | 
 
 
 
 
 | 9 | #include <QMimeData> | 
 
 
 
 
 | 10 | #include <QHBoxLayout> | 
 
 
 
 
 | 11 |  | 
 
 
 
 
 | 12 | #include "utilvago.h" | 
 
 
 
 
 | 13 | #include "xmlprocessor.h" | 
 
 
 
 
 | 14 | #include "xmltoolsinterfacecommandpreview.h" | 
 
 
 
 
 | 15 |  | 
 
 
 
 
 | 16 |  | 
 
 
 
 
 | 17 | namespace Ui { | 
 
 
 
 
 | 18 | class XmlToolsInterface; | 
 
 
 
 
 | 19 | } | 
 
 
 
 
 | 20 |  | 
 
 
 
 
 | 21 | class XmlToolsInterface : public QMainWindow | 
 
 
 
 
 | 22 | { | 
 
 
 
 
 | 23 | Q_OBJECT | 
 
 
 
 
 | 24 |  | 
 
 
 
 
 | 25 | public: | 
 
 
 
 
 | 26 | explicit XmlToolsInterface(QWidget *parent = 0); | 
 
 
 
 
 | 27 | ~XmlToolsInterface(); | 
 
 
 
 
 | 28 |  | 
 
 
 
 
 | 29 | protected: | 
 
 
 
 
 | 30 |  | 
 
 
 
 
 | 31 | private slots: | 
 
 
 
 
 | 32 |  | 
 
 
 
 
 | 33 | void TXmlToolsResult(QString result, int numErrors); | 
 
 
 
 
 | 34 |  | 
 
 
 
 
 | 35 | void on_rbFilterRelativeElements_clicked(); | 
 
 
 
 
 | 36 |  | 
 
 
 
 
 | 37 | void on_rbFilterXPathExpression_clicked(); | 
 
 
 
 
 | 38 |  | 
 
 
 
 
 | 39 | void on_cbXmlToolsOperation_currentIndexChanged(const QString &arg1); | 
 
 
 
 
 | 40 |  | 
 
 
 
 
 | 41 | void on_cbFilterParentElement_toggled(bool checked); | 
 
 
 
 
 | 42 |  | 
 
 
 
 
 | 43 | void on_cbFilterAttributeName_toggled(bool checked); | 
 
 
 
 
 | 44 |  | 
 
 
 
 
 | 45 | void on_pbInputBrowse_clicked(); | 
 
 
 
 
 | 46 |  | 
 
 
 
 
 | 47 | void on_pbPreviewOperation_clicked(); | 
 
 
 
 
 | 48 |  | 
 
 
 
 
 | 49 | void on_pbOperationCommandCopyToClipboard_clicked(); | 
 
 
 
 
 | 50 |  | 
 
 
 
 
 | 51 | void on_leInputInputFiles_textChanged(const QString &arg1); | 
 
 
 
 
 | 52 |  | 
 
 
 
 
 | 53 | void on_leFilterElement_textChanged(const QString &arg1); | 
 
 
 
 
 | 54 |  | 
 
 
 
 
 | 55 | void on_leFilterParentElement_textChanged(const QString &arg1); | 
 
 
 
 
 | 56 |  | 
 
 
 
 
 | 57 | void on_leFilterAttributeName_textChanged(const QString &arg1); | 
 
 
 
 
 | 58 |  | 
 
 
 
 
 | 59 | void on_leFilterAttributeValue_textChanged(const QString &arg1); | 
 
 
 
 
 | 60 |  | 
 
 
 
 
 | 61 | void on_leInputCurrentValues_textChanged(const QString &arg1); | 
 
 
 
 
 | 62 |  | 
 
 
 
 
 | 63 | void on_leInputNewValues_textChanged(const QString &arg1); | 
 
 
 
 
 | 64 |  | 
 
 
 
 
 | 65 | void on_leInputPositions_textChanged(const QString &arg1); | 
 
 
 
 
 | 66 |  | 
 
 
 
 
 | 67 | void on_leInputDiffOldNewValue_textChanged(const QString &arg1); | 
 
 
 
 
 | 68 |  | 
 
 
 
 
 | 69 | void on_cbOptionsNoBackups_toggled(bool checked); | 
 
 
 
 
 | 70 |  | 
 
 
 
 
 | 71 | void on_pbApplyOperation_clicked(); | 
 
 
 
 
 | 72 |  | 
 
 
 
 
 | 73 | private: | 
 
 
 
 
 | 74 | Ui::XmlToolsInterface *ui; | 
 
 
 
 
 | 75 | QStringList listToProccess; //commands to execute | 
 
 
 
 
 | 76 | XmlProcessor *xmlProcessor = nullptr; | 
 
 
 
 
 | 77 | bool previewInProgress = false; | 
 
 
 
 
 | 78 |  | 
 
 
 
 
 | 79 | bool validateInput(); | 
 
 
 
 
 | 80 | QString buildCommand(const QString &alternativeFileLocation = ""); | 
 
 
 
 
 | 81 | void setCommand(); | 
 
 
 
 
 | 82 | void dropEvent(QDropEvent* event); | 
 
 
 
 
 | 83 | void dragEnterEvent(QDragEnterEvent *event); | 
 
 
 
 
 | 84 | }; | 
 
 
 
 
 | 85 |  | 
 
 
 
 
 | 86 | #endif // XMLTOOLSINTERFACE_H |