ToC tree redrawing after resets.

http://bugzilla.lyx.org/show_bug.cgi?id=3740


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23436 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Pavel Sanda 2008-03-04 12:39:03 +00:00
parent de5fb7caf9
commit 6b2d20c8a6
2 changed files with 6 additions and 0 deletions

View File

@ -19,6 +19,7 @@
#include "support/debug.h"
#include <QHeaderView>
#include <QTimer>
#include <vector>
@ -239,6 +240,10 @@ void TocWidget::updateGui(int selected_type)
typeCO->blockSignals(false);
setTocModel(typeCO->currentIndex());
// setTocModel produce QTreeView reset and setting depth again
// is needed. That must be done after all Qt updates are processed.
QTimer::singleShot(1, this, SLOT(setTreeDepth()));
}

View File

@ -51,6 +51,7 @@ protected Q_SLOTS:
void on_moveDownTB_clicked();
void on_moveInTB_clicked();
void on_moveOutTB_clicked();
void setTreeDepth() { setTreeDepth(depth_); };
protected:
///