Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot call getBarBounds from objective-c #570

Closed
ghost opened this issue Nov 25, 2015 · 1 comment
Closed

Cannot call getBarBounds from objective-c #570

ghost opened this issue Nov 25, 2015 · 1 comment

Comments

@ghost
Copy link

ghost commented Nov 25, 2015

This is not a bug but it is a problem for me because I cannot get the size of the bars in any other way.

The problem at hand is the impossibility of calling this one method because the swift implementation returns nil when no data set is found. Since CGRect in obj-c is not an object and cannot be set to nil, the method is not callable.

There is an easy workaround for this which is returning CGRectNull instead of nil. I am creating a pull request for this.

This behaviour is there since the first implementation of the method which is in this commit: 19165dd

@liuxuan30
Copy link
Member

well, if you need get the barRect, can you use protocols or add more functions to do so?

danielgindi added a commit that referenced this issue Nov 26, 2015
Make getBarBounds callable from Objective-C code (Fixes #570)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant