From f65354096163c6a80462dc56c1d6b4f15dfe9054 Mon Sep 17 00:00:00 2001 From: Abdelrazak Younes Date: Tue, 15 May 2007 17:02:10 +0000 Subject: [PATCH] Fix bug 3183 by Ozgur Ugras BARAN: * TocWidget::select() - Do not allow select ModelItem from the code for non-TOC types - add a FIXME explaining the situation. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18348 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/frontends/qt4/TocWidget.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/frontends/qt4/TocWidget.cpp b/src/frontends/qt4/TocWidget.cpp index 7046dda2f2..3edc839f54 100644 --- a/src/frontends/qt4/TocWidget.cpp +++ b/src/frontends/qt4/TocWidget.cpp @@ -206,6 +206,12 @@ void TocWidget::select(QModelIndex const & index) return; } + // FIXME: The TocBackend infrastructure is not ready for LOF and LOT + // This is because a proper ParConstIterator is not constructed in + // InsetCaption::addToToc() + if(!form_->canOutline(typeCO->currentIndex())) + return; + disconnectSelectionModel(); tocTV->setCurrentIndex(index); tocTV->scrollTo(index); -- 2.39.2