From c8c454d104fe37efead1f577af063b49256445cf Mon Sep 17 00:00:00 2001
From: srosse <stephane.rosse@frentix.com>
Date: Tue, 11 Jun 2019 10:25:05 +0200
Subject: [PATCH] OO-4084: allow to add both numerical and text entry in gap
 editor

---
 .../qti21/ui/editor/interactions/FIBEditorController.java    | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/src/main/java/org/olat/ims/qti21/ui/editor/interactions/FIBEditorController.java b/src/main/java/org/olat/ims/qti21/ui/editor/interactions/FIBEditorController.java
index 0cf20c1d59a..6633a289051 100644
--- a/src/main/java/org/olat/ims/qti21/ui/editor/interactions/FIBEditorController.java
+++ b/src/main/java/org/olat/ims/qti21/ui/editor/interactions/FIBEditorController.java
@@ -115,13 +115,10 @@ public class FIBEditorController extends FormBasicController {
 		if(!hasNumericals && !hasTexts) {
 			if(preferredType == QTI21QuestionType.numerical) {
 				hasNumericals = true;
-				hasTexts = false;
 			} else if(preferredType == QTI21QuestionType.fib) {
 				hasNumericals = false;
-				hasTexts = true;
 			} else {
 				hasNumericals = true;
-				hasTexts = true;
 			}
 		}
 		if(hasNumericals) {
@@ -129,7 +126,7 @@ public class FIBEditorController extends FormBasicController {
 		} else {
 			setFormContextHelp("Test editor QTI 2.1 in detail#details_testeditor_fragetypen_fib");
 		}
-		richTextConfig.enableQTITools(hasTexts, hasNumericals, false);
+		richTextConfig.enableQTITools(true, true, false);
 		
 		// Submit Button
 		FormLayoutContainer buttonsContainer = FormLayoutContainer.createButtonLayout("buttons", getTranslator());
-- 
GitLab