CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3
  1. #1
    Join Date
    Jun 2002
    Location
    Lyman ME - USA | Oneonta NY - USA
    Posts
    399

    Making the JFrame stay @ absolute pos

    Hi,
    I'm wondering if it is possible to keep a Window at it's location on the screen that i place it at. For instance if i set it's location to (400, 500) i want it to stay there...make it non-movable

    do i have to listen to window events or mouse events to accomplish this or is there an easier way to do it?

    Thanks for the help!

    - nc
    "In a world without walls and barriers, what need is there for windows and gates!" - a mac ad
    "What was the best thing before sliced bread and when did sliced bread go out of existence?" - me
    "Software is like sex, it's better when it's free." - Linus Torvalds <- gotten from Andreas Masur


    Live Penguine! - Tux the linux mascot
    Vivez le penguine!, ¡Viva en penguine!, Lang lebe der Pinguin!, Viva no penguine!, Viva sul penguine!

  2. #2
    Join Date
    Jan 2003
    Posts
    9
    I believe that the only way to accomplish this would be to listen for the drag started event and if the object being fragged is the main window just cancel the event. Not 100% sure on this but it seems viable.

    HTH,
    -=- Kevin

  3. #3
    Join Date
    Jun 2002
    Location
    Lyman ME - USA | Oneonta NY - USA
    Posts
    399
    ok kevin, thanks for your input i'm gonna go work on it.

    ty!

    - nc
    "In a world without walls and barriers, what need is there for windows and gates!" - a mac ad
    "What was the best thing before sliced bread and when did sliced bread go out of existence?" - me
    "Software is like sex, it's better when it's free." - Linus Torvalds <- gotten from Andreas Masur


    Live Penguine! - Tux the linux mascot
    Vivez le penguine!, ¡Viva en penguine!, Lang lebe der Pinguin!, Viva no penguine!, Viva sul penguine!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured