Classes in this File | Line Coverage | Branch Coverage | Complexity | ||||
WaitFigure |
|
| 1.0;1 |
1 | package org.jtheque.core.managers.view.impl.components; | |
2 | ||
3 | /* | |
4 | * This file is part of JTheque. | |
5 | * | |
6 | * JTheque is free software: you can redistribute it and/or modify | |
7 | * it under the terms of the GNU General Public License as published by | |
8 | * the Free Software Foundation, either version 3 of the License. | |
9 | * | |
10 | * JTheque is distributed in the hope that it will be useful, | |
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
13 | * GNU General Public License for more details. | |
14 | * | |
15 | * You should have received a copy of the GNU General Public License | |
16 | * along with JTheque. If not, see <http://www.gnu.org/licenses/>. | |
17 | */ | |
18 | ||
19 | import javax.swing.JComponent; | |
20 | import java.awt.Graphics; | |
21 | ||
22 | /** | |
23 | * A wait figure. | |
24 | * | |
25 | * @author Baptiste Wicht | |
26 | */ | |
27 | public interface WaitFigure { | |
28 | /** | |
29 | * Init the wait figure. | |
30 | */ | |
31 | void init(); | |
32 | ||
33 | /** | |
34 | * Start the animation. | |
35 | */ | |
36 | void start(); | |
37 | ||
38 | /** | |
39 | * Stop the animation. | |
40 | */ | |
41 | void stop(); | |
42 | ||
43 | /** | |
44 | * Paint something in the Graphics of the GlassPane. | |
45 | * | |
46 | * @param graphics The Graphics of the glass pane | |
47 | */ | |
48 | void paint(Graphics graphics); | |
49 | ||
50 | /** | |
51 | * Set the bounds of the figure. This method is called when the same method is called on the glass pane. We | |
52 | * use that to be sure that its correctly resized. | |
53 | * | |
54 | * @param width The width of the glass pane | |
55 | * @param height The height of the glass pane | |
56 | */ | |
57 | void setBounds(int width, int height); | |
58 | ||
59 | /** | |
60 | * Set the parent glass pane of the wait figure. | |
61 | * | |
62 | * @param glassPane The parent glass pane | |
63 | */ | |
64 | void setGlassPane(JComponent glassPane); | |
65 | } |