From: Abdelrazak Younes Date: Thu, 15 Mar 2007 19:16:53 +0000 (+0000) Subject: Fix this bug reported by Bernhard Roider: X-Git-Tag: 1.6.10~10592 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=f752d776f646ed5d8e7484b8e60a3c11a247b92a;p=features.git Fix this bug reported by Bernhard Roider: steps to reproduce: - create a new document - change the document class to article (AMS) - change the current layout to theorem, definition, proposition, .... - try to write something -> boom git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17449 a592a061-630c-0410-9148-cb99ea01b6c8 --- diff --git a/src/buffer_funcs.C b/src/buffer_funcs.C index aa01afe6d7..77c1af818d 100644 --- a/src/buffer_funcs.C +++ b/src/buffer_funcs.C @@ -703,7 +703,8 @@ void updateLabels(Buffer const & buf, bool childonly) void checkBufferStructure(Buffer & buffer, ParIterator const & par_it) { - if (par_it->layout()->labeltype == LABEL_COUNTER) { + if (par_it->layout()->labeltype == LABEL_COUNTER + && par_it->layout()->toclevel != LyXLayout::NOT_IN_TOC) { buffer.tocBackend().updateItem(par_it); buffer.structureChanged(); }