Gitlab CSE Unil

Commit 9ce719e9 authored by M. Chardon's avatar M. Chardon
Browse files

vue lecture étudiante : propre, sans interaction et bouton

parent 779534ef
......@@ -805,7 +805,7 @@ Y.extend(ANNOTATION, Y.Base, {
div += "</div>";
return Y.Node.create(div);
},
get_div_cartridge_label: function (colorcartridge) {
get_div_cartridge_label: function (colorcartridge, draggable) {
var divcartridge = "<div ";
divcartridge += "id='" + this.divcartridge + "_cartridge' ";
divcartridge += "class='assignfeedback_editpdfplus_" + this.tooltypefamille.label + "_cartridge' ";
......@@ -817,7 +817,12 @@ Y.extend(ANNOTATION, Y.Base, {
divcartridge += "> ";
divcartridge += this.tooltype.cartridge;
divcartridge += "</div>";
return Y.Node.create(divcartridge);
var divcartridgedisplay = Y.Node.create(divcartridge);
if (draggable && !this.editor.get('readonly')) {
divcartridgedisplay.on('mousedown', this.move_cartridge_begin, this);
return divcartridgedisplay;
}
return divcartridgedisplay;
},
get_div_input: function (colorcartridge) {
var divinput = "<div ";
......@@ -2987,11 +2992,10 @@ Y.extend(ANNOTATIONFRAME, M.assignfeedback_editpdfplus.annotation, {
var divdisplay = this.get_div_cartridge(colorcartridge);
divdisplay.addClass('assignfeedback_editpdfplus_frame');
divdisplay.setStyles({'border-style': this.borderstyle});
divdisplay.set('draggable', 'true');
//divdisplay.set('draggable', 'true');
// inscription entete
var divcartridge = this.get_div_cartridge_label(colorcartridge);
divcartridge.on('mousedown', this.move_cartridge_begin, this);
var divcartridge = this.get_div_cartridge_label(colorcartridge, true);
divdisplay.append(divcartridge);
//creation input
......@@ -3502,8 +3506,7 @@ Y.extend(ANNOTATIONVERTICALLINE, M.assignfeedback_editpdfplus.annotation, {
divdisplay.addClass('assignfeedback_editpdfplus_verticalline');
// inscription entete
var divcartridge = this.get_div_cartridge_label(colorcartridge);
divcartridge.on('mousedown', this.move_cartridge_begin, this);
var divcartridge = this.get_div_cartridge_label(colorcartridge, true);
divdisplay.append(divcartridge);
//creation input
......
......@@ -805,7 +805,7 @@ Y.extend(ANNOTATION, Y.Base, {
div += "</div>";
return Y.Node.create(div);
},
get_div_cartridge_label: function (colorcartridge) {
get_div_cartridge_label: function (colorcartridge, draggable) {
var divcartridge = "<div ";
divcartridge += "id='" + this.divcartridge + "_cartridge' ";
divcartridge += "class='assignfeedback_editpdfplus_" + this.tooltypefamille.label + "_cartridge' ";
......@@ -817,7 +817,12 @@ Y.extend(ANNOTATION, Y.Base, {
divcartridge += "> ";
divcartridge += this.tooltype.cartridge;
divcartridge += "</div>";
return Y.Node.create(divcartridge);
var divcartridgedisplay = Y.Node.create(divcartridge);
if (draggable && !this.editor.get('readonly')) {
divcartridgedisplay.on('mousedown', this.move_cartridge_begin, this);
return divcartridgedisplay;
}
return divcartridgedisplay;
},
get_div_input: function (colorcartridge) {
var divinput = "<div ";
......@@ -2985,11 +2990,10 @@ Y.extend(ANNOTATIONFRAME, M.assignfeedback_editpdfplus.annotation, {
var divdisplay = this.get_div_cartridge(colorcartridge);
divdisplay.addClass('assignfeedback_editpdfplus_frame');
divdisplay.setStyles({'border-style': this.borderstyle});
divdisplay.set('draggable', 'true');
//divdisplay.set('draggable', 'true');
// inscription entete
var divcartridge = this.get_div_cartridge_label(colorcartridge);
divcartridge.on('mousedown', this.move_cartridge_begin, this);
var divcartridge = this.get_div_cartridge_label(colorcartridge, true);
divdisplay.append(divcartridge);
//creation input
......@@ -3498,8 +3502,7 @@ Y.extend(ANNOTATIONVERTICALLINE, M.assignfeedback_editpdfplus.annotation, {
divdisplay.addClass('assignfeedback_editpdfplus_verticalline');
// inscription entete
var divcartridge = this.get_div_cartridge_label(colorcartridge);
divcartridge.on('mousedown', this.move_cartridge_begin, this);
var divcartridge = this.get_div_cartridge_label(colorcartridge, true);
divdisplay.append(divcartridge);
//creation input
......
......@@ -264,7 +264,7 @@ Y.extend(ANNOTATION, Y.Base, {
div += "</div>";
return Y.Node.create(div);
},
get_div_cartridge_label: function (colorcartridge) {
get_div_cartridge_label: function (colorcartridge, draggable) {
var divcartridge = "<div ";
divcartridge += "id='" + this.divcartridge + "_cartridge' ";
divcartridge += "class='assignfeedback_editpdfplus_" + this.tooltypefamille.label + "_cartridge' ";
......@@ -276,7 +276,12 @@ Y.extend(ANNOTATION, Y.Base, {
divcartridge += "> ";
divcartridge += this.tooltype.cartridge;
divcartridge += "</div>";
return Y.Node.create(divcartridge);
var divcartridgedisplay = Y.Node.create(divcartridge);
if (draggable && !this.editor.get('readonly')) {
divcartridgedisplay.on('mousedown', this.move_cartridge_begin, this);
return divcartridgedisplay;
}
return divcartridgedisplay;
},
get_div_input: function (colorcartridge) {
var divinput = "<div ";
......
......@@ -198,11 +198,10 @@ Y.extend(ANNOTATIONFRAME, M.assignfeedback_editpdfplus.annotation, {
var divdisplay = this.get_div_cartridge(colorcartridge);
divdisplay.addClass('assignfeedback_editpdfplus_frame');
divdisplay.setStyles({'border-style': this.borderstyle});
divdisplay.set('draggable', 'true');
//divdisplay.set('draggable', 'true');
// inscription entete
var divcartridge = this.get_div_cartridge_label(colorcartridge);
divcartridge.on('mousedown', this.move_cartridge_begin, this);
var divcartridge = this.get_div_cartridge_label(colorcartridge, true);
divdisplay.append(divcartridge);
//creation input
......
......@@ -160,8 +160,7 @@ Y.extend(ANNOTATIONVERTICALLINE, M.assignfeedback_editpdfplus.annotation, {
divdisplay.addClass('assignfeedback_editpdfplus_verticalline');
// inscription entete
var divcartridge = this.get_div_cartridge_label(colorcartridge);
divcartridge.on('mousedown', this.move_cartridge_begin, this);
var divcartridge = this.get_div_cartridge_label(colorcartridge, true);
divdisplay.append(divcartridge);
//creation input
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment