HISE Logo Forum
    • Categories
    • Register
    • Login

    open panel animation

    Scheduled Pinned Locked Moved General Questions
    7 Posts 5 Posters 388 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.
    • Y
      yall
      last edited by

      SUBPANEL.set("height", 0);
      
      SUBPANEL.setTimerCallback(function()
      {
             
          if (this.data.open)
              this.set("height", this.getHeight() + 9);
          else
              this.set("height", this.getHeight() - 9);
          
          if (this.getHeight() < 0 || this.getHeight() > 350)
              this.stopTimer();
      });
      
      

      in this code, my panel opens from top to bottom gradually. Is it possible to reverse the opening direction to make it open from bottom to top?

      oskarshO ulrikU 2 Replies Last reply Reply Quote 0
      • oskarshO
        oskarsh @yall
        last edited by

        @yall just keep the height fixed and move it using the

        this.set('y', value);

        Place it below the screen and move it in.

        HISE Developer for hire :)

        Y 1 Reply Last reply Reply Quote 0
        • Y
          yall @oskarsh
          last edited by

          @oskarsh I admit I didn't quite understand

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

            @yall just add

            this.set("y", 400 - this.getHeight());
            

            to your timer callback, height is max 350 and I set y to be 400 - 350

            panelopen.gif

            
            HiseSnippet 953.3ocsVssaSiDFdbZcDw6BZQhK3xQ8JGscqbnkSpbnjzzciVZIh.n8tpo1SpGU6YhrGCDA8oja4gf2ft+yL9XSfRiD9hn7e9a9OMy3DgOMMUjfr57l4ynHqe2dxbtLbPHgwQi1GYcK6CIoRZB1vp+7YjzTZ.xxZs+Vwvpy5H822ddeRDg6SqXgPuSv7oujEyjUbGu2+xhhNfDPeCKtl16r2HeAefHRjA3YMaOzLh+YjSoGQTp0xFY0dX.SJRlHIRZJnSeQv7IghOvM5+NVJ6jHphnGZB3HCazfPVTv3hyZJBYs93pS9ZlS9crOjEvJ4WkA9Cs.bkE0yAVs9QPp20.RV0fz5FHca6I9IrYxJIJ77a1i3PAYJAR00ghQWTq6tl8.AnAWtUL4L5AI.QoEtOvyaSL7S2ccbfzcpD+dRBdxa6O9EGM7k3mhKr8TpbfHdlfCDtaTnvFJ6bJn1JkBxBorSCkarIV4zRQADIYKwLJG74TRTJc2Flop8ICHQQm.EY2oYbeISvc657IGL7wlhckgrzJ2zUyW8o42LxZV.h+GMC2t3+D+X.LJsoPnuVl9Wkl5zzj4f1634AJbYapqeIxq6ymf8ve9yKFqmg299dW9jIEyzYGWvsmqy2LdDiSwEYIrf+JHinpTIhHW+hxzlPsLJipxgcVZcPKd2ZBSkjDSovcaU06bHZKuAPEvM5pRD4gsr10.LfOpgxiDR5qLE0NNm6furnoSWprbeEoRAKQbdx46anKOK9DZR8zgRQXtp4vZ6etgUeSBolhB9HNSpN1F5CDQApgP0+WbzFkmQUC44HDTUpGwuU9Hd+LoTvQLvIss0NVi85qWQucz9PsrvKfCgfLilHYpyh09z2C6ZMKN5XuOM8LnOBVaVVCQV2vDyaVrVgvoQ5P5XWzQf9XUHe1dyAh18x2k+AVfLrRJaOyHjRkisx4IowEKv6z9KWftnI26oXewWMrQ0PV6qJar.rJuz36CqR8QKtZEVpKBxhHxla5UWokK.5nZrdUsBkmxjyqWStFq+89gq++Yg3ssGyj9gKGisVBFg1keEXL+RyaZOb5TpurBfqaev+sp2PdEg+0hLIie5gDYBC5GrOJKdBzT4SgnygVYv41VsTMVFZOEsJCLgxCzDW.e4B6onsxE1qPHJl3mHN12LkptV9FZN.l35WgzAdNDPi6c44SDJFdkvw99Mc0BFduU0vsWUC2YUM79qpgOXUM7gqpgO5pMT8HtWjIEwlwFD5vwC06SsrFxIPGntaE8+brML.E
            

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

            T 1 Reply Last reply Reply Quote 0
            • T
              treynterrio @ulrik
              last edited by

              @ulrik snippet doesn't work ".... not contain a valid container / snippet."

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

                @treynterrio Works here, you probably copied some spaces or extra characters.

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

                T 1 Reply Last reply Reply Quote 0
                • T
                  treynterrio @d.healey
                  last edited by

                  @d-healey ok tried it again now it works

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

                  11

                  Online

                  1.7k

                  Users

                  11.8k

                  Topics

                  102.4k

                  Posts