Skip to content

Commit

Permalink
🔨 release 3.2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
sdwfqin committed Jan 20, 2020
1 parent 9607563 commit d857961
Show file tree
Hide file tree
Showing 20 changed files with 62 additions and 54 deletions.
13 changes: 7 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,18 @@
// 支持AndroidX

// quicklib(Base)
implementation 'com.sdwfqin.quicklib:quicklib:3.0.3'
implementation 'com.sdwfqin.quicklib:quicklib:3.2.0'
// 如果使用butterknife请添加【可选】
annotationProcessor 'com.jakewharton:butterknife-compiler:10.2.0'
annotationProcessor 'com.jakewharton:butterknife-compiler:10.2.1'

// 支付模块
implementation 'com.sdwfqin.quicklib:paylib:3.1.0'

// Android 图片加载库(Glide封装)
implementation 'com.sdwfqin.quick:imageloader:3.0.3'
implementation 'com.sdwfqin.quick:imageloader:3.2.0'

// Android 自定义View组件
implementation 'com.sdwfqin.quick:widget:3.0.3'
implementation 'com.sdwfqin.quick:widget:3.2.0'

==================== AndroidX 分界线 ====================

Expand Down Expand Up @@ -50,9 +50,9 @@

# 需要注意!!!

1. `quicklib`依赖`QMUI`,需要在主项目中配置`QMUI``styles`,可参考`app`项目中的相应代码。
1. `quicklib`依赖`QMUI`,需要在主项目中配置`QMUI``styles`,可参考`app`项目中的相应代码。V3.2+使用的`QMUI`2.0或更高版本,请参考`app`中的`theme.xml`,主题请继承`QuickTheme`
2. 需要注意quicklib中的QuickInit类,需要的话请在Application中初始化(一般用不到)。
3. `quicklib``qrscan``widget`这几个模块因为项目引入了`AndroidUtilCode`,所以需要在`Application`初始化`Utils.init(this);`
3. `quicklib``widget`这几个模块因为项目引入了`AndroidUtilCode`,所以需要在`Application`初始化`Utils.init(this);`
4. 请在module的`build.gradle#android`中添加如下代码:

