PowerPointLabs / PowerPointLabs

This is the project for PowerPointLabs, a productivity add-in for PowerPoint
http://powerpointlabs.info
GNU General Public License v2.0
191 stars 105 forks source link

Events: Add support for listening to Shape-based events #1243

Open Skaty opened 7 years ago

Skaty commented 7 years ago

This would be useful for our existing and future features, as some features may go out of sync if a certain Shape is modified.

For instance: SyncLab will still show the copied attributes even though the shape is deleted via Undo.

alexfjw commented 6 years ago

We might be able to achieve this by exploring EApplication_WindowSelectionChangeEventHandler Delegate We can probably poll a group of shapes whenever the window selection changes. (word of caution, attaching event handlers is reserved for internal use) https://msdn.microsoft.com/en-us/library/microsoft.office.interop.powerpoint.eapplication_windowselectionchangeeventhandler(v=office.14).aspx https://msdn.microsoft.com/en-us/library/microsoft.office.interop.powerpoint.eapplication_event_members(v=office.14).aspx

I'm not exactly sure where we would use such a feature though. For the given example on SyncLab, the user might still want the copied attributes even if he deletes the original shape.