Home » Modeling » EMF » Modifying properties view (combo box value)
|
Re: Modifying properties view (combo box value) [message #503474 is a reply to message #503466] |
Mon, 14 December 2009 06:42 |
Ed Merks Messages: 33141 Registered: July 2009 |
Senior Member |
|
|
This is a multi-part message in MIME format.
--------------040200030908080407010903
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Carlos,
There's an example in EReferenceItemProvider.
protected void addEOppositePropertyDescriptor(Object object)
{
itemPropertyDescriptors.add
(new ItemPropertyDescriptor
(((ComposeableAdapterFactory)adapterFactory).getRootAdapterF actory(),
getResourceLocator(),
getString("_UI_EReference_eOpposite_feature"),
getString("_UI_EReference_eOpposite_description"),
EcorePackage.Literals.EREFERENCE__EOPPOSITE,
true,
false,
true,
null,
null,
null)
{
@Override
public Collection<?> *getChoiceOfValues*(Object object)
{
I.e., specialize getChoiceOfValues of the property descriptor.
Carlos wrote:
> Hello,
>
> I want to modify the behaviour of the properties view.
> When you make double click in a property value which is a combo box,
> the view shows all the available values. If the property is a
> reference, combo box shows all objects which can be targeted for those
> elements.
>
> Maybe the project was: "org.eclipse.emf.edit.ui", and teh class
> "AdapterFactoryContentProvider"... but I'm not sure...
>
> Please, what class and what EMF project do I have to modify for
> getting the combo box only load the values I want (basically a filter
> on the default combo values)?
>
> Have you got any suggestion about this issue?
>
> Thanks in advance.
> Best regards.
>
>
--------------040200030908080407010903
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: 8bit
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=UTF-8" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Carlos,<br>
<br>
There's an example in EReferenceItemProvider.<br>
<br>
<small> protected void addEOppositePropertyDescriptor(Object object)<br>
{<br>
itemPropertyDescriptors.add<br>
(new ItemPropertyDescriptor<br>
(((ComposeableAdapterFactory)adapterFactory).getRootAdapterF actory(), <br>
getResourceLocator(),<br>
getString("_UI_EReference_eOpposite_feature"),<br>
getString("_UI_EReference_eOpposite_description"),<br>
EcorePackage.Literals.EREFERENCE__EOPPOSITE,<br>
true,<br>
false,<br>
true,<br>
null,<br>
null,<br>
null)<br>
{<br>
@Override<br>
public Collection<?> <b>getChoiceOfValues</b>(Object
object)<br>
{</small><br>
<br>
I.e., specialize getChoiceOfValues of the property descriptor.<br>
<br>
<br>
Carlos wrote:
<blockquote cite="mid:hg56h6$3a9$1@build.eclipse.org" type="cite">Hello,
<br>
<br>
I want to modify the behaviour of the properties view.
<br>
When you make double click in a property value which is a combo box,
the view shows all the available values. If the property is a
reference, combo box shows all objects which can be targeted for those
elements.
<br>
<br>
Maybe the project was: "org.eclipse.emf.edit.ui", and teh class
"AdapterFactoryContentProvider"... but I'm not sure...
<br>
<br>
Please, what class and what EMF project do I have to modify for getting
the combo box only load the values I want (basically a filter on the
default combo values)?
<br>
<br>
Have you got any suggestion about this issue?
<br>
<br>
Thanks in advance.
<br>
Best regards.
<br>
<br>
<br>
</blockquote>
</body>
</html>
--------------040200030908080407010903--
Ed Merks
Professional Support: https://www.macromodeling.com/
|
|
| |
Goto Forum:
Current Time: Thu Apr 25 16:51:41 GMT 2024
Powered by FUDForum. Page generated in 0.02795 seconds
|