Browse Source

Added show preview option

master
erqan 11 years ago
parent
commit
b4ede1d54f
  1. 13
      js/options.js
  2. 15
      options.html

13
js/options.js

@ -131,6 +131,18 @@ var TwisterOptions = function() @@ -131,6 +131,18 @@ var TwisterOptions = function()
$.Options.setOption(this.id, this.value);
})
}
this.getShowPreviewOpt = function() {
return $.Options.getOption('displayPreview',"disable");
}
this.setShowPreviewOpt = function () {
$('#showPreviewOpt select')[0].value = this.getShowPreviewOpt();
$('#showPreviewOpt select').on('change', function(){
$.Options.setOption(this.id, this.value);
})
}
this.InitOptions = function() {
this.soundNotifOptions();
@ -139,6 +151,7 @@ var TwisterOptions = function() @@ -139,6 +151,7 @@ var TwisterOptions = function()
this.setLang();
this.setTheme();
this.setLineFeedsOpt();
this.setShowPreviewOpt();
}
}

15
options.html

@ -149,6 +149,21 @@ @@ -149,6 +149,21 @@
</div>
</div>
<div class="preview-display">
<div class="module">
<p> Posts display </p>
<div>
<form action="" id="showPreviewOpt">
<p>Inline image preview</p>
<select name="" id="displayPreview">
<option value="disable">Ignore</option>
<option value="enable">Display</option>
</select>
</form>
</div>
</div>
</div>
</div>
</body>
</html>

Loading…
Cancel
Save