Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
Determining a selection or module content change #1143
I recall seeing references to key hooks, presumably to catch keyboard shortcuts, but also to capture edits to a module and/or changes to the current text selection.
I've done some preliminary work to look at alternatives to keyhooks for tracking edits and selections...
All code panes are MDI child windows, so the MDIClient window sends and receives a number of messages. The WM_MDIGETACTIVE message is sent and received with details of the active MDI Child window, every time the MDI Client needs to update.
A change to the Code Pane, results in a WM_MDIGETACTIVE message in the MDI Client Window, and those Code Pane *changes" seem to include:
If we track these messages, we're effectively getting an event that tells us that a particular MDI child window has potentially changed in some way, and we only have to listen on a single hWnd.
On every WM_MDIGETACTIVE message, by comparing the last known selection with the new selection, we could determine the changes?