Community
Participate
Working Groups
Build Identifier: When a user's selection contains an artifact and a diagram file (either class or instance), the standard edit actions are disabled. Reproducible: Always Steps to Reproduce: 1. In your TS project, select an artifact and a diagram file (either instance or class diagram) 2. Right click > Notice that the delete, cut, and copy actions are disabled. These actions will be enabled if you select the files individually or select a bunch of artifacts without selecting any diagram files.
Dan, can you please take a look whenever you get a chance? Thanks!
Navid, After a lot of experimenting with this I have come to the following conclusion: Delete: When deleting a mixed set of files (artifacts and diagrams) we have to override the behavior of how a diagram is deleted. When trying to delete an artifact without our custom behavior eclipse would not recognize the file was selected to delete. I came up with a solution to split the selection into their various types and then delete each type of files as their own selections, but this requires two dialogs asking the user if they are sure they want to delete the items, one in our custom behavior before the delete begins to be processed, and another one when we call the standard delete action to delete things that are supported by eclipse. The other option here is to re-implement the standard eclipse delete action, which seems like a waste to me. But other than this I can't find a good way to allow the deletion of these various file types at the same time. Copy/Cut: A similar problem occurs with copy/cut, where when you try to seperate the types of files each one overwrites what the other already placed in the clipboard. There may be a way around this, such as clearing the clipboard, adding contents for one file type, then getting the clipboard contents and appending the other file types and then resetting the clipboard contents. I am still trying to work on this, but I am starting to feel a bit stuck, and that it is not going to be easily fixed. I have spent most of my time on Delete, but will try to spend a bit more time with Cut/Copy and see if I make any progress there.
I'm happy if we put this one on hold for now since it seems harder than expected. At least we now have a better understanding of what the issue is. For now perhaps we can document it as a limitation so it doesn't confuse users.
The special handling for diagrams is there because although there are two files that comprise each diagram we only want to see one entry in the explorer.
The only suggestion that I can think of, based on the info from Daniel is to convert the logical selection to actual files then pass the whole lot to Eclipse. e.g. (1) User selects class 'Aclass' and class diagram 'Adiagram' (2) Tigerstripe then converts these to files Aclass.java Adiagram.wvm Adiagram.wvd and puts the result back on the clipboard or whatever (3) then passes this list to Eclipse for action (copy , cut , paste , delete)
Dan, Thanks for your analysis! What Chris has suggested in Comment#5 makes sense, but I don't think this defect is worth the effort. As Chris has suggested, let's put this on hold for the time being. I've changed the status back to NEW from ASSIGNED. We can come back to it after we've resolved some of the higher priority items.
Documented as a limitation. I don't think it's worth risking a fix for this. Marking as Won't fix.