Changeset 238 for trunk


Ignore:
Timestamp:
06/22/05 13:09:42 (14 years ago)
Author:
gocher
Message:

new config property skin

skin select for full_example

Location:
trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/examples/full_example-body.html

    r211 r238  
    130130    window.onload = xinha_init; 
    131131  </script> 
    132   <link type="text/css" rel="stylesheet" title="blue-look" href="../skins/blue-look/skin.css" /> 
     132  <!--link type="text/css" rel="alternate stylesheet" title="blue-look" href="../skins/blue-look/skin.css" /> 
    133133  <link type="text/css" rel="alternate stylesheet" title="green-look" href="../skins/green-look/skin.css" /> 
    134134  <link type="text/css" rel="alternate stylesheet" title="xp-blue" href="../skins/xp-blue/skin.css" /> 
    135135  <link type="text/css" rel="alternate stylesheet" title="xp-green" href="../skins/xp-green/skin.css" /> 
    136136  <link type="text/css" rel="alternate stylesheet" title="inditreuse" href="../skins/inditreuse/skin.css" /> 
    137   <link type="text/css" rel="alternate stylesheet" title="blue-metallic" href="../skins/blue-metallic/skin.css" /> 
     137  <link type="text/css" rel="alternate stylesheet" title="blue-metallic" href="../skins/blue-metallic/skin.css" /--> 
    138138</head> 
    139139 
  • trunk/examples/full_example-menu.html

    r228 r238  
    161161          </select> 
    162162        </label> 
     163        <label> 
     164          Skin: 
     165          <select name="skin"> 
     166          <option value="blue-look">blue-look</option> 
     167          <option value="green-look">green-look</option> 
     168          <option value="xp-blue">xp-blue</option> 
     169          <option value="xp-green">xp-green</option> 
     170          <option value="inditreuse">inditreuse</option> 
     171          <option value="blue-metallic">blue-metallic</option> 
     172          </select> 
     173        </label> 
    163174    </fieldset> 
    164175    <input type="submit" value="Show Example" /> 
  • trunk/examples/full_example.js

    r211 r238  
    1212 
    1313  var num     = 1; 
     14  var skin    = ""; 
    1415  if(window.parent && window.parent != window) 
    1516  { 
    1617    var f = window.parent.menu.document.forms[0]; 
    1718    _editor_lang = f.lang.value; 
     19    skin = f.skin.value; 
    1820    num = parseInt(f.num.value); 
    1921    if(isNaN(num)) 
     
    4042    var    config = new HTMLArea.Config(); 
    4143 
     44    if(skin != "") 
     45    { 
     46      config.skin = skin; 
     47    }   
    4248    if(typeof CSS != 'undefined') 
    4349    { 
  • trunk/htmlarea.js

    r233 r238  
    278278 
    279279  this.flowToolbars = true; 
     280   
     281  // skin stylesheet to load 
     282  this.skin = ""; 
    280283 
    281284  /** CUSTOMIZING THE TOOLBAR 
     
    11261129      return false; 
    11271130  } 
     1131   
     1132  if(editor.config.skin != "") { 
     1133    var found=false; 
     1134    var head = document.getElementsByTagName("head")[0]; 
     1135    var links = document.getElementsByTagName("link"); 
     1136    for(var i = 0; i<links.length; i++) { 
     1137      if((links[i].rel == "stylesheet")&&(links[i].href == _editor_url + 'skins/' + editor.config.skin + '/skin.css')) 
     1138        found = true; 
     1139    } 
     1140    if(!found) { 
     1141      var link = document.createElement("link"); 
     1142      link.type = "text/css"; 
     1143      link.href = _editor_url + 'skins/' + editor.config.skin + '/skin.css'; 
     1144      link.rel = "stylesheet" 
     1145      head.appendChild(link); 
     1146    } 
     1147  } 
    11281148 
    11291149  //backwards-compatibility: load FullScreen-Plugin if we find a "popupeditor"-button in the toolbar 
Note: See TracChangeset for help on using the changeset viewer.