Revision 191f2328
Added by Patrick Plitzner almost 9 years ago
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/media/MediaDetailElement.java | ||
---|---|---|
9 | 9 |
*/ |
10 | 10 |
package eu.etaxonomy.taxeditor.ui.section.media; |
11 | 11 |
|
12 |
import java.net.URISyntaxException; |
|
13 | 12 |
import java.util.List; |
14 | 13 |
import java.util.Set; |
15 | 14 |
|
... | ... | |
19 | 18 |
import eu.etaxonomy.cdm.model.media.MediaUtils; |
20 | 19 |
import eu.etaxonomy.taxeditor.preference.IPreferenceKeys; |
21 | 20 |
import eu.etaxonomy.taxeditor.preference.PreferencesUtil; |
22 |
import eu.etaxonomy.taxeditor.preference.Resources; |
|
23 | 21 |
import eu.etaxonomy.taxeditor.ui.element.CdmFormFactory; |
24 | 22 |
import eu.etaxonomy.taxeditor.ui.element.ICdmFormElement; |
25 | 23 |
import eu.etaxonomy.taxeditor.ui.element.LayoutConstants; |
... | ... | |
62 | 60 |
} |
63 | 61 |
|
64 | 62 |
@Override |
65 |
public void handleEvent(Object eventSource) {
|
|
63 |
public void handleEvent(Object eventSource){ |
|
66 | 64 |
if(eventSource==textUri){ |
67 | 65 |
textUri.setBackground(getPersistentBackground()); |
68 |
try { |
|
69 |
singleMediaRepresentationPart.setUri(textUri.getUri()); |
|
70 |
} catch (URISyntaxException e) { |
|
71 |
textUri.setBackground(getColor(Resources.COLOR_PARSE_ERROR)); |
|
72 |
} |
|
66 |
singleMediaRepresentationPart.setUri(textUri.getUri()); |
|
73 | 67 |
} |
74 | 68 |
} |
75 | 69 |
|
Also available in: Unified diff
Show URI parsing exceptions below URI text field (fixes #5055, #5003, #4587)