mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2025-12-23 10:08:00 +01:00
ctrl-x/a doesn'
This commit is contained in:
@@ -97,14 +97,11 @@ liberator.config = { //{{{
|
|||||||
function incrementURL(count)
|
function incrementURL(count)
|
||||||
{
|
{
|
||||||
var url = liberator.buffer.URL;
|
var url = liberator.buffer.URL;
|
||||||
var regex = /(.*?)(-?\d+)(\D*)$/;
|
var regex = /(.*?)(\d+)(\D*)$/;
|
||||||
|
|
||||||
var matches = url.match(regex);
|
var matches = url.match(regex);
|
||||||
if (!matches || !matches[2]) // no number to increment
|
if (!matches || !matches[2]) // no number to increment
|
||||||
{
|
return liberator.beep();
|
||||||
liberator.beep();
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
var newNum = parseInt(matches[2], 10) + count + ""; // "" to make sure its a string
|
var newNum = parseInt(matches[2], 10) + count + ""; // "" to make sure its a string
|
||||||
var nums = newNum.match(/^(-?)(\d+)$/);
|
var nums = newNum.match(/^(-?)(\d+)$/);
|
||||||
|
|||||||
Reference in New Issue
Block a user