当前位置: 首页>>代码示例>>Java>>正文


Java MobclickAgent类代码示例

本文整理汇总了Java中com.umeng.analytics.MobclickAgent的典型用法代码示例。如果您正苦于以下问题:Java MobclickAgent类的具体用法?Java MobclickAgent怎么用?Java MobclickAgent使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


MobclickAgent类属于com.umeng.analytics包,在下文中一共展示了MobclickAgent类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: sendPraise

import com.umeng.analytics.MobclickAgent; //导入依赖的package包/类
public void sendPraise(boolean isDelete) {
    if (isDelete) {
        StatusApi.deleteFeedbacks(this.mContext, this.post_id, new JsonCallback((Activity)
                this.mContext) {
        });
    } else {
        StatusApi.putFeedbacks(this.mContext, this.post_id, new JsonCallback((Activity) this
                .mContext) {
            public void ok(JSONObject object) {
                super.ok(object);
                if (!TextUtils.isEmpty(object.optString("body"))) {
                    Helper.showToast(PraiseButton.this.getContext(), object.optString("body"));
                }
                MobclickAgent.onEvent(PraiseButton.this.mContext, Event.STATUS_ADD_ATTITUTE_OK);
                MobclickAgent.onEvent(PraiseButton.this.mContext, Event.STATUS_ADD_INTERACT_OK);
                MobclickAgent.onEvent(PraiseButton.this.mContext, Event.MINE_ALL_RECORD_OK);
            }
        });
    }
}
 
开发者ID:JackChan1999,项目名称:boohee_v5.6,代码行数:21,代码来源:PraiseButton.java

示例2: onCreate

import com.umeng.analytics.MobclickAgent; //导入依赖的package包/类
@Override
protected void onCreate(@Nullable Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setSwipeBackEnable(false);
    initBundle(getIntent().getExtras());
    if (getLayoutId() != 0) {
        setContentView(getLayoutId());
    }
    initToolBar();
    initView();
    initData();
    //umeng analytics
    if (BuildConfig.DEBUG) {
        MobclickAgent.setDebugMode(true);
    }
    MobclickAgent.openActivityDurationTrack(false);
    MobclickAgent.setScenarioType(this, MobclickAgent.EScenarioType.E_UM_NORMAL);
}
 
开发者ID:coding-dream,项目名称:TPlayer,代码行数:19,代码来源:BaseActivity.java

示例3: sendClickCount

import com.umeng.analytics.MobclickAgent; //导入依赖的package包/类
private void sendClickCount(int id) {
    switch (id) {
        case 1:
            MobclickAgent.onEvent(getActivity(), Event.status_friendTimeline);
            return;
        case 2:
            MobclickAgent.onEvent(getActivity(), Event.status_hotTimeline);
            return;
        case 3:
            MobclickAgent.onEvent(getActivity(), Event.status_todayContent);
            return;
        case 4:
            MobclickAgent.onEvent(getActivity(), Event.status_betHome);
            return;
        default:
            return;
    }
}
 
开发者ID:JackChan1999,项目名称:boohee_v5.6,代码行数:19,代码来源:NewPartnerFragment.java

示例4: initView

import com.umeng.analytics.MobclickAgent; //导入依赖的package包/类
private void initView() {
    this.tvBind.setOnClickListener(new OnClickListener() {
        public void onClick(View v) {
            MobclickAgent.onEvent(ScaleIntroActivity.this, Event.bingo_clickBindingScalse);
            ScaleBindActivity.startActivity(ScaleIntroActivity.this);
        }
    });
    this.webView.getSettings().setJavaScriptEnabled(true);
    this.webView.getSettings().setLayoutAlgorithm(LayoutAlgorithm.NORMAL);
    this.webView.getSettings().setPluginState(PluginState.ON);
    this.webView.getSettings().setUserAgentString(this.webView.getSettings()
            .getUserAgentString() + " App/boohee");
    this.webView.getSettings().setDomStorageEnabled(true);
    this.webView.setWebViewClient(createWebViewClient());
    this.webView.loadUrl(UrlUtils.handleUrl(URL));
}
 
开发者ID:JackChan1999,项目名称:boohee_v5.6,代码行数:17,代码来源:ScaleIntroActivity.java

示例5: onLoadPatchListenerReceiveFail

