Project Wonder 5.0.0.8787

er.extensions.components._private
Class ERXSubmitButton

java.lang.Object
  extended by com.webobjects.appserver.WOElement
      extended by com.webobjects.appserver.WODynamicElement
          extended by com.webobjects.appserver._private.WODynamicGroup
              extended by com.webobjects.appserver._private.WOHTMLDynamicElement
                  extended by com.webobjects.appserver._private.WOInput
                      extended by er.extensions.components._private.ERXSubmitButton
Direct Known Subclasses:
ERXAccessibleSubmitButton

public class ERXSubmitButton
extends com.webobjects.appserver._private.WOInput

Clone of WOSubmitButton that should emit <button> tags instead of <input> tags. This allows you to use HTML content and superior style features.
Unfortunately, IE is totally broken and always submits all buttons on a page, which makes it unusable for actions. So this component inserts some javascript to fix this. Of course, this means your button is only usable with scripting turned on in IE.
You can add this class via ERXPatcher.setClassForName(ERXSubmitButton.class, "WOSubmitButton"); and see how this works out or use it explicitely. If you just patch it into the system, the value is used as the content, otherwise you can put any html you like into it.

Author:
ak

Field Summary
protected  WOAssociation _action
           
protected  WOAssociation _actionClass
           
protected  WOAssociation _class
           
protected  WOAssociation _directActionName
           
protected  WOAssociation _id
           
protected  WOAssociation _shouldSubmitForm
           
static Logger log
           
static String STYLE_PREFIX
           
 
Fields inherited from class com.webobjects.appserver._private.WOInput
_disabled, _escapeHTML, _hidden, _name, _value
 
Fields inherited from class com.webobjects.appserver._private.WOHTMLDynamicElement
_associations, _constantAttributeAssociations, _constantAttributesRepresentation, _dyneltName, _finishedInitialization, _generatedId, _prefix, _rendered, _secure, _style, _suffix, _title, DontEscapeHTML, EscapeHTML
 
Fields inherited from class com.webobjects.appserver._private.WODynamicGroup
_children
 
Fields inherited from class com.webobjects.appserver.WODynamicElement
_ConstructorParameters
 
Constructor Summary
ERXSubmitButton(String arg0, NSDictionary<String,WOAssociation> nsdictionary, WOElement arg2)
           
 
Method Summary
protected  void _appendCloseTagToResponse(WOResponse woresponse, WOContext wocontext)
           
protected  void _appendNameAttributeToResponse(WOResponse woresponse, WOContext wocontext)
           
protected  void _appendOpenTagToResponse(WOResponse woresponse, WOContext wocontext)
           
 void appendAttributesToResponse(WOResponse woresponse, WOContext wocontext)
           
 void appendChildrenToResponse(WOResponse woresponse, WOContext wocontext)
           
static void appendIEButtonFixToResponse(WOContext wocontext, WOResponse woresponse)
           
 void appendToResponse(WOResponse woresponse, WOContext wocontext)
           
protected  String elementName(WOContext wocontext)
           
 WOActionResults invokeAction(WORequest worequest, WOContext wocontext)
           
protected  boolean isDisabledInContext(WOContext context)
           
 void takeValuesFromRequest(WORequest worequest, WOContext wocontext)
           
 String toString()
           
protected  String type()
           
 
Methods inherited from class com.webobjects.appserver._private.WOInput
_appendDisabledAttributeToResponse, _appendTypeAttributeToResponse, _appendValueAttributeToResponse, defaultEscapeHTML, escapeHTMLInContext, hasContent, hiddenInContext, isValueInInputValues, nameInContext, nameInContext, valueStringInContext
 
Methods inherited from class com.webobjects.appserver._private.WOHTMLDynamicElement
__otherQueryDictionaryInContext, __queryDictionaryInContext, _appendAttributesFromAssociationsToResponse, _appendClassAndIdToResponse, _appendTagAttributeAndValueToResponse, _frameworkNameInComponent, appendConstantAttributesToResponse, appendHiddenFieldToResponse, appendNonURLAttributesToResponse, appendURLAttributesToResponse, classInContext, computeActionStringInContext, computeQueryDictionaryInContext, constantAttributeAssociations, constantAttributesRepresentation, elementName, escapeHTML, idInContext, isRenderedInContext, nonUrlAttributeAssociations, prefixInContext, secureInContext, stringValueInContext, styleInContext, suffixInContext, titleInContext, urlAttributeAssociations
 
Methods inherited from class com.webobjects.appserver._private.WODynamicGroup
addChildElement, childrenElements, EmptyGroup, hasChildrenElements, invokeChildrenAction, takeChildrenValuesFromRequest
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

log

public static final Logger log

STYLE_PREFIX

public static final String STYLE_PREFIX
See Also:
Constant Field Values

_class

protected WOAssociation _class

_id

protected WOAssociation _id

_action

protected WOAssociation _action

_actionClass

protected WOAssociation _actionClass

_directActionName

protected WOAssociation _directActionName

_shouldSubmitForm

protected WOAssociation _shouldSubmitForm
Constructor Detail

ERXSubmitButton

public ERXSubmitButton(String arg0,
                       NSDictionary<String,WOAssociation> nsdictionary,
                       WOElement arg2)
Method Detail

appendIEButtonFixToResponse

public static void appendIEButtonFixToResponse(WOContext wocontext,
                                               WOResponse woresponse)

isDisabledInContext

protected boolean isDisabledInContext(WOContext context)
Overrides:
isDisabledInContext in class com.webobjects.appserver._private.WOInput

type

protected String type()
Overrides:
type in class com.webobjects.appserver._private.WOInput

toString

public String toString()
Overrides:
toString in class com.webobjects.appserver._private.WOInput

takeValuesFromRequest

public void takeValuesFromRequest(WORequest worequest,
                                  WOContext wocontext)
Overrides:
takeValuesFromRequest in class com.webobjects.appserver._private.WOInput

elementName

protected String elementName(WOContext wocontext)

_appendOpenTagToResponse

protected void _appendOpenTagToResponse(WOResponse woresponse,
                                        WOContext wocontext)
Overrides:
_appendOpenTagToResponse in class com.webobjects.appserver._private.WOHTMLDynamicElement

appendAttributesToResponse

public void appendAttributesToResponse(WOResponse woresponse,
                                       WOContext wocontext)
Overrides:
appendAttributesToResponse in class com.webobjects.appserver._private.WOInput

_appendCloseTagToResponse

protected void _appendCloseTagToResponse(WOResponse woresponse,
                                         WOContext wocontext)
Overrides:
_appendCloseTagToResponse in class com.webobjects.appserver._private.WOHTMLDynamicElement

invokeAction

public WOActionResults invokeAction(WORequest worequest,
                                    WOContext wocontext)
Overrides:
invokeAction in class com.webobjects.appserver._private.WODynamicGroup

appendChildrenToResponse

public void appendChildrenToResponse(WOResponse woresponse,
                                     WOContext wocontext)
Overrides:
appendChildrenToResponse in class com.webobjects.appserver._private.WODynamicGroup

_appendNameAttributeToResponse

protected void _appendNameAttributeToResponse(WOResponse woresponse,
                                              WOContext wocontext)
Overrides:
_appendNameAttributeToResponse in class com.webobjects.appserver._private.WOInput

appendToResponse

public void appendToResponse(WOResponse woresponse,
                             WOContext wocontext)
Overrides:
appendToResponse in class com.webobjects.appserver._private.WOHTMLDynamicElement

Last updated: Wed, Jan 7, 2009 • 04:35 AM EST

Copyright © 2002 – 2007 Project Wonder.