Revision be4a9789
Added by Andreas Kohlbecker about 6 years ago
src/main/java/eu/etaxonomy/cdm/vaadin/view/registration/RegistrationWorksetViewBean.java | ||
---|---|---|
184 | 184 |
addNewNameRegistrationButton = new Button("new name"); |
185 | 185 |
addNewNameRegistrationButton.setDescription("A name which is newly published in this publication."); |
186 | 186 |
addNewNameRegistrationButton.addClickListener( |
187 |
e -> eventBus.publishEvent(new TaxonNameEditorAction(EditorActionType.ADD, null, addNewNameRegistrationButton, this))
|
|
187 |
e -> getViewEventBus().publish(this, new TaxonNameEditorAction(EditorActionType.ADD, null, addNewNameRegistrationButton, this))
|
|
188 | 188 |
); |
189 | 189 |
|
190 | 190 |
addExistingNameButton = new Button("existing name:"); |
191 | 191 |
addExistingNameButton.setDescription("A name which was previously published in a earlier publication."); |
192 | 192 |
addExistingNameButton.setEnabled(false); |
193 | 193 |
addExistingNameButton.addClickListener( |
194 |
e -> eventBus.publishEvent(new RegistrationWorkingsetAction(citationID, RegistrationWorkingsetAction.Action.start))
|
|
194 |
e -> getViewEventBus().publish(this, new RegistrationWorkingsetAction(citationID, RegistrationWorkingsetAction.Action.start))
|
|
195 | 195 |
); |
196 | 196 |
|
197 | 197 |
existingNameCombobox = new LazyComboBox<TaxonName>(TaxonName.class); |
... | ... | |
229 | 229 |
if(dto.getMessages().isEmpty()){ |
230 | 230 |
messageButton.setEnabled(false); |
231 | 231 |
} else { |
232 |
messageButton.addClickListener(e -> eventBus.publishEvent(
|
|
232 |
messageButton.addClickListener(e -> getViewEventBus().publish(this,
|
|
233 | 233 |
new ShowDetailsEvent<RegistrationDTO, Integer>( |
234 | 234 |
e, |
235 | 235 |
RegistrationDTO.class, |
... | ... | |
250 | 250 |
Button editRegistrationButton = new Button(FontAwesome.COG); |
251 | 251 |
editRegistrationButton.setStyleName(ValoTheme.BUTTON_TINY); |
252 | 252 |
editRegistrationButton.setDescription("Edit registration"); |
253 |
editRegistrationButton.addClickListener(e -> getEventBus().publishEvent(new RegistrationEditorAction(
|
|
253 |
editRegistrationButton.addClickListener(e -> getViewEventBus().publish(this, new RegistrationEditorAction(
|
|
254 | 254 |
EditorActionType.EDIT, |
255 | 255 |
dto.getId(), |
256 | 256 |
null, |
... | ... | |
269 | 269 |
if(editButtonGroup.getNameButton() != null){ |
270 | 270 |
editButtonGroup.getNameButton().getButton().addClickListener(e -> { |
271 | 271 |
Integer nameId = editButtonGroup.getNameButton().getId(); |
272 |
getEventBus().publishEvent(new TaxonNameEditorAction(
|
|
272 |
getViewEventBus().publish(this, new TaxonNameEditorAction(
|
|
273 | 273 |
EditorActionType.EDIT, |
274 | 274 |
nameId, |
275 | 275 |
e.getButton(), |
... | ... | |
284 | 284 |
TypedEntityReference baseEntityRef = workingsetButton.getBaseEntity(); |
285 | 285 |
TypeDesignationWorkingSetType workingsetType = workingsetButton.getType(); |
286 | 286 |
Integer registrationEntityID = dto.getId(); |
287 |
getEventBus().publishEvent(new TypeDesignationWorkingsetEditorAction(
|
|
287 |
getViewEventBus().publish(this, new TypeDesignationWorkingsetEditorAction(
|
|
288 | 288 |
EditorActionType.EDIT, |
289 | 289 |
baseEntityRef, |
290 | 290 |
workingsetType, |
... | ... | |
342 | 342 |
*/ |
343 | 343 |
protected void addNewTypeDesignationWorkingset(TypeDesignationWorkingSetType newWorkingsetType, Integer registrationEntityId, Window typeDesignationTypeCooser) { |
344 | 344 |
UI.getCurrent().removeWindow(typeDesignationTypeCooser); |
345 |
getEventBus().publishEvent(new TypeDesignationWorkingsetEditorAction(
|
|
345 |
getViewEventBus().publish(this, new TypeDesignationWorkingsetEditorAction(
|
|
346 | 346 |
EditorActionType.ADD, |
347 | 347 |
newWorkingsetType, |
348 | 348 |
registrationEntityId, |
Also available in: Unified diff
fix #7231 replacing SpringApplicationEventBus by scoped Vaadin4Spring Event Bus