]> git.lyx.org Git - lyx.git/blobdiff - src/insets/InsetCaption.cpp
Fix assertion when checking if change in selection
[lyx.git] / src / insets / InsetCaption.cpp
index 0850363bc43f98d40f8004b7227a3572411855ec..8778d78730484c4554e9c67ba7f42cfdcccd9b02 100644 (file)
@@ -17,7 +17,6 @@
 #include "Buffer.h"
 #include "BufferParams.h"
 #include "BufferView.h"
-#include "Counters.h"
 #include "Cursor.h"
 #include "Dimension.h"
 #include "Floating.h"
@@ -389,7 +388,8 @@ void InsetCaption::updateBuffer(ParIterator const & it, UpdateType utype)
                else
                        name = master.B_(tclass.floats().getType(type).name());
                docstring counter = from_utf8(type);
-               if ((is_subfloat_ = cnts.isSubfloat())) {
+               is_subfloat_ = cnts.isSubfloat();
+               if (is_subfloat_) {
                        // only standard captions allowed in subfloats
                        type_ = "Standard";
                        counter = "sub-" + from_utf8(type);