Posted by jonwats on Fri, 15 Oct 2010 23:54:37
Hi I am trying to hook a function when a user from another addon selects from a drop down menu. Specifically I want to know when a user clicks 'Remove Waypoint' from the map with TomTom. I can't hook to the TomTom:RemoveWaypoint function because it is called from a few places and I want to know when the user clicks this menu. Do I hook onto ToggleDropDownMenu? I guess I am kind of lost! I figured you would be an expert at this :) Thanks for the help.
Posted by jnwhiteh on Sat, 16 Oct 2010 08:37:14
It's really difficult to do, actually. What are you trying to accomplish? Maybe there's an easier way to do it?
Posted by jonwats on Sat, 16 Oct 2010 18:21:45
I have a map addon trying to draw little dots between waypoints to connect the points. If someone manually deletes a waypoint, I need to update my dots otherwise they are going to a waypoint that isn't there anymore.
Posted by jnwhiteh on Sun, 17 Oct 2010 11:25:48
You could post-hook the DeleteWaypoint function. You have UIDs for all of "your" waypoints, so you can know when they're deleting one of them.