BadgeView
BadgeView copied to clipboard
支持自由定制外观、拖拽消除的MaterialDesign风格Android BadgeView
Android Studio 4.2 suggest change jcenter() to mavenCentral(). Will mavenCentral() be supported at future updates? https://developer.android.com/studio/build/jcenter-migration
当消息数量为0的时候,红点还是数值还是1.请问如何解决
原理:从findViewById的源码中可以看出,最终调用的是findViewTraversal,因此重写BadgeContainer的findViewTraversal的查找逻辑,即可完美解决依赖id的View布局导致的findViewById错误!
设置了数字显示,但是显示的确实椭圆的
1. 设置 setBadgeGravity 中有 Gravity.CENTER ,不能 设置 setGravityOffset X 偏移 无效。 2. 重复设置背景 会 变色 3. ConstraintLayout 中子 控件 宽度为 0 , 2个 TextView 相互约束。 设置 BadgeView 导致控件显示错位 例:
neither the hide method nor the 0 input can hide the badge...

FloatingActionButton mFabButton; mFabButton = findViewById(R.id.Main_ButtonNav_fab); new QBadgeView(this).bindTarget(mFabButton).setBadgeNumber(5); 能重新悬浮 or 其它解决方法吗