Rev 107 | Rev 110 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 107 | Rev 109 | ||
---|---|---|---|
Line 1... | Line 1... | ||
1 | #ifndef MAINWINDOW_H
|
1 | #ifndef MAINWINDOW_H
|
2 | #define MAINWINDOW_H
|
2 | #define MAINWINDOW_H
|
3 | 3 | ||
4 | 4 | ||
5 | //#include "mysql.h"
|
5 | //#include "mysql.h"
|
- | 6 | ||
6 | #include <QMainWindow>
|
7 | #include <QMainWindow>
|
7 | #include <QStandardItemModel>
|
8 | #include <QStandardItemModel>
|
8 | #include <QStandardItem>
|
9 | #include <QStandardItem>
|
9 | #include <QTreeWidgetItem>
|
10 | #include <QTreeWidgetItem>
|
10 | #include <QTextCodec>
|
11 | #include <QTextCodec>
|
Line 75... | Line 76... | ||
75 | void addChildsItems(QTreeWidgetItem *perent_class_item); // äîáîâëÿåì ê ýëåìåíòó äåðåâà â êà÷åñòâå äî÷åðíèõ ýëåìåíòîâ âñå êëàññû, äëÿ êîòîðûõ êëàññ ýëåìåíòà ÿâëÿåòñÿ êîíòåéíåðîì |
76 | void addChildsItems(QTreeWidgetItem *perent_class_item); // äîáîâëÿåì ê ýëåìåíòó äåðåâà â êà÷åñòâå äî÷åðíèõ ýëåìåíòîâ âñå êëàññû, äëÿ êîòîðûõ êëàññ ýëåìåíòà ÿâëÿåòñÿ êîíòåéíåðîì |
76 | QStringList classChields(QString class_id); |
77 | QStringList classChields(QString class_id); |
77 | QMap <QString, QString> getClassList(); // ïîëó÷àåì ñïèñîê êëàññîâ |
78 | QMap <QString, QString> getClassList(); // ïîëó÷àåì ñïèñîê êëàññîâ |
78 | void initComboBox(); |
79 | void initComboBox(); |
79 | QList<QTreeWidgetItem *> rootItems; // ñïèñîê óêàçàòåëåé êîðíåâûõ óçëîâ (ìîäåëåé) |
80 | QList<QTreeWidgetItem *> rootItems; // ñïèñîê óêàçàòåëåé êîðíåâûõ óçëîâ (ìîäåëåé) |
80 | QMap <QString, QString> class_list_map; |
- | |
81 | 81 | ||
- | 82 | QMap <QString, QString> class_list_map; |
|
- | 83 | void getDatabaseData(); |
|
- | 84 | void buildTree(QTreeWidgetItem * model_item); |
|
- | 85 | QString getClassInctance(QString class_id); // ïîëó÷àåì èìÿ òàáëèöû - õðàíèëèùà îáúåêòîâ êëàññà |
|
- | 86 | void showClassObjects(QTreeWidgetItem * parent_item, QTreeWidgetItem * model_item); // îòîáðàçèì îáúåêòû äî÷åðíèõ êëàññîâ |
|
82 | 87 | ||
83 | private slots: |
88 | private slots: |
84 | void on_comboBox_currentIndexChanged( int index ); |
89 | void on_comboBox_currentIndexChanged( int index ); |
85 | void on_treeWidget_itemChanged ( QTreeWidgetItem * item, int column ); |
90 | void on_treeWidget_itemChanged ( QTreeWidgetItem * item, int column ); |
86 | void on_treeWidget_itemClicked ( QTreeWidgetItem * item, int column ); |
91 | void on_treeWidget_itemClicked ( QTreeWidgetItem * item, int column ); |