Revision b14494a9
Added by Andreas Kohlbecker over 5 years ago
src/main/java/eu/etaxonomy/cdm/vaadin/toolbar/RegistrationToolbar.java | ||
---|---|---|
8 | 8 |
*/ |
9 | 9 |
package eu.etaxonomy.cdm.vaadin.toolbar; |
10 | 10 |
|
11 |
import org.springframework.beans.factory.DisposableBean; |
|
11 | 12 |
import org.springframework.beans.factory.annotation.Autowired; |
12 | 13 |
import org.springframework.beans.factory.annotation.Qualifier; |
13 | 14 |
import org.vaadin.spring.events.EventBus; |
... | ... | |
37 | 38 |
*/ |
38 | 39 |
@SpringComponent("registrationToolbar") |
39 | 40 |
@UIScope |
40 |
public class RegistrationToolbar extends HorizontalLayout implements Toolbar, EventBusListener<AuthenticationSuccessEvent> { |
|
41 |
public class RegistrationToolbar extends HorizontalLayout implements Toolbar, EventBusListener<AuthenticationSuccessEvent>, DisposableBean {
|
|
41 | 42 |
|
42 | 43 |
private static final long serialVersionUID = 2594781255088231474L; |
43 | 44 |
|
... | ... | |
132 | 133 |
navigationManager.reloadCurrentView(); |
133 | 134 |
} |
134 | 135 |
|
136 |
/** |
|
137 |
* {@inheritDoc} |
|
138 |
*/ |
|
139 |
@Override |
|
140 |
public void destroy() throws Exception { |
|
141 |
uiEventBus.unsubscribe(this); |
|
142 |
} |
|
143 |
|
|
135 | 144 |
} |
Also available in: Unified diff
fix #7036 making sure all spring beans are disposed when the vaadin session times out