Revision f6218ddf
Added by Katja Luther over 2 years ago
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/media/MediaDetailElement.java | ||
---|---|---|
20 | 20 |
import org.eclipse.core.runtime.Status; |
21 | 21 |
import org.eclipse.core.runtime.jobs.Job; |
22 | 22 |
import org.eclipse.swt.SWT; |
23 |
import org.eclipse.swt.events.SelectionAdapter; |
|
24 |
import org.eclipse.swt.events.SelectionEvent; |
|
25 |
import org.eclipse.swt.widgets.Button; |
|
23 | 26 |
import org.eclipse.swt.widgets.Label; |
24 | 27 |
|
25 | 28 |
import eu.etaxonomy.cdm.common.UriUtils; |
... | ... | |
250 | 253 |
if (isShowImage){ |
251 | 254 |
LoadImageJob job = new LoadImageJob(singleMediaRepresentationPart.getUri(), LOAD_IMAGE); |
252 | 255 |
job.schedule(); |
256 |
} else{ |
|
257 |
Button button_showImage = formFactory.createButton(getLayoutComposite(), "Show Image", SWT.PUSH); |
|
258 |
button_showImage.setLayoutData(LayoutConstants.FILL_HORIZONTALLY(2, 1)); |
|
259 |
button_showImage.addSelectionListener(new SelectionAdapter() { |
|
260 |
@Override |
|
261 |
public void widgetSelected(SelectionEvent e) { |
|
262 |
LoadImageJob job = new LoadImageJob(singleMediaRepresentationPart.getUri(), "Load Image"); |
|
263 |
job.schedule(); |
|
264 |
} |
|
265 |
}); |
|
253 | 266 |
} |
254 | 267 |
} |
255 | 268 |
} |
Also available in: Unified diff
ref #9065: add a button to load the image in derived unit facade wizard