StrokesPlus Forum
                       
StrokesPlus Forum
Home | Profile | Register | Active Topics
Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 General Discussion
 General Discussion
 Tricky - to disable keystrokes and mouse clicks
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

chandisciple

75 Posts

Posted - 05/24/2016 :  14:25:06  Show Profile  Reply with Quote
Hey ROB ,

Hope you are doing great with the new s+. Can i trouble you for some clues on what i am trying please ?

Once i draw a gesture I want to give an effect of disabling keyboard and mouse in my lappy so whatever I type or click has no effect to the window including any gesture further by S+ except the gesture to enable /allow the keyboard and mouse inputs back by drawing another gesture.

I thought i could achieve this by doing a "acInputBox" and let the box accept whatever i type and click and yes of course it didn't work for me. Can you please hint me on how to achieve this with S+

Rob

USA
2602 Posts

Posted - 05/24/2016 :  14:31:15  Show Profile  Visit Rob's Homepage  Reply with Quote
acConsumePhysicalInput(1) --Consume ALL physical input

acConsumePhysicalInput(0) --Allow physical input

Note, however, and I cannot stress this enough:

Once you call acConsumePhysicalInput(1), absolutely ALL mouse and keyboard input will be consumed by S+, meaning you will have NO ability to draw another gesture or press any key strokes!!

Use this with caution! Be certain you've thought it all through before that first call in your script. Also, I highly recommend that you save any open files in case you have to power off the computer, if something is wrong in your script and acConsumePhysicalInput(0) never gets called.

I find it's best to use these together in a SINGLE script, meaning something like this:
acConsumePhysicalInput(1)
(move the mouse via S+, like acMoveMouse)
(click the mouse via S+, like acMouseClick)
(send some keystrokes via S+, like acSendKeys)
acConsumePhysicalInput(0)
Go to Top of Page

chandisciple

75 Posts

Posted - 05/24/2016 :  16:18:41  Show Profile  Reply with Quote
You hit right to the answer Rob !!!

Thanks much
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
StrokesPlus Forum © 2011-2018 Rob Yapchanyk Go To Top Of Page
Snitz Forums 2000