Dear all,
I have the following situation :
An histo is displayed in a GUI (TRootBrowser, with tabs, etc…). At a given moment, the histo is replaced with a new one and the former one is deleted. The view is properly updated.
My problem is that users can make a right click on the histo before the replacement but actually click on a menu item after the replacement. This leads to a crash.
Some time ago when I asked a related question (http://root.cern.ch/phpBB2/viewtopic.php?t=9407), I was told to reuse the pointer by using Add(…) or =. However this solution doesn’t copy the “functions” (TLine for instance) from the original histogram.
Is there a way to programmatically cancel the context menu if opened (ie close it when updating) ?
Or to have the contextual menu be able to see that an object is not valid anymore ?
This would greatly ease my life…
Thanks in advance
Barth