0
0
Fork 0
mirror of https://github.com/YTVanced/VancedManager synced 2024-11-23 11:45:11 +00:00

ObjectAnimator tests vol.3

This commit is contained in:
X1nto 2020-05-10 17:42:49 +04:00
parent be19cde739
commit bdec6c9947

View file

@ -64,9 +64,11 @@ class HomeFragment : Home() {
activity?.runOnUiThread {
val networkErrorLayout = view?.findViewById<MaterialCardView>(R.id.home_network_wrapper)
val oa0 = ObjectAnimator.ofFloat(networkErrorLayout, "yFraction", 0f, -1f)
val oa1 = ObjectAnimator.ofFloat(networkErrorLayout, "yFraction", -1f, 0.3f)
val oa2 = ObjectAnimator.ofFloat(networkErrorLayout, "yFraction", 0.3f, 0f)
oa0.start()
networkErrorLayout?.visibility = View.VISIBLE
oa1.start()
oa2.start()
@ -112,9 +114,7 @@ class HomeFragment : Home() {
.build()
try {
connectivityManager.unregisterNetworkCallback(networkCallback)
} catch (e: Exception) {
}
} catch (e: Exception) {}
connectivityManager.registerNetworkCallback(networkRequest, networkCallback)
}