Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
R
RvApp
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
1
Merge Requests
1
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
lify
RvApp
Commits
0b21bb37
Commit
0b21bb37
authored
Jul 13, 2019
by
linfeng
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bug修复
parent
f2200469
Changes
19
Hide whitespace changes
Inline
Side-by-side
Showing
19 changed files
with
300 additions
and
16 deletions
+300
-16
rv_act_weclome.xml
RvClient/src/main/res/layout/rv_act_weclome.xml
+1
-0
start_backgroud2.png
..._resource/src/main/res/drawable-hdpi/start_backgroud2.png
+0
-0
start_backgroud2.png
..._resource/src/main/res/drawable-ldpi/start_backgroud2.png
+0
-0
start_backgroud2.png
..._resource/src/main/res/drawable-mdpi/start_backgroud2.png
+0
-0
start_backgroud2.png
...resource/src/main/res/drawable-xhdpi/start_backgroud2.png
+0
-0
start_backgroud2.png
...esource/src/main/res/drawable-xxhdpi/start_backgroud2.png
+0
-0
start_backgroud2.png
...source/src/main/res/drawable-xxxhdpi/start_backgroud2.png
+0
-0
AndroidManifest.xml
module_discovery/src/main/AndroidManifest.xml
+4
-1
DiscoveryFragment.java
...y/src/main/java/com/xxfc/discovery/DiscoveryFragment.java
+42
-12
PatFragment.java
...rc/main/java/com/xxfc/discovery/fragment/PatFragment.java
+42
-0
QuestionAndAnswerFragment.java
...om/xxfc/discovery/fragment/QuestionAndAnswerFragment.java
+41
-0
RecommendFragment.java
...n/java/com/xxfc/discovery/fragment/RecommendFragment.java
+3
-1
ShortVideoFragment.java
.../java/com/xxfc/discovery/fragment/ShortVideoFragment.java
+43
-0
AddDiscoveryContentPw.java
...com/xxfc/discovery/popupwindow/AddDiscoveryContentPw.java
+67
-0
fragment_discovery.xml
module_discovery/src/main/res/layout/fragment_discovery.xml
+4
-2
fragment_pat.xml
module_discovery/src/main/res/layout/fragment_pat.xml
+9
-0
fragment_question_and_answer.xml
...very/src/main/res/layout/fragment_question_and_answer.xml
+9
-0
fragment_short_video.xml
...le_discovery/src/main/res/layout/fragment_short_video.xml
+9
-0
pop_add_discovery_content.xml
...scovery/src/main/res/layout/pop_add_discovery_content.xml
+26
-0
No files found.
RvClient/src/main/res/layout/rv_act_weclome.xml
View file @
0b21bb37
...
@@ -5,6 +5,7 @@
...
@@ -5,6 +5,7 @@
android:layout_height=
"match_parent"
android:layout_height=
"match_parent"
android:background=
"@color/colorWrite"
android:background=
"@color/colorWrite"
tools:context=
"com.test.rv.WelcomeActivity"
>
tools:context=
"com.test.rv.WelcomeActivity"
>
<ImageView
<ImageView
android:layout_width=
"wrap_content"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_height=
"wrap_content"
...
...
component_resource/src/main/res/drawable-hdpi/start_backgroud2.png
0 → 100644
View file @
0b21bb37
5.77 KB
component_resource/src/main/res/drawable-ldpi/start_backgroud2.png
0 → 100644
View file @
0b21bb37
2.74 KB
component_resource/src/main/res/drawable-mdpi/start_backgroud2.png
0 → 100644
View file @
0b21bb37
3.56 KB
component_resource/src/main/res/drawable-xhdpi/start_backgroud2.png
View replaced file @
f2200469
View file @
0b21bb37
8.87 KB
|
W:
|
H:
7.35 KB
|
W:
|
H:
2-up
Swipe
Onion skin
component_resource/src/main/res/drawable-xxhdpi/start_backgroud2.png
0 → 100644
View file @
0b21bb37
11.6 KB
component_resource/src/main/res/drawable-xxxhdpi/start_backgroud2.png
0 → 100644
View file @
0b21bb37
14.6 KB
module_discovery/src/main/AndroidManifest.xml
View file @
0b21bb37
...
@@ -3,7 +3,10 @@
...
@@ -3,7 +3,10 @@
package=
"com.xxfc.discovery"
>
package=
"com.xxfc.discovery"
>
<application>
<application>
<activity
android:name=
".fragment.RecommendFragment"
></activity>
<activity
android:name=
".fragment.QuestionAndAnswerFragment"
></activity>
<activity
android:name=
".fragment.ShortVideoFragment"
/>
<activity
android:name=
".fragment.PatFragment"
/>
<activity
android:name=
".fragment.RecommendFragment"
/>
<activity
android:name=
".DiscoveryFragment"
/>
<activity
android:name=
".DiscoveryFragment"
/>
</application>
</application>
...
...
module_discovery/src/main/java/com/xxfc/discovery/DiscoveryFragment.java
View file @
0b21bb37
...
@@ -6,8 +6,9 @@ import android.support.annotation.Nullable;
...
@@ -6,8 +6,9 @@ import android.support.annotation.Nullable;
import
android.support.v4.view.ViewPager
;
import
android.support.v4.view.ViewPager
;
import
android.support.v7.widget.GridLayoutManager
;
import
android.support.v7.widget.GridLayoutManager
;
import
android.support.v7.widget.RecyclerView
;
import
android.support.v7.widget.RecyclerView
;
import
android.view.LayoutInflater
;
import
android.view.View
;
import
android.view.View
;
import
android.view.ViewGroup
;
import
com.chad.library.adapter.base.BaseQuickAdapter
;
import
com.chad.library.adapter.base.BaseQuickAdapter
;
import
com.ruiwenliu.wrapper.adapter.TabAdapter
;
import
com.ruiwenliu.wrapper.adapter.TabAdapter
;
import
com.ruiwenliu.wrapper.base.BaseBean
;
import
com.ruiwenliu.wrapper.base.BaseBean
;
...
@@ -15,33 +16,40 @@ import com.ruiwenliu.wrapper.base.BaseFragment;
...
@@ -15,33 +16,40 @@ import com.ruiwenliu.wrapper.base.BaseFragment;
import
com.ruiwenliu.wrapper.weight.horizontal.GallerySnapHelper
;
import
com.ruiwenliu.wrapper.weight.horizontal.GallerySnapHelper
;
import
com.ruiwenliu.wrapper.weight.horizontal.SpaceItemDecoration
;
import
com.ruiwenliu.wrapper.weight.horizontal.SpaceItemDecoration
;
import
com.xxfc.discovery.adapter.DiscoveryMenuAdapter
;
import
com.xxfc.discovery.adapter.DiscoveryMenuAdapter
;
import
com.xxfc.discovery.fragment.PatFragment
;
import
com.xxfc.discovery.fragment.QuestionAndAnswerFragment
;
import
com.xxfc.discovery.fragment.RecommendFragment
;
import
com.xxfc.discovery.fragment.RecommendFragment
;
import
com.xxfc.discovery.fragment.ShortVideoFragment
;
import
com.xxfc.discovery.presenter.DiscoveryPresenter
;
import
com.xxfc.discovery.presenter.DiscoveryPresenter
;
import
java.util.ArrayList
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.List
;
import
butterknife.BindView
;
import
butterknife.BindView
;
import
butterknife.ButterKnife
;
import
butterknife.OnClick
;
import
butterknife.Unbinder
;
/**
/**
* 发现模块
* 发现模块
*/
*/
public
class
DiscoveryFragment
extends
BaseFragment
<
DiscoveryPresenter
>{
public
class
DiscoveryFragment
extends
BaseFragment
<
DiscoveryPresenter
>
{
@BindView
(
R2
.
id
.
recyclerView
)
@BindView
(
R2
.
id
.
recyclerView
)
RecyclerView
recyclerView
;
RecyclerView
recyclerView
;
@BindView
(
R2
.
id
.
order_viewPager
)
@BindView
(
R2
.
id
.
order_viewPager
)
ViewPager
mViewPager
;
ViewPager
mViewPager
;
Unbinder
unbinder
;
private
DiscoveryMenuAdapter
menuAdapter
;
private
DiscoveryMenuAdapter
menuAdapter
;
private
TabAdapter
mAdapter
;
private
TabAdapter
mAdapter
;
public
final
static
int
TYPE_FOR_PAYMENT
=
0
;
//待付款
public
final
static
int
TYPE_RECOMMEND
=
0
;
//推荐
public
final
static
int
TYPE_TO_TRAVEL
=
1
;
//待出行
public
final
static
int
TYPE_PAT
=
1
;
//拍拍
public
final
static
int
TYPE_HAVE_TO_TRAVEL
=
2
;
//已出行
public
final
static
int
TYPE_SHORT_VIDEO
=
2
;
//短视频
public
final
static
int
TYPE_COMPLETED
=
3
;
//已完成
public
final
static
int
TYPE_QUESTION_AND_ANSWER
=
3
;
//问题
public
final
static
int
TYPE_ALL_ORDER
=
4
;
//全部
private
int
menuPosition
;
private
int
menuPosition
;
public
static
DiscoveryFragment
getInstance
(
int
type
)
{
public
static
DiscoveryFragment
getInstance
(
int
type
)
{
Bundle
bundl
=
new
Bundle
();
Bundle
bundl
=
new
Bundle
();
bundl
.
putInt
(
"type"
,
type
);
bundl
.
putInt
(
"type"
,
type
);
...
@@ -67,7 +75,6 @@ public class DiscoveryFragment extends BaseFragment<DiscoveryPresenter>{
...
@@ -67,7 +75,6 @@ public class DiscoveryFragment extends BaseFragment<DiscoveryPresenter>{
}
}
@Override
@Override
public
void
onShowResult
(
int
requestType
,
BaseBean
result
)
{
public
void
onShowResult
(
int
requestType
,
BaseBean
result
)
{
...
@@ -130,10 +137,10 @@ public class DiscoveryFragment extends BaseFragment<DiscoveryPresenter>{
...
@@ -130,10 +137,10 @@ public class DiscoveryFragment extends BaseFragment<DiscoveryPresenter>{
private
List
<
BaseFragment
>
getListFragment
()
{
private
List
<
BaseFragment
>
getListFragment
()
{
List
<
BaseFragment
>
list
=
new
ArrayList
<>();
List
<
BaseFragment
>
list
=
new
ArrayList
<>();
list
.
add
(
RecommendFragment
.
getInstance
(
TYPE_
FOR_PAYMENT
));
list
.
add
(
RecommendFragment
.
getInstance
(
TYPE_
RECOMMEND
));
list
.
add
(
RecommendFragment
.
getInstance
(
TYPE_TO_TRAVEL
));
list
.
add
(
PatFragment
.
getInstance
(
TYPE_PAT
));
list
.
add
(
RecommendFragment
.
getInstance
(
TYPE_HAVE_TO_TRAVEL
));
list
.
add
(
ShortVideoFragment
.
getInstance
(
TYPE_SHORT_VIDEO
));
list
.
add
(
RecommendFragment
.
getInstance
(
TYPE_COMPLETED
));
list
.
add
(
QuestionAndAnswerFragment
.
getInstance
(
TYPE_QUESTION_AND_ANSWER
));
return
list
;
return
list
;
}
}
...
@@ -153,6 +160,29 @@ public class DiscoveryFragment extends BaseFragment<DiscoveryPresenter>{
...
@@ -153,6 +160,29 @@ public class DiscoveryFragment extends BaseFragment<DiscoveryPresenter>{
}
}
};
};
@Override
public
View
onCreateView
(
LayoutInflater
inflater
,
ViewGroup
container
,
Bundle
savedInstanceState
)
{
// TODO: inflate a fragment view
View
rootView
=
super
.
onCreateView
(
inflater
,
container
,
savedInstanceState
);
unbinder
=
ButterKnife
.
bind
(
this
,
rootView
);
return
rootView
;
}
@Override
public
void
onDestroyView
()
{
super
.
onDestroyView
();
unbinder
.
unbind
();
}
@OnClick
({
R2
.
id
.
iv_discovery_content_add
})
public
void
onViewClicked
(
View
view
)
{
int
id
=
view
.
getId
();
if
(
id
==
R
.
id
.
iv_discovery_content_add
){
//添加
}
}
/******
/******
* 切换事件
* 切换事件
*/
*/
...
...
module_discovery/src/main/java/com/xxfc/discovery/fragment/PatFragment.java
0 → 100644
View file @
0b21bb37
package
com
.
xxfc
.
discovery
.
fragment
;
import
android.os.Bundle
;
import
com.ruiwenliu.wrapper.base.BaseBean
;
import
com.ruiwenliu.wrapper.base.BaseFragment
;
import
com.xxfc.discovery.R
;
import
com.xxfc.discovery.presenter.DiscoveryPresenter
;
/**
* 拍拍
*/
public
class
PatFragment
extends
BaseFragment
<
DiscoveryPresenter
>
{
public
static
PatFragment
getInstance
(
int
type
)
{
Bundle
bundl
=
new
Bundle
();
bundl
.
putInt
(
"type"
,
type
);
PatFragment
fragment
=
new
PatFragment
();
fragment
.
setArguments
(
bundl
);
return
fragment
;
}
@Override
public
int
getViewLayout
()
{
return
R
.
layout
.
fragment_pat
;
}
@Override
protected
void
initView
(
Bundle
savedInstanceState
)
{
}
@Override
protected
void
loadData
(
Bundle
savedInstanceState
)
{
}
@Override
public
void
onShowResult
(
int
requestType
,
BaseBean
result
)
{
}
}
module_discovery/src/main/java/com/xxfc/discovery/fragment/QuestionAndAnswerFragment.java
0 → 100644
View file @
0b21bb37
package
com
.
xxfc
.
discovery
.
fragment
;
import
android.os.Bundle
;
import
com.ruiwenliu.wrapper.base.BaseBean
;
import
com.ruiwenliu.wrapper.base.BaseFragment
;
import
com.xxfc.discovery.R
;
import
com.xxfc.discovery.presenter.DiscoveryPresenter
;
/**
* 问答
*/
public
class
QuestionAndAnswerFragment
extends
BaseFragment
<
DiscoveryPresenter
>
{
public
static
QuestionAndAnswerFragment
getInstance
(
int
type
)
{
Bundle
bundl
=
new
Bundle
();
bundl
.
putInt
(
"type"
,
type
);
QuestionAndAnswerFragment
fragment
=
new
QuestionAndAnswerFragment
();
fragment
.
setArguments
(
bundl
);
return
fragment
;
}
@Override
public
int
getViewLayout
()
{
return
R
.
layout
.
fragment_question_and_answer
;
}
@Override
protected
void
initView
(
Bundle
savedInstanceState
)
{
}
@Override
protected
void
loadData
(
Bundle
savedInstanceState
)
{
}
@Override
public
void
onShowResult
(
int
requestType
,
BaseBean
result
)
{
}
}
module_discovery/src/main/java/com/xxfc/discovery/fragment/RecommendFragment.java
View file @
0b21bb37
package
com
.
xxfc
.
discovery
.
fragment
;
package
com
.
xxfc
.
discovery
.
fragment
;
import
android.os.Bundle
;
import
android.os.Bundle
;
import
com.ruiwenliu.wrapper.base.BaseBean
;
import
com.ruiwenliu.wrapper.base.BaseBean
;
import
com.ruiwenliu.wrapper.base.BaseFragment
;
import
com.ruiwenliu.wrapper.base.BaseFragment
;
import
com.xxfc.discovery.R
;
import
com.xxfc.discovery.R
;
import
com.xxfc.discovery.presenter.DiscoveryPresenter
;
import
com.xxfc.discovery.presenter.DiscoveryPresenter
;
/**
* 推荐
*/
public
class
RecommendFragment
extends
BaseFragment
<
DiscoveryPresenter
>
{
public
class
RecommendFragment
extends
BaseFragment
<
DiscoveryPresenter
>
{
public
static
RecommendFragment
getInstance
(
int
type
)
{
public
static
RecommendFragment
getInstance
(
int
type
)
{
...
...
module_discovery/src/main/java/com/xxfc/discovery/fragment/ShortVideoFragment.java
0 → 100644
View file @
0b21bb37
package
com
.
xxfc
.
discovery
.
fragment
;
import
android.os.Bundle
;
import
com.ruiwenliu.wrapper.base.BaseBean
;
import
com.ruiwenliu.wrapper.base.BaseFragment
;
import
com.xxfc.discovery.R
;
import
com.xxfc.discovery.presenter.DiscoveryPresenter
;
/**
* 短视频
*/
public
class
ShortVideoFragment
extends
BaseFragment
<
DiscoveryPresenter
>
{
public
static
ShortVideoFragment
getInstance
(
int
type
)
{
Bundle
bundl
=
new
Bundle
();
bundl
.
putInt
(
"type"
,
type
);
ShortVideoFragment
fragment
=
new
ShortVideoFragment
();
fragment
.
setArguments
(
bundl
);
return
fragment
;
}
@Override
public
int
getViewLayout
()
{
return
R
.
layout
.
fragment_short_video
;
}
@Override
protected
void
initView
(
Bundle
savedInstanceState
)
{
}
@Override
protected
void
loadData
(
Bundle
savedInstanceState
)
{
}
@Override
public
void
onShowResult
(
int
requestType
,
BaseBean
result
)
{
}
}
module_discovery/src/main/java/com/xxfc/discovery/popupwindow/AddDiscoveryContentPw.java
0 → 100644
View file @
0b21bb37
package
com
.
xxfc
.
discovery
.
popupwindow
;
import
android.app.Activity
;
import
android.graphics.Rect
;
import
android.os.Build
;
import
android.support.annotation.NonNull
;
import
android.support.v7.widget.LinearLayoutManager
;
import
android.support.v7.widget.RecyclerView
;
import
android.view.View
;
import
com.ruiwenliu.wrapper.dialog.BasePopupWindow
;
import
com.ruiwenliu.wrapper.util.ViewHolder
;
import
com.xxfc.discovery.R
;
/**
* 发现增加功能
*/
public
class
AddDiscoveryContentPw
extends
BasePopupWindow
{
public
AddDiscoveryContentPw
(
@NonNull
Activity
context
)
{
super
(
context
);
setOutsideTouchable
(
false
);
}
@Override
public
int
getViewLayout
()
{
return
R
.
layout
.
pop_add_discovery_content
;
}
@Override
public
void
helper
(
ViewHolder
helper
)
{
super
.
helper
(
helper
);
helper
.
setOnClickListener
(
R
.
id
.
fl_dismiss
,
new
View
.
OnClickListener
()
{
@Override
public
void
onClick
(
View
v
)
{
dismiss
();
}
});
RecyclerView
recyclerView
=
helper
.
getView
(
R
.
id
.
recyclerView
);
recyclerView
.
setLayoutManager
(
new
LinearLayoutManager
(
getDialogContext
()));
}
/**
*
* @param anchor v
*/
public
void
showPopupWindow
(
final
View
anchor
)
{
if
(
Build
.
VERSION
.
SDK_INT
>=
24
)
{
Rect
visibleFrame
=
new
Rect
();
anchor
.
getGlobalVisibleRect
(
visibleFrame
);
int
height
=
anchor
.
getResources
().
getDisplayMetrics
().
heightPixels
-
visibleFrame
.
bottom
;
this
.
setHeight
(
height
);
this
.
showAsDropDown
(
anchor
,
0
,
0
);
}
else
{
this
.
showAsDropDown
(
anchor
,
0
,
0
);
}
}
private
void
fullScreenImmersive
(
View
view
)
{
if
(
Build
.
VERSION
.
SDK_INT
>=
Build
.
VERSION_CODES
.
KITKAT
)
{
int
uiOptions
=
View
.
SYSTEM_UI_FLAG_LAYOUT_STABLE
|
View
.
SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION
|
View
.
SYSTEM_UI_FLAG_HIDE_NAVIGATION
|
View
.
SYSTEM_UI_FLAG_IMMERSIVE_STICKY
|
View
.
SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN
|
View
.
SYSTEM_UI_FLAG_FULLSCREEN
;
view
.
setSystemUiVisibility
(
uiOptions
);
}
}
}
module_discovery/src/main/res/layout/fragment_discovery.xml
View file @
0b21bb37
...
@@ -26,8 +26,10 @@
...
@@ -26,8 +26,10 @@
android:layout_height=
"wrap_content"
>
android:layout_height=
"wrap_content"
>
<ImageView
<ImageView
android:layout_width=
"@dimen/size_25"
android:id=
"@+id/iv_discovery_content_add"
android:layout_height=
"@dimen/size_25"
android:layout_width=
"@dimen/size_35"
android:layout_height=
"@dimen/size_35"
android:padding=
"@dimen/size_5"
android:layout_marginRight=
"@dimen/size_15"
android:layout_marginRight=
"@dimen/size_15"
android:src=
"@drawable/discover_ixon_more"
/>
android:src=
"@drawable/discover_ixon_more"
/>
...
...
module_discovery/src/main/res/layout/fragment_pat.xml
0 → 100644
View file @
0b21bb37
<?xml version="1.0" encoding="utf-8"?>
<android.support.constraint.ConstraintLayout
xmlns:android=
"http://schemas.android.com/apk/res/android"
xmlns:app=
"http://schemas.android.com/apk/res-auto"
xmlns:tools=
"http://schemas.android.com/tools"
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
tools:context=
".fragment.PatFragment"
>
</android.support.constraint.ConstraintLayout>
\ No newline at end of file
module_discovery/src/main/res/layout/fragment_question_and_answer.xml
0 → 100644
View file @
0b21bb37
<?xml version="1.0" encoding="utf-8"?>
<android.support.constraint.ConstraintLayout
xmlns:android=
"http://schemas.android.com/apk/res/android"
xmlns:app=
"http://schemas.android.com/apk/res-auto"
xmlns:tools=
"http://schemas.android.com/tools"
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
tools:context=
".fragment.QuestionAndAnswerFragment"
>
</android.support.constraint.ConstraintLayout>
\ No newline at end of file
module_discovery/src/main/res/layout/fragment_short_video.xml
0 → 100644
View file @
0b21bb37
<?xml version="1.0" encoding="utf-8"?>
<android.support.constraint.ConstraintLayout
xmlns:android=
"http://schemas.android.com/apk/res/android"
xmlns:app=
"http://schemas.android.com/apk/res-auto"
xmlns:tools=
"http://schemas.android.com/tools"
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
tools:context=
".fragment.ShortVideoFragment"
>
</android.support.constraint.ConstraintLayout>
\ No newline at end of file
module_discovery/src/main/res/layout/pop_add_discovery_content.xml
0 → 100644
View file @
0b21bb37
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android=
"http://schemas.android.com/apk/res/android"
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
android:orientation=
"vertical"
>
<FrameLayout
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
>
<LinearLayout
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:orientation=
"vertical"
>
</LinearLayout>
</FrameLayout>
<View
android:id=
"@+id/fl_dismiss"
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
/>
</LinearLayout>
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