litesoft
Diff Revisions
947
vs
948
for /trunk/GWT_Sandbox/FormEngine/src/com/temp/client/foundation/widget/input/support/TextBoxBaseValueAdapter.java
|
@@ -1,31 +1,30 @@ |
1 |
1 |
|
package com.temp.client.foundation.widget.input.support; |
2 |
2 |
|
|
3 |
|
- |
import com.google.gwt.event.dom.client.ChangeHandler; |
4 |
|
- |
import com.google.gwt.event.shared.HandlerRegistration; |
5 |
|
- |
import com.temp.client.foundation.widget.input.fieldsupport.InputWidgetValueAdapter; |
6 |
|
- |
import com.temp.shared.utils.StringUtils; |
7 |
|
- |
import com.temp.shared.utils.Validate; |
|
3 |
+ |
import com.google.gwt.event.dom.client.*; |
|
4 |
+ |
import com.google.gwt.event.shared.*; |
|
5 |
+ |
import com.temp.client.foundation.widget.input.fieldsupport.*; |
|
6 |
+ |
import com.temp.shared.utils.*; |
8 |
7 |
|
|
9 |
8 |
|
public class TextBoxBaseValueAdapter implements InputWidgetValueAdapter<String> { |
10 |
9 |
|
|
11 |
10 |
|
private final ActiveTextBoxBase inputWidget; |
12 |
11 |
|
|
13 |
|
- |
public TextBoxBaseValueAdapter(ActiveTextBoxBase inputWidget) { |
14 |
|
- |
Validate.notNull("inputWidget", this.inputWidget = inputWidget); |
|
12 |
+ |
public TextBoxBaseValueAdapter( ActiveTextBoxBase inputWidget ) { |
|
13 |
+ |
Validate.notNull( "inputWidget", this.inputWidget = inputWidget ); |
15 |
14 |
|
} |
16 |
15 |
|
|
17 |
16 |
|
@Override |
18 |
|
- |
public HandlerRegistration addChangeHandler(ChangeHandler handler) { |
19 |
|
- |
return inputWidget.addChangeHandler(handler); |
|
17 |
+ |
public HandlerRegistration addChangeHandler( ChangeHandler handler ) { |
|
18 |
+ |
return inputWidget.addChangeHandler( handler ); |
20 |
19 |
|
} |
21 |
20 |
|
|
22 |
21 |
|
@Override |
23 |
22 |
|
public String getValue() { |
24 |
|
- |
return StringUtils.deNull(inputWidget.getText()).trim(); |
|
23 |
+ |
return StringUtils.deNull( inputWidget.getText() ).trim(); |
25 |
24 |
|
} |
26 |
25 |
|
|
27 |
26 |
|
@Override |
28 |
|
- |
public void setValue(String value) { |
29 |
|
- |
inputWidget.setText(StringUtils.deNull(value).trim()); |
|
27 |
+ |
public void setValue( String value ) { |
|
28 |
+ |
inputWidget.setText( StringUtils.deNull( value ).trim() ); |
30 |
29 |
|
} |
31 |
30 |
|
} |