├── app
├── .gitignore
├── src
│ ├── main
│ │ ├── res
│ │ │ ├── values
│ │ │ │ ├── strings.xml
│ │ │ │ ├── colors.xml
│ │ │ │ └── styles.xml
│ │ │ ├── drawable-xhdpi
│ │ │ │ ├── ic_app.png
│ │ │ │ ├── welcome.png
│ │ │ │ ├── ic_refresh.png
│ │ │ │ ├── place_holder.png
│ │ │ │ ├── tecent_holder.png
│ │ │ │ └── widget_preview.jpg
│ │ │ ├── mipmap-hdpi
│ │ │ │ ├── ic_launcher.png
│ │ │ │ └── ic_launcher_round.png
│ │ │ ├── mipmap-mdpi
│ │ │ │ ├── ic_launcher.png
│ │ │ │ └── ic_launcher_round.png
│ │ │ ├── mipmap-xhdpi
│ │ │ │ ├── ic_launcher.png
│ │ │ │ └── ic_launcher_round.png
│ │ │ ├── mipmap-xxhdpi
│ │ │ │ ├── ic_launcher.png
│ │ │ │ └── ic_launcher_round.png
│ │ │ ├── mipmap-xxxhdpi
│ │ │ │ ├── ic_launcher.png
│ │ │ │ └── ic_launcher_round.png
│ │ │ ├── xml
│ │ │ │ └── widget_info.xml
│ │ │ ├── layout
│ │ │ │ ├── fragment_tencent.xml
│ │ │ │ ├── fragment_pullload.xml
│ │ │ │ ├── fragment_staggered.xml
│ │ │ │ ├── activity_welcome.xml
│ │ │ │ ├── activity_web.xml
│ │ │ │ ├── fragment_home_banner.xml
│ │ │ │ ├── widget_layout.xml
│ │ │ │ ├── fragment_home_ad.xml
│ │ │ │ ├── fragment_grid.xml
│ │ │ │ ├── fragment_news.xml
│ │ │ │ ├── fragment_home_third.xml
│ │ │ │ ├── third_grid_layout.xml
│ │ │ │ ├── toolbar_title_layout.xml
│ │ │ │ ├── activity_main.xml
│ │ │ │ ├── list_grid_layout.xml
│ │ │ │ ├── staggered_item_layout.xml
│ │ │ │ ├── fragment_home_list.xml
│ │ │ │ ├── news_grid_item_layout.xml
│ │ │ │ ├── news_item_layout.xml
│ │ │ │ └── fragment_home_category.xml
│ │ │ └── drawable
│ │ │ │ └── progress_bar.xml
│ │ ├── java
│ │ │ └── com
│ │ │ │ └── huaqin
│ │ │ │ └── recyclerviewdemo
│ │ │ │ ├── core
│ │ │ │ ├── view
│ │ │ │ │ ├── BaseView.java
│ │ │ │ │ ├── WelcomeActivity.java
│ │ │ │ │ ├── adapter
│ │ │ │ │ │ ├── MainFragmentPagerAdapter.java
│ │ │ │ │ │ ├── ThirdGridAdapter.java
│ │ │ │ │ │ ├── StaggeredAdapter.java
│ │ │ │ │ │ ├── ListGridAdapter.java
│ │ │ │ │ │ ├── NewsGridAdapter.java
│ │ │ │ │ │ ├── NewsAdapter.java
│ │ │ │ │ │ ├── TecentHolder.java
│ │ │ │ │ │ └── TecentAdapter.java
│ │ │ │ │ └── ui
│ │ │ │ │ │ ├── WebActivity.java
│ │ │ │ │ │ ├── FragmentFactory.java
│ │ │ │ │ │ ├── TencentFragment.java
│ │ │ │ │ │ ├── StaggeredDemoFragment.java
│ │ │ │ │ │ ├── PullLoadFragment.java
│ │ │ │ │ │ ├── GridFragment.java
│ │ │ │ │ │ ├── NewsFragment.java
│ │ │ │ │ │ └── NewsHorFragment.java
│ │ │ │ ├── presenter
│ │ │ │ │ ├── BasePresenter.java
│ │ │ │ │ └── NewsPresenter.java
│ │ │ │ ├── model
│ │ │ │ │ ├── BaseModelCallBack.java
│ │ │ │ │ └── NewsModel.java
│ │ │ │ ├── contract
│ │ │ │ │ └── NewsContract.java
│ │ │ │ └── bean
│ │ │ │ │ └── NewsItem.java
│ │ │ │ ├── App.java
│ │ │ │ ├── widget
│ │ │ │ ├── PicassoImageLoader.java
│ │ │ │ ├── NoScrollGridView.java
│ │ │ │ ├── ProgressWebView.java
│ │ │ │ ├── VpRecyclerView.java
│ │ │ │ └── RecyclerWidgetProvider.java
│ │ │ │ ├── BaseFragment.java
│ │ │ │ ├── BaseActivity.java
│ │ │ │ ├── retrofit
│ │ │ │ ├── INewsApi.java
│ │ │ │ ├── ApiManager.java
│ │ │ │ └── RetrofitClient.java
│ │ │ │ ├── util
│ │ │ │ ├── FileUtil.java
│ │ │ │ ├── ImageLoader.java
│ │ │ │ ├── Constants.java
│ │ │ │ └── InternetUtil.java
│ │ │ │ ├── MainActivity.java
│ │ │ │ └── BaseToolbarActivity.java
│ │ └── AndroidManifest.xml
│ ├── test
│ │ └── java
│ │ │ └── com
│ │ │ └── huaqin
│ │ │ └── recyclerviewdemo
│ │ │ └── ExampleUnitTest.java
│ └── androidTest
│ │ └── java
│ │ └── com
│ │ └── huaqin
│ │ └── recyclerviewdemo
│ │ └── ExampleInstrumentedTest.java
├── proguard-rules.pro
└── build.gradle
├── settings.gradle
├── app-debug.apk
├── screenshots
├── 1.gif
├── 2.gif
├── 3.gif
├── 4.gif
├── 5.gif
├── all.gif
├── widget.gif
├── recyclerview.png
└── widget_click.gif
├── .idea
├── copyright
│ └── profiles_settings.xml
├── modules.xml
├── runConfigurations.xml
├── gradle.xml
├── compiler.xml
└── misc.xml
├── gradle
└── wrapper
│ ├── gradle-wrapper.jar
│ └── gradle-wrapper.properties
├── .gitignore
├── README.md
├── gradle.properties
├── gradlew.bat
└── gradlew
/app/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 |
--------------------------------------------------------------------------------
/settings.gradle:
--------------------------------------------------------------------------------
1 | include ':app'
2 |
--------------------------------------------------------------------------------
/app-debug.apk:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/app-debug.apk
--------------------------------------------------------------------------------
/screenshots/1.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/screenshots/1.gif
--------------------------------------------------------------------------------
/screenshots/2.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/screenshots/2.gif
--------------------------------------------------------------------------------
/screenshots/3.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/screenshots/3.gif
--------------------------------------------------------------------------------
/screenshots/4.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/screenshots/4.gif
--------------------------------------------------------------------------------
/screenshots/5.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/screenshots/5.gif
--------------------------------------------------------------------------------
/screenshots/all.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/screenshots/all.gif
--------------------------------------------------------------------------------
/screenshots/widget.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/screenshots/widget.gif
--------------------------------------------------------------------------------
/screenshots/recyclerview.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/screenshots/recyclerview.png
--------------------------------------------------------------------------------
/screenshots/widget_click.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/screenshots/widget_click.gif
--------------------------------------------------------------------------------
/.idea/copyright/profiles_settings.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/app/src/main/res/values/strings.xml:
--------------------------------------------------------------------------------
1 |
2 | RecyclerViewDemo
3 |
4 |
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/gradle/wrapper/gradle-wrapper.jar
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/ic_app.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/app/src/main/res/drawable-xhdpi/ic_app.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/welcome.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/app/src/main/res/drawable-xhdpi/welcome.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-hdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/app/src/main/res/mipmap-hdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-mdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/app/src/main/res/mipmap-mdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/app/src/main/res/mipmap-xhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/ic_refresh.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/app/src/main/res/drawable-xhdpi/ic_refresh.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/place_holder.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/app/src/main/res/drawable-xhdpi/place_holder.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/tecent_holder.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/app/src/main/res/drawable-xhdpi/tecent_holder.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/widget_preview.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/app/src/main/res/drawable-xhdpi/widget_preview.jpg
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-hdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/app/src/main/res/mipmap-hdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-mdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/app/src/main/res/mipmap-mdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AdleyLong/RecyclerViewDemo/HEAD/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | *.iml
2 | .gradle
3 | /local.properties
4 | /.idea/workspace.xml
5 | /.idea/libraries
6 | .DS_Store
7 | /build
8 | /captures
9 | .externalNativeBuild
10 |
--------------------------------------------------------------------------------
/app/src/main/java/com/huaqin/recyclerviewdemo/core/view/BaseView.java:
--------------------------------------------------------------------------------
1 | package com.huaqin.recyclerviewdemo.core.view;
2 |
3 | /**
4 | * Created by ubuntu on 17-4-13.
5 | */
6 |
7 | public interface BaseView {
8 | }
9 |
--------------------------------------------------------------------------------
/app/src/main/java/com/huaqin/recyclerviewdemo/core/presenter/BasePresenter.java:
--------------------------------------------------------------------------------
1 | package com.huaqin.recyclerviewdemo.core.presenter;
2 |
3 | /**
4 | * Created by ubuntu on 17-4-13.
5 | */
6 |
7 | public interface BasePresenter {
8 | }
9 |
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.properties:
--------------------------------------------------------------------------------
1 | #Thu Apr 13 09:19:00 CST 2017
2 | distributionBase=GRADLE_USER_HOME
3 | distributionPath=wrapper/dists
4 | zipStoreBase=GRADLE_USER_HOME
5 | zipStorePath=wrapper/dists
6 | distributionUrl=https\://services.gradle.org/distributions/gradle-3.3-all.zip
7 |
--------------------------------------------------------------------------------
/app/src/main/java/com/huaqin/recyclerviewdemo/core/model/BaseModelCallBack.java:
--------------------------------------------------------------------------------
1 | package com.huaqin.recyclerviewdemo.core.model;
2 |
3 | /**
4 | * Created by ubuntu on 17-4-13.
5 | */
6 |
7 | public interface BaseModelCallBack {
8 | void onResponse(T response);
9 |
10 | void onFailure(String error);
11 | }
12 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | 
2 | 
3 | 
4 | 
--------------------------------------------------------------------------------
/.idea/modules.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/app/src/main/res/xml/widget_info.xml:
--------------------------------------------------------------------------------
1 |
2 |
10 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/fragment_tencent.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
11 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/fragment_pullload.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
11 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/fragment_staggered.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
11 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/activity_welcome.xml:
--------------------------------------------------------------------------------
1 |
2 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/app/src/test/java/com/huaqin/recyclerviewdemo/ExampleUnitTest.java:
--------------------------------------------------------------------------------
1 | package com.huaqin.recyclerviewdemo;
2 |
3 | import org.junit.Test;
4 |
5 | import static org.junit.Assert.*;
6 |
7 | /**
8 | * Example local unit test, which will execute on the development machine (host).
9 | *
10 | * @see Testing documentation
11 | */
12 | public class ExampleUnitTest {
13 | @Test
14 | public void addition_isCorrect() throws Exception {
15 | assertEquals(4, 2 + 2);
16 | }
17 | }
--------------------------------------------------------------------------------
/app/src/main/res/layout/activity_web.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
8 |
9 |
13 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/fragment_home_banner.xml:
--------------------------------------------------------------------------------
1 |
2 |
7 |
8 |
9 |
14 |
15 |
--------------------------------------------------------------------------------
/app/src/main/java/com/huaqin/recyclerviewdemo/App.java:
--------------------------------------------------------------------------------
1 | package com.huaqin.recyclerviewdemo;
2 |
3 | import android.app.Application;
4 |
5 | /**
6 | * Created by ubuntu on 17-4-13.
7 | */
8 |
9 | public class App extends Application {
10 | public static App singleton = null;
11 |
12 | private final String TAG = "App";
13 |
14 | public static App getInstance() {
15 | return singleton;
16 | }
17 |
18 |
19 | @Override
20 | public void onCreate() {
21 | super.onCreate();
22 | singleton = this;
23 |
24 | }
25 |
26 | }
--------------------------------------------------------------------------------
/app/src/main/res/layout/widget_layout.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
13 |
--------------------------------------------------------------------------------
/.idea/runConfigurations.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
11 |
12 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/fragment_home_ad.xml:
--------------------------------------------------------------------------------
1 |
2 |
7 |
8 |
9 |
16 |
17 |
--------------------------------------------------------------------------------
/app/src/main/res/values/colors.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | #e6ab29
4 | #d1940d
5 | #f3d38c
6 | #e6ab29
7 |
8 |
9 | #000000
10 |
11 | #444444
12 |
13 | #9A9A9A
14 |
15 | #F2F2F2
16 |
17 | #FFFFFF
18 |
19 |
--------------------------------------------------------------------------------
/.idea/gradle.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/fragment_grid.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
11 |
12 |
17 |
--------------------------------------------------------------------------------
/app/src/main/java/com/huaqin/recyclerviewdemo/widget/PicassoImageLoader.java:
--------------------------------------------------------------------------------
1 | package com.huaqin.recyclerviewdemo.widget;
2 |
3 | import android.content.Context;
4 | import android.util.Log;
5 | import android.widget.ImageView;
6 |
7 | import com.huaqin.recyclerviewdemo.util.ImageLoader;
8 |
9 | /**
10 | * Created by ubuntu on 17-4-14.
11 | */
12 |
13 | public class PicassoImageLoader extends com.youth.banner.loader.ImageLoader {
14 |
15 |
16 | @Override
17 | public void displayImage(Context context, Object path, ImageView imageView) {
18 | //要先判断url是否为空,不然Picasso会报异常
19 | String url = (String) path;
20 | ImageLoader.getInstance().showImage(context, url, imageView);
21 | }
22 | }
--------------------------------------------------------------------------------
/app/src/main/java/com/huaqin/recyclerviewdemo/BaseFragment.java:
--------------------------------------------------------------------------------
1 | package com.huaqin.recyclerviewdemo;
2 |
3 | import android.support.v4.app.Fragment;
4 | import android.widget.Toast;
5 |
6 | /**
7 | * Created by ubuntu on 17-4-13.
8 | */
9 |
10 | public class BaseFragment extends Fragment {
11 |
12 | /**
13 | * toast弹框
14 | * @param toastStr
15 | */
16 | public void showToast(String toastStr){
17 | Toast.makeText(this.getActivity(),toastStr,Toast.LENGTH_SHORT).show();
18 | }
19 |
20 | /**
21 | * toast弹框
22 | * @param toastId
23 | */
24 | public void showToast(int toastId){
25 | Toast.makeText(this.getActivity(),toastId, Toast.LENGTH_SHORT).show();
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/fragment_news.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
12 |
13 |
18 |
--------------------------------------------------------------------------------
/app/src/main/java/com/huaqin/recyclerviewdemo/BaseActivity.java:
--------------------------------------------------------------------------------
1 | package com.huaqin.recyclerviewdemo;
2 |
3 | import android.support.v7.app.AppCompatActivity;
4 | import android.widget.Toast;
5 |
6 | /**
7 | * Created by ubuntu on 17-4-13.
8 | */
9 |
10 | public class BaseActivity extends AppCompatActivity {
11 | /**
12 | * toast弹框
13 | *
14 | * @param toastStr
15 | */
16 | public void showToast(String toastStr) {
17 | Toast.makeText(this, toastStr, Toast.LENGTH_SHORT).show();
18 | }
19 |
20 | /**
21 | * toast弹框
22 | *
23 | * @param toastId
24 | */
25 | public void showToast(int toastId) {
26 | Toast.makeText(this, toastId, Toast.LENGTH_SHORT).show();
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/.idea/compiler.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
--------------------------------------------------------------------------------
/app/src/main/java/com/huaqin/recyclerviewdemo/core/contract/NewsContract.java:
--------------------------------------------------------------------------------
1 | package com.huaqin.recyclerviewdemo.core.contract;
2 |
3 | import android.app.Activity;
4 |
5 | import com.huaqin.recyclerviewdemo.core.bean.NewsItem;
6 | import com.huaqin.recyclerviewdemo.core.presenter.BasePresenter;
7 | import com.huaqin.recyclerviewdemo.core.view.BaseView;
8 |
9 | import java.util.List;
10 |
11 | /**
12 | * Created by ubuntu on 17-4-13.
13 | */
14 |
15 | public class NewsContract {
16 | public interface View extends BaseView {
17 | void onSuccess(List list);
18 |
19 | void onFailure(String error);
20 |
21 | }
22 |
23 |
24 | public interface Presenter extends BasePresenter {
25 | void getData(Activity activity);
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/gradle.properties:
--------------------------------------------------------------------------------
1 | # Project-wide Gradle settings.
2 |
3 | # IDE (e.g. Android Studio) users:
4 | # Gradle settings configured through the IDE *will override*
5 | # any settings specified in this file.
6 |
7 | # For more details on how to configure your build environment visit
8 | # http://www.gradle.org/docs/current/userguide/build_environment.html
9 |
10 | # Specifies the JVM arguments used for the daemon process.
11 | # The setting is particularly useful for tweaking memory settings.
12 | org.gradle.jvmargs=-Xmx1536m
13 |
14 | # When configured, Gradle will run in incubating parallel mode.
15 | # This option should only be used with decoupled projects. More details, visit
16 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
17 | # org.gradle.parallel=true
18 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/fragment_home_third.xml:
--------------------------------------------------------------------------------
1 |
2 |
7 |
8 |
9 |
19 |
20 |
--------------------------------------------------------------------------------
/app/src/main/java/com/huaqin/recyclerviewdemo/retrofit/INewsApi.java:
--------------------------------------------------------------------------------
1 | package com.huaqin.recyclerviewdemo.retrofit;
2 |
3 | import com.google.gson.JsonObject;
4 | import com.huaqin.recyclerviewdemo.core.bean.NewsItem;
5 |
6 | import org.json.JSONArray;
7 | import org.json.JSONObject;
8 |
9 | import java.util.List;
10 | import java.util.Map;
11 |
12 | import retrofit2.http.GET;
13 | import retrofit2.http.Path;
14 | import rx.Observable;
15 |
16 | /**
17 | * Created by ubuntu on 17-4-13.
18 | */
19 |
20 | public interface INewsApi {
21 |
22 | @GET("/nc/article/list/{explore_id}/{offset}-{limit}.html")
23 | Observable