Closed yuchi closed 10 years ago
Not sure how the iOS version works but I don't see any other way to do that on android without custom views. So I could add classes for button and edittext if you want.
In iOS I can put inner views in the Shimmer view and they will be shimmed too. If you provided a simple View I could put whatever I want inside it and make them shimmed.
Hint: I’m not developing on Android, but on Titanium SDK, which has its own Button/TextView etc.
Ok I have an idea to solve that but I'm not sure you'll be able to apply that to titanium as you need at least a paint to apply the effect to. I'll see that next week.
Actually I made it work. https://github.com/yuchi/TiShimmer/blob/master/Android/src/it/ti/shimmer/ShimmerView.java#L199 As you can see it is also possible to actually shim the view without using an overlay.
Looking good mate. I'm going to leave the focus on the TextView and add a way to apply the effect on arbitrary views. Thanks anyway
The only problem I’m facing is that it shims away the whole canvas, also the underlaying (parent) views…
Added ShimmerButton
in version 1.2.0 if you need a custom view. I won't add a more complex way for this purpose.
Don’t worry, already solved this re-inventing the wheel :) That’s a shame that Android does not have a separate concept for views-hierarchy and rendering-tree, on iOS it’s way easier.
Currently the Shimmer is just a TextView on Steroids. Couldn’t it support any view and views hierarchy as the original iOS version does?