Bug 155170 - [Palette] GMF's PaletteViewerProvider is hidden
Summary: [Palette] GMF's PaletteViewerProvider is hidden
Status: NEW
Alias: None
Product: GMF-Runtime
Classification: Modeling
Component: General (show other bugs)
Version: 1.0   Edit
Hardware: PC Windows XP
: P3 normal
Target Milestone: 2.1   Edit
Assignee: Anthony Hunter CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-08-25 00:39 EDT by Pratik Shah CLA
Modified: 2010-07-19 21:59 EDT (History)
0 users

See Also:


Attachments
Patch (5.21 KB, text/plain)
2006-08-25 00:46 EDT, Pratik Shah CLA
no flags Details
Java class (5.45 KB, text/plain)
2006-08-25 01:13 EDT, Pratik Shah CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Pratik Shah CLA 2006-08-25 00:39:47 EDT
DiagramEditorWithFlyoutPalette#createPaletteViewerProvider() returns a PaletteViewerProvider that cannot be extended.  All I wanted to do was add a Keystroke listener to the palette's keyhandler, and there's no way to do that without copying the code or losing that functionality.

Is it possible to put that code in a separate class and expose it?

PS: Note that the fields paletteKeyHandler and paletteMouseListener, which are relevant to the anonymous PaletteViewerProvider class, are in fact declared in DiagramEditorWithFlyoutPalette.
Comment 1 Pratik Shah CLA 2006-08-25 00:46:41 EDT
Created attachment 48679 [details]
Patch

I've separated the code out in a separate, extensible class called ExtendedPaletteViewerProvider (which can be changed, of course).
Comment 2 Pratik Shah CLA 2006-08-25 01:13:39 EDT
Created attachment 48681 [details]
Java class

Whoops, attached the last piece of code without testing.  I couldn't pass the graphicalViewer in the constructor of the class since the PaletteViewerProvider could be created before the graphicalViewer was.  The new code fixes that problem.
Comment 3 Alex Shatalin CLA 2006-08-25 07:08:13 EDT
Changing component
Comment 4 Anthony Hunter CLA 2007-06-19 12:09:28 EDT
Moving to the next release, GMF 2.1. 
Comment 5 Randy Hudson CLA 2007-06-19 20:23:54 EDT
This is no longer a problem for us, but sounds like it might be a valid request anyway.
Comment 6 Eclipse Webmaster CLA 2010-07-19 21:59:52 EDT
[GMF Restructure] Bug 319140 : product GMF and component
Runtime was the original product and component for this bug