auto hot key, input for continuously holding shift while clicking instead of hitting both for every click











up vote
1
down vote

favorite












I'm trying to make all my apps have the same navigation keys as the app I use most (blender). I set up a script where when I shift middle click, it sends a middle click (middle click alone is reassigned to send left click). It works but the only problem is that I have to press shift every time I click, but I want to be able to just hold down shift and click many times to activate the AHK send.



here's the full script so far



#SingleInstance ignore 
#IfWinActive ahk_exe MagicaVoxel.exe
{
;Middle Mouse Button activates rotate
MButton::
Send, {RButton down}
KeyWait, MButton
Send, {RButton up}
Return

;shift Middle Mouse Button activates pan
+MButton::
Send, {MButton down}
KeyWait, MButton
Send, {MButton up}
Return
}









share|improve this question
























  • The first key in a combination (in this case Shift) doesn't need to be released for repeating the combination-action, unleess you use KeyWait, Shift. Something else is wrong in your script. How do you assign MButton to send left click?
    – user3419297
    Nov 18 at 18:37












  • edited the question to include the full script
    – zander
    Nov 19 at 3:21










  • Works perfectly on my system (Win10, Logitech Gaming Mouse G600) in this program (MagicaVoxel-0.99.2-alpha-win64).
    – user3419297
    Nov 19 at 14:08















up vote
1
down vote

favorite












I'm trying to make all my apps have the same navigation keys as the app I use most (blender). I set up a script where when I shift middle click, it sends a middle click (middle click alone is reassigned to send left click). It works but the only problem is that I have to press shift every time I click, but I want to be able to just hold down shift and click many times to activate the AHK send.



here's the full script so far



#SingleInstance ignore 
#IfWinActive ahk_exe MagicaVoxel.exe
{
;Middle Mouse Button activates rotate
MButton::
Send, {RButton down}
KeyWait, MButton
Send, {RButton up}
Return

;shift Middle Mouse Button activates pan
+MButton::
Send, {MButton down}
KeyWait, MButton
Send, {MButton up}
Return
}









share|improve this question
























  • The first key in a combination (in this case Shift) doesn't need to be released for repeating the combination-action, unleess you use KeyWait, Shift. Something else is wrong in your script. How do you assign MButton to send left click?
    – user3419297
    Nov 18 at 18:37












  • edited the question to include the full script
    – zander
    Nov 19 at 3:21










  • Works perfectly on my system (Win10, Logitech Gaming Mouse G600) in this program (MagicaVoxel-0.99.2-alpha-win64).
    – user3419297
    Nov 19 at 14:08













up vote
1
down vote

favorite









up vote
1
down vote

favorite











I'm trying to make all my apps have the same navigation keys as the app I use most (blender). I set up a script where when I shift middle click, it sends a middle click (middle click alone is reassigned to send left click). It works but the only problem is that I have to press shift every time I click, but I want to be able to just hold down shift and click many times to activate the AHK send.



here's the full script so far



#SingleInstance ignore 
#IfWinActive ahk_exe MagicaVoxel.exe
{
;Middle Mouse Button activates rotate
MButton::
Send, {RButton down}
KeyWait, MButton
Send, {RButton up}
Return

;shift Middle Mouse Button activates pan
+MButton::
Send, {MButton down}
KeyWait, MButton
Send, {MButton up}
Return
}









share|improve this question















I'm trying to make all my apps have the same navigation keys as the app I use most (blender). I set up a script where when I shift middle click, it sends a middle click (middle click alone is reassigned to send left click). It works but the only problem is that I have to press shift every time I click, but I want to be able to just hold down shift and click many times to activate the AHK send.



here's the full script so far



#SingleInstance ignore 
#IfWinActive ahk_exe MagicaVoxel.exe
{
;Middle Mouse Button activates rotate
MButton::
Send, {RButton down}
KeyWait, MButton
Send, {RButton up}
Return

;shift Middle Mouse Button activates pan
+MButton::
Send, {MButton down}
KeyWait, MButton
Send, {MButton up}
Return
}






keyboard-shortcuts autohotkey






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Nov 19 at 3:21

























asked Nov 18 at 13:43









zander

63




63












  • The first key in a combination (in this case Shift) doesn't need to be released for repeating the combination-action, unleess you use KeyWait, Shift. Something else is wrong in your script. How do you assign MButton to send left click?
    – user3419297
    Nov 18 at 18:37












  • edited the question to include the full script
    – zander
    Nov 19 at 3:21










  • Works perfectly on my system (Win10, Logitech Gaming Mouse G600) in this program (MagicaVoxel-0.99.2-alpha-win64).
    – user3419297
    Nov 19 at 14:08


















  • The first key in a combination (in this case Shift) doesn't need to be released for repeating the combination-action, unleess you use KeyWait, Shift. Something else is wrong in your script. How do you assign MButton to send left click?
    – user3419297
    Nov 18 at 18:37












  • edited the question to include the full script
    – zander
    Nov 19 at 3:21










  • Works perfectly on my system (Win10, Logitech Gaming Mouse G600) in this program (MagicaVoxel-0.99.2-alpha-win64).
    – user3419297
    Nov 19 at 14:08
















The first key in a combination (in this case Shift) doesn't need to be released for repeating the combination-action, unleess you use KeyWait, Shift. Something else is wrong in your script. How do you assign MButton to send left click?
– user3419297
Nov 18 at 18:37






The first key in a combination (in this case Shift) doesn't need to be released for repeating the combination-action, unleess you use KeyWait, Shift. Something else is wrong in your script. How do you assign MButton to send left click?
– user3419297
Nov 18 at 18:37














edited the question to include the full script
– zander
Nov 19 at 3:21




edited the question to include the full script
– zander
Nov 19 at 3:21












Works perfectly on my system (Win10, Logitech Gaming Mouse G600) in this program (MagicaVoxel-0.99.2-alpha-win64).
– user3419297
Nov 19 at 14:08




Works perfectly on my system (Win10, Logitech Gaming Mouse G600) in this program (MagicaVoxel-0.99.2-alpha-win64).
– user3419297
Nov 19 at 14:08

















active

oldest

votes











Your Answer






StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");

StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














 

draft saved


draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53361535%2fauto-hot-key-input-for-continuously-holding-shift-while-clicking-instead-of-hit%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown






























active

oldest

votes













active

oldest

votes









active

oldest

votes






active

oldest

votes
















 

draft saved


draft discarded



















































 


draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53361535%2fauto-hot-key-input-for-continuously-holding-shift-while-clicking-instead-of-hit%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Paul Cézanne

UIScrollView CustomStickyHeader Resize height generates problems when scroll is too fast

Angular material date-picker (MatDatepicker) auto completes the date on focus out