Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
android_goodmoney
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_goodmoney
Commits
03432d7e
Commit
03432d7e
authored
Feb 05, 2021
by
mengcuiguang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
首页4tab改为平台分红切换,首页添加来电秀,删除微转sdk方式等
parent
bbbb08cd
Changes
12
Show whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
113 additions
and
83 deletions
+113
-83
MainActivity.kt
...ain/java/com/mints/goodmoney/ui/activitys/MainActivity.kt
+6
-6
WebActivity.kt
...main/java/com/mints/goodmoney/ui/activitys/WebActivity.kt
+1
-0
WrapperActivity.kt
.../java/com/mints/goodmoney/ui/activitys/WrapperActivity.kt
+1
-1
FriendsFragment.kt
...n/java/com/mints/goodmoney/ui/fragment/FriendsFragment.kt
+26
-19
MoneyFragment.kt
...ain/java/com/mints/goodmoney/ui/fragment/MoneyFragment.kt
+11
-8
TaskCpdFragment.kt
...n/java/com/mints/goodmoney/ui/fragment/TaskCpdFragment.kt
+10
-2
WzFragment.kt
...c/main/java/com/mints/goodmoney/ui/fragment/WzFragment.kt
+14
-7
activity_web.xml
GoodMoney/app/src/main/res/layout/activity_web.xml
+2
-37
fragment_main_friends.xml
GoodMoney/app/src/main/res/layout/fragment_main_friends.xml
+3
-1
fragment_main_kyl.xml
GoodMoney/app/src/main/res/layout/fragment_main_kyl.xml
+0
-1
fragment_main_wz.xml
GoodMoney/app/src/main/res/layout/fragment_main_wz.xml
+1
-1
web_header_layout.xml
GoodMoney/app/src/main/res/layout/web_header_layout.xml
+38
-0
No files found.
GoodMoney/app/src/main/java/com/mints/goodmoney/ui/activitys/MainActivity.kt
View file @
03432d7e
...
...
@@ -34,7 +34,7 @@ class MainActivity : BaseActivity(), MainView, View.OnClickListener {
private
var
moneyFragment
:
Fragment
?
=
null
private
var
panFragment
:
Fragment
?
=
null
//
private var friendsFragment: Fragment? = null
private
var
friendsFragment
:
Fragment
?
=
null
private
var
myFragment
:
Fragment
?
=
null
private
var
channelFragment
:
Fragment
?
=
null
private
var
kuYinyueFragment
:
Fragment
?
=
null
...
...
@@ -69,8 +69,8 @@ class MainActivity : BaseActivity(), MainView, View.OnClickListener {
tab_tv_four
.
text
=
"新闻分享"
isMainShowWz
=
true
}
else
{
tab_iv_four
.
setImageResource
(
R
.
drawable
.
tab_
bell
_btn
)
tab_tv_four
.
text
=
"
来电秀
"
tab_iv_four
.
setImageResource
(
R
.
drawable
.
tab_
friends
_btn
)
tab_tv_four
.
text
=
"
平台分红
"
isMainShowWz
=
false
}
...
...
@@ -219,10 +219,10 @@ class MainActivity : BaseActivity(), MainView, View.OnClickListener {
addOrShowFragment
(
supportFragmentManager
,
wzFragment
!!
,
Constant
.
FRAGMENT_TAG_FOUR
)
}
else
{
AppConfig
.
fragmentClickFlag
=
Constant
.
FRAGMENT_CLICK_FOUR
if
(
kuYinyue
Fragment
==
null
)
{
kuYinyueFragment
=
KuYinYue
Fragment
()
if
(
friends
Fragment
==
null
)
{
friendsFragment
=
Friends
Fragment
()
}
addOrShowFragment
(
supportFragmentManager
,
kuYinyue
Fragment
!!
,
Constant
.
FRAGMENT_TAG_FOUR
)
addOrShowFragment
(
supportFragmentManager
,
friends
Fragment
!!
,
Constant
.
FRAGMENT_TAG_FOUR
)
}
...
...
GoodMoney/app/src/main/java/com/mints/goodmoney/ui/activitys/WebActivity.kt
View file @
03432d7e
...
...
@@ -13,6 +13,7 @@ import com.mints.goodmoney.manager.DownloadApkManager
import
com.mints.goodmoney.ui.activitys.base.BaseActivity
import
com.mints.goodmoney.utils.CacheUtil
import
kotlinx.android.synthetic.main.activity_web.*
import
kotlinx.android.synthetic.main.web_header_layout.*
/**
* 描述:WebActivity
...
...
GoodMoney/app/src/main/java/com/mints/goodmoney/ui/activitys/WrapperActivity.kt
View file @
03432d7e
...
...
@@ -57,7 +57,7 @@ class WrapperActivity : BaseActivity(), View.OnClickListener {
}
Constant
.
WRAPPER_TYPE_FRIENDS
->
{
tv_title
.
text
=
"瓜分百万现金福利"
currentFragment
=
FriendsFragment
()
currentFragment
=
FriendsFragment
(
true
)
}
Constant
.
WRAPPER_TYPE_KYL
->
{
tv_title
.
text
=
"来电秀"
...
...
GoodMoney/app/src/main/java/com/mints/goodmoney/ui/fragment/FriendsFragment.kt
View file @
03432d7e
...
...
@@ -12,6 +12,7 @@ import androidx.viewpager.widget.ViewPager
import
com.daimajia.androidanimations.library.Techniques
import
com.daimajia.androidanimations.library.YoYo
import
com.mints.goodmoney.R
import
com.mints.goodmoney.common.AppConfig
import
com.mints.goodmoney.common.Constant
import
com.mints.goodmoney.manager.UserManager
import
com.mints.goodmoney.mvp.model.FriendHallMsgBean
...
...
@@ -41,7 +42,7 @@ import java.math.BigDecimal
* 时间:2020/9/20 17:30
*/
@SuppressLint
(
"SetTextI18n"
)
class
FriendsFragment
:
BaseFragment
(),
FriendsView
,
OnRefreshListener
,
View
.
OnClickListener
{
class
FriendsFragment
(
private
var
isResume
:
Boolean
=
false
)
:
BaseFragment
(),
FriendsView
,
OnRefreshListener
,
View
.
OnClickListener
{
private
val
friendsPresenter
by
lazy
{
FriendsPresenter
()
}
...
...
@@ -75,6 +76,12 @@ class FriendsFragment : BaseFragment(), FriendsView, OnRefreshListener, View.OnC
friendsPresenter
.
attachView
(
this
)
srl_my
.
setOnRefreshListener
(
this
)
if
(
isResume
)
{
friendsLayout
.
visibility
=
View
.
GONE
}
else
{
friendsLayout
.
visibility
=
View
.
VISIBLE
}
initView
()
initRecy
()
}
...
...
@@ -158,7 +165,7 @@ class FriendsFragment : BaseFragment(), FriendsView, OnRefreshListener, View.OnC
override
fun
onResume
()
{
super
.
onResume
()
// if (AppConfig.fragmentClickFlag == Constant.FRAGMENT_CLICK_FRIENDS
) {
if
(
AppConfig
.
fragmentClickFlag
==
Constant
.
FRAGMENT_CLICK_FOUR
||
isResume
)
{
if
(!
TextUtils
.
isEmpty
(
UserManager
.
getInstance
().
userID
))
{
// 刷新分红数据
friendsPresenter
.
getFriendHallMsg
()
...
...
@@ -181,7 +188,7 @@ class FriendsFragment : BaseFragment(), FriendsView, OnRefreshListener, View.OnC
showRedbox
(
btn_get_bonus
)
}
}
//
}
}
}
override
fun
onPause
()
{
...
...
GoodMoney/app/src/main/java/com/mints/goodmoney/ui/fragment/MoneyFragment.kt
View file @
03432d7e
...
...
@@ -31,7 +31,7 @@ class MoneyFragment : BaseFragment(), XTabLayout.OnTabSelectedListener {
// private var newsFragment: Fragment? = null
private
var
xmlyGameFragment
:
Fragment
?
=
null
private
var
liebaoGameFragment
:
Fragment
?
=
null
//
private var kuYinyueFragment: Fragment? = null
private
var
kuYinyueFragment
:
Fragment
?
=
null
private
var
curPosition
=
0
//当前标签选中的下标
...
...
@@ -76,7 +76,7 @@ class MoneyFragment : BaseFragment(), XTabLayout.OnTabSelectedListener {
currentFragment
=
mainFragment
}
xtFragmentMoney
.
setxTabDisplayNum
(
4
)
xtFragmentMoney
.
setxTabDisplayNum
(
5
)
val
newTab1
=
xtFragmentMoney
.
newTab
()
newTab1
.
text
=
"视频"
val
newTab2
=
xtFragmentMoney
.
newTab
()
...
...
@@ -87,11 +87,14 @@ class MoneyFragment : BaseFragment(), XTabLayout.OnTabSelectedListener {
newTab4
.
text
=
"听书"
val
newTab5
=
xtFragmentMoney
.
newTab
()
newTab5
.
text
=
"游戏"
val
newTab6
=
xtFragmentMoney
.
newTab
()
newTab6
.
text
=
"来电秀"
xtFragmentMoney
.
addTab
(
newTab1
)
xtFragmentMoney
.
addTab
(
newTab2
)
// xtFragmentMoney.addTab(newTab3)
xtFragmentMoney
.
addTab
(
newTab4
)
xtFragmentMoney
.
addTab
(
newTab5
)
xtFragmentMoney
.
addTab
(
newTab6
)
xtFragmentMoney
.
addOnTabSelectedListener
(
this
)
}
else
{
...
...
@@ -218,12 +221,12 @@ class MoneyFragment : BaseFragment(), XTabLayout.OnTabSelectedListener {
}
addOrShowFragment
(
childFragmentManager
,
liebaoGameFragment
!!
,
FRAGMENT_TAG_GAME
)
}
// 3
-> {
//
if (kuYinyueFragment == null) {
//
kuYinyueFragment = KuYinYueFragment()
//
}
//
addOrShowFragment(childFragmentManager, kuYinyueFragment!!, FRAGMENT_TAG_KYL)
//
}
4
->
{
if
(
kuYinyueFragment
==
null
)
{
kuYinyueFragment
=
KuYinYueFragment
()
}
addOrShowFragment
(
childFragmentManager
,
kuYinyueFragment
!!
,
FRAGMENT_TAG_KYL
)
}
}
curPosition
=
tab
.
position
}
...
...
GoodMoney/app/src/main/java/com/mints/goodmoney/ui/fragment/TaskCpdFragment.kt
View file @
03432d7e
...
...
@@ -8,6 +8,7 @@ import android.os.Bundle
import
android.text.TextUtils
import
android.view.View
import
androidx.recyclerview.widget.GridLayoutManager
import
com.mints.goodmoney.BuildConfig
import
com.mints.goodmoney.R
import
com.mints.goodmoney.ad.download.CoralDownload
import
com.mints.goodmoney.common.AppConfig
...
...
@@ -179,6 +180,14 @@ class TaskCpdFragment : BaseFragment(), TaskView,
override
fun
getCpdModelSuc
(
dataBean
:
CpdModelBean
.
DataBean
)
{
for
(
material
in
dataBean
.
materials
)
{
// 校验包名、下载apk为空 跳过
if
(
TextUtils
.
isEmpty
(
material
.
app_apk_name
)
||
TextUtils
.
isEmpty
(
material
.
app_url
))
{
if
(
BuildConfig
.
DEBUG
)
{
LogUtil
.
d
(
TAG
,
"syd getCpdModelSuc 校验包名、下载apk为空 跳过${dataBean.uuid}"
)
}
continue
}
val
tzTaskBean
=
TzTaskBean
(
material
.
icons
,
material
.
description
,
material
.
title
,
false
,
mCoin
,
0
,
material
.
app_apk_name
)
tzTaskBean
.
app_url
=
material
.
app_url
tzTaskBean
.
trackerBean
=
material
.
tracker
...
...
@@ -245,8 +254,7 @@ class TaskCpdFragment : BaseFragment(), TaskView,
if
(
flag
)
{
// 添加未安装app
if
(!
TextUtils
.
isEmpty
(
mFakeTaskList
[
i
].
downLoadPkgName
)
&&
!
DeviceInfo
.
instance
.
isLoadingPkg
(
mFakeTaskList
[
i
].
downLoadPkgName
))
{
if
(!
TextUtils
.
isEmpty
(
mFakeTaskList
[
i
].
downLoadPkgName
)
&&
!
DeviceInfo
.
instance
.
isLoadingPkg
(
mFakeTaskList
[
i
].
downLoadPkgName
))
{
cpdLoadCountTime
--
newPkgData
.
add
(
mFakeTaskList
[
i
])
}
...
...
GoodMoney/app/src/main/java/com/mints/goodmoney/ui/fragment/WzFragment.kt
View file @
03432d7e
...
...
@@ -18,7 +18,7 @@ import com.mints.goodmoney.mvp.views.BaseView
import
com.mints.goodmoney.ui.fragment.base.BaseFragment
import
com.mints.goodmoney.utils.ToastUtil
import
kotlinx.android.synthetic.main.fragment_main_wz.*
import
kotlinx.android.synthetic.main.header_layout.*
import
kotlinx.android.synthetic.main.
web_
header_layout.*
import
java.lang.StringBuilder
import
java.util.HashMap
...
...
@@ -35,13 +35,20 @@ class WzFragment(private var isResume: Boolean = false) : BaseFragment(), BaseVi
override
fun
getContentViewLayoutID
()
=
R
.
layout
.
fragment_main_wz
override
fun
initViewsAndEvents
()
{
tv_title
.
text
=
"新闻分享"
iv_left_icon
.
visibility
=
View
.
VISIBLE
iv_left_icon
.
setImageResource
(
R
.
mipmap
.
ic_arrow_back
)
iv_left_icon
.
setOnClickListener
{
tv_activity_title
.
text
=
"新闻分享"
tv_activity_back
.
setOnClickListener
{
blTurntableWebview
.
goBack
()
}
if
(
isResume
)
{
//包装页进入
iv_activity_quit
.
visibility
=
View
.
VISIBLE
iv_activity_quit
.
setOnClickListener
{
activity
?.
finish
()
}
}
else
{
iv_activity_quit
.
visibility
=
View
.
GONE
}
}
override
fun
onHiddenChanged
(
hidden
:
Boolean
)
{
...
...
@@ -55,7 +62,7 @@ class WzFragment(private var isResume: Boolean = false) : BaseFragment(), BaseVi
override
fun
onResume
()
{
super
.
onResume
()
if
(
AppConfig
.
fragmentClickFlag
==
Constant
.
FRAGMENT_CLICK_FOUR
||
isResume
)
{
if
(
AppConfig
.
fragmentClickFlag
==
Constant
.
FRAGMENT_CLICK_FOUR
||
isResume
)
{
if
(
TextUtils
.
isEmpty
(
userManager
?.
userID
))
{
// 游客登录
...
...
GoodMoney/app/src/main/res/layout/activity_web.xml
View file @
03432d7e
...
...
@@ -4,48 +4,13 @@
android:layout_height=
"match_parent"
android:orientation=
"vertical"
>
<RelativeLayout
android:layout_width=
"match_parent"
android:layout_height=
"50dp"
android:layout_marginTop=
"20dp"
>
<ImageView
android:id=
"@+id/tv_activity_back"
android:layout_width=
"50dp"
android:layout_height=
"50dp"
android:layout_centerVertical=
"true"
android:padding=
"10dp"
android:src=
"@mipmap/ic_arrow_back"
/>
<ImageView
android:id=
"@+id/iv_activity_quit"
android:layout_width=
"50dp"
android:layout_height=
"50dp"
android:layout_centerVertical=
"true"
android:layout_toEndOf=
"@id/tv_activity_back"
android:padding=
"12dp"
android:src=
"@mipmap/ic_close"
/>
<TextView
android:id=
"@+id/tv_activity_title"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_centerInParent=
"true"
android:textColor=
"@color/color_121B32"
android:textSize=
"16sp"
/>
<View
android:layout_width=
"match_parent"
android:layout_height=
"1dp"
android:layout_alignParentBottom=
"true"
android:background=
"@color/color_E6E6E6"
/>
</RelativeLayout>
<include
layout=
"@layout/web_header_layout"
/>
<ProgressBar
android:id=
"@+id/pb_web"
style=
"?android:attr/progressBarStyleHorizontal"
android:layout_width=
"match_parent"
android:layout_height=
"2
pt
"
android:layout_height=
"2
dp
"
android:background=
"@null"
android:indeterminateOnly=
"false"
android:max=
"100"
...
...
GoodMoney/app/src/main/res/layout/fragment_main_friends.xml
View file @
03432d7e
...
...
@@ -5,7 +5,9 @@
android:layout_height=
"match_parent"
android:orientation=
"vertical"
>
<include
layout=
"@layout/header_layout"
<include
android:id=
"@+id/friendsLayout"
layout=
"@layout/header_layout"
android:visibility=
"gone"
/>
<com.scwang.smartrefresh.layout.SmartRefreshLayout
...
...
GoodMoney/app/src/main/res/layout/fragment_main_kyl.xml
View file @
03432d7e
...
...
@@ -7,7 +7,6 @@
<com.androidkun.xtablayout.XTabLayout
android:id=
"@+id/xtFragmentKyl"
android:paddingTop=
"14dp"
android:visibility=
"invisible"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
...
...
GoodMoney/app/src/main/res/layout/fragment_main_wz.xml
View file @
03432d7e
...
...
@@ -4,7 +4,7 @@
android:orientation=
"vertical"
android:layout_height=
"match_parent"
>
<include
layout=
"@layout/header_layout"
/>
<include
layout=
"@layout/
web_
header_layout"
/>
<WebView
android:id=
"@+id/blTurntableWebview"
...
...
GoodMoney/app/src/main/res/layout/web_header_layout.xml
0 → 100644
View file @
03432d7e
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout
xmlns:android=
"http://schemas.android.com/apk/res/android"
xmlns:app=
"http://schemas.android.com/apk/res-auto"
android:layout_width=
"match_parent"
android:layout_height=
"50dp"
android:layout_marginTop=
"20dp"
>
<ImageView
android:id=
"@+id/tv_activity_back"
android:layout_width=
"50dp"
android:layout_height=
"50dp"
android:layout_centerVertical=
"true"
android:padding=
"10dp"
android:src=
"@mipmap/ic_arrow_back"
/>
<ImageView
android:id=
"@+id/iv_activity_quit"
android:layout_width=
"50dp"
android:layout_height=
"50dp"
android:layout_centerVertical=
"true"
android:layout_toEndOf=
"@id/tv_activity_back"
android:padding=
"12dp"
android:src=
"@mipmap/ic_close"
/>
<TextView
android:id=
"@+id/tv_activity_title"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_centerInParent=
"true"
android:textColor=
"@color/color_121B32"
android:textSize=
"16sp"
/>
<View
android:layout_width=
"match_parent"
android:layout_height=
"1dp"
android:layout_alignParentBottom=
"true"
android:background=
"@color/color_E6E6E6"
/>
</RelativeLayout>
\ 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