[kepler-dev] Re: [Ptolemy] New copy bug
Stephen Andrew Neuendorffer
neuendor at eecs.berkeley.edu
Mon Jun 7 14:45:38 PDT 2004
OK, I think I see what the difficulty is here.
The problem is that drag and drop apparently resets the keyboard focus.
Before my Mac changes, mouse events were always passed to
the base class, which would result in the keyboard focus getting set properly.
However, on the Mac, setting the keyboard focus also clears the context menu,
so I modified the diva base classes to only pass the event to the base class
if it was not marked as consumed (for example, selecting a figure consumes
However, now this prevents selections from getting around to setting the
I've now backed out some of my MAc fixes and tried a different way of
will hopefully work, by putting the code that gets the keyboard focus
earlier in the event processing
before the context menus... This should still work for Mac.
Dan or Chad: Can you verify that the Mac side still works? particularly
context menus and keyboard
shortcuts immediately after dropping an actor.
I hate debugging without test suites.
At 09:09 AM 6/7/2004, you wrote:
>We have a serious new bug with the UI.
>When I place a Sinewave actor into an empty model,
>select it, hit control-C (or Edit-->Copy), and then paste,
>nothing is pasted. If I paste into a text window, what
>is pasted is the result of toString() on the Sinewave actor.
>The debugger tells me that, in fact,
>BasicGraphFrame.CopyAction.actionPerformed() is not
>called, so the bug is before this in the event handling chain.
>Perhaps the changes to diva to support the MAC caused this?
>Strangely, after I paste into a text editor, then
>I can copy and paste normally, and everything works.
>Until I drag in a new Sinewave actor...
>Edward A. Lee, Professor
>518 Cory Hall, UC Berkeley, Berkeley, CA 94720
>phone: 510-642-0455, fax: 510-642-2739
>eal at eecs.Berkeley.EDU, http://ptolemy.eecs.berkeley.edu/~eal
>Ptolemy maillist - Ptolemy at chess.eecs.berkeley.edu
More information about the Kepler-dev