Project

General

Profile

Bug #3879 ยป treeview_bug.patch

Benoit Daccache, 03/06/2015 01:13 PM

View differences:

examples/treeview/TreeViewExample.C
*/
treeView_->setExpanded(model->index(0, 0), true);
treeView_->setExpanded(model->index(0, 0, model->index(0, 0)), true);
treeView_->setSelectable(true);
treeView_->setSelectionMode(Wt::SingleSelection);
treeView_->mouseWentUp().connect(std::bind([=](const Wt::WModelIndex i, const WMouseEvent &e) {
treeView_->setSelectedIndexes({i});
}, std::placeholders::_1, std::placeholders::_2));
/*
* Setup some buttons to manipulate the view and the model.
*/
WContainerWidget *wc = new WContainerWidget(this);
wc->mouseDragged().connect(std::bind([=](){
std::cerr << "Mouse Dragged" << std::endl;
}));
WPushButton *b;
b = new WPushButton("Toggle row height", wc);
    (1-1/1)