Show underlying applications mouse cursor when hovering over visible section of my application
I am writing a WPF application that allows the user to draw over the entire screen when the right mouse button is held down. I use a full screen transparent overlay form to achieve this, however, as I draw lines with the mouse, what's happening is that the portion of my window that contains the line is becoming visible (as expected). The undesired eff开发者_如何学Cect of this is that if the line is over a part of another application such as a textbox, or hyperlink, this changes the cursor back to the default cursor of my app (arrow), instead of the other applications desired cursor (IBeam). I want my overlay to be seamless to the user, and just show their drawing path, rather than have any interaction with the mouse cursor.
See my example below:
See this thread for a solution however this will probably conflict with how you are capturing the mouse events. You could try a mouse hook or try passsing the input to the window underneath instead. You may want to expand your search to win32, wndproc etc. Also returning HTTRANSPARENT from WM_NCHITTEST doesn't work in this case.
精彩评论