New topic: 

Simulating a Key-Press Condition (Virtual Input)

<http://forums.realsoftware.com/viewtopic.php?t=32183>

       Page 1 of 1
   [ 4 posts ]                 Previous topic | Next topic         Author  
Message       rbasic20091005153           Post subject: Simulating a Key-Press 
Condition (Virtual Input)Posted: Mon Jan 25, 2010 12:56 pm                      
         
Joined: Sat Apr 04, 2009 5:10 pm
Posts: 621              Hola,

Back in May, I was an RB starter and asked if it's possible to create a virtual 
condition of pressing the Return key or something.  Tomis responded as follows.

Quote:Using "virtual" input is certainly possible, but hardly ever a desired 
way to accomplish a task. What exactly is it that you are trying to do? There 
may be a better way.

I don't remember why I needed it any more.  Now, I'm at a different situation.  
I'm playing with Mplayer.  Opening a movie file with Mplayer is simple.  If a 
user wants to stop playing the movie, whether or not Mplayer is accessed 
through Shell, he or she needs to press the Space bar or P.  I don't know if 
there's any other way.  Anyway, I've built a video controller of my own with 
Canvas.  I want to make it so that if the user presses the Play button, the app 
will fire a Space bar stroke under MouseUp.  Is that possible?

In the meantime, I went through many topics.  In one topic, somebody mentions 
Mr. Schmitz's KeypressMBS.  Is that what it does?  Hmm...  I might be tempted 
to try it out.

Muchas gracias for your advice.

Tom     
_________________
Mac OS X 10.5.8/REALBasic 2008 R5.1 ~ REALBasic 2009 R4
Don't MBS-spam me.  Don't plugin-spam me.  No thanks.  
                            Top               rbasic20091005153           Post 
subject: Re: Simulating a Key-Press Condition (Virtual Input)Posted: Mon Jan 
25, 2010 1:02 pm                               
Joined: Sat Apr 04, 2009 5:10 pm
Posts: 621              Actually, SLAVE mode may be what I need.     
_________________
Mac OS X 10.5.8/REALBasic 2008 R5.1 ~ REALBasic 2009 R4
Don't MBS-spam me.  Don't plugin-spam me.  No thanks.  
                            Top               pregan           Post subject: 
Re: Simulating a Key-Press Condition (Virtual Input)Posted: Mon Jan 25, 2010 
1:04 pm                               
Joined: Fri Sep 30, 2005 9:16 am
Posts: 583
Location: Boston, MA, USA              If the on-screen button and the space 
bar both do the same thing, and presumably call the same method, then just call 
the method; virtually pressing the space-bar isn't necessary. I would go so far 
as to argue that any simulated user input via software-induced key presses and 
mouse clicks shouldn't be necessary.     
_________________
RB2K9r5, Mac OS 10.6, Intel, Mac-centric development
Philip Regan - Oatmeal and Coffee - http://www.oatmealandcoffee.com
Treasurer - Association of REALBasic Professionals - http://www.arbp.org  
                            Top               rbasic20091005153           Post 
subject: Re: Simulating a Key-Press Condition (Virtual Input)Posted: Mon Jan 
25, 2010 1:22 pm                               
Joined: Sat Apr 04, 2009 5:10 pm
Posts: 621              Quote:If the on-screen button and the space bar both do 
the same thing, and presumably call the same method,

Well, I want to let the user use a video controller to press the Play button or 
whatever to interact with Mplayer.

The rainbow wheel gets in my way.  I can't even press a button.  I have a 
feeling that this project is over.

I hate the rainbow wheel.     
_________________
Mac OS X 10.5.8/REALBasic 2008 R5.1 ~ REALBasic 2009 R4
Don't MBS-spam me.  Don't plugin-spam me.  No thanks.  
                            Top           Display posts from previous: All 
posts1 day7 days2 weeks1 month3 months6 months1 year Sort by AuthorPost 
timeSubject AscendingDescending          Page 1 of 1
   [ 4 posts ]     
-- 
Over 1500 classes with 29000 functions in one REALbasic plug-in collection. 
The Monkeybread Software Realbasic Plugin v9.3. 
http://www.monkeybreadsoftware.de/realbasic/plugins.shtml

[email protected]

Reply via email to