Comments (7)
Hi. Are you using accessory views? If so, there is an issue with that that you can workaround with code at #8
from bmxswipablecell.
No, I'm not, but thanks! I have a button on each cell, and the button takes up the left side of the cell.
I did a workaround:
- Subclassed BMXSwipableCell with labels and a button (but that was hopeful thinking, the "button" can just be another view in the cell).
- Created a delegate for the subclass and named it something other than "delegate", which is already used in your library. At the TableViewController's cellForRowAtIndexPath, set the cell's delegate = self (i.e. the TVC).
- Added a UITapGestureRecognizer to contentView, set its delegate to self (i.e. the cell). The gesture recognizer doesn't work when added to the button or any other view on the cell.
- Added target action to the UITapGestureRecognizer.
- Set the action to be conditional on the tap occurring where the button is located (CGPoint tapLocation = [gestureRecognizer locationInView:self.contentView];)
- The action method calls a delegate method that the TVC executes
Hope that's helpful to someone!
from bmxswipablecell.
I understand correctly, left side? So you're setting the swipe width to full width? The sample project use button on the right as well as my main project. Maybe the issue is related to this particularity.
from bmxswipablecell.
The button is on the outer cell, not in the basement view. I use the swipe at about the same width as the sample project.
Somehow, the cell doesn't seem to recognize taps on a button placed in the scrollViewContentView.
from bmxswipablecell.
Ok, now I get it. Actually, that case was non tested: I always had output controls on the scrollViewContentView and I focused on getting UITableView native delegate messaging work. I'll take a look at the issue as soon as I have some time, maybe I'll find a way to expand BMXSwipableCell. Thank you.
from bmxswipablecell.
Yeah, that's what I figured. It's not necessarily core functionality. This library is so great and easy to customize - thanks again for creating it!
from bmxswipablecell.
You're welcome!
from bmxswipablecell.
Related Issues (13)
- LayoutSubview crashes in iOS 6.1, iOS 7 working fine HOT 1
- Item options disappear when rotating screen
- Item options disappear when cell is being updated.
- Remove Reveal.app Libraries from Frameworks HOT 1
- Tap enabled buttons in cell HOT 3
- section index title view/bar overlaps right utility button(s) when swiping right-to-left HOT 3
- Floating-point equality check HOT 1
- Autolayout Issue.
- UI has bugs
- Forward touch to UITableViewCell HOT 1
- Does not work with AutoLayout HOT 9
- Problem with accessory views HOT 1
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 bmxswipablecell.