Loading ...
Sorry, an error occurred while loading the content.

Re: Keep panel in screen view

Expand Messages
  • Frank Apap
    Thanks for the reply. I m already using constraintoviewport. What I see is when my panel initially pops up it is off to the side of the screen, but as soon
    Message 1 of 3 , Jul 3, 2007
    • 0 Attachment
      Thanks for the reply. I'm already using constraintoviewport. What I
      see is when my panel initially pops up it is off to the side of the
      screen, but as soon as I go to move it the viewport constraint takes
      effect. It's like I need to enforce the viewport constraint BEFORE it
      renders (or something like that).

      here is my JS:

      <script>
      function initHelpItem7()
      {
      // Instantiate a Panel from markup
      var panel7 = new YAHOO.widget.Panel("H7", { width:"330px",
      visible:false,
      effect:
      {effect:YAHOO.widget.ContainerEffect.FADE,duration:0.25},
      constraintoviewport:true }
      );


      panel7.render();

      document.getElementById("H7").style.display ="";

      YAHOO.util.Event.addListener("show7", "click", panel7.show,
      panel7, true);
      );
      }
      YAHOO.util.Event.addListener(window, "load", initHelpItem7);
      </script>

      Thnx,

      --- In ydn-javascript@yahoogroups.com, Caridy PatiƱo Mayea
      <caridy@...> wrote:
      >
      > Hi Frank,
      >
      > You can use the property "constraintoviewport", and the overlay
      > control will keep visible in the current viewport.
      >
      > var o = new YAHOO.widget.Overlay(el, { constraintoviewport:true } );
      >
      > Regards
      > Caridy (caridy at gmail.com)
      > http://bubbling.comarq.com/
      >
    Your message has been successfully submitted and would be delivered to recipients shortly.