Changeset 893 for trunk/plugins


Ignore:
Timestamp:
10/03/07 20:13:05 (12 years ago)
Author:
ray
Message:
  • #1079 Plugin DynamicCSS lists Xinha internal CSS
  • #1080 Some plugins leave behind stylesheet links in fullpage mode
Location:
trunk/plugins
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • trunk/plugins/Abbreviation/abbreviation.js

    r846 r893  
    4141 
    4242Abbreviation.prototype.onGenerate = function() { 
    43   var style_id = "Abbr-style" 
    44   var style = this.editor._doc.getElementById(style_id); 
    45   if (style == null) { 
    46     style = this.editor._doc.createElement("link"); 
    47     style.id = style_id; 
    48     style.rel = 'stylesheet'; 
    49     style.href = _editor_url + 'plugins/Abbreviation/abbreviation.css'; 
    50     this.editor._doc.getElementsByTagName("HEAD")[0].appendChild(style); 
    51   } 
     43  this.editor.addEditorStylesheet(_editor_url + 'plugins/Abbreviation/abbreviation.css'); 
    5244}; 
    5345 
  • trunk/plugins/DefinitionList/definition-list.js

    r856 r893  
    5050 
    5151DefinitionList.prototype.onGenerate = function() { 
    52   var style_id = "DefinitionList-style" 
    53   var style = this.editor._doc.getElementById(style_id); 
    54   if (style == null) { 
    55     style = this.editor._doc.createElement("link"); 
    56     style.id = style_id; 
    57     style.rel = 'stylesheet'; 
    58     style.href = _editor_url + 'plugins/DefinitionList/definition-list.css'; 
    59     this.editor._doc.getElementsByTagName("HEAD")[0].appendChild(style); 
    60   } 
     52  this.editor.addEditorStylesheet(_editor_url + 'plugins/DefinitionList/definition-list.css'); 
    6153}; 
    6254 
  • trunk/plugins/DynamicCSS/dynamiccss.js

    r856 r893  
    3636        for(i=0;i<iframe.styleSheets.length;i++) 
    3737        { 
    38             if(iframe.styleSheets[i].title == "table borders") continue; 
     38            if(iframe.styleSheets[i].title == "XinhaInternalCSS") continue; 
    3939             
    4040            // Mozilla 
  • trunk/plugins/Forms/forms.js

    r854 r893  
    7676 
    7777Forms.prototype.onGenerate = function() { 
    78   var style_id = "Form-style" 
    79   var style = this.editor._doc.getElementById(style_id); 
    80   if (style == null) { 
    81     style = this.editor._doc.createElement("link"); 
    82     style.id = style_id; 
    83     style.rel = 'stylesheet'; 
    84     style.href = _editor_url + 'plugins/Forms/forms.css'; 
    85     this.editor._doc.getElementsByTagName("HEAD")[0].appendChild(style); 
    86   } 
     78  this.editor.addEditorStylesheet(_editor_url + 'plugins/Forms/forms.css'); 
    8779}; 
    8880 
  • trunk/plugins/InsertAnchor/insert-anchor.js

    r856 r893  
    3434 
    3535InsertAnchor.prototype.onGenerate = function() { 
    36   var style_id = "IA-style"; 
    37   var style = this.editor._doc.getElementById(style_id); 
    38   if (style == null) { 
    39     style = this.editor._doc.createElement("link"); 
    40     style.id = style_id; 
    41     style.rel = 'stylesheet'; 
    42     style.href = _editor_url + 'plugins/InsertAnchor/insert-anchor.css'; 
    43     this.editor._doc.getElementsByTagName("HEAD")[0].appendChild(style); 
    44   } 
     36  this.editor.addEditorStylesheet(_editor_url + 'plugins/InsertAnchor/insert-anchor.css'); 
    4537}; 
    4638 
  • trunk/plugins/InsertSnippet/insert-snippet.js

    r681 r893  
    6060 
    6161InsertSnippet.prototype.onGenerate = function() { 
    62   var style_id = "IS-style"; 
    63   var style = this.editor._doc.getElementById(style_id); 
    64   if (style == null) { 
    65     style = this.editor._doc.createElement("link"); 
    66     style.id = style_id; 
    67     style.rel = 'stylesheet'; 
    68     style.href = _editor_url + 'plugins/InsertSnippet/InsertSnippet.css'; 
    69     this.editor._doc.getElementsByTagName("HEAD")[0].appendChild(style); 
    70   } 
     62  this.editor.addEditorStylesheet(_editor_url + 'plugins/InsertSnippet/InsertSnippet.css'); 
    7163}; 
    7264 
  • trunk/plugins/SetId/set-id.js

    r851 r893  
    3434 
    3535SetId.prototype.onGenerate = function() { 
    36   var style_id = "ID-style"; 
    37   var style = this.editor._doc.getElementById(style_id); 
    38   if (style == null) { 
    39     style = this.editor._doc.createElement("link"); 
    40     style.id = style_id; 
    41     style.rel = 'stylesheet'; 
    42     style.href = _editor_url + 'plugins/SetId/set-id.css'; 
    43     this.editor._doc.getElementsByTagName("HEAD")[0].appendChild(style); 
    44   } 
     36  this.editor.addEditorStylesheet(_editor_url + 'plugins/SetId/set-id.css'); 
    4537}; 
    4638 
  • trunk/plugins/Template/template.js

    r852 r893  
    3535 
    3636Template.prototype.onGenerate = function() { 
    37   var style_id = "Template-style" 
    38   var style = this.editor._doc.getElementById(style_id); 
    39   if (style == null) { 
    40     style = this.editor._doc.createElement("link"); 
    41     style.id = style_id; 
    42     style.rel = 'stylesheet'; 
    43     style.href = _editor_url + 'plugins/Template/template.css'; 
    44     this.editor._doc.getElementsByTagName("HEAD")[0].appendChild(style); 
    45   } 
     37  this.editor.addEditorStylesheet(_editor_url + 'plugins/Template/template.css'); 
    4638}; 
    4739 
Note: See TracChangeset for help on using the changeset viewer.