Skip to content

Commit

Permalink
优化无图/夜间模式
Browse files Browse the repository at this point in the history
  • Loading branch information
iMeiji committed Feb 26, 2017
1 parent 445dbbf commit 22e4100
Show file tree
Hide file tree
Showing 18 changed files with 3,299 additions and 34 deletions.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@

## 更新日志
```
2017-2-26
优化无图/夜间模式
2017-2-25
部分界面支持点击 Toolbar 返回顶部
优化 BottomSheet 界面
Expand Down Expand Up @@ -49,6 +52,7 @@ WebView无图模式(beta)
```

## TODO
- WebView无图模式支持 gif 图
- WebView无图模式支持点击加载图片
- 夜间模式无缝切换
- 添加视频模块
Expand Down
26 changes: 20 additions & 6 deletions app/build.gradle
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
apply plugin: 'com.android.application'

ext {
SUPPORT_LIBRARY_VERSION = '25.1.1'
SUPPORT_LIBRARY_VERSION = '25.2.0'
BUILD_TOOLS = "25.0.0"
}

def releaseTime() {
return new Date().format("yyyy-MM-dd", TimeZone.getTimeZone("UTC"))
}

android {
compileSdkVersion 25
buildToolsVersion "25.0.1"
Expand All @@ -13,14 +17,26 @@ android {
minSdkVersion 15
targetSdkVersion 25
versionCode 1
versionName "0.1"
//multiDexEnabled true
versionName "1.0"
multiDexEnabled true
vectorDrawables.useSupportLibrary = true
}
buildTypes {
release {
minifyEnabled false
minifyEnabled true //设为false即可断点调试
shrinkResources true //自动移除不用资源
debuggable false //设为true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
applicationVariants.all { variant ->
variant.outputs.each { output ->
def outputFile = output.outputFile
if (outputFile != null && outputFile.name.endsWith('.apk')) {
// 输出apk名称为Toutiao_release_v0.1_2017-02-26.apk
def fileName = "Toutiao_release_v${defaultConfig.versionName}_${releaseTime()}.apk"
output.outputFile = new File(outputFile.parent, fileName)
}
}
}
}
}
}
Expand All @@ -43,6 +59,4 @@ dependencies {
compile 'com.afollestad.material-dialogs:commons:0.9.1.0'
compile 'com.github.franmontiel:PersistentCookieJar:v1.0.0'
compile 'com.github.chrisbanes.photoview:library:1.2.4'
compile 'com.android.support:support-v4:25.1.1'
compile 'com.android.support:support-vector-drawable:25.1.1'
}
5 changes: 5 additions & 0 deletions app/proguard-rules.pro
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,8 @@
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
# public *;
#}

-keep class !android.support.v7.internal.view.menu.**,** {*;}
-dontwarn okio.**
-dontwarn com.google.gson.stream**
-ignorewarnings
Loading

0 comments on commit 22e4100

Please sign in to comment.