Community
Participate
Working Groups
3.1M6 - when dragging a perspective button in the perspective bar to rearrange its order, I moved it slightly out of bounds of the perspective bar - the result was not a rearrangement of the perspectives, but a new window - this was unexpected - also, it's not really detaching the perspective, but rather opening a new window with a fresh perspective of the same kind This is equivalent to doing Window > New Window. The DnD support seems to be causing more confusion than benefit. I suggest we back out of it for 3.1.
I wrote this so I'll take ownership, we could enhance to actually close the existing perspective and reopen in the other window with the new save/restore state support.
That's not bad, but it would be slow and lose any state stored in the widgets. We could also try reparenting the widgets to a new workbench window... but that would also require reparenting all the workbench parts into a new IWorkbenchPage.
For what it's worth, the cursor and "highlight" rect that displays while dragging a perspective button indicates pretty clearly what's going to happen when you let go of the mouse button. Even if a user accidentally drags a perspective to a new window, nothing in the original window is mucked up--they simply have to close the new window...easy enough to figure out.
good point, loss of state is bad, but re-parenting wont work on all platforms. How about opening a new perspective with close to the same state as the current perspective, but leave the old one open as they might be unhappy when realizing that this is not exactly the same.
Agree that there's decent feedback for the two cases, but I've still accidentally detached a perspective twice when reordering the items. We could try the saveState/restoreState trick. My feeling is that we should either make it really work (fully detached, with as much state saved as possible), or back out of it since in its current form it doesn't provide anything over Window > New Window, plus this is not the behaviour I'd expect from DnD. If we allow detaching, it would be nice and consistent to allow re-attach. But this would be trickier due to shared views: presumably we'd have to drop the state of the views in the perspective being reattached if there's a conflict.
If we take the approach of having this gesture open a new window with as much state as possible maintained then why wouldn't we do this for the 'New Window' action as well ? I could live without the gesture (i.e. DnD only used to re-order)
For me as a developer of a RCP application the Drag n Drop feature is not important. Our testers found the feature accidently and it causes exceptions in our application. So (if you stay with this feature) I would vote for something that can be switched off in RCP applications. Thanks for your work :)
I agree that most RCP apps will probably not want this. If you have more details of the failure (e.g. a stack dump), please post them here.
Nick, I don't think anyone has reported a 'failure' here (except perhaps for the GUI design..;-). I could propbably wire this up with a configurable (i.e. -not- user settable)) option specific to this feature if desired.
Nick, sorry if I stated my point incomprehensibly. There are no Platform failures in our application - we maid the exceptions ourselfs ;) Our data management was not designed to have more than one workbench window open... Eric, our thanks to you would be assured! Right now we close a second workbench window shortly after creation - which gives me bad dreams in the night.
I'm perfectly in favor of doing this (especially since there's an existing (and more intuitive?) path to the same functioanlity; open a new window and set its perspective. I'm just ttring to determine if there's a better approach than making yet another 'tweak' preference tied specifically to this request. I'm already looking at a number of other similar issues. In this case I'm wondering if I can simply remove the functioanlity altogether and take the heat...;-).
Committed in >20061012. Removed the functionality completely. I'll likely get flamed by somebody but I can't find a single person here who thinks that it makes sense...
Here is the person who thinks that it made sense ;-) The users of the RCP I am working on, are used to open perspectives this way. A 'tweak' preference to preserve backward compatibility would have been the better choice. (Not very nice, but a pragmatic solution.) I also commited #203927 about the problem.
Closing since 203927 covers the review...