import com.umeng.analytics.MobclickAgent; //导入依赖的package包/类
public void onLoadPatchListenerReceiveFail(final File patchFile, int errorCode, boolean
        isUpgrade) {
    super.onLoadPatchListenerReceiveFail(patchFile, errorCode, isUpgrade);
    switch (errorCode) {
        case -6:
            MobclickAgent.onEvent(MyApplication.getContext(), Event.tinker_error_no_space);
            break;
        case -3:
            if (isUpgrade) {
                this.handler.postDelayed(new Runnable() {
                    public void run() {
                        TinkerInstaller.onReceiveUpgradePatch(SampleLoadReporter.this
                                .context, patchFile.getAbsolutePath());
                    }
                }, 60000);
                break;
            }
            break;
        case -2:
            MobclickAgent.onEvent(MyApplication.getContext(), Event.tinker_error_patch_noexits);
            break;
    }
    SampleTinkerReport.onTryApplyFail(errorCode);
}
 
开发者ID:JackChan1999,项目名称:boohee_v5.6,代码行数:25,代码来源:SampleLoadReporter.java

示例6: onCreate

import com.umeng.analytics.MobclickAgent; //导入依赖的package包/类
@Override
protected void onCreate(Bundle savedInstanceState) {
	super.onCreate(savedInstanceState);
	//PushAgent.getInstance(this).onAppStart();
	MobclickAgent.openActivityDurationTrack(false);

	getWindow().setSoftInputMode(
			WindowManager.LayoutParams.SOFT_INPUT_STATE_ALWAYS_HIDDEN
	);
	mBaseActivity.init(getBaseContext(), this);
	onActivityInit();
	LogUtil.d(TAG, "checktask onCreate:" + super.getClass().getSimpleName()
			+ "#0x" + super.hashCode() + ", taskid:" + getTaskId()
			+ ", task:" + new ActivityTaskUtils(this));
	abstracrRegist();
	getTopBarView().showSearch(hasSearch());

}
 
开发者ID:NewCasino,项目名称:browser,代码行数:19,代码来源:AppBaseActivity.java

示例7: quit

import com.umeng.analytics.MobclickAgent; //导入依赖的package包/类
public void quit() {
	MobclickAgent.onKillProcess(this);
	MyApp myApp = ((MyApp)getApplication());
	L.i("isAntiTheftServiceStarted:" + myApp.isAntiTheftServiceStarted);
	L.i("isBgdService2Started:" + myApp.isBgdService2Started);
	if (myApp.isAntiTheftServiceStarted || myApp.isBgdService2Started){
		MainActivity.this.finish();
	}else{
		Intent startMain = new Intent(Intent.ACTION_MAIN);
		startMain.addCategory(Intent.CATEGORY_HOME);
		startMain.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK); 
		startActivity(startMain);
		System.exit(0);
	}
	//确认是否在退出后取消接收聊天信息
	SettingSPUtil setSP = MyApp.getInstance().getSettingSPUtil();
	if (!setSP.isChatReceiveMsgAlways()){
		PushManager.stopWork(getApplicationContext());
	}
}
 
开发者ID:SShineTeam,项目名称:Huochexing12306,代码行数:21,代码来源:MainActivity.java

示例8: createActivity

import com.umeng.analytics.MobclickAgent; //导入依赖的package包/类
private void createActivity() {
    if (this.mRecordSport != null) {
        RecordSport record = new SportRecordDao(getActivity()).add(this.mRecordSport);
        dismissAllowingStateLoss();
        if (record != null) {
            EventBus.getDefault().post(new SportEvent().setRecordSport(record).setEditType(1));
        }
        if (this.mRecordSport != null) {
            EventBus.getDefault().post(new AddFinishAnimEvent().setThumb_image_name(this
                    .mRecordSport.thumb_img_url));
        }
        MobclickAgent.onEvent(getActivity(), Event.tool_addSportRecordOK);
        MobclickAgent.onEvent(getActivity(), Event.tool_recordOK);
        if (this.changeListener != null) {
            this.changeListener.onFinish();
        }
    }
}
 
开发者ID:JackChan1999,项目名称:boohee_v5.6,代码行数:19,代码来源:AddSportFragment.java

示例9: recordMc

