Procházet zdrojové kódy

Merge branch 'develop' of https://github.com/swict/LifePlusAndroid into develop

hyodong.min před 7 roky
rodič
revize
3483e123e2

+ 22 - 11
app/src/main/java/kr/co/zumo/app/lifeplus/view/fragment/bucketlist/AddMyBucketListFragment.java

@@ -5,6 +5,7 @@ import android.support.annotation.NonNull;
 import android.support.annotation.Nullable;
 import android.support.v7.widget.LinearLayoutManager;
 import android.support.v7.widget.RecyclerView;
+import android.util.Log;
 import android.view.LayoutInflater;
 import android.view.View;
 import android.view.ViewGroup;
@@ -55,6 +56,16 @@ public class AddMyBucketListFragment extends FragmentBase<MyBucketListPresenter>
 
     editTextMyBucketTitle = findViewById(R.id.edit_text_my_bucket);
     buttonAddMyBucket = findViewById(R.id.button_add_my_bucket);
+
+    editTextMyBucketTitle.setOnFocusChangeListener(new View.OnFocusChangeListener() {
+      @Override
+      public void onFocusChange(View view, boolean isFocused) {
+        if (isFocused) {
+          Log.e("APP#  AddMyBucketListFragment | onFocusChange", "|" + "들어옴");
+        }
+      }
+    });
+
     //등록버튼 클릭시
     buttonAddMyBucket.setOnClickListener(view -> presenter.onEvent(new Event.Builder(Event.CLICK).build()));
     recyclerViewImageList = findViewById(R.id.recycler_view_image_list);
@@ -76,17 +87,17 @@ public class AddMyBucketListFragment extends FragmentBase<MyBucketListPresenter>
     return new MyBucketListPresenter(getModel(MyBucketListModel.class), this);
   }
 
-  private void doDummyData(){
+  private void doDummyData() {
     addMyBucketListData = new ArrayList<>();
-    addMyBucketListData.add(new TextImageBean(R.drawable.img_select_bg_1 , R.string.bucket_select_text1));
-    addMyBucketListData.add(new TextImageBean(R.drawable.img_select_bg_2 , R.string.bucket_select_text2));
-    addMyBucketListData.add(new TextImageBean(R.drawable.img_select_bg_3 , R.string.bucket_select_text3));
-    addMyBucketListData.add(new TextImageBean(R.drawable.img_select_bg_4 , R.string.bucket_select_text4));
-    addMyBucketListData.add(new TextImageBean(R.drawable.img_select_bg_5 , R.string.bucket_select_text5));
-    addMyBucketListData.add(new TextImageBean(R.drawable.img_select_bg_6 , R.string.bucket_select_text1));
-    addMyBucketListData.add(new TextImageBean(R.drawable.img_select_bg_7 , R.string.bucket_select_text2));
-    addMyBucketListData.add(new TextImageBean(R.drawable.img_select_bg_8 , R.string.bucket_select_text3));
-    addMyBucketListData.add(new TextImageBean(R.drawable.img_select_bg_9 , R.string.bucket_select_text4));
-    addMyBucketListData.add(new TextImageBean(R.drawable.img_select_bg_10 , R.string.bucket_select_text5));
+    addMyBucketListData.add(new TextImageBean(R.drawable.img_select_bg_1, R.string.bucket_select_text1));
+    addMyBucketListData.add(new TextImageBean(R.drawable.img_select_bg_2, R.string.bucket_select_text2));
+    addMyBucketListData.add(new TextImageBean(R.drawable.img_select_bg_3, R.string.bucket_select_text3));
+    addMyBucketListData.add(new TextImageBean(R.drawable.img_select_bg_4, R.string.bucket_select_text4));
+    addMyBucketListData.add(new TextImageBean(R.drawable.img_select_bg_5, R.string.bucket_select_text5));
+    addMyBucketListData.add(new TextImageBean(R.drawable.img_select_bg_6, R.string.bucket_select_text1));
+    addMyBucketListData.add(new TextImageBean(R.drawable.img_select_bg_7, R.string.bucket_select_text2));
+    addMyBucketListData.add(new TextImageBean(R.drawable.img_select_bg_8, R.string.bucket_select_text3));
+    addMyBucketListData.add(new TextImageBean(R.drawable.img_select_bg_9, R.string.bucket_select_text4));
+    addMyBucketListData.add(new TextImageBean(R.drawable.img_select_bg_10, R.string.bucket_select_text5));
   }
 }

+ 0 - 22
app/src/main/java/kr/co/zumo/app/lifeplus/view/fragment/bucketlist/AddMyBucketListViewHolder.java

