Subversion Repository Public Repository

litesoft

Diff Revisions 948 vs 950 for /trunk/Java/GWT/Client/src/org/litesoft/GWT/client/widgets/NextButton.java

Diff revisions: vs.
  @@ -1,33 +1,33 @@
1 - // This Source Code is in the Public Domain per: http://unlicense.org
2 - package org.litesoft.GWT.client.widgets;
3 -
4 - import org.litesoft.commonfoundation.typeutils.*;
5 - import org.litesoft.uispecification.*;
6 -
7 - public class NextButton implements ButtonFactory {
8 - public static final String NAME = "Next";
9 -
10 - public static DefButtonNamedTypedFactory factory( String pText ) {
11 - return new DefButtonNamed( NAME ).green().postImageWidth( 12 ).text( pText );
12 - }
13 -
14 - public static DefButtonNamedTypedFactory factory() {
15 - return factory( (String) null );
16 - }
17 -
18 - public static DefButtonNamedTypedFactory factory( ViewDef pTarget ) {
19 - return justButtonFactory( pTarget ).add( pTarget );
20 - }
21 -
22 - public static DefButtonNamedTypedFactory factory( ViewDef pTarget, UriFragmentIdParams.ScreenParamsFactory pFactory ) {
23 - return justButtonFactory( pTarget ).add( pTarget, pFactory );
24 - }
25 -
26 - public static DefButtonNamedTypedFactory justButtonFactory( ViewDef pViewDef ) {
27 - return factory().enabledToolTip( toolTip( "", pViewDef ) );
28 - }
29 -
30 - public static String toolTip( String pPrefix, ViewDef pViewDef ) {
31 - return (pViewDef == null) ? "" : Strings.deNull( pPrefix ) + "Advance to the " + pViewDef.getUiString() + " step";
32 - }
33 - }
1 + // This Source Code is in the Public Domain per: http://unlicense.org
2 + package org.litesoft.GWT.client.widgets;
3 +
4 + import org.litesoft.commonfoundation.base.*;
5 + import org.litesoft.uispecification.*;
6 +
7 + public class NextButton implements ButtonFactory {
8 + public static final String NAME = "Next";
9 +
10 + public static DefButtonNamedTypedFactory factory( String pText ) {
11 + return new DefButtonNamed( NAME ).green().postImageWidth( 12 ).text( pText );
12 + }
13 +
14 + public static DefButtonNamedTypedFactory factory() {
15 + return factory( (String) null );
16 + }
17 +
18 + public static DefButtonNamedTypedFactory factory( ViewDef pTarget ) {
19 + return justButtonFactory( pTarget ).add( pTarget );
20 + }
21 +
22 + public static DefButtonNamedTypedFactory factory( ViewDef pTarget, UriFragmentIdParams.ScreenParamsFactory pFactory ) {
23 + return justButtonFactory( pTarget ).add( pTarget, pFactory );
24 + }
25 +
26 + public static DefButtonNamedTypedFactory justButtonFactory( ViewDef pViewDef ) {
27 + return factory().enabledToolTip( toolTip( "", pViewDef ) );
28 + }
29 +
30 + public static String toolTip( String pPrefix, ViewDef pViewDef ) {
31 + return (pViewDef == null) ? "" : ConstrainTo.notNull( pPrefix ) + "Advance to the " + pViewDef.getUiString() + " step";
32 + }
33 + }