projects
/
family-shop-mgr
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
git-svn-id: file:///svnroot/family-shop-mgr@14 26eb2498-383b-47a6-be48-5d6f36779e85
[family-shop-mgr]
/
code
/
family-shop-mgr
/
ListManagerView.cpp
diff --git
a/code/family-shop-mgr/ListManagerView.cpp
b/code/family-shop-mgr/ListManagerView.cpp
index
d602753
..
38525f7
100644
(file)
--- a/
code/family-shop-mgr/ListManagerView.cpp
+++ b/
code/family-shop-mgr/ListManagerView.cpp
@@
-22,13
+22,27
@@
#include "ListManagerView.h"
\r
#include "ui_ListManager.h"
\r
\r
#include "ListManagerView.h"
\r
#include "ui_ListManager.h"
\r
\r
-ListManagerView::ListManagerView(QWidget *parent)
\r
- :QWidget(parent), ui(new Ui::ListManagerView)
\r
+#include "ShoppingTreeModel.h"
\r
+
\r
+ListManagerView::ListManagerView(QString xmlFileName, QWidget *parent)
\r
+ :QDialog(parent), ui(new Ui::ListManagerView)
\r
{
\r
ui->setupUi(this);
\r
{
\r
ui->setupUi(this);
\r
+ ShoppingTreeModel *model = new ShoppingTreeModel(xmlFileName, this);
\r
+ ui->treeView->setModel(model);
\r
+ for(int column = 0; column < model->columnCount(); column++)
\r
+ ui->treeView->resizeColumnToContents(column);
\r
+
\r
+ show();
\r
}
\r
\r
ListManagerView::~ListManagerView()
\r
{
\r
delete ui;
\r
}
\r
}
\r
\r
ListManagerView::~ListManagerView()
\r
{
\r
delete ui;
\r
}
\r
+
\r
+void ListManagerView::updateActions()
\r
+{
\r
+ bool hasSelection = !ui->treeView->selectionModel()->selection().isEmpty();
\r
+
\r
+}
\r