本文整理汇总了Java中com.facebook.internal.Utility.FetchedAppSettings类的典型用法代码示例。如果您正苦于以下问题:Java FetchedAppSettings类的具体用法?Java FetchedAppSettings怎么用?Java FetchedAppSettings使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
FetchedAppSettings类属于com.facebook.internal.Utility包,在下文中一共展示了FetchedAppSettings类的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: checkNuxSettings
import com.facebook.internal.Utility.FetchedAppSettings; //导入依赖的package包/类
private void checkNuxSettings() {
if (nuxMode == ToolTipMode.DISPLAY_ALWAYS) {
String nuxString = getResources().getString(R.string.com_facebook_tooltip_default);
displayNux(nuxString);
} else {
// kick off an async request
final String appId = Utility.getMetadataApplicationId(getContext());
AsyncTask<Void, Void, FetchedAppSettings> task = new AsyncTask<Void, Void, Utility.FetchedAppSettings>() {
@Override
protected FetchedAppSettings doInBackground(Void... params) {
FetchedAppSettings settings = Utility.queryAppSettings(appId, false);
return settings;
}
@Override
protected void onPostExecute(FetchedAppSettings result) {
showNuxPerSettings(result);
}
};
task.execute((Void[])null);
}
}
示例2: checkNuxSettings
import com.facebook.internal.Utility.FetchedAppSettings; //导入依赖的package包/类
private void checkNuxSettings() {
if (nuxMode == ToolTipMode.DISPLAY_ALWAYS) {
String nuxString = getResources().getString(R.string.com_facebook_tooltip_default);
displayNux(nuxString);
} else {
// kick off an async request
final String appId = Utility.getMetadataApplicationId(getContext());
AsyncTask<Void, Void, FetchedAppSettings> task =
new AsyncTask<Void, Void, Utility.FetchedAppSettings>() {
@Override
protected FetchedAppSettings doInBackground(Void... params) {
FetchedAppSettings settings = Utility.queryAppSettings(appId, false);
return settings;
}
@Override
protected void onPostExecute(FetchedAppSettings result) {
showNuxPerSettings(result);
}
};
task.execute((Void[]) null);
}
}
示例3: checkNuxSettings
import com.facebook.internal.Utility.FetchedAppSettings; //导入依赖的package包/类
private void checkNuxSettings()
{
if (this.nuxMode == ToolTipMode.DISPLAY_ALWAYS)
{
displayNux(getResources().getString(R.string.com_facebook_tooltip_default));
return;
}
new AsyncTask()
{
protected Utility.FetchedAppSettings doInBackground(Void[] paramAnonymousArrayOfVoid)
{
return Utility.queryAppSettings(this.val$appId, false);
}
protected void onPostExecute(Utility.FetchedAppSettings paramAnonymousFetchedAppSettings)
{
LoginButton.this.showNuxPerSettings(paramAnonymousFetchedAppSettings);
}
}
.execute(null);
}
示例4: checkToolTipSettings
import com.facebook.internal.Utility.FetchedAppSettings; //导入依赖的package包/类
private void checkToolTipSettings() {
switch (toolTipMode) {
case AUTOMATIC:
// kick off an async request
final String appId = Utility.getMetadataApplicationId(getContext());
FacebookSdk.getExecutor().execute(new Runnable() {
@Override
public void run() {
final FetchedAppSettings settings = Utility.queryAppSettings(appId, false);
getActivity().runOnUiThread(new Runnable() {
@Override
public void run() {
showToolTipPerSettings(settings);
}
});
}
});
break;
case DISPLAY_ALWAYS:
String toolTipString = getResources().getString(
R.string.com_facebook_tooltip_default);
displayToolTip(toolTipString);
break;
case NEVER_DISPLAY:
break;
}
}
示例5: showToolTipPerSettings
import com.facebook.internal.Utility.FetchedAppSettings; //导入依赖的package包/类
private void showToolTipPerSettings(FetchedAppSettings settings) {
if (settings != null && settings.getNuxEnabled() && getVisibility() == View.VISIBLE) {
String toolTipString = settings.getNuxContent();
displayToolTip(toolTipString);
}
}
示例6: showNuxPerSettings
import com.facebook.internal.Utility.FetchedAppSettings; //导入依赖的package包/类
private void showNuxPerSettings(FetchedAppSettings settings) {
if (settings != null && settings.getNuxEnabled() && getVisibility() == View.VISIBLE) {
String nuxString = settings.getNuxContent();
displayNux(nuxString);
}
}
示例7: showNuxPerSettings
import com.facebook.internal.Utility.FetchedAppSettings; //导入依赖的package包/类
private void showNuxPerSettings(Utility.FetchedAppSettings paramFetchedAppSettings)
{
if ((paramFetchedAppSettings != null) && (paramFetchedAppSettings.getNuxEnabled()) && (getVisibility() == 0))
displayNux(paramFetchedAppSettings.getNuxContent());
}