``` groovy
Expand Down Expand Up @@ -180,6 +180,7 @@
| AmountView | 购物车商品数量选择 |
| ~~AutoLinesLayoutManager~~ | 自动换行的布局管理器(流式布局),建议使用[flexbox-layout](https://github.com/google/flexbox-layout)代替 |
| ControlViewPager | 可动态禁止(允许)左滑/右滑的ViewPager |
| StatusPlaceholderView | 沉浸式状态栏占位 |
4. imageloader
Expand Down
2 changes: 1 addition & 1 deletion app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ dependencies {
annotationProcessor compilerDependencies["butterknife-compiler"]
annotationProcessor compilerDependencies["arch-compiler"]

debugImplementation 'com.squareup.leakcanary:leakcanary-android:2.0'
debugImplementation 'com.squareup.leakcanary:leakcanary-android:2.1'
}

//apply from: "tinker_config.gradle"
Expand Down
3 changes: 2 additions & 1 deletion app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,8 @@
android:configChanges="orientation|keyboardHidden|screenSize" />
<activity
android:name=".ui.components.CameraxDemoActivity"
android:configChanges="orientation|keyboardHidden|screenSize" />
android:configChanges="orientation|keyboardHidden|screenSize"
android:hardwareAccelerated="true" />
<activity
android:name=".ui.components.VLayoutSampleActivity"
android:configChanges="orientation|keyboardHidden|screenSize" />
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.sdwfqin.quickseed.adapter;

import com.chad.library.adapter.base.BaseViewHolder;
import com.chad.library.adapter.base.viewholder.BaseViewHolder;
import com.sdwfqin.quickseed.R;
import com.sdwfqin.widget.recyclerview.BaseAutoPollAdapter;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.sdwfqin.quickseed.adapter;

import com.alibaba.android.vlayout.LayoutHelper;
import com.chad.library.adapter.base.BaseViewHolder;
import com.chad.library.adapter.base.viewholder.BaseViewHolder;
import com.sdwfqin.quickseed.R;
import com.sdwfqin.widget.recyclerview.BaseVlayoutAdapter;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.sdwfqin.quickseed.adapter;

import com.alibaba.android.vlayout.LayoutHelper;
import com.chad.library.adapter.base.BaseViewHolder;
import com.chad.library.adapter.base.viewholder.BaseViewHolder;
import com.sdwfqin.quickseed.R;
import com.sdwfqin.widget.recyclerview.BaseVlayoutAdapter;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.sdwfqin.quickseed.adapter;

import com.alibaba.android.vlayout.LayoutHelper;
import com.chad.library.adapter.base.BaseViewHolder;
import com.chad.library.adapter.base.viewholder.BaseViewHolder;
import com.sdwfqin.quickseed.R;
import com.sdwfqin.widget.recyclerview.BaseVlayoutAdapter;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.sdwfqin.quickseed.adapter;

import com.alibaba.android.vlayout.LayoutHelper;
import com.chad.library.adapter.base.BaseViewHolder;
import com.chad.library.adapter.base.viewholder.BaseViewHolder;
import com.sdwfqin.quickseed.R;
import com.sdwfqin.widget.recyclerview.BaseVlayoutAdapter;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ public void onCreate() {
initUtils();
// 只能在某个Activity显示更新弹窗
Beta.canShowUpgradeActs.add(MainActivity.class);
Bugly.init(this, "534e5a3930", !BuildConfig.DEBUG);
Bugly.init(this, "534e5a3930", BuildConfig.DEBUG);
QuickInit.setBaseUrl(Constants.BASE_URL);
QuickInit.setRealPath(Constants.SAVE_REAL_PATH);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,12 @@ public String getImgPath() {
public void setImgPath(String imgPath) {
this.imgPath = imgPath;
}

@Override
public String toString() {
return "PictureModel{" +
"imgPath='" + imgPath + '\'' +
", image=" + image +
'}';
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
import android.content.Intent;
import android.net.Uri;

import com.blankj.utilcode.util.LogUtils;
import com.sdwfqin.quickseed.R;
import com.sdwfqin.quickseed.base.SampleBaseActivity;
import com.sdwfqin.quickseed.model.PictureModel;
Expand Down Expand Up @@ -80,7 +81,6 @@ protected void onActivityResult(int requestCode, int resultCode, Intent data) {
Intent mediaScanIntent = new Intent(Intent.ACTION_MEDIA_SCANNER_SCAN_FILE, contentUri);
sendBroadcast(mediaScanIntent);
}

break;
default:
}
Expand Down
24 changes: 12 additions & 12 deletions config.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -23,17 +23,17 @@ ext {

eventDependencies = [
// rxjava
"rxjava" : "io.reactivex.rxjava2:rxjava:2.2.15",
"rxjava" : "io.reactivex.rxjava2:rxjava:2.2.17",
"rxandroid": "io.reactivex.rxjava2:rxandroid:2.1.1",
// eventbus
"eventbus" : "org.greenrobot:eventbus:3.1.1",
]

retrofitDependencies = [
"retrofit" : "com.squareup.retrofit2:retrofit:2.6.1",
"converter-gson" : "com.squareup.retrofit2:converter-gson:2.6.1",
"converter-scalars": "com.squareup.retrofit2:converter-scalars:2.6.1",
"adapter-rxjava2" : "com.squareup.retrofit2:adapter-rxjava2:2.6.1",
"retrofit" : "com.squareup.retrofit2:retrofit:2.7.1",
"converter-gson" : "com.squareup.retrofit2:converter-gson:2.7.1",
"converter-scalars": "com.squareup.retrofit2:converter-scalars:2.7.1",
"adapter-rxjava2" : "com.squareup.retrofit2:adapter-rxjava2:2.7.1",
]

okhttpDependencies = [
Expand All @@ -43,18 +43,18 @@ ext {

viewDependencies = [
// brvah
"brvah" : "com.github.CymChad:BaseRecyclerViewAdapterHelper:2.9.49-androidx",
"brvah" : "com.github.CymChad:BaseRecyclerViewAdapterHelper:3.0.0-beta11",
// smartrefresh
"smartrefresh": "com.scwang.smartrefresh:SmartRefreshLayout:1.1.0",
// pickerview
"pickerview" : "com.contrarywind:Android-PickerView:4.1.9",
// butterknife
"butterknife" : "com.jakewharton:butterknife:10.2.0",
"butterknife" : "com.jakewharton:butterknife:10.2.1",
]

imageDependencies = [
"glide" : "com.github.bumptech.glide:glide:4.10.0",
"glide-integration": "com.github.bumptech.glide:okhttp3-integration:4.10.0",
"glide" : "com.github.bumptech.glide:glide:4.11.0",
"glide-integration": "com.github.bumptech.glide:okhttp3-integration:4.11.0",
// photoView 图片放大
"photoview" : "com.github.chrisbanes:PhotoView:2.3.0",
// matisse
Expand Down Expand Up @@ -82,8 +82,8 @@ ext {
]

compilerDependencies = [
"glide-compiler" : "com.github.bumptech.glide:compiler:4.10.0",
"butterknife-compiler": "com.jakewharton:butterknife-compiler:10.1.0",
"arch-compiler" : "com.qmuiteam:arch-compiler:2.0.0-alpha01",
"glide-compiler" : "com.github.bumptech.glide:compiler:4.11.0",
"butterknife-compiler": "com.jakewharton:butterknife-compiler:10.2.1",
"arch-compiler" : "com.qmuiteam:arch-compiler:2.0.0-alpha03",
]
}
8 changes: 8 additions & 0 deletions docs/update.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# 更新文档

### 2020/01/19

1. 升级QMUI到2.0,支持侧滑返回,支持基于uiMode的换肤
2. 升级BaseRecyclerViewAdapterHelper到3.0,不完全向前兼容
3. retrofit 2.7.1
4. glide:4.11.0
5. okhttp:4.2.2

### 2019/04/14

1. 修改`quicklib`目录结构
Expand Down
4 changes: 2 additions & 2 deletions imageloader/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apply plugin: 'com.android.library'

// gradlew imageloader:clean imageloader:build imageloader:bintrayUpload

version = "3.0.3"
version = "3.2.0"

android {
compileSdkVersion rootProject.ext.android.compileSdkVersion
Expand All @@ -11,7 +11,7 @@ android {
defaultConfig {
minSdkVersion rootProject.ext.android.minSdkVersion
targetSdkVersion rootProject.ext.android.targetSdkVersion
versionCode 16
versionCode 17
versionName version
}

Expand Down
4 changes: 2 additions & 2 deletions quicklib/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apply plugin: 'com.android.library'

// ./gradlew quicklib:clean quicklib:build quicklib:bintrayUpload

version = "3.0.3"
version = "3.2.0"

android {
compileSdkVersion rootProject.ext.android.compileSdkVersion
Expand All @@ -11,7 +11,7 @@ android {
defaultConfig {
minSdkVersion rootProject.ext.android.minSdkVersion
targetSdkVersion rootProject.ext.android.targetSdkVersion
versionCode 83
versionCode 84
versionName version
}

Expand Down
4 changes: 2 additions & 2 deletions widget/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@ apply plugin: 'com.android.library'

// gradlew widget:clean widget:build widget:bintrayUpload

version = "3.0.3"
version = "3.2.0"

android {
compileSdkVersion rootProject.ext.android.compileSdkVersion
buildToolsVersion rootProject.ext.android.buildToolsVersion
defaultConfig {
minSdkVersion rootProject.ext.android.minSdkVersion
targetSdkVersion rootProject.ext.android.targetSdkVersion
versionCode 16
versionCode 17
versionName version
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
import androidx.annotation.Nullable;

import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;
import com.chad.library.adapter.base.viewholder.BaseViewHolder;
import com.sdwfqin.imageloader.ImageLoader;
import com.sdwfqin.widget.R;

Expand All @@ -21,6 +21,7 @@ public class PictureUploadAdapter<T extends PictureUpModel> extends BaseQuickAda

public PictureUploadAdapter(int layoutResId, @Nullable List<T> data) {
super(layoutResId, data);
addChildClickViewIds(R.id.ii_img, R.id.ii_del);
}

@Override
Expand All @@ -40,22 +41,6 @@ protected void convert(BaseViewHolder helper, T item) {
iiImg.setImageResource(R.drawable.quick_add_img);
}

// 视图树的观察者,可以监听 View 的全局变化事件
// iiImg.getViewTreeObserver()
// .addOnGlobalLayoutListener(new ViewTreeObserver.OnGlobalLayoutListener() {
// @Override
// public void onGlobalLayout() {
// iiImg.getViewTreeObserver().removeOnGlobalLayoutListener(this);
// ViewGroup.LayoutParams layoutParams = iiImg.getLayoutParams();
// layoutParams.height = iiImg.getWidth();
// iiImg.setLayoutParams(layoutParams);
// }
// });

// 点击事件
helper.addOnClickListener(R.id.ii_img)
.addOnClickListener(R.id.ii_del);

if (item == null) {
helper.setVisible(R.id.ii_del, false);
} else {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
import androidx.recyclerview.widget.RecyclerView;

import com.blankj.utilcode.util.ConvertUtils;
import com.blankj.utilcode.util.LogUtils;
import com.sdwfqin.widget.R;

import java.util.ArrayList;
Expand Down Expand Up @@ -170,7 +171,8 @@ public void setNewData(List<T> data) {
mDataList.add(null);
}
mDataList = data;
mUploadAdapter.setNewData(mDataList);
mUploadAdapter.notifyDataSetChanged();
// mUploadAdapter.setNewData(mDataList);
}

/**
Expand All @@ -186,7 +188,10 @@ public void setAddData(List<T> data) {
// 如果数量小于最大值,添加一个null作为占位符
mDataList.add(null);
}
mUploadAdapter.setNewData(mDataList);
LogUtils.e(mDataList);
// fixme brvah3
mUploadAdapter.notifyDataSetChanged();
// mUploadAdapter.setNewData(mDataList);
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
import androidx.annotation.Nullable;
import androidx.recyclerview.widget.RecyclerView;

import com.chad.library.adapter.base.BaseViewHolder;
import com.chad.library.adapter.base.viewholder.BaseViewHolder;

import java.util.ArrayList;
import java.util.List;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
import com.alibaba.android.vlayout.DelegateAdapter;
import com.alibaba.android.vlayout.LayoutHelper;
import com.alibaba.android.vlayout.VirtualLayoutManager;
import com.chad.library.adapter.base.BaseViewHolder;
import com.chad.library.adapter.base.viewholder.BaseViewHolder;

import java.util.ArrayList;
import java.util.LinkedHashSet;
Expand Down

0 comments on commit d857961

Please sign in to comment.