Results 1 to 10 of 10

Thread: .skin based command "ONSKINENTER"/"ONSKINEXIT"

  1. #1
    Mo' Programming Mo' Problems
    Auto Apps:loading...
    Sonicxtacy02's Avatar
    Join Date
    Sep 2004
    Location
    Woodbridge, VA
    Posts
    8,173
    Blog Entries
    53

    .skin based command "ONSKINENTER"/"ONSKINEXIT"

    I made mention to this request in some thread awhile back but i honestly cant find it. I think its a warranted command set however. Basically you'd have 2 user-definable exectbl.ini "type" commands in a .skin file

    "ONSKINENTER","DOSOMETHING" Would run upon the skin form being loaded
    "ONSKINEXIT","STOPDOINGSOMETHING" Would run upon the skin being discarded.

    I think they would work well with plugins particularly. Many plugins use pop-up boxes via the MENU; command, but the MENU; command cannot be defined in exectbl.ini as far as i can tell. Therefore, we cannot define a command to run when that MENU; command is executed.

    A real world example of this being used would be with the MobilePhone plugin. When the incoming call .skin file is opened it'd be nice to have a .wav file associated with a ringer indicating a call is incoming. Doing this now seems to be impossible, but with "ONSKINENTER","SAY;Ringer.wav" it would work

    feasible? Make sense?
    mp3Car.com Senior Tech Blogger (Want a product reviewed? Contact me.)
    Find my plugins on the MP3Car App Store!
    Follow Me on Twitter or Facebook
    Live mp3Car Facebook Chat

  2. #2
    Confusion Master
    Auto Apps:loading...
    Enforcer's Avatar
    Join Date
    Sep 2003
    Location
    If you go down to the woods today, You're sure of
    Posts
    14,634
    I think ONSKINENTER would be confusing.

    I thought you meant when a new skin is started, not an individual screen.

    maybe ONSCREENENTER and ONSCREENEXIT

  3. #3
    Maximum Bitrate
    Join Date
    Aug 2004
    Location
    Germany
    Posts
    520
    Well, you somehow call the skin. Why not put the SAY;Ringer.wav there ?
    Same when you leave the screen. Just add your commands there.
    So just execute your commands before using the MENU command. I Don't really see the problem ?!

  4. #4
    Mo' Programming Mo' Problems
    Auto Apps:loading...
    Sonicxtacy02's Avatar
    Join Date
    Sep 2004
    Location
    Woodbridge, VA
    Posts
    8,173
    Blog Entries
    53
    Quote Originally Posted by Konrad View Post
    Well, you somehow call the skin. Why not put the SAY;Ringer.wav there ?
    Same when you leave the screen. Just add your commands there.
    So just execute your commands before using the MENU command. I Don't really see the problem ?!
    the problem is YOU dont call the skin all the time... nor do you always define how a skin is called.

    Mobilephone uses the command MENU;mobilecall.skin whenever an incoming call is discovered. this command can not be user defined via exectbl.ini.

    My upcoming maintenance plugin uses the command MENU;RRVM_popup.skin when your maintenance item is due. A user doesnt control when that command is run. Now i know i can change the command from MENU;RRVM_popup.skin to RRVM_POPUP then use exectbl to define the command... but i'm using my plugin as a second example.

    The request is handy with plugins mostly... where the user doesnt create the event nor the command based on the event.
    mp3Car.com Senior Tech Blogger (Want a product reviewed? Contact me.)
    Find my plugins on the MP3Car App Store!
    Follow Me on Twitter or Facebook
    Live mp3Car Facebook Chat

  5. #5
    Mo' Programming Mo' Problems
    Auto Apps:loading...
    Sonicxtacy02's Avatar
    Join Date
    Sep 2004
    Location
    Woodbridge, VA
    Posts
    8,173
    Blog Entries
    53
    Quote Originally Posted by Enforcer View Post
    I think ONSKINENTER would be confusing.

    I thought you meant when a new skin is started, not an individual screen.

    maybe ONSCREENENTER and ONSCREENEXIT
    that'll work too!
    mp3Car.com Senior Tech Blogger (Want a product reviewed? Contact me.)
    Find my plugins on the MP3Car App Store!
    Follow Me on Twitter or Facebook
    Live mp3Car Facebook Chat

  6. #6
    FLAC Sal R.'s Avatar
    Join Date
    Aug 2006
    Location
    Sun Diego
    Posts
    1,448
    have you tried:

    "ONSCREENCHANGE","SAY;ringer.wav",mobilecall.s kin
    Pico-ITX / XP Home with EWF-HORM / RR v12/02/2009 / Winamp v5.13 / RRMedia v1.2.2

  7. #7
    RoadRunner Mastermind
    Auto Apps:loading...
    guino's Avatar
    Join Date
    Nov 2004
    Location
    Toronto, Canada
    Posts
    9,817
    This is a relative thing. Generally if you're just using skin code, you can add a command before/after a MENU/LOAD command which does what you need or before/after an EXIT/CANCEL command to do the same. If you're making an extension plugin, then you can simply put a timer in your project to monitor the current screen with RRSDK.GetInfo("RRSCREEN") then you can take actions on screen changes accordingly, furthermore you can monitor the commands that come in from the "ProcessCommand" call so you know that the last screen change was caused by a LOAD/MENU/EXIT/CANCEL command.

    I'm not opposed to adding new events, but we avoid adding what we can as a precaution. Still, there's already a ONSCREENCHANGE event, which is executed right before a screen is about to change -- this may be enough for what you want, in any case if it isn't, give me an example of what you're trying to accomplish and we can definitely work on it.

    For the ringer situation, it really should be done on the plugin side of it (not on the skin side), but it could be done as an extension plugin as well. On the skin side of things, you could use ONSCREENCHANGE to run the command to do what you want on that specific screen like:

    "ONSCREENCHANGE","PLAYSOUND;INCALL.WAV",call_in.sk in

    Or even put a TMR,1 in the call_in.skin and use:

    "TIMER","PLAYSOUND;INCALL.WAV",call_in.skin

    There are even other options available...

    EDIT: Darn it, beat by seconds...
    Ride Runner RR's Myspace

    "Being happy is not about having what you want, it's about wanting what you have."
    "The best things in life are always free - but that doesn't mean money can't buy you good things."

  8. #8
    The Curator
    Auto Apps:loading...
    Blue ZX3's Avatar
    Join Date
    Aug 2004
    Location
    Chicago area,IL
    Posts
    5,079
    Quote Originally Posted by Enforcer View Post
    I think ONSKINENTER would be confusing.
    Agreed

    Quote Originally Posted by Enforcer View Post
    I thought you meant when a new skin is started, not an individual screen.

    maybe ONSCREENENTER and ONSCREENEXIT
    I think this is going a little over board with the "ON" events... if you really need this, could simply make a PI that watches for either the 'LOAD' or 'MENU' cmds. With using a single var for logic to prevent an indefinite loop.

    We could add an "ONSCREENDISCARD" for when a screen is designated as such or use the sample below...

    Example
    Code:
    Dim ScrnLoading As Boolean
    Dim LoadingCMD AS String
    
    Public Function ProcessCommand(CMD As String, frm As Object) As Integer
         LoadingCMD = LCase(Left$(CMD,4))
         If InStr(1,"menu:load")>0 Then
    		If Not ScrnLoading Then
    			ScrnLoading = True
    			If frm.Discardable Then
    				CMD =  "ONSCREENDISCARD||" + CMD
    			Else
    				CMD =  "ONSCREENEXIT||" + CMD
    			End If
    			ProcessCommand = 3
    		Else
    			ScrnLoading = False
    			ProcessCommand = 0
    		End If
    	End If
    End Function
    Same as found in this PI:
    Attached Files Attached Files
    RideRunner...The #1 FE, PERIOD.

    Current Project: DFXVoice [v1.0 Released]
    Next in line: RRMedia v2.0

    DFX 5.1.1 Skin
    Appstore Link

    My RideRunner Plugins
    RRMedia
    RRExtended
    DFXVoice

    "There are no bugs - only undocumented features."

  9. #9
    The Curator
    Auto Apps:loading...
    Blue ZX3's Avatar
    Join Date
    Aug 2004
    Location
    Chicago area,IL
    Posts
    5,079
    Quote Originally Posted by guino
    I'm not opposed to adding new events, but we avoid adding what we can as a precaution. Still, there's already a ONSCREENCHANGE event, which is executed right before a screen is about to change -- this may be enough for what you want, in any case if it isn't, give me an example of what you're trying to accomplish and we can definitely work on it.
    Small correction, the "ONSCREENCHANGE" fires as soon as the screen finishes loading. Including if you have an emb app that takes a few seconds to load, you'll not see that cmd till the screens finished and shown...

    I gave both a example code and even supplied a simple PI that accomplishes what hes after... or anyone else..
    RideRunner...The #1 FE, PERIOD.

    Current Project: DFXVoice [v1.0 Released]
    Next in line: RRMedia v2.0

    DFX 5.1.1 Skin
    Appstore Link

    My RideRunner Plugins
    RRMedia
    RRExtended
    DFXVoice

    "There are no bugs - only undocumented features."

  10. #10
    The Curator
    Auto Apps:loading...
    Blue ZX3's Avatar
    Join Date
    Aug 2004
    Location
    Chicago area,IL
    Posts
    5,079
    Also, I could add this to RRExtended as that would also fall into extending RR functionality...

    Let me know, and I'll just include that above one into it....
    RideRunner...The #1 FE, PERIOD.

    Current Project: DFXVoice [v1.0 Released]
    Next in line: RRMedia v2.0

    DFX 5.1.1 Skin
    Appstore Link

    My RideRunner Plugins
    RRMedia
    RRExtended
    DFXVoice

    "There are no bugs - only undocumented features."

Similar Threads

  1. request: exclude command on .skin
    By liquid_smoke in forum Road Runner
    Replies: 5
    Last Post: 11-03-2006, 07:41 PM
  2. Hardware based players (Not PC based)
    By andrewc in forum Newbie
    Replies: 3
    Last Post: 05-31-2005, 03:36 PM
  3. OBD2 interface based on Max232/Max233??
    By Maddog_rvo in forum Engine Management, OBD-II, Engine Diagnostics, etc.
    Replies: 4
    Last Post: 02-08-2005, 05:11 PM
  4. Newbie asks ? Laptop based carputer vs desktop pc based carputer
    By SAScooby in forum General Hardware Discussion
    Replies: 2
    Last Post: 03-01-2004, 02:59 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •