01: /*******************************************************************************
02: * Copyright (c) 2000, 2006 IBM Corporation and others.
03: * All rights reserved. This program and the accompanying materials
04: * are made available under the terms of the Eclipse Public License v1.0
05: * which accompanies this distribution, and is available at
06: * http://www.eclipse.org/legal/epl-v10.html
07: *
08: * Contributors:
09: * IBM Corporation - initial API and implementation
10: *******************************************************************************/package org.eclipse.jface.util;
11:
12: import org.eclipse.swt.events.SelectionEvent;
13:
14: /**
15: * Listener for open events which are generated on selection
16: * of default selection depending on the user preferences.
17: *
18: * <p>
19: * Usage:
20: * <pre>
21: * OpenStrategy handler = new OpenStrategy(control);
22: * handler.addOpenListener(new IOpenEventListener() {
23: * public void handleOpen(SelectionEvent e) {
24: * ... // code to handle the open event.
25: * }
26: * });
27: * </pre>
28: * </p>
29: *
30: * @see OpenStrategy
31: */
32: public interface IOpenEventListener {
33: /**
34: * Called when a selection or default selection occurs
35: * depending on the user preference.
36: * @param e the selection event
37: */
38: public void handleOpen(SelectionEvent e);
39: }
|