I have 2 buttons. Each button is bringing a subview on top of the main view.
I'm checking in each button tapped method if the other button view is active then first dismiss it and then bring up its own view but for that I need to tap button twice. Does popover passthrough-view apply here as well?
Related
Question 1:
I have a collection view and every item on collection view has a button and a label. When I click on the label, collection view delegate's function 'didSelectItemAt' does get called. However when I click on the button, 'didSelectItemAt' does not get called.
To fix this, I removed the touch-up inside action I had set on the button, but that didn't help either. How do I get 'didSelectItemAt' of collection view to be called when button is clicked?
Question 2:
For the same button described in Question 1, there are cases where I only want to show the label and not the button. However when I hide the button, it still takes up the space on the view. How can I hide the button such that it doesn't consume the space? Below is what I tried:
collectionViewCell.button.isHidden = true
collectionViewCell.button.alpha = 0
collectionViewCell.button.imageView?.alpha = 0
(First - i'm sorry about my english:).
I want to create a tutorial bubble that will pop up in some situations while using my app.
I need this popup to disappear when clicking or scrolling on every view in my VC, and i need that these buttons to do what they need to do in this click event and not only dismiss the pop up so then we will need to click on the buttons again.
I have 2 ways to do it, but every one of them have some disadvantage.
the popup view will have a transparent view with frame of the whole VC. this background view will dismiss the pop up in its touchBegin event.
but like that i can't click ob my buttons that below this popup background view.
the second option is to create the pop up without the background transparent background, so all the buttons will be clickable.
but in this situation i don't know how to listen all the buttons click event or table scroll event so i can dismiss the popup.
I don't know how to do this. I have a view created in Storyboard containing a picker wheel and slightly below a button.
Now if the user clicks a button in my view controller I want this "view container" slided in from the top and as soon as this button (within this view container) is clicked, the view should slide out to the top again. But how can I do this? As said I created this view container completely in my storyboard over my main view controller but don't know how to program this and also not what to do with the vertical constraints?
You want this view to be managed by a view controller. When the button is tapped, you call the view controller with a down animation. When the button under the picker wheel is tapped, you dismiss the view controller with a top animation.
I have a button that has a custom view that I share between several view controllers for a rightbarbutton item on the navigationitem. Sometimes the button doesn't appear, but is clickable. This button is created programmatically (not in IB).
In one case where I pop the view controller that it is invisible on (by clicking the back button) and then push it again (by putting the button that creates it), then the button shows up again.
I want to create an interaction between two view controller.
The first view controller has a button with the action to show the second view controller from the bottom to half of his height.
From there i can dismiss the second view controller, from first view controller underneath it, by using the swipe gestures slide up (full screen) and slide down (dismiss).
For example: the same interaction in Google Maps app when long pressed a point on the map. First the second view controller is shown over the map view controller than with swipe gesture you can dismiss or changed in full screen the second view controller's appearance.