Comments (5)
Hi @robmontesinos
Can I see your implementation of the visibleCells
method?
My guess is that you are not properly passing an array of UIViews, so that method call is calling setTransform on an array instead.
from amwavetransition.
Oh oh. You pretty damn smart. Here you go:
lazy var visibleCells: [AnyObject] = self.waveCells()
func waveCells() -> [AnyObject] {
var cells = [AnyObject]()
cells.append(self.mainImageView)
cells.append(self.mainTableView.visibleCells())
return cells
}
I wanted lazy initialization but maybe that was not the way to go.
from amwavetransition.
Lazy instantiation is fine, but when you append self.mainTableView.visibleCells()
you are appending an array. So your cells
array looks like this: [UIImageView, NSArray]
. In order for that to work you need to flatten the array. A fast way is to use the +=
operand instead of append
:
var cells = [AnyObject]()
cells += self.mainImageView
cells += self.mainTableView.visibleCells()
return cells
from amwavetransition.
Andrea, you rock!
Implementing the above caused a complaint - something about self.mainImageView and AnyObject not being a CGFloat.
This below does work thanks to you.
func waveCells() -> [AnyObject] {
var cells = [AnyObject]()
cells.append(self.mainImageView)
cells += self.mainTableView.visibleCells()
return cells
}
Salud!!!!
from amwavetransition.
Happy to help 👍
from amwavetransition.
Related Issues (19)
- Swipe Gesture HOT 22
- Is a transparent background of table view a must if this wave can work? HOT 1
- Gestures cause cells to be misaligned HOT 11
- Is it possible to make header and footer view also wave? HOT 3
- Crash while trying to swipe on table cell HOT 4
- UINavigationControllerOperationPop delta for fromVC HOT 2
- the background of next view controller turns to be disappeared HOT 4
- Animation curve. HOT 1
- Added some changes HOT 2
- To VC sometimes jumps on display before animating. HOT 3
- Tabbar is moved out of the screen alongside the cells HOT 11
- Swift compatibility HOT 3
- Transition between View Controllers issue HOT 3
- Multiple tableviews in one VC/Class HOT 1
- Interactive pop transition broken on iOS 8 HOT 2
- Issues with translucent navigation bar HOT 2
- Possible to get this animation to show on tableview reloadData? HOT 1
- Top layout guide not honored. HOT 8
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 amwavetransition.