keyconfig 20110522
-
- Posts: 2
- Joined: March 3rd, 2006, 5:49 am
using mouse buttons
Hi!
Is it possible (if yes, how?) to use mouse buttons as shortcuts?
i would like to go "Back" by pressing CTRL+"left mouse button" and forward on CTRL+"right mouse button"
(i've got CTRL on my thumb-button so this would give more power to the mouse)
Thx!
/Jonas
Is it possible (if yes, how?) to use mouse buttons as shortcuts?
i would like to go "Back" by pressing CTRL+"left mouse button" and forward on CTRL+"right mouse button"
(i've got CTRL on my thumb-button so this would give more power to the mouse)
Thx!
/Jonas
-
- Posts: 1203
- Joined: January 9th, 2004, 9:57 am
- Contact:
Re: using mouse buttons
No.Mattsson.Jonas wrote:Is it possible (if yes, how?) to use mouse buttons as shortcuts?
-
- Posts: 0
- Joined: December 31st, 1969, 5:00 pm
Re: using mouse buttons
Mattsson.Jonas wrote:this would give more power to the mouse
If you want more power for the mouse, why not try a mouse gestures extension like Mouse Gestures or All-in-one Gestures instead? They're about the keyconfig equivalent for the mouse.
-
- Posts: 2
- Joined: March 3rd, 2006, 5:49 am
-
- Posts: 1029
- Joined: January 28th, 2006, 3:08 pm
hi dorando, need a bit more help with the arrow keys to do find, per a page back or so..
arrow keys work fine, but i also need to use them when invoking the findbar dialog by button or /, eg if the input field is not blank, then arrow key does find next exactly like F3.
i looked at the code in toolkit.jar and added a second if statement like so:
if(findService.searchString.length > 0)
stonie_findSelection(0);
but that didn't do it. i'm on thin ice trying to read code anyway.. any ideas?
arrow keys work fine, but i also need to use them when invoking the findbar dialog by button or /, eg if the input field is not blank, then arrow key does find next exactly like F3.
i looked at the code in toolkit.jar and added a second if statement like so:
if(findService.searchString.length > 0)
stonie_findSelection(0);
but that didn't do it. i'm on thin ice trying to read code anyway.. any ideas?
- Mickey73
- Posts: 26
- Joined: March 4th, 2006, 12:16 pm
- Location: Toronto
-
- Posts: 0
- Joined: December 31st, 1969, 5:00 pm
Assign keywords to your bookmarklets and use then the following code (replace KEYWORD with the assigned keywords):
Code: Select all
content.location = getShortcutOrURI("KEYWORD", {});
- Mickey73
- Posts: 26
- Joined: March 4th, 2006, 12:16 pm
- Location: Toronto
-
- Posts: 1203
- Joined: January 9th, 2004, 9:57 am
- Contact:
The problem is that the findbar textbox receives the focus and those handle these keys themselves. To handle these it would be necessary to capture the event before it reaches the textbox (while some <a href="http://xulplanet.com/references/elemref/ref_key.html#attr_phase">sources</a> suggests that it is possible change the event phase of a <key> I wasn't able to get it working) so you could build a custom extension (starting with a <a href="http://dev.dorando.at/mozilla/blank.xpi">blank</a> one) and use some code similar to this (insert it in overlays/browser.xul between the <script></script>):alta88 wrote:hi dorando, need a bit more help with the arrow keys to do find, per a page back or so..
arrow keys work fine, but i also need to use them when invoking the findbar dialog by button or /, eg if the input field is not blank, then arrow key does find next exactly like F3.
i looked at the code in toolkit.jar and added a second if statement like so:
if(findService.searchString.length > 0)
stonie_findSelection(0);
but that didn't do it. i'm on thin ice trying to read code anyway.. any ideas?
Code: Select all
document.getElementById("find-field").
addEventListener("keypress",function(event){
switch(event.keyCode) {
case event.DOM_VK_LEFT:
if(event.target.selectionStart == 0)
findPrevious();
break;
case event.DOM_VK_RIGHT:
if(event.target.selectionEnd == event.target.textLength)
findNext();
break;
}
},false);
-
- Posts: 3
- Joined: March 24th, 2006, 12:59 pm
Is there a way to make FF use ctrl+enter instead of alt+enter for opening new tabs? I am used to using Mozilla and that is how it works. Also ctrl makes more sense to me as it is already conected to tabs, example: ctrl+click opens link in new tab and ctrl+enter in Googlebar opens search in a new tab.
All I want is to do is make alt+enter open stuff with .com extension and make ctrl+enter open new tab.
thanks,
oab2
All I want is to do is make alt+enter open stuff with .com extension and make ctrl+enter open new tab.
thanks,
oab2
-
- Posts: 1203
- Joined: January 9th, 2004, 9:57 am
- Contact:
Build a custom extension (starting with a <a href="http://dev.dorando.at/mozilla/blank.xpi">blank</a> one) and use the following code (insert it in overlays/browser.xul between the <script></script>):
Code: Select all
eval("BrowserLoadURL ="+BrowserLoadURL.toString().replace(
/altKey/g,
'ctrlKey'
));
eval("canonizeUrl ="+canonizeUrl.toString().replace(
/ctrlKey/g,
'altKey'
));
-
- Posts: 3
- Joined: March 24th, 2006, 12:59 pm
dorando wrote:Build a custom extension (starting with a <a href="http://dev.dorando.at/mozilla/blank.xpi">blank</a> one) and use the following code (insert it in overlays/browser.xul between the <script></script>):Code: Select all
eval("BrowserLoadURL ="+BrowserLoadURL.toString().replace(
/altKey/g,
'ctrlKey'
));
eval("canonizeUrl ="+canonizeUrl.toString().replace(
/ctrlKey/g,
'altKey'
));
Thanks for the response. That sorta works. However when i control enter it does not open a new tap but loads in current tap. alt enter does add .com however. ctrl click doesn't work though. So maybe i need to learn to use alt. Why did they do this with FF?
-
- Posts: 1203
- Joined: January 9th, 2004, 9:57 am
- Contact:
-
- Posts: 1029
- Joined: January 28th, 2006, 3:08 pm
dorando wrote:The problem is that the findbar textbox receives the focus and those handle these keys themselves. To handle these it would be necessary to capture the event before it reaches the textbox (while some <a href="http://xulplanet.com/references/elemref/ref_key.html#attr_phase">sources</a> suggests that it is possible change the event phase of a <key> I wasn't able to get it working) so you could build a custom extension (starting with a <a href="http://dev.dorando.at/mozilla/blank.xpi">blank</a> one) and use some code similar to this (insert it in overlays/browser.xul between the <script></script>):Code: Select all
document.getElementById("find-field").
addEventListener("keypress",function(event){
switch(event.keyCode) {
case event.DOM_VK_LEFT:
if(event.target.selectionStart == 0)
findPrevious();
break;
case event.DOM_VK_RIGHT:
if(event.target.selectionEnd == event.target.textLength)
findNext();
break;
}
},false);
i had been pondering whether to figure out how to make this extension, and if that were even the better long term method to solve this, given i probably have loads of tiny tweaks and it would take 2 files per, pretty manual as opposed to automated work (and greasemonkey couldn't help), new Fx coming, etc.
well, with zeniko's userChrome.js extension, i just popped this code into a file and it worked as expected.
thanks to you both!
(although it would be nice to have keyconfig take over events before anything else gets them..)