root / src / gr / ebs / gss / client / LoadingIndicator.java @ 6951c253
History | View | Annotate | Download (1.6 kB)
1 | 14ad7326 | pastith | /*
|
---|---|---|---|
2 | 12231a24 | Panagiotis Astithas | * Copyright 2007, 2008, 2009, 2010 Electronic Business Systems Ltd.
|
3 | 14ad7326 | pastith | *
|
4 | 14ad7326 | pastith | * This file is part of GSS.
|
5 | 14ad7326 | pastith | *
|
6 | 14ad7326 | pastith | * GSS is free software: you can redistribute it and/or modify
|
7 | 14ad7326 | pastith | * it under the terms of the GNU General Public License as published by
|
8 | 14ad7326 | pastith | * the Free Software Foundation, either version 3 of the License, or
|
9 | 14ad7326 | pastith | * (at your option) any later version.
|
10 | 14ad7326 | pastith | *
|
11 | 14ad7326 | pastith | * GSS is distributed in the hope that it will be useful,
|
12 | 14ad7326 | pastith | * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
13 | 14ad7326 | pastith | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
14 | 14ad7326 | pastith | * GNU General Public License for more details.
|
15 | 14ad7326 | pastith | *
|
16 | 14ad7326 | pastith | * You should have received a copy of the GNU General Public License
|
17 | 14ad7326 | pastith | * along with GSS. If not, see <http://www.gnu.org/licenses/>.
|
18 | 14ad7326 | pastith | */
|
19 | 14ad7326 | pastith | package gr.ebs.gss.client; |
20 | 14ad7326 | pastith | |
21 | 12231a24 | Panagiotis Astithas | import com.google.gwt.resources.client.ClientBundle; |
22 | 12231a24 | Panagiotis Astithas | import com.google.gwt.resources.client.ImageResource; |
23 | 12231a24 | Panagiotis Astithas | import com.google.gwt.user.client.ui.AbstractImagePrototype; |
24 | 12231a24 | Panagiotis Astithas | import com.google.gwt.user.client.ui.Composite; |
25 | 14ad7326 | pastith | import com.google.gwt.user.client.ui.HTML; |
26 | 14ad7326 | pastith | |
27 | 14ad7326 | pastith | /**
|
28 | 14ad7326 | pastith | * The 'loading' indicator widget implementation.
|
29 | 14ad7326 | pastith | */
|
30 | 12231a24 | Panagiotis Astithas | public class LoadingIndicator extends Composite { |
31 | 14ad7326 | pastith | |
32 | 14ad7326 | pastith | /**
|
33 | 12231a24 | Panagiotis Astithas | * An image bundle for this widgets images.
|
34 | 14ad7326 | pastith | */
|
35 | 12231a24 | Panagiotis Astithas | public interface Images extends ClientBundle { |
36 | 12231a24 | Panagiotis Astithas | @Source("gr/ebs/gss/resources/ajax-loader.gif") |
37 | 12231a24 | Panagiotis Astithas | ImageResource loading(); |
38 | 12231a24 | Panagiotis Astithas | } |
39 | 12231a24 | Panagiotis Astithas | |
40 | 12231a24 | Panagiotis Astithas | /**
|
41 | 12231a24 | Panagiotis Astithas | * The widget's constructor that creates a spinning indicator image.
|
42 | 12231a24 | Panagiotis Astithas | */
|
43 | 12231a24 | Panagiotis Astithas | public LoadingIndicator(Images images) {
|
44 | 12231a24 | Panagiotis Astithas | HTML inner = new HTML(AbstractImagePrototype.create(images.loading()).getHTML()); |
45 | 12231a24 | Panagiotis Astithas | initWidget(inner); |
46 | 14ad7326 | pastith | } |
47 | 14ad7326 | pastith | } |