|
|
@@ -8,6 +8,7 @@ import androidx.recyclerview.widget.LinearLayoutManager
|
|
|
import com.adealink.frame.aab.util.getCompatColor
|
|
|
import com.adealink.frame.base.Rlt
|
|
|
import com.adealink.frame.base.fastLazy
|
|
|
+import com.adealink.frame.log.Log
|
|
|
import com.adealink.frame.mvvm.view.viewBinding
|
|
|
import com.adealink.frame.util.ONE_MINUTE
|
|
|
import com.adealink.frame.util.runOnUiThread
|
|
|
@@ -25,6 +26,7 @@ import com.adealink.weparty.module.operation.OperationModule
|
|
|
import com.adealink.weparty.module.profile.ProfileModule
|
|
|
import com.adealink.weparty.module.profile.data.Gender
|
|
|
import com.adealink.weparty.module.userlist.HomeUserListFragment
|
|
|
+import com.adealink.weparty.module.userlist.TAG_HOME_USER_LIST
|
|
|
import com.adealink.weparty.module.userlist.binder.BannerItemViewBinder
|
|
|
import com.adealink.weparty.module.userlist.binder.NoLocationDataViewBinder
|
|
|
import com.adealink.weparty.module.userlist.binder.UserInfoItemViewBinder
|
|
|
@@ -210,31 +212,44 @@ abstract class HomeBaseUserListFragment : BaseFragment(R.layout.layout_home_user
|
|
|
} else {
|
|
|
firstNonUserInfoItemPosition + 2
|
|
|
}
|
|
|
- val childView = binding.rvUserList.getChildAt(targetUserInfoItem)
|
|
|
- val itemBinding = ItemHomeUserInfoBinding.bind(childView)
|
|
|
-
|
|
|
- HomeLocalService.hasShowSayHiPopupGuide = true
|
|
|
-
|
|
|
- val sayHiPopupBinding =
|
|
|
- PopupHomeUserSayHiBinding.inflate(LayoutInflater.from(requireContext()), null, false)
|
|
|
- val popup = QMUIPopups.popup(requireContext(), ViewGroup.LayoutParams.MATCH_PARENT)
|
|
|
- .view(sayHiPopupBinding.root)
|
|
|
- .animStyle(QMUIPopup.ANIM_GROW_FROM_CENTER)
|
|
|
- .preferredDirection(QMUIPopup.DIRECTION_TOP)
|
|
|
- .arrow(false)
|
|
|
- .radius(0)
|
|
|
- .bgColor(getCompatColor(R.color.transparent))
|
|
|
- .borderWidth(0)
|
|
|
- .setFocusable(false)
|
|
|
- .setTouchable(false)
|
|
|
- .onDismiss {
|
|
|
- //先这样实现。。
|
|
|
- runOnUiThread(
|
|
|
- { HomeUserListFragment.showMessageGuide.setValue(Unit) },
|
|
|
- ONE_MINUTE
|
|
|
- )
|
|
|
+ try {
|
|
|
+ val childView = binding.rvUserList.getChildAt(targetUserInfoItem)
|
|
|
+ //childView可能为空
|
|
|
+ if (childView == null) {
|
|
|
+ return@launch
|
|
|
}
|
|
|
- .show(itemBinding.sayHiView)
|
|
|
+ val itemBinding = ItemHomeUserInfoBinding.bind(childView)
|
|
|
+
|
|
|
+ HomeLocalService.hasShowSayHiPopupGuide = true
|
|
|
+
|
|
|
+ val sayHiPopupBinding =
|
|
|
+ PopupHomeUserSayHiBinding.inflate(
|
|
|
+ LayoutInflater.from(requireContext()),
|
|
|
+ null,
|
|
|
+ false
|
|
|
+ )
|
|
|
+ val popup = QMUIPopups.popup(requireContext(), ViewGroup.LayoutParams.MATCH_PARENT)
|
|
|
+ .view(sayHiPopupBinding.root)
|
|
|
+ .animStyle(QMUIPopup.ANIM_GROW_FROM_CENTER)
|
|
|
+ .preferredDirection(QMUIPopup.DIRECTION_TOP)
|
|
|
+ .arrow(false)
|
|
|
+ .radius(0)
|
|
|
+ .bgColor(getCompatColor(R.color.transparent))
|
|
|
+ .borderWidth(0)
|
|
|
+ .setFocusable(false)
|
|
|
+ .setTouchable(false)
|
|
|
+ .onDismiss {
|
|
|
+ //先这样实现。。
|
|
|
+ runOnUiThread(
|
|
|
+ { HomeUserListFragment.showMessageGuide.setValue(Unit) },
|
|
|
+ ONE_MINUTE
|
|
|
+ )
|
|
|
+ }
|
|
|
+ .show(itemBinding.sayHiView)
|
|
|
+ } catch (e: Exception) {
|
|
|
+ Log.e(TAG_HOME_USER_LIST, "showSayHiGuide", e)
|
|
|
+ }
|
|
|
+
|
|
|
}
|
|
|
|
|
|
|