]> git.lyx.org Git - lyx.git/blobdiff - src/insets/InsetFloat.cpp
Remove dead code + whitespace
[lyx.git] / src / insets / InsetFloat.cpp
index bd465fbc3eb8606d2e2fd38f8ef532ebcba8998d..beb5e0b5571e1b2d63508eafef0d52f2fcb0a9b8 100644 (file)
@@ -189,6 +189,12 @@ bool InsetFloat::getStatus(Cursor & cur, FuncRequest const & cmd,
                        return true;
                } else
                        return false;
+       
+       case LFUN_NEWLINE_INSERT:
+               if (params_.subfloat) {
+                       flag.setEnabled(false);
+                       return true;
+               }
 
        default:
                return InsetCollapsable::getStatus(cur, cmd, flag);
@@ -470,6 +476,12 @@ void InsetFloat::setNewLabel()
 }
 
 
+bool InsetFloat::allowsCaptionVariation(std::string const & newtype) const
+{
+       return !params_.subfloat && newtype != "LongTableNoNumber";
+}
+
+
 docstring InsetFloat::getCaption(OutputParams const & runparams) const
 {
        if (paragraphs().empty())