HISE Logo Forum
    • Categories
    • Register
    • Login

    Repaint panel or sliders on combobox callback

    Scheduled Pinned Locked Moved General Questions
    25 Posts 3 Posters 1.1k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • gorangroovesG
      gorangrooves @ulrik
      last edited by

      @ulrik Yeah, I know I can set each slider separately, but I am looking for a more elegant, scalable option. I know that Dave is a "freak" of that department 😁

      Goran Rista
      https://gorangrooves.com

      Handy Drums and Handy Grooves
      https://library.gorangrooves.com

      d.healeyD ulrikU 2 Replies Last reply Reply Quote 0
      • d.healeyD
        d.healey @gorangrooves
        last edited by

        @gorangrooves said in Repaint panel or sliders on combobox callback:

        I know that Dave is a "freak" of that department

        Working on it... :)

        Libre Wave - Freedom respecting instruments and effects
        My Patreon - HISE tutorials
        YouTube Channel - Public HISE tutorials

        1 Reply Last reply Reply Quote 0
        • ulrikU
          ulrik @gorangrooves
          last edited by

          @gorangrooves ok

          Hise Develop branch
          MacOs 15.3.1, Xcode 16.2
          http://musikboden.se

          gorangroovesG 1 Reply Last reply Reply Quote 0
          • gorangroovesG
            gorangrooves @ulrik
            last edited by

            @ulrik I appreciate your help very much, regardless of what solution yield most practical results! Thank you.

            Goran Rista
            https://gorangrooves.com

            Handy Drums and Handy Grooves
            https://library.gorangrooves.com

            1 Reply Last reply Reply Quote 0
            • d.healeyD
              d.healey
              last edited by d.healey

              This is the problem

              var PanState = PanStates[obj];

              obj is not an index, so you will always get PanStates[0].

              I can see a couple of possible solutions, but the thing that is really confusing me is why the laf function is retriggered when changing the combobox value... I added a button to the UI and pressing that also triggers the slider LAF function. Maybe it's always been this way but it seems weird to me.

              Edit: Nope, I just made a test and this is definitely weird behaviour in your snippet. I need to figure out what's going on.

              Libre Wave - Freedom respecting instruments and effects
              My Patreon - HISE tutorials
              YouTube Channel - Public HISE tutorials

              gorangroovesG 1 Reply Last reply Reply Quote 0
              • gorangroovesG
                gorangrooves @d.healey
                last edited by

                @d-healey I am itching. I've been pouring over this for over a day now....

                Goran Rista
                https://gorangrooves.com

                Handy Drums and Handy Grooves
                https://library.gorangrooves.com

                d.healeyD 1 Reply Last reply Reply Quote 0
                • d.healeyD
                  d.healey @gorangrooves
                  last edited by

                  @gorangrooves There is something very strange with your snippet and I can't figure it out. I'll make a new snippet.

                  Libre Wave - Freedom respecting instruments and effects
                  My Patreon - HISE tutorials
                  YouTube Channel - Public HISE tutorials

                  1 Reply Last reply Reply Quote 0
                  • d.healeyD
                    d.healey
                    last edited by

                    Ok here's a minimal example. I'm just colouring the sliders in a solid colour, you can fill in the blanks in the laf to do what you want.

                    There are a few ways to achieve the goal but I just discovered that we can now access the component ID in the obj within the laf function, I don't know when this was added so if it's not working for you you need to update HISE. But using it I think gives the cleanest approach.

                    HiseSnippet 1187.3ocsW01aZbDDdOaeIkqsQIp4yUm7mNjbH.NMspVsEaroEE+BJjZUojznk6VfsrrKZ2EanU9OT+00+Asyr2AbIFgsox9CV2ryaOyK6rCszpXlwnzDuBuY5HFw6K7aOUZ6WuOkKIMOj38H+SnFKSGldzASGQMFVBwyayeFOvqvVD2e+yOc.UPkwrEGQHmq3wri4C41Em1p1q3BQCZB6M7g4j9E0ZFqj0UB0X.Oa5WlLhFOf1icJEEaCeh2CNJgaU51VpkY.YNPkLsce0kxT4Oma3cDLjnBoMXnziI06yEIslEqFBwaqVKh7MSi7m5eBOgO+7EYfG6XDtPi74.uMVEjpbGfjWNHsUJjdhe6XMejcAGDOeteSITP5RgTcdnjJKYiuZK+5JPBoszP5.VCMPLWinWVt7Ngv+JtWP.jtM1vARUGAsa3ODNSsXMChliUwTwwJ0f8kIMXLQDpRlvkzrdbrsnwXYrkqjQamnoWdLWxn51BdBSu8Ngcmwr2NgpN+Qwf+JnvETcHWlvl.9CMVyDSIG8Yci.YJwS.23jxfoTPpX0vNpCTSXl25D78k5wrmSEiYQECeVXE.UN4iccNfxAELWxsw8CiblnXPAvuEhoFVX4uG9pPpjt.F+v.QSxdHiNPfO.sWpzUVtzc.WuLwqtbw6oYLYd4KbEhwdk5BWC1WHhR0n3dEBtBSwO+4tDiIW4ARRfAe662K2YlbELHg.FptZ3HkDnMQa+JPh28tjsQC1UoCil.Y8T8bkgYo9QiM8ilfFnYRTQL0OojgYuVsOqtCBbEfcDitxRXGrtjgpEEpUBs5Yhcc3sv.EyvAZEsRTmJDcfgAQJ4LYx3fHNfKEPi271svqIEjhy7+NgWfcNtbf.Cx4MiKb979w4Zgdwk6l0AZXxjWyFAiHrm.2LggT3siqxgfSUV1YxHmiBtJH7SY0s6R4kAXASuT13DS8pTLRNdXGlNeXhBBiT934TO31MmJNsJlSPkrojaOaDKitgRjfyevuu9TMRVa.LeayLDBeYcS2db1zsY8CDdBNbaFYEhKDx+.C4NZhp++MwtKwD+ZyCoVJNxNK5fHdDSa4Xh06P1EvadoCvK3eHyLvpFAI74WAHdOL00OJy0oyKcN9g93E2JjIDOeumBta5BO+i0L1oB2az+hRy+Sv2TAAF616Ptl45C9DdF5ErlxVZFbSBegfjCCO3FvP0TL722FLrJ+bSw5to9olmyO9deM3k6g37Fa1ljeQjbQ7uWaH0gvMABtkMzfHuRP0fcI2c+TMmepwt+7yt4iG6s1OWeEDX4GUxXA09waDgq9kw.KG4WCAW0PZ31o4uybGVSp7JWS51Bwm32BWAX4XbikfQ3578AFyVt7K8OpaWn2cA.2xuwustaRdCt+0pwVtr2ITqlik5SGOrMrfQLC7tTxDFr7uANbNktLRiYf1vqZNh+E9KiYEj1KiYkYLICowZ0GhSGlhqu9YtS.LIcaqW.9YC.c37o399kKUlLD1j9CwwX3+L38hkqS00PmcWCcdwZny2rF57x0PmucMz46VoN3OhY+wV0vzqCvAsNx8Nlm2QRJzY45BI+GngGjOC
                    

                    Libre Wave - Freedom respecting instruments and effects
                    My Patreon - HISE tutorials
                    YouTube Channel - Public HISE tutorials

                    gorangroovesG 1 Reply Last reply Reply Quote 1
                    • gorangroovesG
                      gorangrooves @d.healey
                      last edited by

                      @d-healey thank you very much! I'll investigate that thoroughly and report back (on successful results, i hope).

                      Goran Rista
                      https://gorangrooves.com

                      Handy Drums and Handy Grooves
                      https://library.gorangrooves.com

                      gorangroovesG 1 Reply Last reply Reply Quote 0
                      • gorangroovesG
                        gorangrooves @gorangrooves
                        last edited by

                        @d-healey @ulrik Thank you both so very much! Both of your solutions work very well.

                        @ulrik I didn't see your latest simplified version at first. While I was taking a break, I was thinking of a possible solution if I wouldn't be able to iterate through the index within LAF. I thought about creating multiple LAFs within a loop. Then, when I opened your latest script, I saw that you did that 😁

                        Thank you!

                        Goran Rista
                        https://gorangrooves.com

                        Handy Drums and Handy Grooves
                        https://library.gorangrooves.com

                        ulrikU 1 Reply Last reply Reply Quote 2
                        • ulrikU
                          ulrik @gorangrooves
                          last edited by

                          @gorangrooves my pleasure 👍

                          Hise Develop branch
                          MacOs 15.3.1, Xcode 16.2
                          http://musikboden.se

                          1 Reply Last reply Reply Quote 0
                          • First post
                            Last post

                          26

                          Online

                          1.8k

                          Users

                          12.1k

                          Topics

                          105.0k

                          Posts