import com.umeng.analytics.MobclickAgent; //导入依赖的package包/类
private void recordMc(String action, Date day) {
    if (day != null) {
        JsonParams params = new JsonParams();
        params.put("record_on", DateHelper.format(day));
        if (McLatest.ACTION_START.equals(action)) {
            params.put("mc_status", "1");
        } else if (McLatest.ACTION_END.equals(action)) {
            params.put("mc_status", "2");
        }
        RecordApi.postMcRecords(this.activity, params, new JsonCallback(this.activity) {
            public void ok(JSONObject object) {
                super.ok(object);
                if (!PeriodCalendarActivity.this.isFinishing()) {
                    PeriodCalendarActivity.this.requestRecords();
                    PeriodCalendarActivity.this.setResult(-1);
                    EventBus.getDefault().post(new PeriodEvent());
                    MobclickAgent.onEvent(PeriodCalendarActivity.this.ctx, Event
                            .tool_updateMcRecordOK);
                    MobclickAgent.onEvent(PeriodCalendarActivity.this.ctx, Event.tool_recordOK);
                }
            }
        });
    }
}
 
开发者ID:JackChan1999,项目名称:boohee_v5.6,代码行数:25,代码来源:PeriodCalendarActivity.java

示例10: onClick

import com.umeng.analytics.MobclickAgent; //导入依赖的package包/类
@OnClick({2131427869, 2131427870, 2131427871, 2131427876, 2131427862})
public void onClick(View view) {
    switch (view.getId()) {
        case R.id.view_load_more:
            sendSearchRequest(false);
            return;
        case R.id.view_search_topic:
            SearcherOtherActivity.comeOnBaby(this.ctx, Type.topic);
            MobclickAgent.onEvent(this.ctx, Event.other_clickSearchTopic);
            return;
        case R.id.view_search_article:
            MobclickAgent.onEvent(this.ctx, Event.other_clickSearchContent);
            SearcherOtherActivity.comeOnBaby(this.ctx, Type.article);
            return;
        case R.id.view_search_user:
            MobclickAgent.onEvent(this.ctx, Event.ohter_clickSearchUser);
            SearchFriendsActivity.comeOnBaby(this.ctx);
            return;
        case R.id.tv_search_alert:
            sendSearchRequest(false);
            return;
        default:
            return;
    }
}
 
开发者ID:JackChan1999,项目名称:boohee_v5.6,代码行数:26,代码来源:SearcherActivity.java

示例11: onEvent

import com.umeng.analytics.MobclickAgent; //导入依赖的package包/类
public static void onEvent(Context arg0, String arg1, String arg2)
{
	if (!DEBUG)
	{
		MobclickAgent.onEvent(arg0, arg1, arg2);
	}
}
 
开发者ID:benniaobuguai,项目名称:android-project-gallery,代码行数:8,代码来源:MobclickAgentProxy.java

示例12: onResume

import com.umeng.analytics.MobclickAgent; //导入依赖的package包/类
@Override
protected void onResume() {
	super.onResume();
	//未读消息数清零
	MyApp.getInstance().setNewMsgCount(0);
	MobclickAgent.onResume(this);
}
 
开发者ID:SShineTeam,项目名称:Huochexing12306,代码行数:8,代码来源:ChatRoomAty.java

示例13: onCreate

import com.umeng.analytics.MobclickAgent; //导入依赖的package包/类
public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.a4);
    MobclickAgent.onEvent(this, Event.STATUS_VIEW_MESSAGE_CATE);
    setTitle(R.string.su);
    findViews();
    initData();
}
 
开发者ID:JackChan1999,项目名称:boohee_v5.6,代码行数:9,代码来源:MsgCategoryActivity.java

示例14: onCreate

import com.umeng.analytics.MobclickAgent; //导入依赖的package包/类
public void onCreate(Bundle outState) {
    super.onCreate(outState);
    setContentView(R.layout.kj);
    MobclickAgent.onEvent(this, Event.STATUS_VIEW_MESSAGE_LST);
    setTitle(getStringExtra(EXTRA_TITLE));
    this.mUserId = getIntent().getIntExtra("user_id", 0);
    this.isRead = getIntent().getBooleanExtra("isRead", true);
    this.mType = getStringExtra("type");
    init();
    PullToRefreshHelper.loadFirst(this);
}
 
开发者ID:JackChan1999,项目名称:boohee_v5.6,代码行数:12,代码来源:NotificationActivity.java

示例15: onResume

import com.umeng.analytics.MobclickAgent; //导入依赖的package包/类
@Override
protected void onResume() {
    super.onResume();
    if (isCountingPage()) {
        countingPageStart();
    }
    MobclickAgent.onResume(this);
}
 
开发者ID:z-chu,项目名称:FriendBook,代码行数:9,代码来源:BaseSuperActivity.java


注:本文中的com.umeng.analytics.MobclickAgent类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。