mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2026-03-13 11:05:45 +01:00
case-insensitivity for :sidebar and :dialog
This commit is contained in:
@@ -255,7 +255,7 @@ const liberator = (function () //{{{
|
|||||||
"Open a " + config.name + " dialog",
|
"Open a " + config.name + " dialog",
|
||||||
function (args)
|
function (args)
|
||||||
{
|
{
|
||||||
let arg = args[0];
|
let arg = args[0].toLowerCase();
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -82,6 +82,7 @@
|
|||||||
* stop macro playback on <C-c>
|
* stop macro playback on <C-c>
|
||||||
* :bmark now updates a bookmark, if possible. :bmark! adds a new one
|
* :bmark now updates a bookmark, if possible. :bmark! adds a new one
|
||||||
* many bug fixes
|
* many bug fixes
|
||||||
|
* :dialog and :sidebar now doesn't care about case for arguments
|
||||||
|
|
||||||
2008-08-16:
|
2008-08-16:
|
||||||
* version 1.2
|
* version 1.2
|
||||||
|
|||||||
@@ -371,10 +371,10 @@ const config = { //{{{
|
|||||||
"Open the sidebar window",
|
"Open the sidebar window",
|
||||||
function (args)
|
function (args)
|
||||||
{
|
{
|
||||||
let arg = args.literalArg;
|
let arg = args.literalArg.toLowerCase();
|
||||||
|
|
||||||
// focus if the requested sidebar is already open
|
// focus if the requested sidebar is already open
|
||||||
if (document.getElementById("sidebar-title").value == arg)
|
if (document.getElementById("sidebar-title").value.toLowerCase() == arg)
|
||||||
{
|
{
|
||||||
document.getElementById("sidebar-box").focus();
|
document.getElementById("sidebar-box").focus();
|
||||||
return;
|
return;
|
||||||
@@ -384,7 +384,7 @@ const config = { //{{{
|
|||||||
|
|
||||||
for (let [,panel] in Iterator(menu.childNodes))
|
for (let [,panel] in Iterator(menu.childNodes))
|
||||||
{
|
{
|
||||||
if (panel.label == arg)
|
if (panel.label.toLowerCase() == arg)
|
||||||
{
|
{
|
||||||
panel.doCommand();
|
panel.doCommand();
|
||||||
return;
|
return;
|
||||||
|
|||||||
Reference in New Issue
Block a user