From 9f6d441ad1de6bbb340462899b1c4a2ca3d4ddf3 Mon Sep 17 00:00:00 2001 From: kehaoyuan Date: Thu, 18 Jul 2019 15:04:20 +0800 Subject: [PATCH] =?UTF-8?q?=E7=A4=BE=E5=8C=BA=E6=90=9C=E7=B4=A2=E6=A0=B7?= =?UTF-8?q?=E5=BC=8F=E4=BF=AE=E6=94=B9=E4=BB=A5=E5=8F=8A=E6=9C=80=E7=83=AD?= =?UTF-8?q?=E6=A8=A1=E5=9D=97=E5=A2=9E=E5=8A=A0=E9=97=AE=E9=A2=98=E5=86=85?= =?UTF-8?q?=E5=AE=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/gh/common/util/DataLogUtils.java | 10 +- .../gamecenter/adapter/ImagePagerAdapter.java | 6 +- .../questions/edit/QuestionEditViewModel.kt | 8 +- .../search/AskSearchNormalItemViewHolder.java | 2 - .../qa/search/base/BaseAskSearchAdapter.kt | 2 +- .../qa/search/hottest/HottestAdapter.kt | 94 ++++++++--- .../qa/search/newest/NewestAdapter.kt | 4 +- .../qa/search/question/QuestionAdapter.kt | 7 +- .../ic_right_arrow.png | Bin .../ic_right_arrow_darker.png | Bin .../drawable-xxhdpi/search_answer_icon.png | Bin 0 -> 3111 bytes .../drawable-xxhdpi/search_article_icon.png | Bin 0 -> 3368 bytes .../drawable-xxhdpi/search_column_icon.png | Bin 0 -> 2134 bytes .../drawable-xxhdpi/search_question_icon.png | Bin 0 -> 3326 bytes .../search_special_column_icon.png | Bin 0 -> 1490 bytes app/src/main/res/layout/ask_search_item.xml | 137 ++++++++-------- .../res/layout/ask_search_question_item.xml | 71 +++++---- .../layout/community_search_columm_item.xml | 149 +++++++++--------- .../community_search_special_columm_item.xml | 145 +++++++++-------- 19 files changed, 344 insertions(+), 291 deletions(-) rename app/src/main/res/{drawable-xhdpi => drawable-xxhdpi}/ic_right_arrow.png (100%) rename app/src/main/res/{drawable-xhdpi => drawable-xxhdpi}/ic_right_arrow_darker.png (100%) create mode 100644 app/src/main/res/drawable-xxhdpi/search_answer_icon.png create mode 100644 app/src/main/res/drawable-xxhdpi/search_article_icon.png create mode 100644 app/src/main/res/drawable-xxhdpi/search_column_icon.png create mode 100644 app/src/main/res/drawable-xxhdpi/search_question_icon.png create mode 100644 app/src/main/res/drawable-xxhdpi/search_special_column_icon.png diff --git a/app/src/main/java/com/gh/common/util/DataLogUtils.java b/app/src/main/java/com/gh/common/util/DataLogUtils.java index 36139e0d19..725136b95f 100644 --- a/app/src/main/java/com/gh/common/util/DataLogUtils.java +++ b/app/src/main/java/com/gh/common/util/DataLogUtils.java @@ -27,13 +27,13 @@ import okhttp3.ResponseBody; public class DataLogUtils { // 轮播图 - public static void uploadLunbotuLog(Context context, String type, String title, String location) { + public static void uploadLunbotuLog(Context context, String type, String text, String index, String source) { Map map = new HashMap<>(); - map.put("location", location); + map.put("index", index); map.put("type", type); - map.put("title", title); - map.put("form", "click"); - uploadLog(context, "lunbotu", map); + map.put("text", text); + map.put("source", source); + uploadLog(context, "slide", map); } // 上传日志 diff --git a/app/src/main/java/com/gh/gamecenter/adapter/ImagePagerAdapter.java b/app/src/main/java/com/gh/gamecenter/adapter/ImagePagerAdapter.java index 108ef3552a..f3549e641e 100644 --- a/app/src/main/java/com/gh/gamecenter/adapter/ImagePagerAdapter.java +++ b/app/src/main/java/com/gh/gamecenter/adapter/ImagePagerAdapter.java @@ -81,12 +81,12 @@ public class ImagePagerAdapter extends RecyclingPagerAdapter { // 首页轮播图数据统计 DataLogUtils.uploadLunbotuLog(mContext, slideEntity.getType(), - slideEntity.getText(), String.valueOf(getPosition(position) % size + 1)); + slideEntity.getText(), String.valueOf(getPosition(position) % size + 1), mSource); - String entrance = StringUtils.buildString("(游戏-专题:滚动图[" + String entrance = StringUtils.buildString("(", mSource, "-轮播图[" , slideEntity.getText() , "=", slideEntity.getType() - , "=", String.valueOf(size + 1) + , "=", String.valueOf(getPosition(position) % size + 1) , "])"); DataUtils.onMtaEvent(mContext, "轮播图", mSource, String.valueOf(getPosition(position) % size + 1)); diff --git a/app/src/main/java/com/gh/gamecenter/qa/questions/edit/QuestionEditViewModel.kt b/app/src/main/java/com/gh/gamecenter/qa/questions/edit/QuestionEditViewModel.kt index b6f1b41522..d1fb105c7c 100644 --- a/app/src/main/java/com/gh/gamecenter/qa/questions/edit/QuestionEditViewModel.kt +++ b/app/src/main/java/com/gh/gamecenter/qa/questions/edit/QuestionEditViewModel.kt @@ -333,10 +333,12 @@ class QuestionEditViewModel(application: Application) : AndroidViewModel(applica val body = RequestBody.create(MediaType.parse("application/json"), GsonUtils.toJson(entity)) mApiService.patchQuestions(body, questionEntity?.id) // patch } else { - val postContent = GsonUtils.toJson(entity) - if (isForce) { // 标题重复提示后强制提交 - val bodyJson = JSONObject(postContent) + val postContent = if (isForce) { // 标题重复提示后强制提交 + val bodyJson = JSONObject(GsonUtils.toJson(entity)) bodyJson.put("again", true) + bodyJson.toString() + } else { + GsonUtils.toJson(entity) } val body = RequestBody.create(MediaType.parse("application/json"), postContent) mApiService.postQuestions(body, communityId) // add diff --git a/app/src/main/java/com/gh/gamecenter/qa/search/AskSearchNormalItemViewHolder.java b/app/src/main/java/com/gh/gamecenter/qa/search/AskSearchNormalItemViewHolder.java index 70557d40eb..4de216ea1a 100644 --- a/app/src/main/java/com/gh/gamecenter/qa/search/AskSearchNormalItemViewHolder.java +++ b/app/src/main/java/com/gh/gamecenter/qa/search/AskSearchNormalItemViewHolder.java @@ -26,8 +26,6 @@ public class AskSearchNormalItemViewHolder extends BaseRecyclerViewHolder(context: Context, id, UserManager.getInstance().community, mEntrance, mPath)) postSearchLogAndSearchHistory() } + private fun postSearchLogAndSearchHistory() { if (mContext is AskSearchActivity) { (mContext as AskSearchActivity).postLog(false) diff --git a/app/src/main/java/com/gh/gamecenter/qa/search/hottest/HottestAdapter.kt b/app/src/main/java/com/gh/gamecenter/qa/search/hottest/HottestAdapter.kt index b60b195caa..8214d5c981 100644 --- a/app/src/main/java/com/gh/gamecenter/qa/search/hottest/HottestAdapter.kt +++ b/app/src/main/java/com/gh/gamecenter/qa/search/hottest/HottestAdapter.kt @@ -1,21 +1,29 @@ package com.gh.gamecenter.qa.search.hottest import android.content.Context +import android.graphics.drawable.Drawable import androidx.recyclerview.widget.RecyclerView import android.text.Html import android.view.View import android.view.ViewGroup +import androidx.databinding.DataBindingUtil import com.gh.base.BaseRecyclerViewHolder import com.gh.common.constant.ItemViewType +import com.gh.common.util.DisplayUtils import com.gh.common.util.ImageUtils import com.gh.common.util.NumberUtils import com.gh.gamecenter.R import com.gh.gamecenter.baselist.NormalListViewModel +import com.gh.gamecenter.databinding.AskSearchQuestionItemBinding import com.gh.gamecenter.databinding.CommunitySearchColummItemBinding import com.gh.gamecenter.databinding.CommunitySearchSpecialColummItemBinding +import com.gh.gamecenter.qa.entity.Questions import com.gh.gamecenter.qa.entity.SearchHottestEntity import com.gh.gamecenter.qa.search.AskSearchNormalItemViewHolder +import com.gh.gamecenter.qa.search.AskSearchQuestionItemViewHolder import com.gh.gamecenter.qa.search.base.BaseAskSearchAdapter +import com.gh.gamecenter.qa.search.hottest.HottestAdapter.ResourceImageGetter.Companion.addHintIconToTitle +import com.halo.assistant.HaloApp class HottestAdapter(context: Context, entrance: String, @@ -42,13 +50,16 @@ class HottestAdapter(context: Context, "community_column" -> { COLUMN_TYPE } + "question" -> { + QUESTION_TYPE + } else -> { ANSWER_TYPE } } } - override fun onCreateBodyViewHolder(parent: ViewGroup, viewType: Int): androidx.recyclerview.widget.RecyclerView.ViewHolder { + override fun onCreateBodyViewHolder(parent: ViewGroup, viewType: Int): RecyclerView.ViewHolder { return when (viewType) { COLUMN_TYPE -> { val view = mLayoutInflater.inflate(R.layout.community_search_columm_item, parent, false) @@ -58,6 +69,10 @@ class HottestAdapter(context: Context, val view = mLayoutInflater.inflate(R.layout.community_search_special_columm_item, parent, false) SpecialColumnViewHolder(CommunitySearchSpecialColummItemBinding.bind(view)) } + QUESTION_TYPE -> { + val view = mLayoutInflater.inflate(R.layout.ask_search_question_item, parent, false) + return AskSearchQuestionItemViewHolder(AskSearchQuestionItemBinding.bind(view)) + } else -> { val view = mLayoutInflater.inflate(R.layout.ask_search_item, parent, false) AskSearchNormalItemViewHolder(view) @@ -65,65 +80,75 @@ class HottestAdapter(context: Context, } } - override fun onBindBodyViewHolder(holder: androidx.recyclerview.widget.RecyclerView.ViewHolder, position: Int) { + override fun onBindBodyViewHolder(holder: RecyclerView.ViewHolder, position: Int) { + val entity = mEntityList[position] when (holder) { is AskSearchNormalItemViewHolder -> { if (getItemViewType(position) == ARTICLE_TYPE) { - val entity = mEntityList[position] if (entity.images.isNotEmpty()) { holder.mImage.visibility = View.VISIBLE ImageUtils.display(holder.mImage, entity.images[0]) } else { holder.mImage.visibility = View.GONE } - holder.mTopIcon.visibility = if (entity.topSearchType == "community_article") { - View.VISIBLE + + val title = if (entity.topSearchType == "community_article") { + Html.fromHtml(addHintIconToTitle(ARTICLE_TYPE, replayKeyword(entity.title)), + ResourceImageGetter(), null) } else { - View.GONE + Html.fromHtml(replayKeyword(entity.title)) } + holder.mTitle.text = title + holder.mAnswerCount.visibility = View.GONE holder.mAnswerCount.text = mContext.getString(R.string.ask_answer_count, NumberUtils.transSimpleCount(entity.count.comment)) holder.mVoteCount.text = mContext.getString(R.string.ask_vote_count, NumberUtils.transSimpleCount(entity.count.vote)) - holder.mTitle.text = Html.fromHtml(replayKeyword(entity.title)) holder.mContent.text = Html.fromHtml(replayKeyword(entity.brief)) holder.itemView.setOnClickListener { skipArticleDetail(entity.id) } } else { - val searchEntity = mEntityList[position] - val question = searchEntity.question - if (searchEntity.images.isNotEmpty()) { + val question = entity.question + + if (entity.images.isNotEmpty()) { holder.mImage.visibility = View.VISIBLE - ImageUtils.display(holder.mImage, searchEntity.images[0]) + ImageUtils.display(holder.mImage, entity.images[0]) } else { holder.mImage.visibility = View.GONE } - holder.mTopIcon.visibility = if (searchEntity.topSearchType == "answer") { - View.VISIBLE + + val title = if (entity.topSearchType == "answer") { + Html.fromHtml(addHintIconToTitle(ANSWER_TYPE, replayKeyword(question.title)), + ResourceImageGetter(), null) } else { - View.GONE + Html.fromHtml(replayKeyword(question.title)) } + holder.mTitle.text = title + holder.mAnswerCount.visibility = View.GONE holder.mAnswerCount.text = mContext.getString(R.string.ask_answer_count, - NumberUtils.transSimpleCount(searchEntity.count.answer)) + NumberUtils.transSimpleCount(entity.count.answer)) holder.mVoteCount.text = mContext.getString(R.string.ask_vote_count, - NumberUtils.transSimpleCount(searchEntity.count.vote)) - holder.mTitle.text = Html.fromHtml(replayKeyword(question.title)) - holder.mContent.text = Html.fromHtml(replayKeyword(searchEntity.brief)) + NumberUtils.transSimpleCount(entity.count.vote)) + holder.mContent.text = Html.fromHtml(replayKeyword(entity.brief)) holder.mTitle.setOnClickListener { skipQuestionDetail(question) } - holder.itemView.setOnClickListener { skipAnswerDetail(searchEntity.id) } + holder.itemView.setOnClickListener { skipAnswerDetail(entity.id) } } } is ColumnViewHolder -> { - val entity = mEntityList[position] holder.binding.data = entity holder.itemView.setOnClickListener { skipColumn(entity.id) } } is SpecialColumnViewHolder -> { - val entity = mEntityList[position] holder.binding.data = entity holder.itemView.setOnClickListener { skipSpecialColumn(entity.id) } } + is AskSearchQuestionItemViewHolder -> { + holder.binding.questionHintIcon.visibility = View.VISIBLE + holder.binding.questionsTitle.text = Html.fromHtml(replayKeyword(entity.title)) + holder.binding.questionsAnswerCount.text = (NumberUtils.transSimpleCount(entity.count.answer) + " 回答") + holder.itemView.setOnClickListener { skipQuestionDetail(Questions(id = entity.id)) } + } } } @@ -132,9 +157,36 @@ class HottestAdapter(context: Context, const val SPECIAL_COLUMN_TYPE = 201 const val COLUMN_TYPE = 202 const val ARTICLE_TYPE = 203 + const val QUESTION_TYPE = 204 } class ColumnViewHolder(val binding: CommunitySearchColummItemBinding) : BaseRecyclerViewHolder(binding.root) class SpecialColumnViewHolder(val binding: CommunitySearchSpecialColummItemBinding) : BaseRecyclerViewHolder(binding.root) + + class ResourceImageGetter : Html.ImageGetter { + override fun getDrawable(source: String): Drawable { + val drawable = if (source.contains("answer")) { + HaloApp.getInstance().application.resources.getDrawable(R.drawable.search_answer_icon) + } else { + HaloApp.getInstance().application.resources.getDrawable(R.drawable.search_article_icon) + } + drawable.setBounds(0, 0, drawable.intrinsicWidth, drawable.intrinsicHeight) + return drawable + } + + companion object { + fun addHintIconToTitle(type: Int, title: String?): String { + return when { + ANSWER_TYPE == type -> { + "\u00A0\u00A0\u00A0$title" + } + ARTICLE_TYPE == type -> { + "\u00A0\u00A0\u00A0$title" + } + else -> throw IllegalStateException("$type not found") + } + } + } + } } \ No newline at end of file diff --git a/app/src/main/java/com/gh/gamecenter/qa/search/newest/NewestAdapter.kt b/app/src/main/java/com/gh/gamecenter/qa/search/newest/NewestAdapter.kt index babff0526e..48423cf16c 100644 --- a/app/src/main/java/com/gh/gamecenter/qa/search/newest/NewestAdapter.kt +++ b/app/src/main/java/com/gh/gamecenter/qa/search/newest/NewestAdapter.kt @@ -30,12 +30,12 @@ class NewestAdapter(context: Context, } } - override fun onCreateBodyViewHolder(parent: ViewGroup, viewType: Int): androidx.recyclerview.widget.RecyclerView.ViewHolder { + override fun onCreateBodyViewHolder(parent: ViewGroup, viewType: Int): RecyclerView.ViewHolder { val view = mLayoutInflater.inflate(R.layout.ask_search_item, parent, false) return AskSearchNormalItemViewHolder(view) } - override fun onBindBodyViewHolder(holder: androidx.recyclerview.widget.RecyclerView.ViewHolder, position: Int) { + override fun onBindBodyViewHolder(holder: RecyclerView.ViewHolder, position: Int) { if (getItemViewType(position) == HottestAdapter.ANSWER_TYPE) { holder as AskSearchNormalItemViewHolder val searchEntity = mEntityList[position] diff --git a/app/src/main/java/com/gh/gamecenter/qa/search/question/QuestionAdapter.kt b/app/src/main/java/com/gh/gamecenter/qa/search/question/QuestionAdapter.kt index c17454ab55..bbfbd25297 100644 --- a/app/src/main/java/com/gh/gamecenter/qa/search/question/QuestionAdapter.kt +++ b/app/src/main/java/com/gh/gamecenter/qa/search/question/QuestionAdapter.kt @@ -8,6 +8,7 @@ import android.view.ViewGroup import com.gh.common.util.NumberUtils import com.gh.gamecenter.R import com.gh.gamecenter.baselist.NormalListViewModel +import com.gh.gamecenter.databinding.AskSearchQuestionItemBinding import com.gh.gamecenter.qa.entity.Questions import com.gh.gamecenter.qa.search.AskSearchQuestionItemViewHolder import com.gh.gamecenter.qa.search.base.BaseAskSearchAdapter @@ -22,12 +23,12 @@ class QuestionAdapter(context: Context, return oldItem?.id == newItem?.id } - override fun onCreateBodyViewHolder(parent: ViewGroup, viewType: Int): androidx.recyclerview.widget.RecyclerView.ViewHolder { + override fun onCreateBodyViewHolder(parent: ViewGroup, viewType: Int): RecyclerView.ViewHolder { val view = mLayoutInflater.inflate(R.layout.ask_search_question_item, parent, false) - return AskSearchQuestionItemViewHolder(DataBindingUtil.bind(view)!!) + return AskSearchQuestionItemViewHolder(AskSearchQuestionItemBinding.bind(view)) } - override fun onBindBodyViewHolder(holder: androidx.recyclerview.widget.RecyclerView.ViewHolder, position: Int) { + override fun onBindBodyViewHolder(holder: RecyclerView.ViewHolder, position: Int) { if (holder is AskSearchQuestionItemViewHolder) { val entity = mEntityList[position] holder.binding.questionsTitle.text = Html.fromHtml(replayKeyword(entity.title)) diff --git a/app/src/main/res/drawable-xhdpi/ic_right_arrow.png b/app/src/main/res/drawable-xxhdpi/ic_right_arrow.png similarity index 100% rename from app/src/main/res/drawable-xhdpi/ic_right_arrow.png rename to app/src/main/res/drawable-xxhdpi/ic_right_arrow.png diff --git a/app/src/main/res/drawable-xhdpi/ic_right_arrow_darker.png b/app/src/main/res/drawable-xxhdpi/ic_right_arrow_darker.png similarity index 100% rename from app/src/main/res/drawable-xhdpi/ic_right_arrow_darker.png rename to app/src/main/res/drawable-xxhdpi/ic_right_arrow_darker.png diff --git a/app/src/main/res/drawable-xxhdpi/search_answer_icon.png b/app/src/main/res/drawable-xxhdpi/search_answer_icon.png new file mode 100644 index 0000000000000000000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`o}BsVN5)otB_$KWt~t>}Q4Z$xL*a&08zwAqL;3h<|`JJo~5 z)o0(so`@R%8yV;{yYWmMa~Y%qzlD)FQfiZSz}Qow^b3gp7on3j7I-9|ye!dj;Gqs< zIrNV~KiZ=U^!Gx4KapkxSmDP7oc14tka>I$EuxCOZ*j|>NjGLsSWEuhEkI~kVDM`g#h+jtdabb!c`oR2cvH-?&98xx9 zznnN@`kahd~!n9JR4es@(rf#L;&lVib>%w(VR!X$x(dX*}&IbAUwN!z1F|%li3HXiLzy0ooSm z02}y4gkMI^*w-1_S+)j9^cVBB<~;t$7wG_BF8|%;YYb+hVIn%|MgRZ+ M07*qoM6N<$f>a0=asU7T literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-xxhdpi/search_question_icon.png b/app/src/main/res/drawable-xxhdpi/search_question_icon.png new file mode 100644 index 0000000000000000000000000000000000000000..f5f9d5b0a450c00c1fa838cb1a4db265d3e203ab GIT binary patch literal 3326 zcmVPx>xJg7oRCodHT?uei)fxU@LK3zFNLWHhFo0nP*@DVaX_4A>+L_Kc?X+6k%4mma zt=iTu(vDWG)u993X6#I-j&|B9RJ&=5Z5>f4AjmFi2@--Jl0aAj30YsikCWqF-hJ=g zd*8j62fTmgzIV^L=lo~6|M}0qo%dn_h}T_RB)f;~lvsX^NS{2BSd96hLA*nxwIO)) zL#Bx27Y2_vhp~4CVjU8bJ)oG?a?`*SvDljKm?ECi7Ks%VL^e;Ir$joMf^V**TBLAD z@OX0=6K5bM>p(;|<|)n-A@Q&)J?9cT6huyEYYg48(4RyhE8MLg+bLfw)WyUtqR3 z+#Mp9An}C7-R$GYr7;8X!f3e5xTBKw)lQdZb+;b2!~j?)$fJ(+%2N9Kk8wIDcj_is} zg-bv+pA%WIQl#H-$UaoxyP}!spbd(7MIr;Mqv`u4)=Ibp)Th75uvsFDpA;E7GrFk> zN{}ubBvSK5kws65T>H34QCW0jxI|j&6KX#TKtP0ofg%fkDYCh*$br==FU(JEP>f}| zK2X1M3H)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/drawable-xxhdpi/search_special_column_icon.png new file mode 100644 index 0000000000000000000000000000000000000000..46ecfa10198f48ffcae7dc8ef7de479f156fc944 GIT binary patch literal 1490 zcmV;@1ugoCP)Px)j7da6RA>d&T1{*lRSL_i>j-GYRx+C&wH1VIIdf*|77RETha6F)^r zSg2II$1i7Jr)Lc+Oqz6>FPE{j8>jV@eifZco`VBL?w!6Fb zt~cJT8?R(}_x;R#-+S|B=gnIX0bH@^OTFr!t4{%{#}P0ADB?oEfB@{*#Uqr2z{?1t z00@f+@|3*&=I@I~cdz25uXb1KuKK^PPDqebeA`r`-kE+$mw>07-UWEE@0}HY@G*(RQ zTWTe%C4pEv_b@8>=6a2~6F_4&@Nh9R^s`eNE|+eV1pawMnC~=r#>6^VH)C+a=r{x1 zQ7Q4cTjx&INhw~SnfRiazNQ3pv*D3Pys25IPM49ZT?4>_&CIER054cvt^DF{Hsm3s zct0#)razQ8o6}&U9a2LY?kZIl_iqUt7fQTAh7)pAw zs7Qb(i`nG7ld^WoW2yW>h4_OT33~A@Jo;er5wnZ6EMoTa?%)X;jeOAHnXoRCWV@5c z5d-73R`nUEzF`aQrXxgH%8`qiL-em@$km_H30n~^J{euQyf2uGeSYVm>>IWev932v@m@Y2?~ z4URH)$vdfSZ$_M@cCLmtP>ekcLOns#>ifd2_3xsooF@~aw&T7Pk^tVqhRH4M3qn}c zrjG?N7+&%4{#zOwaIal>vB z?DbH>R@F6+VPPbl?(mD)%?q&!1?71xI0-wg0px^|e*(svwWD5$u}e<(Sy*+^17jyQ z3X5HY*#ecZ(+tQ{meMYI(38ZRB^G+3H9+JbRw$E@i3qrlf0QoFl8%)CHPGuzlo@-N zQ{028b91yH#{4UQ1(4!I@0~qg7AE$to8+bA$1h}8|K5C#LXHWF--k_gZQjBhW7qcs zoZ_bVx-9|}|8EL_ujzN3_O_>;&{PSXr23Q5$=uuITBn@adMRhj+)gLJ`T4E?u9j#P zwzVr`Gm&BW!6hxRY*$Jf{sT196MDIg+%30;PL!@xd=P*VV`ka)tVDG3T#6#oj2(#m zd3kE6-p5`?W)jiOM2XjFFl?D@!@MG)$o$&odYbBAs`WR^9GuLx3~VSfkzSg5Aj|#r z8Q>c}T%g_lYpv2M+}3{W))oiVmU^|kvT=mss=Ms<#xstf5}&Q9wdU0xORH&>=~~|1 zGMce;{uQOvhpw_9lvvIt&U2f(nIJwx!`9>4&!tlKME3G_lmfoEYO&RnQXVO0k{{K? zSqOMcE&fiS^DF^=EEsP>c5EaB=m15Gxo`FxQ;QY?%*tDGx5mG7|4zx>hH#p*zaa52 zc^H4j8Xz~u!kFxtX;#rdfD1VfPx<(l`F(`x6>KM z*{}w<(0u8qH9Po_uO$H{vy+cm9ZkqQ3%q#vWQ2V%djoS_koPQ`b+E2x3$~dqPcvZd s*tMS;m`U(`*M96_C&JG+@^hR20g}3pee`Y1vj6}907*qoM6N<$f>PJp*Z=?k literal 0 HcmV?d00001 diff --git a/app/src/main/res/layout/ask_search_item.xml b/app/src/main/res/layout/ask_search_item.xml index caaaa4dbfc..042d04a366 100644 --- a/app/src/main/res/layout/ask_search_item.xml +++ b/app/src/main/res/layout/ask_search_item.xml @@ -1,87 +1,78 @@ - + - - + android:id="@+id/ask_search_item_title" + android:layout_width="0dp" + android:layout_height="wrap_content" + android:ellipsize="end" + android:maxLines="2" + android:textColor="@color/black" + android:textSize="16sp" + android:textStyle="bold" + android:includeFontPadding="false" + app:layout_constraintLeft_toLeftOf="parent" + app:layout_constraintRight_toRightOf="parent" + app:layout_constraintTop_toTopOf="parent" /> + android:id="@+id/ask_search_item_content_container" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_marginTop="9dp" + app:layout_constraintTop_toBottomOf="@id/ask_search_item_title"> + android:id="@+id/ask_search_item_content" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_marginRight="5dp" + android:layout_toLeftOf="@+id/ask_search_item_image" + android:ellipsize="end" + android:lineSpacingMultiplier="1.2" + android:maxLines="3" + android:textColor="@color/title" + android:textSize="14sp" /> - + android:id="@+id/ask_search_item_image" + android:layout_width="90dp" + android:layout_height="60dp" + android:layout_alignParentRight="true" + android:visibility="visible" /> + + android:id="@+id/ask_search_item_votecount" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_marginTop="7dp" + android:textColor="@color/hint" + android:textSize="12sp" + app:layout_constraintLeft_toLeftOf="parent" + app:layout_constraintTop_toBottomOf="@id/ask_search_item_content_container" + tools:text="235赞同" /> + android:id="@+id/ask_search_item_answercount" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_marginLeft="12dp" + android:layout_marginTop="7dp" + android:textColor="@color/hint" + android:textSize="12sp" + app:layout_constraintLeft_toRightOf="@id/ask_search_item_votecount" + app:layout_constraintTop_toBottomOf="@id/ask_search_item_content_container" + tools:text="235回答" /> - \ No newline at end of file + \ No newline at end of file diff --git a/app/src/main/res/layout/ask_search_question_item.xml b/app/src/main/res/layout/ask_search_question_item.xml index 65c4d19821..5fa232c8db 100644 --- a/app/src/main/res/layout/ask_search_question_item.xml +++ b/app/src/main/res/layout/ask_search_question_item.xml @@ -1,38 +1,51 @@ - + + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:background="@android:color/white" + android:paddingLeft="20dp" + android:paddingTop="17dp" + android:paddingRight="20dp" + android:paddingBottom="18dp"> + + + android:id="@+id/questions_title" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:includeFontPadding="false" + android:maxLines="2" + android:textColor="@color/black" + android:textSize="14sp" + android:textStyle="bold" + app:layout_constraintBottom_toTopOf="@id/questions_answer_count" + app:layout_constraintLeft_toLeftOf="parent" + app:layout_constraintTop_toBottomOf="@id/question_hint_icon" /> + android:id="@+id/questions_answer_count" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_marginTop="24dp" + android:includeFontPadding="false" + android:textColor="@color/button_gray" + android:textSize="11dp" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintTop_toBottomOf="@id/questions_title" /> - + - \ No newline at end of file + \ No newline at end of file diff --git a/app/src/main/res/layout/community_search_columm_item.xml b/app/src/main/res/layout/community_search_columm_item.xml index 6fa283fe4b..2f85d4c5bc 100644 --- a/app/src/main/res/layout/community_search_columm_item.xml +++ b/app/src/main/res/layout/community_search_columm_item.xml @@ -1,92 +1,89 @@ - + - + + name="data" + type="com.gh.gamecenter.qa.entity.SearchHottestEntity" /> - + - + + android:id="@+id/column_name" + android:layout_width="wrap_content" + android:layout_height="45dp" + android:drawableLeft="@drawable/search_column_icon" + android:drawablePadding="6dp" + android:gravity="center_vertical" + android:text="专题" + android:textColor="@color/text_3a3a3a" + android:textSize="14sp" + app:layout_constraintLeft_toLeftOf="parent" + app:layout_constraintTop_toTopOf="parent" /> - - + android:id="@+id/column_skip" + android:layout_width="wrap_content" + android:layout_height="45dp" + android:drawableRight="@drawable/ic_right_arrow_darker" + android:gravity="center_vertical" + android:text="查看 " + android:textColor="@color/text_b3b3b3" + android:textSize="12sp" + app:layout_constraintRight_toRightOf="parent" + app:layout_constraintTop_toTopOf="parent" /> + android:id="@+id/column_image" + style="@style/frescoStyle" + imageUrl="@{data.icon}" + android:layout_width="90dp" + android:layout_height="60dp" + app:layout_constraintRight_toRightOf="parent" + app:layout_constraintTop_toBottomOf="@id/column_name" /> + android:id="@+id/column_title" + android:layout_width="0dp" + android:layout_height="wrap_content" + android:layout_marginRight="12dp" + android:singleLine="true" + android:text="@{data.title}" + android:textColor="@color/tag_orange" + android:textSize="15sp" + app:layout_constraintBottom_toTopOf="@+id/column_desc" + app:layout_constraintLeft_toLeftOf="parent" + app:layout_constraintRight_toLeftOf="@id/column_image" + app:layout_constraintRight_toRightOf="parent" + app:layout_constraintTop_toTopOf="@id/column_image" + tools:text="我是大哥大哈哈哈哈哈哈哈哈哈哈哈哈和哈哈哈哈和" /> - - \ No newline at end of file + android:id="@+id/column_desc" + android:layout_width="0dp" + android:layout_height="wrap_content" + android:layout_marginTop="6dp" + android:ellipsize="end" + android:maxLines="2" + android:paddingBottom="3dp" + android:text="@{data.description}" + android:textColor="@color/text_3a3a3a" + android:textSize="12sp" + app:layout_constraintBottom_toBottomOf="@id/column_image" + app:layout_constraintLeft_toLeftOf="parent" + app:layout_constraintRight_toRightOf="@id/column_title" + app:layout_constraintTop_toBottomOf="@id/column_title" + tools:text="我是大哥大哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈" /> + + \ No newline at end of file diff --git a/app/src/main/res/layout/community_search_special_columm_item.xml b/app/src/main/res/layout/community_search_special_columm_item.xml index 5e881c079e..0fb4bc102b 100644 --- a/app/src/main/res/layout/community_search_special_columm_item.xml +++ b/app/src/main/res/layout/community_search_special_columm_item.xml @@ -1,90 +1,89 @@ - + - + + name="data" + type="com.gh.gamecenter.qa.entity.SearchHottestEntity" /> - + - + + android:id="@+id/special_column_name" + android:layout_width="wrap_content" + android:layout_height="45dp" + android:drawableLeft="@drawable/search_special_column_icon" + android:drawablePadding="6dp" + android:gravity="center_vertical" + android:text="专栏" + android:textColor="@color/text_3a3a3a" + android:textSize="14sp" + app:layout_constraintLeft_toLeftOf="parent" + app:layout_constraintTop_toTopOf="parent" /> + android:id="@+id/special_column_skip" + android:layout_width="wrap_content" + android:layout_height="45dp" + android:drawableRight="@drawable/ic_right_arrow_darker" + android:gravity="center_vertical" + android:text="查看 " + android:textColor="@color/text_b3b3b3" + android:textSize="12sp" + app:layout_constraintRight_toRightOf="parent" + app:layout_constraintTop_toTopOf="parent" /> - + android:id="@+id/special_column_image" + style="@style/frescoStyle" + imageUrl="@{data.icon}" + android:layout_width="60dp" + android:layout_height="60dp" + app:layout_constraintLeft_toLeftOf="parent" + app:layout_constraintTop_toBottomOf="@id/special_column_name" /> + android:id="@+id/special_column_title" + android:layout_width="0dp" + android:layout_height="wrap_content" + android:layout_marginLeft="12dp" + android:singleLine="true" + android:text="@{data.name}" + android:textColor="@color/tag_orange" + android:textSize="15sp" + app:layout_constraintBottom_toTopOf="@+id/special_column_desc" + app:layout_constraintLeft_toRightOf="@id/special_column_image" + app:layout_constraintRight_toRightOf="parent" + app:layout_constraintTop_toTopOf="@id/special_column_image" + tools:text="我是大哥大哈哈哈哈哈哈哈哈哈哈哈哈和哈哈哈哈和" /> - - + android:id="@+id/special_column_desc" + android:layout_width="0dp" + android:layout_height="wrap_content" + android:layout_marginTop="6dp" + android:ellipsize="end" + android:maxLines="2" + android:paddingBottom="3dp" + android:text="@{data.description}" + android:textColor="@color/text_3a3a3a" + android:textSize="12sp" + app:layout_constraintBottom_toBottomOf="@id/special_column_image" + app:layout_constraintLeft_toLeftOf="@id/special_column_title" + app:layout_constraintRight_toRightOf="parent" + app:layout_constraintTop_toBottomOf="@id/special_column_title" + tools:text="我是大哥大哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈" /> + +