Project

General

Profile

« Previous | Next » 

Revision f561b00c

Added by Niels Hoffmann about 13 years ago

Refactoring selection elements so they can be configured

View differences:

eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/selection/SynonymSelectionElement.java
1 1
// $Id$
2 2
/**
3
* Copyright (C) 2007 EDIT
4
* European Distributed Institute of Taxonomy 
5
* http://www.e-taxonomy.eu
6
* 
7
* The contents of this file are subject to the Mozilla Public License Version 1.1
8
* See LICENSE.TXT at the top of this package for the full license terms.
9
*/
3
 * Copyright (C) 2007 EDIT
4
 * European Distributed Institute of Taxonomy 
5
 * http://www.e-taxonomy.eu
6
 * 
7
 * The contents of this file are subject to the Mozilla Public License Version 1.1
8
 * See LICENSE.TXT at the top of this package for the full license terms.
9
 */
10 10

  
11 11
package eu.etaxonomy.taxeditor.ui.selection;
12 12

  
......
25 25
 */
26 26
public class SynonymSelectionElement extends AbstractSelectionElement<Synonym> {
27 27

  
28
	public static final int DEFAULT = SELECTABLE | DELETABLE;
29

  
28 30
	/**
29 31
	 * @param formFactory
30 32
	 * @param conversation
......
38 40
	 */
39 41
	public SynonymSelectionElement(CdmFormFactory formFactory,
40 42
			ConversationHolder conversation, ICdmFormElement parentElement,
41
			String labelString, Synonym entity, int style) {
43
			String labelString, Synonym entity, int mode, int style) {
42 44
		super(formFactory, conversation, parentElement, labelString, entity,
43
				false, true, true, style);
45
				mode, style);
44 46
	}
45 47

  
46
	/* (non-Javadoc)
47
	 * @see org.eclipse.swt.events.SelectionListener#widgetSelected(org.eclipse.swt.events.SelectionEvent)
48
	/*
49
	 * (non-Javadoc)
50
	 * 
51
	 * @see
52
	 * org.eclipse.swt.events.SelectionListener#widgetSelected(org.eclipse.swt
53
	 * .events.SelectionEvent)
48 54
	 */
49 55
	@Override
50 56
	public void widgetSelected(SelectionEvent e) {
51
		Synonym newSelection = TaxonBaseSelectionDialog.selectSynonym(getShell(), getConversationHolder());
57
		Synonym newSelection = TaxonBaseSelectionDialog.selectSynonym(
58
				getShell(), getConversationHolder());
52 59
		setSelectionInternal(newSelection);
53 60
	}
54 61

  

Also available in: Unified diff