| Index: options/privacy.js |
| =================================================================== |
| new file mode 100644 |
| --- /dev/null |
| +++ b/options/privacy.js |
| @@ -0,0 +1,44 @@ |
| +var privacyParent = document.getElementById('privacy'); |
| + |
| +var section = document.createElement('h2'); |
| +section.appendChild(document.createTextNode(translate.get('privacy_lists'))); |
| +privacyParent.appendChild(section); |
| + |
| +section = document.createElement('div'); |
| +section.setAttribute('class', 'section'); |
| +for(key in sources.privacy) { |
| + var br = document.createElement('br'); |
| + var label = document.createElement('label'); |
| + label.setAttribute('id', key); |
| + |
| + var checkbox = document.createElement('input'); |
| + checkbox.setAttribute('type', 'checkbox'); |
| + checkbox.setAttribute('name', key); |
| + checkbox.setAttribute('id', key + '-check'); |
| + checkbox.setAttribute('value', preferences.bool(key)); |
| + //checkbox.setAttribute('onClick', 'listClick("' + key + '")'); |
| + //checkbox.checked = lists.status(key); |
| + |
| + label.appendChild(checkbox); |
| + var text = document.createElement('span'); |
| + text.appendChild(document.createTextNode(sources.name(key) + ' ')); |
| + label.appendChild(text); |
| + if(sources.style[key] == 'opera') { |
| + var icon = document.createElement('img'); |
| + icon.setAttribute('src', '/images/opera_small.png'); |
| + label.appendChild(icon); |
| + } |
| + if(sources.url(key).match(/^https/)) { |
| + var icon = document.createElement('img'); |
| + icon.setAttribute('src', '/images/secure.png'); |
| + label.appendChild(icon); |
| + } |
| + var time = document.createElement('i'); |
| + time.setAttribute('class', 'update_time'); |
| + label.appendChild(time); |
| + section.appendChild(label); |
| + section.appendChild(br); |
| +} |
| +privacyParent.appendChild(section); |
| + |
| +//Uses listClick from lists.js |