|
|
|
Re: Strange behaviour overiding use of tabbedPropertyView in graphical GMF-Editor [message #63371 is a reply to message #61985] |
Mon, 16 October 2006 12:41 |
Artem Tikhomirov Messages: 222 Registered: July 2009 |
Senior Member |
|
|
How about trying 2.0 M2, with newly added extended handling of property
sheet (check
http://wiki.eclipse.org/index.php/GMF_GenModel_Hints#Tuning_ property_sheet).
Even if it doesn not fit your needs, you'll get the code that does most of
the initialization stuff for you.
Artem
"Alex Haag" <Alexander.Haag@esg.de> wrote in message
news:egniu1$b13$1@utils.eclipse.org...
> Hi Anthony,
>
> thanks for your answer. Your proposal sounds correct, but I'm not sure
> where to call this method?
> I return 'null' in getAdapter(Class key) when the argument key ==
> IPropertySheetPage.class.
> If I don't have the Page (because returning null), where should I add the
> SourceProvider to?
>
> I tried to create my own PropertySheetPage (as shown in EMF Editor) but If
> I use it, there are no entries shown at all
>
> Could you provide further help then??
> thanks Alex
>
> Anthony Hunter wrote:
>> Hi Alex,
>>
>> Sounds like you are missing a call to setPropertySourceProvider().
>>
>> If you look at the AdvancedPropertySection, you can see the call to
>> setPropertySourceProvider().
>>
>> There is a similar call in the EMF generated editor that creates an
>> ExtendedPropertySheetPage and initializes the 'normal'
>> tablePropertiesView when you use the EMF editor.
>>
>> Cheers...
>> Anthony
>>
>> "Alex Haag" <Alexander.Haag@esg.de> wrote in message
>> news:egimdr$unc$1@utils.eclipse.org...
>>> Hi,
>>>
>>> I tried to replace the tabbedPropertyView used by a
>>> GMF-generated-graphical-Editor with the 'normal' tablePropertiesView
>>> (Name-Value-Table).
>>> As described in former posts I overrode the getAdapter(y)-method in
>>> xxxxDiagramEditor to return null if y was instanceof
>>> IPropertySheetPage. --> that should disable the use of
>>> tabbedPropertiesView and it did so!
>>>
>>> After the overriding no properties where shown at all, so I undid the
>>> overriding and tried again and that's where I observed some strange
>>> behaviour:
>>>
>>> While running the application in debugmode I started the diagrameditor
>>> with tabbedProperties and closed it just to look if it is alright. Then
>>> I overrode the getAdapter()-method to return null as described above and
>>> started the diagrameditor again. Now it showed some properties (the
>>> properties that are shown in advanced Tab).
>>>
>>> Now I wonder if there is some kind of initialisation that is done while
>>> starting the tabbedProperties? Maybe I need to do this initialisation
>>> before I can use 'normal' propertiesview?
>>>
>>> Does anyone ever had some similar problems?
>>>
>>>
>>> Thanks in advance for any help!!
>>> Alex Haag
>>
|
|
|
Powered by
FUDForum. Page generated in 0.03921 seconds