Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 357745 - [modeling] Support focus in EcoreTools diagram editor outline
Summary: [modeling] Support focus in EcoreTools diagram editor outline
Status: ASSIGNED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: Mylyn (show other bugs)
Version: unspecified   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Miles Parker CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-09-15 05:27 EDT by Steffen Pingel CLA
Modified: 2011-12-06 11:50 EST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Steffen Pingel CLA 2011-09-15 05:27:25 EDT
Steps:
1. Open diagram editor
2. Focus outline

All nodes are still visible regardless of their interest.
Comment 1 Miles Parker CLA 2011-09-15 13:37:32 EDT
You're referring to the Outline which has the visual thumbnail and the tree? that's a kind of funny Ecore thing and I hadn't noticed it.

One related issue, the outline thumbnail focus follows the diagram editor focus. There really isn't anything we can do about that as the tumbnail is literally a thumbnail of whatever the view is seeing. So it is odd to have the thumbnail showing just the focused nodes and the tree showing all nodes. Not sure what to do about this. My feeling is that these should be synchronized with each other -- that is it seems unnatural for me that say in the Java editor you can have the editor focused and the outline not focused and vis. vs. but that might just be me.
Comment 2 Steffen Pingel CLA 2011-09-15 14:25:22 EDT
> My feeling is that these should be synchronized with each other
> -- that is it seems unnatural for me that say in the Java editor you can have
> the editor focused and the outline not focused and vis. vs. but that might just
> be me.

It's intentional that these can be controlled independently. I wouldn't worry about the thumbnail but it would be nice to get focusing working for the tree. Otherwise we should look into removing or disabling the focus button.
Comment 3 Miles Parker CLA 2011-09-15 15:26:23 EDT
I think the latter would be harder. :) OK, I'll see what kind of trickery EcoreTools is doing here.
Comment 4 Miles Parker CLA 2011-09-21 15:29:31 EDT
This is involved and is really a functional requirement so I'm going to mark it as an enhancement.
Comment 5 Steffen Pingel CLA 2011-09-21 17:19:21 EDT
Having an enabled button that doen't work as expected is a bug. Shawn, is there a simple way to disable it through the bridge?
Comment 6 Miles Parker CLA 2011-09-21 17:30:42 EDT
(In reply to comment #5)
> Having an enabled button that doen't work as expected is a bug. Shawn, is there
> a simple way to disable it through the bridge?

What I meant is that I'd like to be able to support this and it should have been on the initial list of requirements. I'd rather not have to disable the functionality as that would look kind of lame. The issue is that they aren't using the navigator or outline extensions, they're plugging it together programmatically, so I'm just needing to dive into their code and see if there is a way to change the provider or something.
Comment 7 Steffen Pingel CLA 2011-09-22 04:29:21 EDT
If it's a structured viewer it should be sufficient to install an interest filter.
Comment 8 Miles Parker CLA 2011-09-28 00:34:59 EDT
(In reply to comment #7)
> If it's a structured viewer it should be sufficient to install an interest
> filter.

Yeah, as usual with GMF, the problem is getting to the damn thing. If it were just a matter of having an exposed outline, I think it might even have worked OOTB. As it is, they've got the viewer hidden away. API looks like it isn't doable at all, but I might be able to get at it through an extension point.
Comment 9 Steffen Pingel CLA 2011-09-28 01:59:46 EDT
Sometimes it works to cast the selection viewer of the view part. Often this is the viewer itself.
Comment 10 Miles Parker CLA 2011-09-28 22:40:54 EDT
An update on this after a hell of a lot of experimentation. Yep going through the selection provider worked, thanks for the idea! It's still really byzantine to get at it though, and it's looking like I'm going to need to manage a bunch of stuff programatically. They're using page views as well, so there is just a lot of life-cycle stuff to deal with. Part of me is still wanting to just disable focus for the GMF case for the reasons given above but I'll update on this tmrw am.

> Having an enabled button that doen't work as expected is a bug. 

If we can get this working, then it was an enhancement. If we have to disable focus, it was a bug. :)
Comment 11 Thomas Ehrnhoefer CLA 2011-09-29 12:59:10 EDT
talked to shawn and Miles

I understand it's out of scope to provide proper, working focus/unfocus, it's just too complex for now.
Having the focus button that doesn't do anything, while annoying, also is the case for the outline of a task.

So bottom line: this task becomes an enhancement, moves out of the release, and we have to live with the fact that the button doesn't do anything
Comment 12 Miles Parker CLA 2011-09-29 13:27:46 EDT
See https://github.com/MilesParker/mylyn.incubator/commit/a7ea5b3ee4ac5cd3cf41cc0615aaf5f59783193f for current progress. This pilot implementation does filter correctly for the first opened editor, but activating other editors, connection to focus buttons and probably lot's of other stuff doesn't work.