simple text field widget does not work [message #1032071] |
Tue, 02 April 2013 14:32 |
Oliver Kolling Messages: 24 Registered: April 2010 |
Junior Member |
|
|
In my try to move an 3.x RCP Application to 4 I managed to bump into another issue. I created a simple test part with a simple Text on it. When I start the application, it displays fine and does not show any errors. But when I try typing in the field I get a null pointer in the KeyBindingDispatcher.
my code:
public class DpeEditorPart {
private Text someText;
@PostConstruct
public void createPartControl(Composite parent) {
parent.setLayout(new GridLayout(3, false));
someText = new Text(parent, SWT.BORDER);
someText.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, false, 1, 1));
}
@Focus
private void setFocus(IEclipseContext context) {
// someText.setFocus();
}
}
the problem seams to be that the call below in the
org.eclipse.e4.ui.bindings.keys.KeyBindingDispatcher
returns null here:
private EBindingService getBindingService() {
if (bindingService == null) {
bindingService = (EBindingService) context.get(EBindingService.class.getName());
}
return bindingService;
}
Which might be, because this service is never put into the context. My guess is, that I missed some dependencies/imports here...?
Thanks.
|
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.04388 seconds