Topener / nl.fokkezb.pullToRefresh

Widget to implement a table pull-to-refresh header in Titanium Alloy
184 stars 60 forks source link

exposed title, tintColor via <Widget /> #42

Closed brianjd closed 8 years ago

brianjd commented 9 years ago

Thoughts?

FokkeZB commented 9 years ago

Good idea, but I'd rather see one control property that gets (merged and) passed to both createRefreshControl and createSwipeRefresh so we don't have to update it for every new property in both APIs.

brianjd commented 9 years ago

I had considered that as well, but initially didn't proceed because I didn't immediately notice a way to programmatically set colors. But after reviewing Ti.SwipeRefreshLayout, it appears I would have to submit a PR over there as well to expose setColorScheme method to bypass the static resource strings it references. Even then, to simplify use of this widget when targeting both platforms, I'm guessing the idea could be to pass an array of colors during configuration. If IOS, the first can be used as the tint. Then on Android, the full array used as the scheme. Any other approaches?

FokkeZB commented 9 years ago

@brianjd there's a ticket for that ;) https://github.com/raymondkam/Ti.SwipeRefreshLayout/issues/2

Sure, if we can synchronise colours that would be best, but then I'd still prefer to be able to pass the full params dictionary and then support some shared property that translate to the os-specific properties to set.

FokkeZB commented 8 years ago

Closing for inactivity