浏览代码

0.0.37 update

kongzue 4 年之前
父节点
当前提交
4648b2b0e4

+ 3 - 3
README.md

@@ -119,7 +119,7 @@ DialogX 采用了主题分离结构,主框架仅包含 Material 设计风格
 想要在您的项目引入 DialogX,您需要在 app 的 build.gradle 文件中找到 `dependencies{}` 代码块,并在其中加入以下语句:
 
 ```
-implementation 'com.kongzue.dialogx:DialogX:0.0.36'
+implementation 'com.kongzue.dialogx:DialogX:0.0.37'
 ```
 
 #### 方式二:Gradle 引入  jitPack 源
@@ -143,7 +143,7 @@ allprojects {
 2) 在 app 的 build.gradle 文件中找到 `dependencies{}` 代码块,并在其中加入以下语句:
 
 ```
-implementation 'com.github.kongzue.dialogx:DialogX:0.0.36'
+implementation 'com.github.kongzue.dialogx:DialogX:0.0.37'
 ```
 
 #### 方式三:直接引入 AAR 包文件
@@ -171,7 +171,7 @@ implementation(name: 'AAR文件名', ext: 'aar')
 <dependency>
   <groupId>com.kongzue.dialogx</groupId>
   <artifactId>DialogX</artifactId>
-  <version>0.0.36</version>
+  <version>0.0.37</version>
   <type>pom</type>
 </dependency>
 ```

+ 3 - 3
app/src/main/AndroidManifest.xml

@@ -12,9 +12,9 @@
         android:roundIcon="@mipmap/ic_launcher_round"
         android:supportsRtl="true"
         android:theme="@style/AppTheme">
-        <activity android:name=".MainActivity"
-            android:configChanges="orientation|keyboardHidden|screenSize|uiMode"
-            >
+        <activity
+            android:name=".MainActivity"
+            android:configChanges="orientation|keyboardHidden|screenSize|uiMode">
             <intent-filter>
                 <action android:name="android.intent.action.MAIN" />
 

+ 1 - 1
app/src/main/java/com/kongzue/dialogxdemo/MainActivity.java

@@ -408,7 +408,7 @@ public class MainActivity extends BaseActivity {
                         new OnBindView<BottomDialog>(R.layout.layout_custom_view) {
                             @Override
                             public void onBind(BottomDialog dialog, View v) {
-
+                            
                             }
                         })
                         .show();

+ 11 - 0
app/src/main/res/drawable/rect_custom_dialog_from_top_bkg.xml

@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="utf-8"?>
+<shape xmlns:android="http://schemas.android.com/apk/res/android"
+    android:shape="rectangle">
+    <!--left to right-->
+    <solid
+        android:color="@color/white"/>
+
+    <corners
+        android:bottomRightRadius="10dp"
+        android:bottomLeftRadius="10dp"/>
+</shape>

+ 2 - 2
app/src/main/res/layout/layout_custom_dialog.xml

@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="utf-8"?>
-<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
     android:layout_width="match_parent"
     android:layout_height="wrap_content">
 
@@ -24,4 +24,4 @@
 
     </RelativeLayout>
 
-</RelativeLayout>
+</LinearLayout>

+ 17 - 0
app/src/main/res/layout/layout_custom_dialog_from_top.xml

@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="utf-8"?>
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    android:orientation="vertical" android:layout_width="match_parent"
+    android:layout_height="match_parent">
+
+    <LinearLayout
+        android:layout_width="match_parent"
+        android:layout_height="300dp"
+        android:orientation="vertical"
+        android:background="@drawable/rect_custom_dialog_from_top_bkg">
+
+        <include
+            layout="@layout/layout_custom_dialog"/>
+
+    </LinearLayout>
+
+</LinearLayout>

+ 2 - 2
gradle.properties

@@ -18,5 +18,5 @@ android.useAndroidX=true
 # Automatically convert third-party libraries to use AndroidX
 android.enableJetifier=true
 
-BUILD_VERSION=0.0.37.beta10
-BUILD_VERSION_INT=36
+BUILD_VERSION=0.0.37
+BUILD_VERSION_INT=37