use of com.umeng.fb.FeedbackAgent in project SimplifyReader by chentao0707.
the class HomeActivity method initViewsAndEvents.
@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();
}
use of com.umeng.fb.FeedbackAgent in project android-app by eoecn.
the class MainActivity method onClick.
// [end]
// [start]继承方法
@Override
public void onClick(View v) {
// TODO Auto-generated method stub
switch(v.getId()) {
case R.id.Linear_above_toHome:
showMenu();
break;
case R.id.login_login:
SharedPreferences share = this.getSharedPreferences(UserLoginUidActivity.SharedName, Context.MODE_PRIVATE);
// [start] 修复上一个bug
String Key = share.getString(UserLoginUidActivity.KEY, "");
if (Key != "" && !Key.contains(":")) {
Editor edit = share.edit();
edit.putString(UserLoginUidActivity.KEY, "");
edit.commit();
}
// [end] 下一版本删除掉
if (share.contains(UserLoginUidActivity.KEY) && !share.getString(UserLoginUidActivity.KEY, "").equals("")) {
IntentUtil.start_activity(this, UserCenterActivity.class);
} else {
IntentUtil.start_activity(this, UserLoginActivity.class);
}
break;
case R.id.imageview_above_more:
if (isShowPopupWindows) {
new PopupWindowUtil(mViewPager).showActionWindow(v, this, mBasePageAdapter.tabs);
}
break;
case R.id.imageview_above_query:
if (NetWorkHelper.isNetworkAvailable(MainActivity.this)) {
IntentUtil.start_activity(this, SearchActivity.class, new BasicNameValuePair("tag", current_page));
} else {
Toast.makeText(getApplicationContext(), "网络连接失败,请检查网络", Toast.LENGTH_LONG).show();
}
break;
case R.id.cbFeedback:
FeedbackAgent agent = new FeedbackAgent(this);
agent.startFeedbackActivity();
break;
case R.id.cbAbove:
IntentUtil.start_activity(this, AboutActivity.class);
break;
case R.id.bn_refresh:
switch(mTag) {
case 0:
imgQuery.setVisibility(View.GONE);
new MyTask().execute(topDao);
break;
case 1:
new MyTask().execute(newsDao);
break;
case 2:
new MyTask().execute(wikiDao);
break;
case 3:
new MyTask().execute(blogsDao);
break;
default:
break;
}
break;
}
}
use of com.umeng.fb.FeedbackAgent in project SunDay by iQuick.
the class SettingActivity method clickFeedback.
/**
* 用户反馈
*/
@Click(R.id.setting_user_feedback)
void clickFeedback() {
FeedbackAgent agent = new FeedbackAgent(SettingActivity.this);
agent.startFeedbackActivity();
}
use of com.umeng.fb.FeedbackAgent in project umeng-android-sdk-theme by umeng.
the class ConversationActivity method onCreate.
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.umeng_fb_activity_conversation);
try {
agent = new FeedbackAgent(this);
defaultConversation = agent.getDefaultConversation();
replyListView = (ListView) findViewById(R.id.umeng_fb_reply_list);
setListViewHeader();
adapter = new ReplyListAdapter(this);
replyListView.setAdapter(adapter);
// sync up the conversations on Activity start up.
sync();
// contact info entry
View contact_entry = findViewById(R.id.umeng_fb_conversation_contact_entry);
contact_entry.setOnClickListener(new OnClickListener() {
@SuppressLint("NewApi")
@Override
public void onClick(View v) {
Intent intent = new Intent();
intent.setClass(ConversationActivity.this, ContactActivity.class);
startActivity(intent);
// http://stackoverflow.com/questions/6495007/verifyerror-deploying-on-api-1-6
if (android.os.Build.VERSION.SDK_INT > android.os.Build.VERSION_CODES.DONUT) {
overridePendingTransition(R.anim.umeng_fb_slide_in_from_right, R.anim.umeng_fb_slide_out_from_left);
}
}
});
if (agent.getUserInfoLastUpdateAt() > 0)
contact_entry.setVisibility(View.GONE);
findViewById((R.id.umeng_fb_back)).setOnClickListener(new OnClickListener() {
@Override
public void onClick(View v) {
finish();
}
});
userReplyContentEdit = (EditText) findViewById(R.id.umeng_fb_reply_content);
findViewById(R.id.umeng_fb_send).setOnClickListener(new OnClickListener() {
@Override
public void onClick(View v) {
String content = userReplyContentEdit.getEditableText().toString().trim();
if (TextUtils.isEmpty(content))
return;
userReplyContentEdit.getEditableText().clear();
defaultConversation.addUserReply(content);
// adapter.notifyDataSetChanged();
// scoll to the end of listview after updating the
// conversation.
// replyList.setSelection(adapter.getCount()-1);
sync();
// hide soft input window after sending.
InputMethodManager imm = (InputMethodManager) getSystemService(Context.INPUT_METHOD_SERVICE);
if (imm != null)
imm.hideSoftInputFromWindow(userReplyContentEdit.getWindowToken(), 0);
}
});
} catch (Exception e) {
e.printStackTrace();
this.finish();
}
}
Aggregations