J
Jon Pawley
Hi guys.
Back in July, Katie Schaeffer wrote the following:
| From: (e-mail address removed) (Katie Schaeffer [MSFT])
| Organization: Microsoft
| Date: Thu, 12 Jun 2003 23:09:12 GMT
| Subject: RE: .NETCF ContextMenu -- The mouse coordinates?
|
|
| Hello Mark,
|
| You are correct that the tap-and-hold which brings up the context menu
| doesn't generate a MouseDown event. You may be able to use
| Control.MousePosition in the ContextMenu.Popup event to identify the
| current position of the mouse.
|
| -Katie
|
| --------------------
| | From: "Mark McKnight" <[email protected]>
| | Subject: .NETCF ContextMenu -- The mouse coordinates?
| | Date: Tue, 10 Jun 2003 16:20:16 -0500
| |
| | I assigned a ContextMenu to a custom-control I wrote and it works --
the
| | menu displays after the red dots appear, but how do I know what the
mouse
| | coordinates are when the this happens?
| |
| | I don't seem to be getting a MouseDown event. I tried many things,
but
| | no luck. Thanks!
| |
It seems absurd to me that the "tap and hold" doesn't fire the MouseDown
event, when in non-.NETCF environments there is obviously an event that is
caught (have a look at Pocket Outlook, for example. That seems to receive a
mouse down event even before the "red dots" start appearing--something which
is not possible in .NETCF.)
Thankfully, I found Katie's suggestion (using the ContextMenu.Popup event)
and hence worked out a reasonable way of getting what I wanted (the item
within a customised control that the user was tapping on). I am slightly
worried that people then followed up Katies suggestion with reports that the
Control.MousePosition returned incorrect coordinates, but I don't seem to
have much choice, I'll just have to press on with what I have got.
(So, that's a slightly roundabout way of saying thank you to Katie, while
still being slight put out that I've spent a good 8 hours trying to sort out
something fairly simple...
Does anyone know of a fairly comprehensive description of the sequence of
events that get fired (and are consumed and/or exposed by various controls)
in various scenarios? On MSDN? I'm hoping that something like the following
exists:
Maybe there is a case for writing some definitive documentation on this
area.
Cheers,
Jon
Back in July, Katie Schaeffer wrote the following:
| From: (e-mail address removed) (Katie Schaeffer [MSFT])
| Organization: Microsoft
| Date: Thu, 12 Jun 2003 23:09:12 GMT
| Subject: RE: .NETCF ContextMenu -- The mouse coordinates?
|
|
| Hello Mark,
|
| You are correct that the tap-and-hold which brings up the context menu
| doesn't generate a MouseDown event. You may be able to use
| Control.MousePosition in the ContextMenu.Popup event to identify the
| current position of the mouse.
|
| -Katie
|
| --------------------
| | From: "Mark McKnight" <[email protected]>
| | Subject: .NETCF ContextMenu -- The mouse coordinates?
| | Date: Tue, 10 Jun 2003 16:20:16 -0500
| |
| | I assigned a ContextMenu to a custom-control I wrote and it works --
the
| | menu displays after the red dots appear, but how do I know what the
mouse
| | coordinates are when the this happens?
| |
| | I don't seem to be getting a MouseDown event. I tried many things,
but
| | no luck. Thanks!
| |
It seems absurd to me that the "tap and hold" doesn't fire the MouseDown
event, when in non-.NETCF environments there is obviously an event that is
caught (have a look at Pocket Outlook, for example. That seems to receive a
mouse down event even before the "red dots" start appearing--something which
is not possible in .NETCF.)
Thankfully, I found Katie's suggestion (using the ContextMenu.Popup event)
and hence worked out a reasonable way of getting what I wanted (the item
within a customised control that the user was tapping on). I am slightly
worried that people then followed up Katies suggestion with reports that the
Control.MousePosition returned incorrect coordinates, but I don't seem to
have much choice, I'll just have to press on with what I have got.
(So, that's a slightly roundabout way of saying thank you to Katie, while
still being slight put out that I've spent a good 8 hours trying to sort out
something fairly simple...
Does anyone know of a fairly comprehensive description of the sequence of
events that get fired (and are consumed and/or exposed by various controls)
in various scenarios? On MSDN? I'm hoping that something like the following
exists:
Example:
--------
Scenario: user taps and holds on a Control object
Sequence of events:
1) Blah
2) Blah
3) MouseDown
4) Blah
...
Maybe there is a case for writing some definitive documentation on this
area.
Cheers,
Jon