Grammalecte  Diff

Differences From Artifact [8de62f65f5]:

To Artifact [647c8a603c]:


20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
        this.nPositionX = 2;
        this.nPositionY = 2;
        this.bOpened = false;
        this.bWorking = false;

        this.bShadow = document.body.createShadowRoot || document.body.attachShadow;
        if (this.bShadow) {
            this.xShadowPanel = oGrammalecte.createNode("div", {id: this.sId+"_shadow", style: "width:0;height:0;"});
            this.xShadow = this.xShadowPanel.attachShadow({mode: "open"});
            this.xParent = this.xShadow;
        } else {
            this.xParent = document;
        }

        this.xPanelBar = oGrammalecte.createNode("div", {className: "grammalecte_panel_bar"});
        this.xPanelContent = oGrammalecte.createNode("div", {className: "grammalecte_panel_content"});
        this.xWaitIcon = this._createWaitIcon();







|
|
|







20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
        this.nPositionX = 2;
        this.nPositionY = 2;
        this.bOpened = false;
        this.bWorking = false;

        this.bShadow = document.body.createShadowRoot || document.body.attachShadow;
        if (this.bShadow) {
            this.xShadowHost = oGrammalecte.createNode("div", {id: this.sId+"_shadow_host", style: "width:0;height:0;"});
            this.xShadowRoot = this.xShadowHost.attachShadow({mode: "open"});
            this.xParent = this.xShadowRoot;
        } else {
            this.xParent = document;
        }

        this.xPanelBar = oGrammalecte.createNode("div", {className: "grammalecte_panel_bar"});
        this.xPanelContent = oGrammalecte.createNode("div", {className: "grammalecte_panel_content"});
        this.xWaitIcon = this._createWaitIcon();
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
        this.xPanelMessageActionButton = oGrammalecte.createNode("div", {id: "grammalecte_panel_message_action_button"});
        this.xPanelMessageBlock.appendChild(this.xPanelMessage);
        this.xPanelMessageBlock.appendChild(this.xPanelMessageActionButton);
    }

    insertIntoPage () {
        if (this.bShadow) {
            oGrammalecte.createStyle("content_scripts/panel.css", null, this.xShadow);
            oGrammalecte.createStyle("content_scripts/panel_gc.css", null, this.xShadow);
            oGrammalecte.createStyle("content_scripts/panel_lxg.css", null, this.xShadow);
            oGrammalecte.createStyle("content_scripts/panel_conj.css", null, this.xShadow);
            oGrammalecte.createStyle("content_scripts/panel_tf.css", null, this.xShadow);
            this.xShadow.appendChild(this.xPanel);
            document.body.appendChild(this.xShadowPanel);
        } else {
            if (!document.getElementById("grammalecte_csspanel")) {
                oGrammalecte.createStyle("content_scripts/panel.css", "grammalecte_csspanel", document.head);
                oGrammalecte.createStyle("content_scripts/panel_gc.css", null, document.head);
                oGrammalecte.createStyle("content_scripts/panel_lxg.css", null, document.head);
                oGrammalecte.createStyle("content_scripts/panel_conj.css", null, document.head);
                oGrammalecte.createStyle("content_scripts/panel_tf.css", null, document.head);







|
|
|
|
|
|
|







120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
        this.xPanelMessageActionButton = oGrammalecte.createNode("div", {id: "grammalecte_panel_message_action_button"});
        this.xPanelMessageBlock.appendChild(this.xPanelMessage);
        this.xPanelMessageBlock.appendChild(this.xPanelMessageActionButton);
    }

    insertIntoPage () {
        if (this.bShadow) {
            oGrammalecte.createStyle("content_scripts/panel.css", null, this.xShadowRoot);
            oGrammalecte.createStyle("content_scripts/panel_gc.css", null, this.xShadowRoot);
            oGrammalecte.createStyle("content_scripts/panel_lxg.css", null, this.xShadowRoot);
            oGrammalecte.createStyle("content_scripts/panel_conj.css", null, this.xShadowRoot);
            oGrammalecte.createStyle("content_scripts/panel_tf.css", null, this.xShadowRoot);
            this.xShadowRoot.appendChild(this.xPanel);
            document.body.appendChild(this.xShadowHost);
        } else {
            if (!document.getElementById("grammalecte_csspanel")) {
                oGrammalecte.createStyle("content_scripts/panel.css", "grammalecte_csspanel", document.head);
                oGrammalecte.createStyle("content_scripts/panel_gc.css", null, document.head);
                oGrammalecte.createStyle("content_scripts/panel_lxg.css", null, document.head);
                oGrammalecte.createStyle("content_scripts/panel_conj.css", null, document.head);
                oGrammalecte.createStyle("content_scripts/panel_tf.css", null, document.head);