[Ext 1.1] Constraining Grid Context Menu to the Viewport

January 05th, 2009 edit

  • I searched the forums and found only this related thread (http://extjs.com/forum/showthread.php?t=8264&highlight=constrain) in standard help.

    Is there a way to constrain the grid context menu to the viewport? I have attached a thumbnail of what happens when invoking the context menu in the lower right corner of a grid. It happens in both IE7 and FF.

    Thanks in Advance,
    skippy


  • Thanks Jozef!


  • Once I had similar problem and I solved it by this code:


    menu.showAt(menu.getEl().getAlignToXY(node.getUI() .getEl(), 'tl-tl?', [0, 18]));
    This shows context menu on tree and the trick is to align 'tl-tl?' - whit question mark, what means that ext tries to align as requested but always in the viewport. I also needed adjustments [0, 18] you may not need 'em.







  • #If you have any other info about this subject , Please add it free.#
    Your name:
    E-mail:
    Telphone:

    Your comments:


    If you have any other info about [Ext 1.1] Constraining Grid Context Menu to the Viewport , Please add it free.