Merge branch 'master' into qr

Conflicts:
	4chan_x.user.js
	script.coffee
This commit is contained in:
Nicolas Stepien 2012-01-01 15:26:24 +01:00
commit ce7aa784e4
3 changed files with 10 additions and 0 deletions

View File

@ -138,6 +138,7 @@
backlink: '>>%id', backlink: '>>%id',
favicon: 'ferongr', favicon: 'ferongr',
hotkeys: { hotkeys: {
openOptions: 'ctrl+o',
close: 'Esc', close: 'Esc',
spoiler: 'ctrl+s', spoiler: 'ctrl+s',
openQR: 'i', openQR: 'i',
@ -882,6 +883,9 @@
if (!(key = keybinds.keyCode(e))) return; if (!(key = keybinds.keyCode(e))) return;
thread = nav.getThread(); thread = nav.getThread();
switch (key) { switch (key) {
case conf.openOptions:
if (!$.id('overlay')) options.dialog();
break;
case conf.close: case conf.close:
if (o = $.id('overlay')) { if (o = $.id('overlay')) {
$.rm(o); $.rm(o);
@ -1508,6 +1512,7 @@ textarea.field {\
<div class=error><code>Keybinds</code> are disabled.</div>\ <div class=error><code>Keybinds</code> are disabled.</div>\
<table><tbody>\ <table><tbody>\
<tr><th>Actions</th><th>Keybinds</th></tr>\ <tr><th>Actions</th><th>Keybinds</th></tr>\
<tr><td>Open Options</td><td><input name=openOptions></td></tr>\
<tr><td>Close Options or QR</td><td><input name=close></td></tr>\ <tr><td>Close Options or QR</td><td><input name=close></td></tr>\
<tr><td>Quick spoiler</td><td><input name=spoiler></td></tr>\ <tr><td>Quick spoiler</td><td><input name=spoiler></td></tr>\
<tr><td>Open QR with post number inserted</td><td><input name=openQR></td></tr>\ <tr><td>Open QR with post number inserted</td><td><input name=openQR></td></tr>\

View File

@ -1,6 +1,7 @@
master master
- mayhem - mayhem
redirect 404'd pictures to archives when possible redirect 404'd pictures to archives when possible
new keybind to open the options: ctrl+o
the unread count will decrease when inlining quotes of unread posts the unread count will decrease when inlining quotes of unread posts
the report button can open multiple popups again the report button can open multiple popups again
add omploader to the list of optional flavors (http://ompldr.org/upload?url1=) add omploader to the list of optional flavors (http://ompldr.org/upload?url1=)

View File

@ -70,6 +70,7 @@ config =
backlink: '>>%id' backlink: '>>%id'
favicon: 'ferongr' favicon: 'ferongr'
hotkeys: hotkeys:
openOptions: 'ctrl+o'
close: 'Esc' close: 'Esc'
spoiler: 'ctrl+s' spoiler: 'ctrl+s'
openQR: 'i' openQR: 'i'
@ -644,6 +645,8 @@ keybinds =
thread = nav.getThread() thread = nav.getThread()
switch key switch key
when conf.openOptions
options.dialog() unless $.id 'overlay'
when conf.close when conf.close
if o = $.id 'overlay' if o = $.id 'overlay'
$.rm o $.rm o
@ -1159,6 +1162,7 @@ options =
<div class=error><code>Keybinds</code> are disabled.</div> <div class=error><code>Keybinds</code> are disabled.</div>
<table><tbody> <table><tbody>
<tr><th>Actions</th><th>Keybinds</th></tr> <tr><th>Actions</th><th>Keybinds</th></tr>
<tr><td>Open Options</td><td><input name=openOptions></td></tr>
<tr><td>Close Options or QR</td><td><input name=close></td></tr> <tr><td>Close Options or QR</td><td><input name=close></td></tr>
<tr><td>Quick spoiler</td><td><input name=spoiler></td></tr> <tr><td>Quick spoiler</td><td><input name=spoiler></td></tr>
<tr><td>Open QR with post number inserted</td><td><input name=openQR></td></tr> <tr><td>Open QR with post number inserted</td><td><input name=openQR></td></tr>