Constraint the mouse

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • =?Utf-8?B?VHJlY2l1cw==?=

    #1

    Constraint the mouse

    Hello, Newsgroupians:

    I have a window, and I would like to constrain the mouse to a triangle in
    that window when a certain condition exists. I've tried overriding
    OnMouseMove and adding an event handler for MouseMove, but the MouseEventArgs
    X and Y are "get" properties, or readonly properties. How can I constrain
    the mouse to the triangle?

    Thank you,


    Trecius
  • =?Utf-8?B?VHJlY2l1cw==?=

    #2
    RE: Constraint the mouse

    I think I figured it out...

    It should be...

    Cursor.Position = ...

    This should work unless anyone has anything else to add or another approach.


    Trecius

    "Trecius" wrote:
    Hello, Newsgroupians:
    >
    I have a window, and I would like to constrain the mouse to a triangle in
    that window when a certain condition exists. I've tried overriding
    OnMouseMove and adding an event handler for MouseMove, but the MouseEventArgs
    X and Y are "get" properties, or readonly properties. How can I constrain
    the mouse to the triangle?
    >
    Thank you,
    >
    >
    Trecius

    Comment

    Working...