litesoft
Diff Revisions
23
vs
49
for /trunk/Java/GWT/Client/src/org/litesoft/GWT/client/widgets/nonpublic/external/ControllerSupportDelegate.java
|
@@ -1,19 +1,20 @@ |
|
1 |
+ |
// This Source Code is Copyright & Licenced as indicated below |
|
2 |
+ |
package org.litesoft.GWT.client.widgets.nonpublic.external; |
1 |
3 |
|
/* |
2 |
4 |
|
* Copyright 2006 Mat Gessel <mat.gessel@gmail.com> |
3 |
|
- |
* |
|
5 |
+ |
* |
4 |
6 |
|
* Licensed under the Apache License, Version 2.0 (the "License"); you may not |
5 |
7 |
|
* use this file except in compliance with the License. You may obtain a copy of |
6 |
8 |
|
* the License at |
7 |
|
- |
* |
|
9 |
+ |
* |
8 |
10 |
|
* http://www.apache.org/licenses/LICENSE-2.0 |
9 |
|
- |
* |
|
11 |
+ |
* |
10 |
12 |
|
* Unless required by applicable law or agreed to in writing, software |
11 |
13 |
|
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT |
12 |
14 |
|
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the |
13 |
15 |
|
* License for the specific language governing permissions and limitations under |
14 |
16 |
|
* the License. |
15 |
17 |
|
*/ |
16 |
|
- |
package org.litesoft.GWT.client.widgets.nonpublic.external; |
17 |
18 |
|
|
18 |
19 |
|
import java.util.*; |
19 |
20 |
|
|
|
@@ -32,7 +33,7 @@ |
32 |
33 |
|
|
33 |
34 |
|
private List<Controller> m_controllers; |
34 |
35 |
|
private int m_legacyEventBits = 0; |
35 |
|
- |
// private boolean m_processing = false; |
|
36 |
+ |
// private boolean m_processing = false; |
36 |
37 |
|
|
37 |
38 |
|
/** |
38 |
39 |
|
* Creates a delegate for the specified widget. |
|
@@ -198,19 +199,19 @@ |
198 |
199 |
|
plugInControllers(); |
199 |
200 |
|
} |
200 |
201 |
|
|
201 |
|
- |
// /** |
202 |
|
- |
// * @throws IllegalStateException if the widget is detached while controllers |
203 |
|
- |
// * are processing an event. To prevent this from happening, use |
204 |
|
- |
// * {@link com.google.gwt.user.client.DeferredCommand DeferredCommand} |
205 |
|
- |
// * to remove the widget. |
|
202 |
+ |
// /** |
|
203 |
+ |
// * @throws IllegalStateException if the widget is detached while controllers |
|
204 |
+ |
// * are processing an event. To prevent this from happening, use |
|
205 |
+ |
// * {@link com.google.gwt.user.client.DeferredCommand DeferredCommand} |
|
206 |
+ |
// * to remove the widget. |
206 |
207 |
|
|
207 |
|
- |
// */ |
|
208 |
+ |
// */ |
208 |
209 |
|
|
209 |
210 |
|
public void onDetach() |
210 |
211 |
|
{ |
211 |
|
- |
// if (m_processing) |
212 |
|
- |
// throw new IllegalStateException("Detach called while calling onBrowserEvent(Event event)"); |
213 |
|
- |
// |
|
212 |
+ |
// if (m_processing) |
|
213 |
+ |
// throw new IllegalStateException("Detach called while calling onBrowserEvent(Event event)"); |
|
214 |
+ |
// |
214 |
215 |
|
unplugControllers(); |
215 |
216 |
|
} |
216 |
217 |
|
|
|
@@ -218,7 +219,7 @@ |
218 |
219 |
|
{ |
219 |
220 |
|
if ( m_controllers != null ) |
220 |
221 |
|
{ |
221 |
|
- |
// m_processing = true; |
|
222 |
+ |
// m_processing = true; |
222 |
223 |
|
for ( int i = 0, size = m_controllers.size(); i < size; i++ ) |
223 |
224 |
|
{ |
224 |
225 |
|
Controller controller = m_controllers.get( i ); |
|
@@ -227,7 +228,7 @@ |
227 |
228 |
|
controller.onBrowserEvent( m_widget, event ); |
228 |
229 |
|
} |
229 |
230 |
|
} |
230 |
|
- |
// m_processing = false; |
|
231 |
+ |
// m_processing = false; |
231 |
232 |
|
} |
232 |
233 |
|
} |
233 |
234 |
|
} |