Commit edfb598e by 霍志良

feat:UI修改

parent fcb72e11
...@@ -119,7 +119,7 @@ public class PublishQuestionAndTrendFragment extends BaseFragment implements Vie ...@@ -119,7 +119,7 @@ public class PublishQuestionAndTrendFragment extends BaseFragment implements Vie
private EditText publish_trend_title_editext, publish_trend_content_editext; private EditText publish_trend_title_editext, publish_trend_content_editext;
private RecyclerView publish_trend_img_rcv; private RecyclerView publish_trend_img_rcv;
private ImageView publish_trend_bottom_img_iv; private ImageView publish_trend_bottom_img_iv;
private View lineTitle;
private LinearLayout publish_anonymity_rel; private LinearLayout publish_anonymity_rel;
private LinearLayout ll_to_expert; private LinearLayout ll_to_expert;
private ImageView publish_anonymity_iv; private ImageView publish_anonymity_iv;
...@@ -394,6 +394,7 @@ public class PublishQuestionAndTrendFragment extends BaseFragment implements Vie ...@@ -394,6 +394,7 @@ public class PublishQuestionAndTrendFragment extends BaseFragment implements Vie
publish_trend_content_num_tv = getRootView().findViewById(R.id.publish_trend_content_num_tv); publish_trend_content_num_tv = getRootView().findViewById(R.id.publish_trend_content_num_tv);
publish_trend_bottom_topic_tv = getRootView().findViewById(R.id.publish_trend_bottom_topic_tv); publish_trend_bottom_topic_tv = getRootView().findViewById(R.id.publish_trend_bottom_topic_tv);
publish_trend_title_editext = getRootView().findViewById(R.id.publish_trend_title_editext); publish_trend_title_editext = getRootView().findViewById(R.id.publish_trend_title_editext);
lineTitle = getRootView().findViewById(R.id.lineTitle);
publish_trend_content_editext = getRootView().findViewById(R.id.publish_trend_content_editext); publish_trend_content_editext = getRootView().findViewById(R.id.publish_trend_content_editext);
publish_trend_img_rcv = getRootView().findViewById(R.id.publish_trend_img_rcv); publish_trend_img_rcv = getRootView().findViewById(R.id.publish_trend_img_rcv);
publish_trend_bottom_img_iv = getRootView().findViewById(R.id.publish_trend_bottom_img_iv); publish_trend_bottom_img_iv = getRootView().findViewById(R.id.publish_trend_bottom_img_iv);
...@@ -435,6 +436,7 @@ public class PublishQuestionAndTrendFragment extends BaseFragment implements Vie ...@@ -435,6 +436,7 @@ public class PublishQuestionAndTrendFragment extends BaseFragment implements Vie
if (TextUtils.equals(type, TYPE_TREND)) {//动态 if (TextUtils.equals(type, TYPE_TREND)) {//动态
publish_trend_title_editext.setVisibility(View.GONE); publish_trend_title_editext.setVisibility(View.GONE);
lineTitle.setVisibility(View.GONE);
ll_to_expert.setVisibility(View.GONE); ll_to_expert.setVisibility(View.GONE);
publish_trend_content_editext.setFilters(new InputFilter[]{new InputFilter.LengthFilter(500)}); publish_trend_content_editext.setFilters(new InputFilter[]{new InputFilter.LengthFilter(500)});
publish_trend_content_num_tv.setText("0/500"); publish_trend_content_num_tv.setText("0/500");
...@@ -442,6 +444,7 @@ public class PublishQuestionAndTrendFragment extends BaseFragment implements Vie ...@@ -442,6 +444,7 @@ public class PublishQuestionAndTrendFragment extends BaseFragment implements Vie
} else {//提问 } else {//提问
publish_trend_title_editext.setVisibility(View.VISIBLE); publish_trend_title_editext.setVisibility(View.VISIBLE);
lineTitle.setVisibility(View.VISIBLE);
ll_to_expert.setVisibility(View.VISIBLE); ll_to_expert.setVisibility(View.VISIBLE);
publish_trend_content_editext.setFilters(new InputFilter[]{new InputFilter.LengthFilter(1000)}); publish_trend_content_editext.setFilters(new InputFilter[]{new InputFilter.LengthFilter(1000)});
publish_trend_content_num_tv.setText("0/1000"); publish_trend_content_num_tv.setText("0/1000");
......
...@@ -9,13 +9,16 @@ ...@@ -9,13 +9,16 @@
android:id="@+id/trends_publish_question" android:id="@+id/trends_publish_question"
android:focusableInTouchMode="true" android:focusableInTouchMode="true"
android:orientation="vertical"> android:orientation="vertical">
<RelativeLayout <androidx.core.widget.NestedScrollView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:paddingBottom="50dp">
<RelativeLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
app:layout_constraintStart_toStartOf="parent" app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" app:layout_constraintTop_toTopOf="parent"
android:background="@color/dynamic_white"> android:background="@color/dynamic_white">
<EditText <EditText
android:id="@+id/publish_trend_title_editext" android:id="@+id/publish_trend_title_editext"
android:layout_width="match_parent" android:layout_width="match_parent"
...@@ -26,6 +29,7 @@ ...@@ -26,6 +29,7 @@
android:minHeight="50dp" android:minHeight="50dp"
android:maxLength="35" android:maxLength="35"
android:paddingLeft="15dp" android:paddingLeft="15dp"
android:layout_alignParentTop="true"
android:paddingTop="13dp" android:paddingTop="13dp"
android:paddingRight="15dp" android:paddingRight="15dp"
android:paddingBottom="13dp" android:paddingBottom="13dp"
...@@ -33,139 +37,143 @@ ...@@ -33,139 +37,143 @@
android:textColorHint="#bfbfbf" android:textColorHint="#bfbfbf"
android:textSize="24sp" android:textSize="24sp"
tools:text="标题:说说你的标题:说说你的标题:说说你的困惑标题:说说你的困标题:说说你的困惑标题:说说你的困惑困惑标题:说说你的困惑" /> tools:text="标题:说说你的标题:说说你的标题:说说你的困惑标题:说说你的困标题:说说你的困惑标题:说说你的困惑困惑标题:说说你的困惑" />
<androidx.core.widget.NestedScrollView <View
android:layout_width="match_parent" android:id="@+id/lineTitle"
android:layout_height="match_parent" android:layout_width="match_parent"
android:paddingBottom="50dp" android:layout_height="1dp"
> android:layout_marginLeft="15dp"
<RelativeLayout android:layout_below="@+id/publish_trend_title_editext"
android:layout_width="match_parent" android:layout_marginTop="6dp"
android:layout_height="wrap_content" android:background="#eae9e9" />
android:orientation="vertical" <RelativeLayout
android:layout_below="@id/publish_trend_title_editext" android:layout_width="match_parent"
> android:layout_height="wrap_content"
android:orientation="vertical"
android:layout_below="@id/lineTitle"
>
<EditText <EditText
android:id="@+id/publish_trend_content_editext" android:id="@+id/publish_trend_content_editext"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:background="@color/dynamic_white" android:background="@color/dynamic_white"
android:focusable="true" android:focusable="true"
android:focusableInTouchMode="true" android:focusableInTouchMode="true"
android:gravity="left|top" android:gravity="left|top"
android:hint="1、清晰描述事情的背景及经过\n2、你想寻求哪方面的帮助\n这样更容易获得咨询师准确、专业的解答哦~" android:hint="1、清晰描述事情的背景及经过\n2、你想寻求哪方面的帮助\n这样更容易获得咨询师准确、专业的解答哦~"
android:includeFontPadding="false" android:includeFontPadding="false"
android:minLines="6" android:minLines="6"
android:padding="15dp" android:padding="15dp"
android:paddingLeft="15dp" android:paddingLeft="15dp"
android:textColor="@color/dynamic_text_trend_title_black" android:textColor="@color/dynamic_text_trend_title_black"
android:textColorHint="#bfbfbf" android:textColorHint="#bfbfbf"
android:textSize="17sp" /> android:textSize="17sp" />
<androidx.recyclerview.widget.RecyclerView <androidx.recyclerview.widget.RecyclerView
android:id="@+id/publish_trend_img_rcv" android:id="@+id/publish_trend_img_rcv"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_below="@+id/publish_trend_content_editext" android:layout_below="@+id/publish_trend_content_editext"
android:layout_marginTop="16dp" android:layout_marginTop="16dp"
android:paddingLeft="@dimen/platform_dp_12" android:paddingLeft="@dimen/platform_dp_12"
android:paddingRight="@dimen/platform_dp_12" android:paddingRight="@dimen/platform_dp_12"
android:visibility="gone" /> android:visibility="gone" />
<RelativeLayout <RelativeLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_below="@+id/publish_trend_img_rcv" android:layout_below="@+id/publish_trend_img_rcv"
android:layout_margin="15dp"> android:layout_margin="15dp">
<TextView <TextView
android:id="@+id/publish_trend_bottom_topic_tv" android:id="@+id/publish_trend_bottom_topic_tv"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="24dp" android:layout_height="24dp"
android:background="@drawable/dynamic_bg_topic" android:background="@drawable/dynamic_bg_topic"
android:gravity="center_vertical" android:gravity="center_vertical"
android:paddingLeft="10dp" android:paddingLeft="10dp"
android:paddingRight="10dp" android:paddingRight="10dp"
android:text="# 选择话题" android:text="# 选择话题"
android:textColor="#999999" android:textColor="#999999"
android:textSize="11sp" /> android:textSize="11sp" />
<TextView <TextView
android:id="@+id/publish_trend_content_num_tv" android:id="@+id/publish_trend_content_num_tv"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="24dp" android:layout_height="24dp"
android:layout_alignParentRight="true" android:layout_alignParentRight="true"
android:layout_marginRight="15dp" android:layout_marginRight="15dp"
android:gravity="center_vertical" android:gravity="center_vertical"
android:includeFontPadding="false" android:includeFontPadding="false"
android:text="0/1000" android:text="0/1000"
android:textColor="#b8b8b8" android:textColor="#b8b8b8"
android:textSize="11sp" /> android:textSize="11sp" />
<View <View
android:id="@+id/line" android:id="@+id/line"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="1dp" android:layout_height="1dp"
android:layout_below="@+id/publish_trend_content_num_tv" android:layout_below="@+id/publish_trend_content_num_tv"
android:layout_marginTop="15dp" android:layout_marginTop="15dp"
android:background="@color/platform_new_divide_color" /> android:background="#eae9e9" />
<androidx.cardview.widget.CardView <androidx.cardview.widget.CardView
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_below="@+id/line" android:layout_below="@+id/line"
android:layout_marginLeft="1dp" android:layout_marginLeft="1dp"
android:layout_marginTop="15dp" android:layout_marginTop="15dp"
android:layout_marginRight="1dp" android:layout_marginRight="1dp"
android:layout_marginBottom="@dimen/platform_dp_1" android:layout_marginBottom="@dimen/platform_dp_1"
android:elevation="1dp" android:elevation="1dp"
app:cardCornerRadius="6dp"> app:cardCornerRadius="6dp">
<RelativeLayout <RelativeLayout
android:id="@+id/publish_trend_ad_rel" android:id="@+id/publish_trend_ad_rel"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="60dp" android:layout_height="60dp"
android:background="@color/platform_color_F7F7F7" android:background="@color/platform_color_F7F7F7"
android:visibility="gone" android:visibility="gone"
tools:visibility="visible"> tools:visibility="visible">
<ImageView <ImageView
android:id="@+id/publish_trend_ad_iv" android:id="@+id/publish_trend_ad_iv"
android:layout_width="60dp" android:layout_width="60dp"
android:layout_height="60dp" android:layout_height="60dp"
android:layout_centerVertical="true" android:layout_centerVertical="true"
android:scaleType="fitXY" android:scaleType="fitXY"
android:src="@drawable/dynamic_default_img" /> android:src="@drawable/dynamic_default_img" />
<ImageView <ImageView
android:id="@+id/iv_fm" android:id="@+id/iv_fm"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_centerVertical="true" android:layout_centerVertical="true"
android:layout_marginLeft="18dp" android:layout_marginLeft="18dp"
android:src="@drawable/dynamic_img_trend_fm_play" android:src="@drawable/dynamic_img_trend_fm_play"
android:visibility="gone" android:visibility="gone"
tools:visibility="visible" /> tools:visibility="visible" />
<TextView <TextView
android:id="@+id/publish_trend_ad_tv" android:id="@+id/publish_trend_ad_tv"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_centerVertical="true" android:layout_centerVertical="true"
android:layout_marginLeft="15dp" android:layout_marginLeft="15dp"
android:layout_marginRight="15dp" android:layout_marginRight="15dp"
android:layout_toRightOf="@+id/publish_trend_ad_iv" android:layout_toRightOf="@+id/publish_trend_ad_iv"
android:maxLines="2" android:maxLines="2"
android:text="测测你的童年阴影" android:text="测测你的童年阴影"
android:textColor="#333" android:textColor="#333"
android:textSize="15sp" /> android:textSize="15sp" />
</RelativeLayout> </RelativeLayout>
</androidx.cardview.widget.CardView> </androidx.cardview.widget.CardView>
</RelativeLayout> </RelativeLayout>
</RelativeLayout> </RelativeLayout>
</androidx.core.widget.NestedScrollView>
</RelativeLayout> </RelativeLayout>
</androidx.core.widget.NestedScrollView>
<include <include
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment