Moving a JFrame

Discussion in 'Java' started by L Clarke, Feb 25, 2006.

  1. L Clarke

    L Clarke Guest

    Hi,

    I want to move a JFrame or any other type of window, but i want to be able
    to do this by clicking and dragging anywhere inside the frame (or window),
    rather than just moving by using the titlebar. Can anyone point me in the
    right direction to look into this.

    thanks
    lee



    --
    Posted via NewsDemon.com - Premium Uncensored Newsgroup Service
    ------->>>>>>http://www.NewsDemon.com<<<<<<------
    Unlimited Access, Anonymous Accounts, Uncensored Broadband Access
     
    L Clarke, Feb 25, 2006
    #1
    1. Advertising

  2. L Clarke

    zero Guest

    "L Clarke" <> wrote in
    news:44008643$0$5430$:

    > I want to move a JFrame or any other type of window, but i want to be
    > able to do this by clicking and dragging anywhere inside the frame (or
    > window), rather than just moving by using the titlebar. Can anyone
    > point me in the right direction to look into this.


    Implement a MouseMotionListener (look into MouseMotionAdapter) calling
    setLocation

    I don't know if this is very performant and I haven't tested, but it should
    work.
     
    zero, Feb 25, 2006
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.

Share This Page