]> gerrit.simantics Code Review - simantics/platform.git/blob - bundles/org.eclipse.swt.win32.win32.x86_64/src/org/eclipse/swt/events/ControlAdapter.java
Remove invalid SHA-256-Digests
[simantics/platform.git] / bundles / org.eclipse.swt.win32.win32.x86_64 / src / org / eclipse / swt / events / ControlAdapter.java
1 /*******************************************************************************
2  * Copyright (c) 2000, 2017 IBM Corporation and others.
3  *
4  * This program and the accompanying materials
5  * are made available under the terms of the Eclipse Public License 2.0
6  * which accompanies this distribution, and is available at
7  * https://www.eclipse.org/legal/epl-2.0/
8  *
9  * SPDX-License-Identifier: EPL-2.0
10  *
11  * Contributors:
12  *     IBM Corporation - initial API and implementation
13  *******************************************************************************/
14 package org.eclipse.swt.events;
15
16
17 /**
18  * This adapter class provides default implementations for the
19  * methods described by the <code>ControlListener</code> interface.
20  * <p>
21  * Classes that wish to deal with <code>ControlEvent</code>s can
22  * extend this class and override only the methods which they are
23  * interested in.
24  * </p>
25  * <p>
26  * An alternative to this class are the static helper methods
27  * {@link ControlListener#controlMovedAdapter(java.util.function.Consumer)}
28  * and
29  * {@link ControlListener#controlResizedAdapter(java.util.function.Consumer)},
30  * which accept a lambda expression or a method reference that implements the event consumer.
31  * </p>
32  *
33  * @see ControlListener
34  * @see ControlEvent
35  * @see <a href="http://www.eclipse.org/swt/">Sample code and further information</a>
36  */
37 public abstract class ControlAdapter implements ControlListener {
38
39 /**
40  * Sent when the location (x, y) of a control changes relative
41  * to its parent (or relative to the display, for <code>Shell</code>s).
42  * The default behavior is to do nothing.
43  *
44  * @param e an event containing information about the move
45  */
46 @Override
47 public void controlMoved(ControlEvent e) {
48 }
49
50 /**
51  * Sent when the size (width, height) of a control changes.
52  * The default behavior is to do nothing.
53  *
54  * @param e an event containing information about the resize
55  */
56 @Override
57 public void controlResized(ControlEvent e) {
58 }
59 }