KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > eclipse > swt > custom > CTabFolder2Listener


1 /*******************************************************************************
2  * Copyright (c) 2000, 2004 IBM Corporation and others.
3  * All rights reserved. This program and the accompanying materials
4  * are made available under the terms of the Eclipse Public License v1.0
5  * which accompanies this distribution, and is available at
6  * http://www.eclipse.org/legal/epl-v10.html
7  *
8  * Contributors:
9  * IBM Corporation - initial API and implementation
10  *******************************************************************************/

11 package org.eclipse.swt.custom;
12
13 import org.eclipse.swt.internal.*;
14
15 /**
16  * Classes which implement this interface provide methods
17  * that deal with the events that are generated by the CTabFolder
18  * control.
19  * <p>
20  * After creating an instance of a class that implements
21  * this interface it can be added to a CTabFolder using the
22  * <code>addCTabFolder2Listener</code> method and removed using
23  * the <code>removeCTabFolder2Listener</code> method. When
24  * events occurs in a CTabFolder the appropriate method
25  * will be invoked.
26  * </p>
27  *
28  * @see CTabFolder2Adapter
29  * @see CTabFolderEvent
30  *
31  * @since 3.0
32  */

33 public interface CTabFolder2Listener extends SWTEventListener {
34     
35 /**
36  * Sent when the user clicks on the close button of an item in the CTabFolder.
37  * The item being closed is specified in the event.item field.
38  * Setting the event.doit field to false will stop the CTabItem from closing.
39  * When the CTabItem is closed, it is disposed. The contents of the
40  * CTabItem (see CTabItem.setControl) will be made not visible when
41  * the CTabItem is closed.
42  *
43  * @param event an event indicating the item being closed
44  */

45 public void close(CTabFolderEvent event);
46
47 /**
48  * Sent when the user clicks on the minimize button of a CTabFolder.
49  * The state of the CTabFolder does not change automatically - it
50  * is up to the application to change the state of the CTabFolder
51  * in response to this event using CTabFolder.setMinimized(true).
52  *
53  * @param event an event containing information about the minimize
54  *
55  * @see CTabFolder#getMinimized()
56  * @see CTabFolder#setMinimized(boolean)
57  * @see CTabFolder#setMinimizeVisible(boolean)
58  */

59 public void minimize(CTabFolderEvent event);
60
61 /**
62  * Sent when the user clicks on the maximize button of a CTabFolder.
63  * The state of the CTabFolder does not change automatically - it
64  * is up to the application to change the state of the CTabFolder
65  * in response to this event using CTabFolder.setMaximized(true).
66  *
67  * @param event an event containing information about the maximize
68  *
69  * @see CTabFolder#getMaximized()
70  * @see CTabFolder#setMaximized(boolean)
71  * @see CTabFolder#setMaximizeVisible(boolean)
72  */

73 public void maximize(CTabFolderEvent event);
74
75 /**
76  * Sent when the user clicks on the restore button of a CTabFolder.
77  * This event is sent either to restore the CTabFolder from the
78  * minimized state or from the maximized state. To determine
79  * which restore is requested, use CTabFolder.getMinimized() or
80  * CTabFolder.getMaximized() to determine the current state.
81  * The state of the CTabFolder does not change automatically - it
82  * is up to the application to change the state of the CTabFolder
83  * in response to this event using CTabFolder.setMaximized(false)
84  * or CTabFolder.setMinimized(false).
85  *
86  * @param event an event containing information about the restore
87  *
88  * @see CTabFolder#getMinimized()
89  * @see CTabFolder#getMaximized()
90  * @see CTabFolder#setMinimized(boolean)
91  * @see CTabFolder#setMinimizeVisible(boolean)
92  * @see CTabFolder#setMaximized(boolean)
93  * @see CTabFolder#setMaximizeVisible(boolean)
94  */

95 public void restore(CTabFolderEvent event);
96
97 /**
98  * Sent when the user clicks on the chevron button of the CTabFolder.
99  * A chevron appears in the CTabFolder when there are more tabs
100  * than can be displayed at the current widget size. To select a
101  * tab that is not currently visible, the user clicks on the
102  * chevron and selects a tab item from a list. By default, the
103  * CTabFolder provides a list of all the items that are not currently
104  * visible, however, the application can provide its own list by setting
105  * the event.doit field to <code>false</code> and displaying a selection list.
106  *
107  * @param event an event containing information about the show list
108  *
109  * @see CTabFolder#setSelection(CTabItem)
110  */

111 public void showList(CTabFolderEvent event);
112 }
113
Popular Tags