Community
Participate
Working Groups
Eclipse 20021210 When I select an entry from either the Navigator, or the Package Explorer the ClipBoard is accessed. Is this access required? I do not understand why we would want to involve the clipboard on a selection event. My workspace had one simple project, consisting of two files, aFile.txt and bFile.txt. There were two accesses to the ClipBoard. After the file is open, I tried a paste to a window outside of eclipse, I did not get the file names, rather the last thing I had put in the clipboard. A paste within eclipse produced the same results. This makes sense. I had a breakpoint on both setContents and getContents, only getContents was hit.
Created attachment 2760 [details] stacktrace illustrating path to ClipBoard#getContents
When I select a file(s) (single click) the menu item Editor#Copy is enabled, Editor#paste is disabled. Editor#paste is only enabled after I invoke the copy action via Editor#Copy. So I guess this is what it is trying to determine; should Editor#paste be enabled (and other menu items). Still don't see why this would be done each time I select an editor, the selection action has nothing to do with setting of these edit menu items.
Copy/paste actions are in the workbench Edit menu. Enablement state can only be set during selectionChanged.