Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
android_vedio
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
android
android_vedio
Commits
00fe50da
Commit
00fe50da
authored
Aug 10, 2023
by
mengcuiguang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
代码优化
parent
f37b9415
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
17 additions
and
4 deletions
+17
-4
MintsApplication.java
...p/src/main/java/com/mints/helivideo/MintsApplication.java
+4
-4
UmengManager.kt
...src/main/java/com/mints/helivideo/manager/UmengManager.kt
+9
-0
BaseAppCompatActivity.java
...in/java/com/mints/library/base/BaseAppCompatActivity.java
+4
-0
No files found.
video/app/src/main/java/com/mints/helivideo/MintsApplication.java
View file @
00fe50da
...
...
@@ -53,10 +53,10 @@ public class MintsApplication extends MultiDexApplication {
super
.
onCreate
();
mContext
=
this
.
getApplicationContext
();
//
// 友盟SDK预初始化函数
//
// preInit预初始化函数耗时极少,不会影响App首次冷启动用户体验
//
UmengManager.INSTANCE.preInit(this,
//
MateUtils.INSTANCE.getAppMetaData(this, "CHANNEL_NAME"));
// 友盟SDK预初始化函数
// preInit预初始化函数耗时极少,不会影响App首次冷启动用户体验
UmengManager
.
INSTANCE
.
preInit
(
this
,
MateUtils
.
INSTANCE
.
getAppMetaData
(
this
,
"CHANNEL_NAME"
));
// 判断应用是否在前台
ForegroundOrBackground
.
init
(
this
);
...
...
video/app/src/main/java/com/mints/helivideo/manager/UmengManager.kt
View file @
00fe50da
package
com.mints.helivideo.manager
import
android.app.Application
import
android.content.Context
import
com.mints.helivideo.BuildConfig
import
com.mints.helivideo.utils.MateUtils
import
com.umeng.analytics.MobclickAgent
...
...
@@ -40,4 +41,12 @@ object UmengManager {
}
}
fun
onResume
(
context
:
Context
)
{
MobclickAgent
.
onResume
(
context
)
}
fun
onPause
(
context
:
Context
)
{
MobclickAgent
.
onPause
(
context
)
}
}
\ No newline at end of file
video/app/src/main/java/com/mints/library/base/BaseAppCompatActivity.java
View file @
00fe50da
...
...
@@ -15,6 +15,7 @@ import android.view.Window;
import
android.view.WindowManager
;
import
com.google.android.material.snackbar.Snackbar
;
import
com.mints.helivideo.manager.UmengManager
;
import
com.mints.library.utils.CommonUtils
;
import
com.mints.helivideo.R
;
import
com.readystatesoftware.systembartint.SystemBarTintManager
;
...
...
@@ -106,12 +107,15 @@ public abstract class BaseAppCompatActivity extends TransitionActivity {
@Override
protected
void
onResume
()
{
super
.
onResume
();
UmengManager
.
INSTANCE
.
onResume
(
this
);
}
@Override
protected
void
onPause
()
{
super
.
onPause
();
UmengManager
.
INSTANCE
.
onPause
(
this
);
}
@Override
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment