Comments (10)
Hi, glad that you liked my library.
I probably understand which bug you are describing, I had it in java earlier, but it seems to be fixed now. Does it looks ok for you in common java code?
I believe that NativeScript is for cross platform, is that right? I didn't tested it on it, more over it wasn't designed for cross platforming. I think that it will require additional fixing after converting, so that I can't really help you with.
For fixing animations you can check if frame
values are initialized well at the start, that probably why you get issues with drawing it. For the worm animation those values are: frameLeftX
and frameRightX
. They should firstly initialize in setFrameValues
method after calling view constructor.
Hope it will help you,
thanks.
from pageindicatorview.
I didn't get a change to test it purely in java no. NativeScript is native-cross-platform ;) Each plugin we create can have a platform-specific part, that aims directly at android or ios libraries. So this "porting" that I'm doing is actually just a javascript-wrapper that calls the native functions, properties ect in the "PageIndicatorView" lib. https://www.nativescript.org/about
I will look more into it, and do some more testing. The hard part here is the debugging of these native libraries... These properties you mention, aren't available as public
?
from pageindicatorview.
No those are private inside a PageIndicatorView
. They are responsable for drawing each frame while animation is performing. So you just need to check if they are updating correctly for those animation, that has issues.
You can probably send me some videos or gifs and we can try to figure out what's wrong.
from pageindicatorview.
Ok, I created two .gifs, one for each animation that I have issues with.
Scale
https://dl.dropboxusercontent.com/u/33168380/scale_animation.gif
Worm
https://dl.dropboxusercontent.com/u/33168380/worm_animation.gif
from pageindicatorview.
Looks like I figured out what was the problem with worm animation and fixed it. I will appreciate if you will be able to check it from dev branch.
But I still can't reproduce issue that you have with scale animation. Maybe it is defect by porting library to native script. Can you please describe which parameters in scale animation do you use?
from pageindicatorview.
Thanks, I'll try it out.
The library is used as-is, no porting being done. NativeScript lets your write apps in JavaScript/TypeScript and XML (UI), but compiles and runs as native. Libraries used are left untouched.
Just to show you how we use native libraries, all we do is this:
var pageIndicatorView = new com.rd.PageIndicatorView(_context);
pageIndicatorView.setViewPager(_viewPager);
pageIndicatorView.setCount(_items.childrenCount);
pageIndicatorView.setAnimationType(com.rd.animation.AnimationType.SCALE);
That's it :)
from pageindicatorview.
Please see update in v0.0.7
from pageindicatorview.
I just updated to v0.0.7 and now the entire Indicator is gone, not visible at all.
If I revert back to v0.0.6 it works again, did not touch my own code.
Any special trick in order to get v0.0.7 working?
from pageindicatorview.
I have tried to use same parameters that you provided and still can't reproduce issue.
Can you please also provide layout.xml that you use?
The only reason PageIndicatorView could be invisible is that is has indicators count 0. Please make sure you set a right value.
Thanks.
from pageindicatorview.
I don't have a layout.xml since I'm using NativeScript...
I tried with and without setting the indicator count, still nothing. If I do a getCount()
after the view is loaded, it returns the proper count (5 items). I can call all properties and methods, I get no exceptions, but still no indicator is shown.
from pageindicatorview.
Related Issues (20)
- how do we change the size of the dots?
- setSelection with no animation HOT 2
- Changing radius of the selected indicator HOT 1
- PageIndicatorView only work outside viewpager HOT 4
- Increase sdk version to 29
- Issue at first point
- Can i Use this with viewFlipper?
- Can i use android:gravity to centerize page indicator in its view?
- Maybe im doing something wrong, but padding and radius in layout doesnt work to me HOT 3
- ViewPager doesn't receive setOnTouchListener with 1.0.3 Version
- What to do if the number of sections does not fit the screen?
- piv_scaleFactor seems to be ignored HOT 1
- last dot completely transparent
- 支持轮播吗
- can we change the shape of dot as line
- Support for ViewPager2 HOT 3
- Release to jitpack or mavenCentral HOT 8
- Rtl mode not working
- Unable to add lib in new created project (Android Studio Giraffe | 2022.3.1)
- App Crashes in latest version
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pageindicatorview.