-
Notifications
You must be signed in to change notification settings - Fork 440
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1,304 changed files
with
39 additions
and
41,101 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,6 @@ | |
|
||
import android.os.Bundle; | ||
import android.support.design.widget.CollapsingToolbarLayout; | ||
import android.support.v7.app.AppCompatActivity; | ||
import android.support.v7.widget.Toolbar; | ||
import android.view.View; | ||
import android.widget.ImageView; | ||
|
@@ -13,23 +12,28 @@ | |
import com.lauren.simplenews.news.presenter.NewsDetailPresenter; | ||
import com.lauren.simplenews.news.presenter.NewsDetailPresenterImpl; | ||
import com.lauren.simplenews.news.view.NewsDetailView; | ||
import com.lauren.simplenews.utils.DensityUtil; | ||
import com.lauren.simplenews.utils.ImageLoaderUtils; | ||
|
||
import org.sufficientlysecure.htmltextview.HtmlTextView; | ||
|
||
import me.imid.swipebacklayout.lib.SwipeBackLayout; | ||
import me.imid.swipebacklayout.lib.app.SwipeBackActivity; | ||
|
||
/** | ||
* Description : 新闻详情界面 | ||
* Author : lauren | ||
* Email : [email protected] | ||
* Blog : http://www.liuling123.com | ||
* Date : 15/12/19 | ||
*/ | ||
public class NewsDetailActivity extends AppCompatActivity implements NewsDetailView { | ||
public class NewsDetailActivity extends SwipeBackActivity implements NewsDetailView { | ||
|
||
private NewsBean mNews; | ||
private HtmlTextView mTVNewsContent; | ||
private NewsDetailPresenter mNewsDetailPresenter; | ||
private ProgressBar mProgressBar; | ||
private SwipeBackLayout mSwipeBackLayout; | ||
|
||
@Override | ||
protected void onCreate(Bundle savedInstanceState) { | ||
|
@@ -48,6 +52,10 @@ public void onClick(View view) { | |
} | ||
}); | ||
|
||
mSwipeBackLayout = getSwipeBackLayout(); | ||
mSwipeBackLayout.setEdgeSize(DensityUtil.getWidthInPx(this)); | ||
mSwipeBackLayout.setEdgeTrackingEnabled(SwipeBackLayout.EDGE_LEFT); | ||
|
||
mNews = (NewsBean) getIntent().getSerializableExtra("news"); | ||
|
||
CollapsingToolbarLayout collapsingToolbar = (CollapsingToolbarLayout) findViewById(R.id.collapsing_toolbar); | ||
|
11 changes: 7 additions & 4 deletions
11
app/src/main/java/com/lauren/simplenews/utils/DensityUtil.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,16 @@ | ||
package com.lauren.simplenews.utils; | ||
|
||
import java.util.concurrent.Executors; | ||
|
||
import android.content.Context; | ||
|
||
/** | ||
* Description : | ||
* Author : lauren | ||
* Email : [email protected] | ||
* Blog : http://www.liuling123.com | ||
* Date : 15/12/21 | ||
*/ | ||
public class DensityUtil { | ||
|
||
|
||
|
||
public static final int getHeightInPx(Context context) { | ||
final int height = context.getResources().getDisplayMetrics().heightPixels; | ||
return height; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
#Wed Oct 21 11:34:03 PDT 2015 | ||
#Mon Dec 14 16:34:39 CST 2015 | ||
distributionBase=GRADLE_USER_HOME | ||
distributionPath=wrapper/dists | ||
zipStoreBase=GRADLE_USER_HOME | ||
zipStorePath=wrapper/dists | ||
distributionUrl=https\://services.gradle.org/distributions/gradle-2.8-all.zip | ||
distributionUrl=https\://services.gradle.org/distributions/gradle-2.4-all.zip |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
include ':app' | ||
include ':app',':swipeback' |
13 changes: 0 additions & 13 deletions
13
...ack/build/generated/source/buildConfig/debug/me/imid/swipebacklayout/lib/BuildConfig.java
This file was deleted.
Oops, something went wrong.
13 changes: 0 additions & 13 deletions
13
...k/build/generated/source/buildConfig/release/me/imid/swipebacklayout/lib/BuildConfig.java
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.