Not Working on swift 2.3
grantkemp opened this issue · 2 comments
Unfortunately the project doesn't build on 2.3
in dg_center:
> if usePresentationLayerIfPossible,
> let presentationLayer = layer.presentationLayer() as? CALayer {
> // Position can be used as a center, because anchorPoint is (0.5, 0.5)
> return presentationLayer.position
> }
> return center
returns the following error:
Downcast from 'CALayer?' to 'CALayer' only unwraps optionals; did you mean to use '!'?
I am not sure why that downcast is there as layer.presentationlayer() seems to return a CALayer. If its unneeded then removing the downcast allows the project to build
I will try to look into that this week.
@gontovnik I have a fix for this on my swift-2.3 branch. Its very simple, here is a diff of my branch on your 1.0.3 tag.
I'm unable to make a pull request because the 1.0.3 tag doesn't exist as the head of any branches. If you could make a swift-2.3
branch based on your 1.0.3 tag I'd be happy to make a pull request for you to merge in.