It was possible to insert a caption in a listing not marked as
floating. This didn't cause errors but the caption simply was
disappearing in the output.
return true;
case LFUN_CAPTION_INSERT: {
// the inset outputs at most one caption
return true;
case LFUN_CAPTION_INSERT: {
// the inset outputs at most one caption
- if (params().isInline() || getCaptionInset()) {
+ if (params().isInline() || !params().isFloat()
+ || getCaptionInset()) {
status.setEnabled(false);
return true;
}
status.setEnabled(false);
return true;
}