Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
RE: [ve-dev] Unable to see images on Open

Hi Rich,
 
Appreciate your help. I will try your suggestions.
 
However, a question:
 
Case 1: When I drop a ULCButton it shows up fine.
 
Case 2: When I close the visual class and open it, the button is not visible.
 
I checked in the debugger the sequence of calls in both the cases.
 
In Case1:
 
CompositionProxyAdapter.notifyChanged calls initSetting() which creates BeanProxies.
 
After the command is executed, ModelChangeController.doModelChanges() and transactionEnded() are called.
Which in turn calls ComponentsGraphicalEditPart.queRefreshChildren() which calls SubClassCompositionComponentsGEP.refreshChildren() which leads to  addChild() which subsequently calls activate() on ULCComponentGraphicalEditPart.
 
The activate() method calls setImageNotifier on the ImageFigureController. In this method refreshImage() is called on the ProxyAdapter class which delegates to ComponentManager.
 
In Case 2:
 
JavaVisualEditorPart first builds the model and then CopositionProxyAdapter is created and subsequently its initSetting() method is called which creates BeanProxy.
 
Then JavaVisualEditorPart calls initializeViewers() wherein setRootModel is called.This calls SubClassComponentGraphicalEditPart's activate() which results in the call to ULCComponentGraphicalEditPart.activate().
 
The activate() method calls setImageNotifier on the ImageFigureController. In this method refreshImage() is called on the ProxyAdapter class which delegates to ComponentManager.
 
--------
 
As can be seen, in both the cases, refreshImage() is called. Then why does the image not show up in Case 2?
 
Thanks and regards,
 
Janak
 
PS:
To propagate the changes made to the ULC widgets to its Swing counter part in the client, I always call pack on the free form dialog after adding the widget to the free form dialog after initing the proxy. pack() is also called in applySetting() after applying the property.

Back to the top