I'm presently committing the attached patch that disables inset-dissolve 
correctly (preventing a crash in an invalid case) and also disables it for 
table insets.

I have also integrated those changes to my (uncommitted) backport of the 
feature to 1.4.

Jürgen
Index: src/insets/insettabular.C
===================================================================
--- src/insets/insettabular.C	(Revision 14878)
+++ src/insets/insettabular.C	(Arbeitskopie)
@@ -1045,6 +1045,28 @@ bool InsetTabular::getStatus(LCursor & c
 			return true;
 		}
 
+	case LFUN_INSET_DISSOLVE: {
+		status.enabled(false);
+		return true;
+	}
+
+	// because of the dissolve handling in insettext:
+	case LFUN_CHAR_DELETE_FORWARD:
+		if (!cur.selection() && cur.depth() > 1
+		    && cur.pit() == cur.lastpit()
+		    && cur.pos() == cur.lastpos()) {
+		status.enabled(false);
+		return true;
+		}
+		// Fall through
+
+	case LFUN_CHAR_DELETE_BACKWARD:
+		if (cur.depth() > 1 && cur.pit() == 0 && cur.pos() == 0) {
+		status.enabled(false);
+		return true;
+		}
+		// Fall through
+
 	case LFUN_INSET_MODIFY:
 		if (translate(cmd.getArg(0)) == TABULAR_CODE) {
 			status.enabled(true);
Index: src/text3.C
===================================================================
--- src/text3.C	(Revision 14878)
+++ src/text3.C	(Arbeitskopie)
@@ -1731,7 +1731,7 @@ bool LyXText::getStatus(LCursor & cur, F
 	}
 
 	case LFUN_INSET_DISSOLVE: {
-		enable = &cur.inset() && cur.inTexted();
+		enable = !isMainText() && cur.inTexted();
 		break;
 	}
 

Reply via email to