3 * This file is part of LyX, the document processor.
4 * Licence details can be found in the file COPYING.
8 * Full author contact details are available in file CREDITS
15 #include "QTocDialog.h"
16 #include "qt_helpers.h"
18 #include <qlistview.h>
19 #include <qpushbutton.h>
22 QTocDialog::QTocDialog(QToc * form)
23 : QTocDialogBase(0, 0, false, 0),
27 tocLV->setSorting(-1);
29 // hide the pointless QHeader
30 QWidget * w = static_cast<QWidget*>(tocLV->child("list view header"));
34 connect(closePB, SIGNAL(clicked()),
35 form, SLOT(slotClose()));
39 QTocDialog::~QTocDialog()
44 void QTocDialog::activate_adaptor(int)
46 form_->updateToc(form_->depth_);
50 void QTocDialog::depth_adaptor(int depth)
52 form_->set_depth(depth);
56 void QTocDialog::select_adaptor(QListViewItem * item)
58 form_->select(fromqstr(item->text(0)));
62 void QTocDialog::update_adaptor()
68 void QTocDialog::closeEvent(QCloseEvent * e)