Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
android_highgold
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_highgold
Commits
6d6902f1
Commit
6d6902f1
authored
Jun 30, 2020
by
mengcuiguang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加阅读赚钱
parent
3555a778
Changes
10
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
1244 additions
and
6 deletions
+1244
-6
build.gradle
highgold/app/build.gradle
+5
-0
AndroidManifest.xml
highgold/app/src/main/AndroidManifest.xml
+1
-0
MintsApplication.java
...pp/src/main/java/com/mints/highgold/MintsApplication.java
+25
-0
WxLoginPresenter.java
...a/com/mints/highgold/mvp/presenters/WxLoginPresenter.java
+61
-1
LoanService.java
...app/src/main/java/com/mints/highgold/net/LoanService.java
+8
-0
AdWebActivity.java
...n/java/com/mints/highgold/ui/activitys/AdWebActivity.java
+1068
-0
WxLoginActivity.java
...java/com/mints/highgold/ui/activitys/WxLoginActivity.java
+1
-4
MainFragment.java
...ain/java/com/mints/highgold/ui/fragment/MainFragment.java
+3
-1
SystemUtils.java
...p/src/main/java/com/mints/highgold/utils/SystemUtils.java
+29
-0
activity_adweb.xml
highgold/app/src/main/res/layout/activity_adweb.xml
+43
-0
No files found.
highgold/app/build.gradle
View file @
6d6902f1
...
@@ -242,6 +242,7 @@ dependencies {
...
@@ -242,6 +242,7 @@ dependencies {
implementation
(
name:
'x5fit-1.2.2'
,
ext:
'aar'
)
implementation
(
name:
'x5fit-1.2.2'
,
ext:
'aar'
)
implementation
(
name:
'gdtfit-1.2.2'
,
ext:
'aar'
)
implementation
(
name:
'gdtfit-1.2.2'
,
ext:
'aar'
)
implementation
files
(
"libs/qq_x5.jar"
)
implementation
files
(
"libs/qq_x5.jar"
)
// 鱼丸盒子
// 鱼丸盒子
implementation
(
name:
'xzzq_ywsdk_1.0.6'
,
ext:
'aar'
)
implementation
(
name:
'xzzq_ywsdk_1.0.6'
,
ext:
'aar'
)
implementation
"org.jetbrains.kotlin:kotlin-stdlib-jdk7:1.3.41"
implementation
"org.jetbrains.kotlin:kotlin-stdlib-jdk7:1.3.41"
...
@@ -305,6 +306,10 @@ dependencies {
...
@@ -305,6 +306,10 @@ dependencies {
// 多盟
// 多盟
implementation
(
name:
'domob_rvads_1.0.0'
,
ext:
'aar'
)
implementation
(
name:
'domob_rvads_1.0.0'
,
ext:
'aar'
)
implementation
'com.google.protobuf:protobuf-lite:3.0.0'
implementation
'com.google.protobuf:protobuf-lite:3.0.0'
// 酷问新闻
// implementation 'com.tencent.tbs.tbssdk:sdk:43903'
implementation
'com.liulishuo.filedownloader:library:1.7.4'
testImplementation
'junit:junit:4.12'
testImplementation
'junit:junit:4.12'
...
...
highgold/app/src/main/AndroidManifest.xml
View file @
6d6902f1
...
@@ -151,6 +151,7 @@
...
@@ -151,6 +151,7 @@
<activity
android:name=
".ui.activitys.SettingActivity"
/>
<activity
android:name=
".ui.activitys.SettingActivity"
/>
<activity
android:name=
".ui.activitys.PhoneActivity"
/>
<activity
android:name=
".ui.activitys.PhoneActivity"
/>
<activity
android:name=
".ui.activitys.EraseActivity"
/>
<activity
android:name=
".ui.activitys.EraseActivity"
/>
<activity
android:name=
".ui.activitys.AdWebActivity"
/>
<activity
<activity
android:name=
".ui.activitys.WebActivity"
android:name=
".ui.activitys.WebActivity"
android:windowSoftInputMode=
"adjustResize"
/>
android:windowSoftInputMode=
"adjustResize"
/>
...
...
highgold/app/src/main/java/com/mints/highgold/MintsApplication.java
View file @
6d6902f1
...
@@ -18,6 +18,7 @@ import com.component.dly.xzzq_ywsdk.YwSDK;
...
@@ -18,6 +18,7 @@ import com.component.dly.xzzq_ywsdk.YwSDK;
import
com.downloader.PRDownloader
;
import
com.downloader.PRDownloader
;
import
com.downloader.PRDownloaderConfig
;
import
com.downloader.PRDownloaderConfig
;
import
com.lechuan.midunovel.view.FoxSDK
;
import
com.lechuan.midunovel.view.FoxSDK
;
import
com.liulishuo.filedownloader.FileDownloader
;
import
com.mintegral.msdk.MIntegralSDK
;
import
com.mintegral.msdk.MIntegralSDK
;
import
com.mintegral.msdk.out.MIntegralSDKFactory
;
import
com.mintegral.msdk.out.MIntegralSDKFactory
;
import
com.mints.highgold.common.AppConfig
;
import
com.mints.highgold.common.AppConfig
;
...
@@ -43,6 +44,7 @@ import com.orhanobut.logger.FormatStrategy;
...
@@ -43,6 +44,7 @@ import com.orhanobut.logger.FormatStrategy;
import
com.orhanobut.logger.Logger
;
import
com.orhanobut.logger.Logger
;
import
com.orhanobut.logger.PrettyFormatStrategy
;
import
com.orhanobut.logger.PrettyFormatStrategy
;
import
com.tencent.ep.shanhuad.adpublic.ShanHuAD
;
import
com.tencent.ep.shanhuad.adpublic.ShanHuAD
;
import
com.tencent.smtt.sdk.QbSdk
;
import
com.tendcloud.tenddata.TCAgent
;
import
com.tendcloud.tenddata.TCAgent
;
import
com.tmsdk.module.coin.AbsTMSConfig
;
import
com.tmsdk.module.coin.AbsTMSConfig
;
import
com.tmsdk.module.coin.TMSDKContext
;
import
com.tmsdk.module.coin.TMSDKContext
;
...
@@ -159,6 +161,9 @@ public class MintsApplication extends MultiDexApplication {
...
@@ -159,6 +161,9 @@ public class MintsApplication extends MultiDexApplication {
//移动安装联盟 获取OAID等设备标识符
//移动安装联盟 获取OAID等设备标识符
initMiitHelper
();
initMiitHelper
();
// 酷问新闻
initPipi
();
// 机型适配
// 机型适配
initRudenessScreen
();
initRudenessScreen
();
...
@@ -236,6 +241,7 @@ public class MintsApplication extends MultiDexApplication {
...
@@ -236,6 +241,7 @@ public class MintsApplication extends MultiDexApplication {
// 极光一键登录
// 极光一键登录
initJLogin
();
initJLogin
();
}
}
/**
/**
...
@@ -479,6 +485,25 @@ public class MintsApplication extends MultiDexApplication {
...
@@ -479,6 +485,25 @@ public class MintsApplication extends MultiDexApplication {
});
});
}
}
/**
* 酷问新闻
*/
private
void
initPipi
()
{
FileDownloader
.
setup
(
this
);
QbSdk
.
PreInitCallback
cb
=
new
QbSdk
.
PreInitCallback
()
{
@Override
public
void
onViewInitFinished
(
boolean
arg0
)
{
LogUtil
.
d
(
TAG
,
"onViewInitFinished is "
+
arg0
);
}
@Override
public
void
onCoreInitFinished
()
{
}
};
//x5内核初始化接口
QbSdk
.
initX5Environment
(
this
,
cb
);
}
/**
/**
* app退出
* app退出
*/
*/
...
...
highgold/app/src/main/java/com/mints/highgold/mvp/presenters/WxLoginPresenter.java
View file @
6d6902f1
...
@@ -30,7 +30,7 @@ public class WxLoginPresenter extends BasePresenter<WxLoginView> {
...
@@ -30,7 +30,7 @@ public class WxLoginPresenter extends BasePresenter<WxLoginView> {
private
UserBean
.
ConsumerBean
consumer
;
private
UserBean
.
ConsumerBean
consumer
;
/**
/**
* 登录
*
微信
登录
*/
*/
public
void
login
(
Context
context
,
String
wxInfo
)
{
public
void
login
(
Context
context
,
String
wxInfo
)
{
view
.
showLoading
(
"加载中..."
);
view
.
showLoading
(
"加载中..."
);
...
@@ -89,6 +89,66 @@ public class WxLoginPresenter extends BasePresenter<WxLoginView> {
...
@@ -89,6 +89,66 @@ public class WxLoginPresenter extends BasePresenter<WxLoginView> {
});
});
}
}
/**
* 极光一键登录
*/
public
void
jPushlogin
(
Context
context
,
String
token
)
{
view
.
showLoading
(
"加载中..."
);
HashMap
<
String
,
Object
>
vo
=
new
HashMap
<>();
try
{
vo
.
put
(
"shumeiId"
,
ShumeiManager
.
getInstance
().
getShumeiDeviceId
());
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
vo
.
put
(
"device"
,
new
DeviceUuidFactory
(
context
).
getDeviceUuid
().
toString
());
vo
.
put
(
"loginToken"
,
token
);
AppHttpManager
.
getInstance
(
loanApplication
)
.
call
(
loanService
.
jPushlogin
(
vo
),
new
BaseSubscriber
<
BaseResponse
<
UserBean
>>()
{
@Override
public
void
onCompleted
()
{
if
(
isLinkView
())
return
;
view
.
hideLoading
();
}
@Override
public
void
onError
(
Throwable
e
)
{
if
(
isLinkView
())
return
;
view
.
hideLoading
();
view
.
showToast
(
e
.
getMessage
());
}
@Override
public
void
onNext
(
BaseResponse
<
UserBean
>
baseResponse
)
{
if
(
isLinkView
())
return
;
int
code
=
baseResponse
.
getStatus
();
String
message
=
baseResponse
.
getMessage
();
UserBean
data
=
baseResponse
.
getData
();
switch
(
code
)
{
case
200
:
//成功
if
(
data
!=
null
)
{
UserManager
.
getInstance
().
saveUserInfo
(
data
);
consumer
=
data
.
getConsumer
();
if
(
consumer
!=
null
)
{
saveTerminalInfo
(
context
);
}
view
.
loginSuc
();
}
break
;
default
:
view
.
showToast
(
message
);
break
;
}
}
});
}
/**
/**
* 提交设备信息
* 提交设备信息
*
*
...
...
highgold/app/src/main/java/com/mints/highgold/net/LoanService.java
View file @
6d6902f1
...
@@ -91,6 +91,14 @@ public interface LoanService {
...
@@ -91,6 +91,14 @@ public interface LoanService {
@POST
(
"api/v125/wechatlogin"
)
@POST
(
"api/v125/wechatlogin"
)
Observable
<
BaseResponse
<
UserBean
>>
wechatlogin
(
@Body
Map
<
String
,
Object
>
vo
);
Observable
<
BaseResponse
<
UserBean
>>
wechatlogin
(
@Body
Map
<
String
,
Object
>
vo
);
/**
* 极光一键登录
*
* @return
*/
@POST
(
"api/v125/JPushlogin"
)
Observable
<
BaseResponse
<
UserBean
>>
jPushlogin
(
@Body
Map
<
String
,
Object
>
vo
);
/**
/**
* 注册极光设备
* 注册极光设备
...
...
highgold/app/src/main/java/com/mints/highgold/ui/activitys/AdWebActivity.java
0 → 100755
View file @
6d6902f1
This diff is collapsed.
Click to expand it.
highgold/app/src/main/java/com/mints/highgold/ui/activitys/WxLoginActivity.java
View file @
6d6902f1
...
@@ -239,10 +239,7 @@ public class WxLoginActivity extends BaseActivity implements WxLoginView, OnLogi
...
@@ -239,10 +239,7 @@ public class WxLoginActivity extends BaseActivity implements WxLoginView, OnLogi
if
(
code
==
6000
)
{
if
(
code
==
6000
)
{
//登录成功
//登录成功
// toSuccessActivity(5,token);
wxLoginPresenter
.
jPushlogin
(
getContext
(),
token
);
showToast
(
"登录成功"
);
readyGo
(
MainActivity
.
class
);
}
else
if
(
code
!=
6002
)
{
}
else
if
(
code
!=
6002
)
{
showToast
(
operator
);
showToast
(
operator
);
}
}
...
...
highgold/app/src/main/java/com/mints/highgold/ui/fragment/MainFragment.java
View file @
6d6902f1
...
@@ -44,6 +44,7 @@ import com.mints.highgold.mvp.model.UserTaskMsgBean;
...
@@ -44,6 +44,7 @@ import com.mints.highgold.mvp.model.UserTaskMsgBean;
import
com.mints.highgold.mvp.model.VedioAdingBean
;
import
com.mints.highgold.mvp.model.VedioAdingBean
;
import
com.mints.highgold.mvp.presenters.LoanPresenter
;
import
com.mints.highgold.mvp.presenters.LoanPresenter
;
import
com.mints.highgold.mvp.views.LoanView
;
import
com.mints.highgold.mvp.views.LoanView
;
import
com.mints.highgold.ui.activitys.AdWebActivity
;
import
com.mints.highgold.ui.activitys.AwardActivity
;
import
com.mints.highgold.ui.activitys.AwardActivity
;
import
com.mints.highgold.ui.activitys.FriendsNewActivity
;
import
com.mints.highgold.ui.activitys.FriendsNewActivity
;
import
com.mints.highgold.ui.activitys.MainActivity
;
import
com.mints.highgold.ui.activitys.MainActivity
;
...
@@ -357,7 +358,8 @@ public class MainFragment extends BaseFragment
...
@@ -357,7 +358,8 @@ public class MainFragment extends BaseFragment
Bundle
bundle
;
Bundle
bundle
;
switch
(
view
.
getId
())
{
switch
(
view
.
getId
())
{
case
R
.
id
.
tv_fragment_main_whatgold
:
// 如何赚金币
case
R
.
id
.
tv_fragment_main_whatgold
:
// 如何赚金币
readyGo
(
WhatGoldActivity
.
class
);
// readyGo(WhatGoldActivity.class);
readyGo
(
AdWebActivity
.
class
);
break
;
break
;
case
R
.
id
.
rl_fragment_main_redbox
:
// 红包
case
R
.
id
.
rl_fragment_main_redbox
:
// 红包
readyGo
(
RedboxActivity
.
class
);
readyGo
(
RedboxActivity
.
class
);
...
...
highgold/app/src/main/java/com/mints/highgold/utils/SystemUtils.java
0 → 100755
View file @
6d6902f1
package
com
.
mints
.
highgold
.
utils
;
import
android.content.Context
;
import
android.content.pm.PackageInfo
;
import
android.content.pm.PackageManager
;
public
class
SystemUtils
{
/**
* @param context
* @param packagename
* @return
*/
public
static
boolean
isAppInstalled
(
Context
context
,
String
packagename
)
{
PackageInfo
packageInfo
;
try
{
packageInfo
=
context
.
getPackageManager
().
getPackageInfo
(
packagename
,
PackageManager
.
GET_UNINSTALLED_PACKAGES
);
}
catch
(
PackageManager
.
NameNotFoundException
e
)
{
packageInfo
=
null
;
e
.
printStackTrace
();
}
if
(
packageInfo
==
null
)
{
//System.out.println("没有安装");
return
false
;
}
else
{
//System.out.println("已经安装");
return
true
;
}
}
}
highgold/app/src/main/res/layout/activity_adweb.xml
0 → 100755
View file @
6d6902f1
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android=
"http://schemas.android.com/apk/res/android"
xmlns:tools=
"http://schemas.android.com/tools"
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
android:orientation=
"vertical"
>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
android:orientation=
"vertical"
>
<Button
android:visibility=
"gone"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:text=
"跳转"
android:id=
"@+id/btn"
/>
<android.support.v4.widget.SwipeRefreshLayout
android:id=
"@+id/swipe_container"
android:layout_width=
"match_parent"
android:layout_height=
"0dp"
android:layout_weight=
"1"
>
<com.tencent.smtt.sdk.WebView
android:id=
"@+id/webview"
android:layout_width=
"match_parent"
android:layout_height=
"0dp"
android:layout_weight=
"1"
tools:context=
"com.ns.pipidemo.AdWebActivity"
>
</com.tencent.smtt.sdk.WebView>
</android.support.v4.widget.SwipeRefreshLayout>
<TextView
android:id=
"@+id/tv_start_download"
android:layout_width=
"match_parent"
android:layout_height=
"44dp"
android:background=
"#f29445"
android:gravity=
"center"
android:text=
"立即下载"
android:textColor=
"#ffffff"
android:textSize=
"15sp"
android:visibility=
"gone"
/>
</LinearLayout>
</LinearLayout>
\ No newline at end of file
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