Announcement

Collapse
No announcement yet.

Press & Hold Button - Question

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Press & Hold Button - Question

    I'm trying to have seperate day and night background images stored in my skin file, which can then be called from elsewhere in the skin. It's working to a point but I keep having an issue with the "Press & Hold" function.

    On my BG browser I have a button called "Day", which has this code
    B15,615,343,170,75,"LOADBG1",@SETBG1@

    and in exectbl.ini the following commands are defined

    "LOADBG1","SAVETOSKIN;BACKGROUND;$BKGND1$||RELOADS KIN"
    "SETBG1","SETVARBYCODE;BKGND;LISTTEXT||SAVETOSKIN; BKGND1;$picspath$\$BKGND$||CNF_BKG1"
    "CNF_BKG1","WRITETOFILE;$skinpath$confirm.txt; =/DEFINE CONFIRMTEXT New Background Set||WAIT;0.5||MENU;confirm.skin"


    Here's the issue. With the code this way, the background is not saved correctly to my skin file, it misses the actual filename so all that gets stored is "BKGND1=C:\Car\Background\\" ... but if I remove the "||CNF_BKG1" or change the button command to be B15,615,343,170,75,"SETBG1",@LOADBG1@ it works perfectly. I would really like to have the "Load" function on press and "Set" function on the press & hold ...

    Any idea's why this ain't working ... ???
    -------------------------------
    The TEKNIK Family ... Teknik 1 & Teknik 2, Teknik T-3, Teknik v4.0, Teknik-X.

  • #2
    i don't see why it shouldn't be working.

    Try this:
    B15,615,343,170,75,"LOADBG1",@SETBG1||CNF_BKG1@

    ExecTBL.ini:
    Code:
    "LOADBG1","SAVETOSKIN;BACKGROUND;$BKGND1$||RELOADS KIN"
    "SETBG1","SETVARBYCODE;BKGND;LISTTEXT||SAVETOSKIN; BKGND1;$picspath$\$BKGND$"
    "CNF_BKG1","WRITETOFILE;$skinpath$confirm.txt; =/DEFINE CONFIRMTEXT New Background Set||WAIT;0.5||MENU;confirm.skin"
    
    
    .
    Pico-ITX / XP Home with EWF-HORM / RR v12/02/2009 / Winamp v5.13 / RRMedia v1.2.2

    Comment


    • #3
      Here is my command for that...

      Code:
      B01,599,506,101,82,"SETVARBYCODE;Background;$NightBackground$||SAVETOSKIN;Background;$NightBackground$||RELOADSKIN||NIGHTGAMMA",@SETVARBYCODE;Background;$DayBackground$||SAVETOSKIN;Background;$DayBackground$||RELOADSKIN||DAYGAMMA@

      Comment


      • #4
        @Sal-R : tried that ... still the same

        @MGD : your code is exactly what I'm trying to do, but it's the step before that code that aint working, where I would set the $NightBackground$ variable etc if it was your skin ...

        thanks for the suggestions tho ...
        -------------------------------
        The TEKNIK Family ... Teknik 1 & Teknik 2, Teknik T-3, Teknik v4.0, Teknik-X.

        Comment


        • #5
          I forgot to mention, I have a background_Browser.skin where you can set the background for Day and Night and then recall the value. I attach the skin with the code so you can take a look. Just copy it to your skin folder and call the background_browser.skin
          Attached Files

          Comment


          • #6
            Umm...is there supposed to be a space b/w the ";" and the "=" in the CNF_BKG1 command?

            Cuz I just tried your code w/o the space in my mock-up background skin and the press and hold worked...
            Pico-ITX / XP Home with EWF-HORM / RR v12/02/2009 / Winamp v5.13 / RRMedia v1.2.2

            Comment


            • #7
              It is a well known forum problem. The forum will break extra long lines with a space. The only way to prevent this from happening is to wrap them in the code/php tags.
              Front End of Choice: Ride Runner (Is there anything else??? ) & Powered by the DFX5.1 Skin Available in the Mobile App Mart

              My Fiero Build Thread

              Comment


              • #8
                hey guys ...

                I've tried just about everything I can, includeing replicating MGD's code etc and still no joy ... whenever I add the code for the Confirmation popup, the data is not saved correctly. BTW i'm using the beta RR version with fixed weather - if that makes any difference.


                back to the drawing board - and more scratching of the head for while
                -------------------------------
                The TEKNIK Family ... Teknik 1 & Teknik 2, Teknik T-3, Teknik v4.0, Teknik-X.

                Comment


                • #9
                  I have no clue on what you're doing, mine works with the newest Beta.
                  What is not saved? DO you have the path to the backgounds set in the browser?

                  Comment


                  • #10
                    Okay...try this. Put it all in one line:

                    Tried this in the new beta and it works for me...
                    Code:
                    "SETBG1","SETVARBYCODE;BKGND;LISTTEXT||SAVETOSKIN; BKGND1;$picspath$\$BKGND$||WRITETOFILE;$skinpath$confirm.txt; =/DEFINE CONFIRMTEXT New Background Set||WAIT;0.5||MENU;confirm.skin"
                    
                    
                    .
                    Pico-ITX / XP Home with EWF-HORM / RR v12/02/2009 / Winamp v5.13 / RRMedia v1.2.2

                    Comment


                    • #11
                      ooops
                      Riderunner / Genesis
                      Plugin Breaker in test BassRR Plugin Player, Wifiman_NET
                      New Home for Genesis & BassRR :adding to site ,, Hellfyre night
                      Bassrr Beta Release :Version 1.3.7
                      Movie_info Release :Version 3.1.0
                      Wifiman_NET:Version 1.0.0

                      Every Future, Needs A Beginning

                      Comment


                      • #12
                        ok .. got it working, but I had to change the code for the confirmation popup to be this
                        "CNF_BKG1","SETVAR;CONFIRMTEXT;Day Background Set||MENU;Confirm.skin"

                        I also changed the confirm skin to use a variable rather than a define code ... not as clean as I'd hoped, but it works.

                        There was something with the timings between the write to the INI file and the write to the confirm.txt files ... and using WAIT's were causing too much delay in the skin...

                        thanks for all your help guys ...
                        -------------------------------
                        The TEKNIK Family ... Teknik 1 & Teknik 2, Teknik T-3, Teknik v4.0, Teknik-X.

                        Comment

                        Working...
                        X