A base class for a facebook button.
Extends: | Button |
Package: | facebook |
FacebookButtonBase(Context, AttributeSet, int, int, String, String)
protected FacebookButtonBase(Context context, AttributeSet attrs, int defStyleAttr, int defStyleRes, String analyticsButtonCreatedEventName, String analyticsButtonTappedEventName)
Parameter | Description |
---|---|
context | |
attrs | |
defStyleAttr | |
defStyleRes | |
analyticsButtonCreatedEventName | |
analyticsButtonTappedEventName |
getDefaultRequestCode()
protected abstract int getDefaultRequestCode()
setFragment(Fragment)
Sets the fragment that contains this control. This allows the button to be embedded inside a Fragment, and will allow the fragment to receive the onActivityResult.onActivityResult(int, int, android.content.Intent) call rather than the Activity.
public void setFragment(Fragment fragment)
Parameter | Description |
---|---|
fragment | The android.support.v4.app.Fragment that contains this control |
setFragment(Fragment)
Sets the fragment that contains this control. This allows the button to be embedded inside a Fragment, and will allow the fragment to receive the onActivityResult.onActivityResult(int, int, android.content.Intent) call rather than the Activity.
public void setFragment(Fragment fragment)
Parameter | Description |
---|---|
fragment | The android.app.Fragment that contains this control |
getFragment()
Gets the fragment that contains this control.
public Fragment getFragment()
getNativeFragment()
Gets the fragment that contains this control.
public Fragment getNativeFragment()
getRequestCode()
Returns the request code used for this Button.
public int getRequestCode()
getActivity()
protected Activity getActivity()
getDefaultStyleResource()
protected int getDefaultStyleResource()
measureTextWidth(String)
protected int measureTextWidth(String text)
Parameter | Description |
---|---|
text |
configureButton(Context, AttributeSet, int, int)
protected void configureButton(Context context, AttributeSet attrs, int defStyleAttr, int defStyleRes)
Parameter | Description |
---|---|
context | |
attrs | |
defStyleAttr | |
defStyleRes |
callExternalOnClickListener(View)
protected void callExternalOnClickListener(View v)
Parameter | Description |
---|---|
v |
setInternalOnClickListener(OnClickListener)
protected void setInternalOnClickListener(OnClickListener l)
Parameter | Description |
---|---|
l |