65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
|
65
66
67
68
69
70
71
72
73
74
75
76
77
78
|
-
-
-
-
|
_createCloseButton () {
let xButton = createNode("div", {className: "grammalecte_close_button", textContent: "×", title: "Fermer la fenêtre"});
xButton.onclick = function () { this.hide(); }.bind(this); // better than writing “let that = this;” before the function?
return xButton;
}
setContentNode (xNode) {
this.xPanelContent.appendChild(xNode);
}
insertIntoPage () {
document.body.appendChild(this.xPanelNode);
}
show () {
this.xPanelNode.style.display = "block";
}
|