HISE Logo Forum
    • Categories
    • Register
    • Login

    Vanishing Combo Box

    Scheduled Pinned Locked Moved Bug Reports
    6 Posts 2 Posters 1.0k 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.
    • d.healeyD
      d.healey
      last edited by

      I have a couple of scripts that aren't main interface scripts, and for some reason the combo boxes on their interfaces randomly disappear. I haven't been able to reproduce it in a controlled way. If I reload the script (copy and paste it into a new script processor) the combo boxes are visible again.

      Content.setWidth(650);
      Content.setHeight(250);
      
      const var map = [];
      const var ccs = [];
      
      for (i = 1; i < 128; i++)
      {
          ccs.push(i);
          map.push(i); //Fill midilist map with default values
      }
      
      const var cmbOrigin = Content.addComboBox("cmbOrigin", 10, 10);
      cmbOrigin.set("text", "Origin");
      cmbOrigin.set("items", ccs.join("\n"));
      
      const var cmbTarget = Content.addComboBox("cmbTarget", 160, 10);
      cmbTarget.set("text", "Target");
      cmbTarget.set("items", ccs.join("\n"));function onNoteOn()
      {
      	
      }
      function onNoteOff()
      {
      	
      }
      function onController()
      {
      	
      }
      function onTimer()
      {
      	
      }
      function onControl(number, value)
      {
      	switch (number)
          {       
              case cmbOrigin:
                  cmbTarget.setValue(map[value]);
              break;
              
              case cmbTarget:
                  map[cmbOrigin.getValue()] = value; //Set the target for the current origin
              break;
          }
      }
      

      0_1520877355673_Screenshot from 2018-03-12 17-54-33.png

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

      1 Reply Last reply Reply Quote 0
      • Christoph HartC
        Christoph Hart
        last edited by

        To be honest it's quite some time that I have worked on a script that isn't an interface so it might be possible that something slipped in there. Does rebuilding the interface using the refresh button solve the problem?

        Also try replacing the calls to AddComboBox() with getComponent(). Maybe something's fishy there.

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

          @christoph-hart I considered using the getComponent() function instead but because these are external scripts that I'm linking to I don't think that will work since the controls won't have been created. Pressing the refresh button didn't solve it, the only thing that does is reloading the script or reconnecting to the external script.

          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

            This one has started haunting me again. I've made a video to demonstrate the issue:

            (is there a way to embed YouTube links in posts?)

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

            1 Reply Last reply Reply Quote 0
            • Christoph HartC
              Christoph Hart
              last edited by

              This is fixed now.

              You need to rebuild HISE from scratch (Resave from Projucer), I am now using the juce_dsp module.

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

                @christoph-hart Yippie! Thank you, I will give it a spin

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

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

                48

                Online

                1.7k

                Users

                11.7k

                Topics

                101.8k

                Posts