public class

ButtonFormCell

extends AppCompatButton
implements FormCell<T>
java.lang.Object
   ↳ android.view.View
     ↳ android.widget.TextView
       ↳ android.widget.Button
         ↳ androidx.appcompat.widget.AppCompatButton
           ↳ com.sap.cloud.mobile.fiori.formcell.ButtonFormCell

Class Overview

A Fiori Button as a FormCell. You can attach a FormCell.CellValueChangeListener to listen to click events on the Cell.

This form cell is a subtype of AppCompatButton.

Summary

[Expand]
Inherited Constants
From class android.widget.TextView
From class android.view.View
Fields
protected int mHorizontalMargin
protected boolean mIsTablet
protected boolean mShouldAttachOrientationListener
[Expand]
Inherited Fields
From class android.view.View
From interface androidx.core.widget.AutoSizeableTextView
Public Constructors
ButtonFormCell(Context context)
Construct a new ButtonFormCell with default styling, sets the CellType to WidgetType.BUTTON
ButtonFormCell(Context context, AttributeSet attrs)
Construct a new ButtonFormCell with default styling, overriding the attributes for the control as requested, sets the CellType to WidgetType.BUTTON
Public Methods
int getCellType()
Get the Cell type as int.
CellValueChangeListener<Void> getCellValueChangeListener()
Get the FormCell.CellValueChangeListener attached to listen to clicks on the cell
Void getValue()
Returns the value on the cell.
boolean isEditable()
Is the cell enabled?
void setCellValueChangeListener(CellValueChangeListener<Void> listener)
Attach a FormCell.CellValueChangeListener to listen to clicks on the cell.
void setEditable(boolean isEditable)
Set the cell editable i.e.
void setShouldAttachOrientationListener(boolean shouldAttach)
Determines if an OrientationEventListener should be attached.
void setValue(Void value)
Set the value on the cell.
[Expand]
Inherited Methods
From class androidx.appcompat.widget.AppCompatButton
From class android.widget.Button
From class android.widget.TextView
From class android.view.View
From class java.lang.Object
From interface android.graphics.drawable.Drawable.Callback
From interface android.view.KeyEvent.Callback
From interface android.view.ViewTreeObserver.OnPreDrawListener
From interface android.view.accessibility.AccessibilityEventSource
From interface androidx.core.view.TintableBackgroundView
From interface androidx.core.widget.AutoSizeableTextView
From interface androidx.core.widget.TintableCompoundDrawablesView
From interface com.sap.cloud.mobile.fiori.formcell.FormCell

Fields

protected int mHorizontalMargin

protected boolean mIsTablet

protected boolean mShouldAttachOrientationListener

Public Constructors

public ButtonFormCell (Context context)

Construct a new ButtonFormCell with default styling, sets the CellType to WidgetType.BUTTON

Parameters
context context

public ButtonFormCell (Context context, AttributeSet attrs)

Construct a new ButtonFormCell with default styling, overriding the attributes for the control as requested, sets the CellType to WidgetType.BUTTON

Parameters
context context
attrs attribute set

Public Methods

public int getCellType ()

Get the Cell type as int.

Returns
  • int

public CellValueChangeListener<Void> getCellValueChangeListener ()

Get the FormCell.CellValueChangeListener attached to listen to clicks on the cell

Returns
  • Get the CellChangeListener

public Void getValue ()

Returns the value on the cell. Place holder for ButtonFormCell.

Returns
  • Void

public boolean isEditable ()

Is the cell enabled?

Returns
  • boolean

public void setCellValueChangeListener (CellValueChangeListener<Void> listener)

Attach a FormCell.CellValueChangeListener to listen to clicks on the cell.

Parameters
listener value change listener of the control

public void setEditable (boolean isEditable)

Set the cell editable i.e. enabled

Parameters
isEditable boolean

public void setShouldAttachOrientationListener (boolean shouldAttach)

Determines if an OrientationEventListener should be attached.

Parameters
shouldAttach Whether the FormCell should consider attaching an OrientationEventListener or not

public void setValue (Void value)

Set the value on the cell. Place holder for ButtonFormCell.

Parameters
value Void