@@ -48,26 +48,4 @@ public class AddMyBucketListViewHolder extends RecyclerView.ViewHolder {
     imageVieWCircleBorder.setImageResource(bean.isClicked()? R.drawable.image_circle_border : R.drawable.radio_uncheck );
   }
 
-//  public static Bitmap getCircleBitmap(Bitmap bitmap , int borderWidth) {
-//    if (bitmap == null || bitmap.isRecycled()) {
-//      return null;
-//    }
-//    final int width = bitmap.getWidth() + borderWidth;
-//    final int height = bitmap.getHeight() + borderWidth;
-//    Bitmap canvasBitmap = Bitmap.createBitmap(width, height, Bitmap.Config.ARGB_8888);
-//    BitmapShader shader = new BitmapShader(bitmap, Shader.TileMode.CLAMP, Shader.TileMode.CLAMP.CLAMP);
-//    Paint paint = new Paint();
-//    paint.setAntiAlias(true);
-//    paint.setShader(shader);
-//
-//    Canvas canvas = new Canvas(canvasBitmap);
-//    float radius = width > height ? ((float) height) / 2f : ((float) width) / 2f;
-//    canvas.drawCircle(width / 2, height / 2, radius, paint);
-//    paint.setShader(null);
-//    paint.setStyle(Paint.Style.STROKE);
-//    paint.setColor(Color.WHITE);
-//    paint.setStrokeWidth(borderWidth);
-//    canvas.drawCircle(width / 2, height / 2, radius - borderWidth / 2, paint);
-//    return canvasBitmap;
-//  }
 }

+ 5 - 0
app/src/main/res/drawable/white_cursor.xml

@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="utf-8"?>
+<shape xmlns:android="http://schemas.android.com/apk/res/android">
+  <size android:width="1.5dp"/>
+  <solid android:color="@color/CFFFFFF"/>
+</shape>

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

@@ -8,8 +8,8 @@
 
   <ImageView
     android:id="@+id/image_view_select_border"
-    android:layout_width="50dp"
-    android:layout_height="50dp"
+    android:layout_width="52dp"
+    android:layout_height="52dp"
     android:layout_gravity="center"
     android:layout_marginStart="5dp"
     android:layout_marginEnd="5dp"

+ 16 - 6
app/src/main/res/layout/fragment_add_my_bucket_list.xml

@@ -5,9 +5,16 @@
   xmlns:tools="http://schemas.android.com/tools"
   android:layout_width="match_parent"
   android:layout_height="match_parent"
-  android:background="@drawable/img_bestbucket_1"
+
   >
 
+  <ImageView
+    android:layout_width="match_parent"
+    android:layout_height="match_parent"
+    android:scaleType="centerCrop"
+    android:src="@drawable/img_bestbucket_1"
+    />
+
   <EditText
     android:id="@+id/edit_text_my_bucket"
     android:layout_width="match_parent"
@@ -15,19 +22,21 @@
     android:layout_alignParentStart="true"
     android:layout_centerVertical="true"
     android:background="@null"
-    android:paddingBottom="20dp"
     android:hint="@string/make_my_bucket_list"
     android:lineSpacingExtra="11sp"
     android:maxLines="1"
+    android:paddingBottom="20dp"
     android:textAlignment="center"
+    android:gravity="top"
     android:textColor="@color/CFFFFFF"
-    android:textColorHint="@color/CFFFFFF"
+    android:textColorHint="#80FFFFFF"
+    android:textCursorDrawable="@drawable/white_cursor"
     android:textSize="28sp"
     tools:text="나만의 버킷리스트 만들기"/>
 
   <Button
     android:id="@+id/button_add_my_bucket"
-    style="@style/SignUpButton"
+    style="@style/WhiteButton"
     android:layout_width="wrap_content"
     android:layout_height="wrap_content"
     android:layout_below="@+id/edit_text_my_bucket"
@@ -40,7 +49,8 @@
     android:layout_width="match_parent"
     android:layout_height="wrap_content"
     android:layout_above="@+id/text_view_my_bucket_example"
-    android:layout_marginBottom="12dp"/>
+    android:layout_alignParentBottom="true"
+    android:layout_marginBottom="20dp"/>
 
   <TextView
     android:id="@+id/text_view_my_bucket_example"
@@ -52,8 +62,8 @@
     android:layout_marginBottom="9dp"
     android:gravity="end"
     android:lineSpacingExtra="4sp"
+    android:text="@string/bucket_select_text1"
     android:textColor="@color/CFFFFFF"
     android:textSize="12sp"
-    android:text="@string/bucket_select_text1"
     />
 </RelativeLayout>