本文整理汇总了Java中com.umeng.fb.FeedbackAgent类的典型用法代码示例。如果您正苦于以下问题:Java FeedbackAgent类的具体用法?Java FeedbackAgent怎么用?Java FeedbackAgent使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
FeedbackAgent类属于com.umeng.fb包,在下文中一共展示了FeedbackAgent类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: onPreferenceClick
import com.umeng.fb.FeedbackAgent; //导入依赖的package包/类
@Override
public boolean onPreferenceClick(Preference preference) {
String clickedKey = preference.getKey();
MobclickAgent.onEvent(this, clickedKey);
AppLog.i(LOGTAG, "onPreferenceClick clickedKey=" + clickedKey);
if (getString(R.string.pref_key_feedback).equals(clickedKey)) {
FeedbackAgent agent = new FeedbackAgent(this);
agent.startFeedbackActivity();
} else if (getString(R.string.pref_key_recommend).equals(clickedKey)) {
YoumiAdProxy.getInstance().showVideoAd(this);
} else if (getString(R.string.pref_key_about).equals(clickedKey)) {
showDialog(0);
} else if (getString(R.string.pref_key_donate).equals(clickedKey)) {
Intent intent = new Intent(Intent.ACTION_VIEW);
intent.setData(Uri.parse("http://droidyue.com/donate/"));
startActivity(intent);
}
return false;
}
示例2: onPreferenceTreeClick
import com.umeng.fb.FeedbackAgent; //导入依赖的package包/类
@Override
public boolean onPreferenceTreeClick(PreferenceScreen preferenceScreen, Preference preference) {
String key = preference.getKey();
String clearCache = getResources().getString(R.string.setting_key_clear_cache);
String postback = getResources().getString(R.string.setting_key_post_back);
String checkUpdate = getResources().getString(R.string.setting_key_check_update);
if (key == clearCache){
//clear cache
biz.clearCache();
Toast.makeText(getActivity(),getResources().getText(R.string.delete_success),Toast.LENGTH_LONG).show();
return true;
}else if (key == postback){
FeedbackAgent agent = new FeedbackAgent(getActivity());
agent.setWelcomeInfo(getActivity().getResources().getString(R.string.welcome_string));
agent.startFeedbackActivity();
return true;
}else if (key == checkUpdate){
UmengUpdateAgent.forceUpdate(getActivity());
return true;
}
return super.onPreferenceTreeClick(preferenceScreen, preference);
}
示例3: buttonClick
import com.umeng.fb.FeedbackAgent; //导入依赖的package包/类
public void buttonClick(View view) {
switch (view.getId()) {
case R.id.gradeButton:
Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse("market://details?id=" + "com.deng.flashingmath"));
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
startActivity(intent);
break;
case R.id.contactButton:
FeedbackAgent agent = new FeedbackAgent(this);
agent.startFeedbackActivity();
break;
case R.id.goMarketButton:
// goToMarket();
break;
}
}
示例4: onClick
import com.umeng.fb.FeedbackAgent; //导入依赖的package包/类
@Override
public void onClick(View v) {
switch (v.getId()){
case R.id.settings_about_tv:
startActivity(new Intent(SettingsActivity.this, AboutActivity.class));
break;
case R.id.settings_score_tv:
SysUtils sysUtils = SysUtils.getInstance(SettingsActivity.this.getApplicationContext());
sysUtils.goMarket();
break;
case R.id.settings_introduce_tv:
startActivity(new Intent(SettingsActivity.this, IntroduceActivity.class));
break;
case R.id.settings_feedback_tv:
agent = new FeedbackAgent(SettingsActivity.this);
agent.startFeedbackActivity();
break;
default:
break;
}
}
示例5: onCreate
import com.umeng.fb.FeedbackAgent; //导入依赖的package包/类
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
UmengUpdateAgent.update(this);
FeedbackAgent agent = new FeedbackAgent(this);
agent.sync();
setContentView(R.layout.activity_main);
ButterKnife.bind(this);
setupDrawerView();
setupToolbar();
setupDrawerLayout();
getUserInfo();
FragmentTransaction fragmentTransaction = getSupportFragmentManager().beginTransaction();
mMainFragment = MainFragment.newInstance();
fragmentTransaction.replace(R.id.fragment_container, mMainFragment).commit();
}
示例6: onOptionsItemSelected
import com.umeng.fb.FeedbackAgent; //导入依赖的package包/类
@Override
public boolean onOptionsItemSelected(MenuItem item) {
// Handle action bar item clicks here. The action bar will
// automatically handle clicks on the Home/Up button, so long
// as you specify a parent activity in AndroidManifest.xml.
int id = item.getItemId();
// �û�������ť
if (id == R.id.feedback) {
FeedbackAgent agent = new FeedbackAgent(MainActivity.this);
agent.startFeedbackActivity();
}
if (id == R.id.logout) {
sharedPreferences.clear();
PersistentCookieStore cookieStore = new PersistentCookieStore(
MainActivity.this);
cookieStore.clear();
Intent intent = new Intent(this, MainActivity.class);
intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);
startActivity(intent);
return true;
}
return super.onOptionsItemSelected(item);
}
示例7: switchContent
import com.umeng.fb.FeedbackAgent; //导入依赖的package包/类
public void switchContent(Fragment fragment, int position) {
if (fragment != null) {
mContent = fragment;
getSupportFragmentManager()
.beginTransaction()
.replace(R.id.content_frame, fragment)
.commit();
}
getSlidingMenu().showContent();
if (position == 3) {
UmengUpdateAgent.forceUpdate(this);
}else if (position == 4) {
FeedbackAgent agent = new FeedbackAgent(this);
agent.sync();
agent.startFeedbackActivity();
}
}
示例8: onClick
import com.umeng.fb.FeedbackAgent; //导入依赖的package包/类
@Override
public void onClick(View view) {
switch (view.getId()) {
case R.id.activity_main_user_layout:
Intent intent = new Intent(mContext, ProfileActivity.class);
intent.putExtra("from", "me");
startActivityForResult(intent, INFOR_REFREFLASH);
OverridePendingUtil.in(MainActivity.this);
break;
case R.id.activity_main_feedback_layout:
FeedbackAgent agent = new FeedbackAgent(MainActivity.this);
agent.startFeedbackActivity();
OverridePendingUtil.in(MainActivity.this);
break;
case R.id.activity_main_about_layout:
startAnimActivity(AboutActivity.class);
break;
case R.id.activity_main_setting_layout:
startAnimActivity(SettingActivity.class);
break;
}
}
示例9: onClick
import com.umeng.fb.FeedbackAgent; //导入依赖的package包/类
@Override
public void onClick(View v) {
switch(v.getId()) {
case R.id.button_feedback:
FeedbackAgent agent = new FeedbackAgent(this);
agent.startFeedbackActivity();
break;
case R.id.button_about:
Intent it = new Intent(this, ActivityAbout.class);
startActivity(it);
break;
case R.id.button_logout:
DialogUtils.showOKCancelButtonDialog(this, getString(R.string.hint_logout_confirm), new AlertDialog.OnClickListener() {
@Override
public void onClick(DialogInterface dialog, int which) {
logout();
}
});
break;
default:
break;
}
}
示例10: operateUmeng
import com.umeng.fb.FeedbackAgent; //导入依赖的package包/类
public void operateUmeng() {
UmengUpdateAgent.setUpdateUIStyle(UpdateStatus.STYLE_NOTIFICATION);
UmengUpdateAgent.setDeltaUpdate(true);
UmengUpdateAgent.setUpdateOnlyWifi(false);
UmengUpdateAgent.update(this);
//检测开发者反馈回复
FeedbackAgent agent = new FeedbackAgent(this);
agent.sync();
}
示例11: initViewsAndEvents
import com.umeng.fb.FeedbackAgent; //导入依赖的package包/类
@Override
protected void initViewsAndEvents() {
mFeedbackAgent = new FeedbackAgent(this);
mFeedbackAgent.sync();
mFeedbackAgent.closeFeedbackPush();
mFeedbackAgent.closeAudioFeedback();
mFeedbackAgent.setWelcomeInfo(getResources().getString(R.string.feedback_welcome_info));
mHomePresenter = new HomePresenterImpl(this, this);
mHomePresenter.initialized();
}
示例12: initView
import com.umeng.fb.FeedbackAgent; //导入依赖的package包/类
public void initView() {
agent = new FeedbackAgent(this);
feedbackEt = (EditText) findViewById(R.id.et_feedback_content);
commitTv = findViewById(R.id.tv_submit_feedback);
commitTv.setOnClickListener(this);
contactInfoEdit = (EditText) findViewById(R.id.et_phone);
defaultConversation = agent.getDefaultConversation();
}
示例13: onClick
import com.umeng.fb.FeedbackAgent; //导入依赖的package包/类
@Override
public void onClick(View v) {
switch (v.getId()){
case R.id.log_out_button:
executeRequest(new LogoutRequest(Request.Method.POST, TuChongApi.LOGOUT_URL,
new Response.Listener<LogoutResult>() {
@Override
public void onResponse(LogoutResult response) {
AppManager.getInstance().finishAllActivities();
startActivity(new Intent(SettingsActivity.this,
RegLoginActivity.class));
if (response != null && "SUCCESS".equalsIgnoreCase(response.getResult())) {
//// leave blank
} else {
Toast.makeText(SettingsActivity.this, R.string.logout_failed, Toast.LENGTH_SHORT).show();
}
}
}, null));
break;
case R.id.setting_item_clean_cache:
//todo clean cache.
break;
case R.id.setting_item_feedback:
//USER FEEDBACK
FeedbackAgent agent = new FeedbackAgent(this);
agent.startFeedbackActivity();
break;
}
}
示例14: onClick
import com.umeng.fb.FeedbackAgent; //导入依赖的package包/类
@Override
public void onClick(View v) {
final int id = v.getId();
if (id == R.id.ly_pic_path) {
AppContext.showToastShort(mCachePicPath);
} else if (id == R.id.ly_about) {
UIHelper.showAbout(getActivity());
} else if (id == R.id.ly_cache_size) {
UIHelper.clearAppCache(getActivity());
mTvCacheSize.setText("0KB");
} else if (id == R.id.ly_version_name) {
if (mIsCheckingUpdate) {
AppContext.showToastShort(R.string.tip_checking_update);
} else {
if (mUpdateInfo != null) {
UmengUpdateAgent.showUpdateDialog(getActivity()
.getApplicationContext(), mUpdateInfo);
} else {
AppContext.showToastShort(R.string.tip_has_not_update);
}
}
} else if (id == R.id.ly_open_market) {
TDevice.openAppInMarket(getActivity());
} else if (id == R.id.ly_feedback) {
FeedbackAgent agent = new FeedbackAgent(getActivity());
agent.startFeedbackActivity();
} else if (id == R.id.btn_logout) {
handleLogout();
} else if (id == R.id.ly_notification_settings) {
UIHelper.showNotificaitonSettings(getActivity());
} else if (id == R.id.ly_font_size) {
handleFontSize();
}
}
示例15: onCreate
import com.umeng.fb.FeedbackAgent; //导入依赖的package包/类
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
sharedPreferences = new FanfanSharedPreferences(MainActivity.this);
ActionBar actionBar = getActionBar();
actionBar.setDisplayShowHomeEnabled(false);
if (!sharedPreferences.getLogInStatus(false)) {
draweritems = this.getResources().getStringArray(
R.array.nologindrawerliststring);
} else {
draweritems = this.getResources().getStringArray(
R.array.drawerliststring);
// Login();
}
mNavigationDrawerFragment = (NavigationDrawerFragment) getFragmentManager()
.findFragmentById(R.id.navigation_drawer);
mTitle = getTitle();
// Set up the drawer.
mNavigationDrawerFragment.setUp(R.id.navigation_drawer,
(DrawerLayout) findViewById(R.id.drawer_layout));
// ���������Զ��������
UmengUpdateAgent.update(MainActivity.this);
// �û���������̨����Ƿ����µ����Կ����ߵĻظ���
FeedbackAgent mAgent = new FeedbackAgent(MainActivity.this);
mAgent.sync();
MobclickAgent.updateOnlineConfig(MainActivity.this);
}