UIPageView swipe on dots transition in wrong direction - objective-c

I have a UIPageView controller with three view. Now the probleem is if you swipe over the view, the page scroll in the swipe direction. But if you swipe over the Page indictor dots the page scroll in the opposite direction of the swipe. Does anyone know how I can fix that?

The page indicator does not recognize swipes, it recognizes only taps.
If you tap on the right side, the next page is shown.
If you tab on the left side, the previous page is shown.
iOS recognizes the tap position where you release your finger (not where you tap down).
So when you think you swipe to the right, you release your finger at the right side and this is recognized by iOS as a tap on the right side which shows the next page.
And vice versa.

Related

React-native-navigation animate popping a screen?

So I have a react-native app which is using react-native-navigation.
Whenever I click a card in my app, it pushes me the card screen.
What I want to achieve is the following: when swiping down from that screen, as you swipe down the screen gets smaller and the other one is in the background, but I haven't found anything that can help me with that, any packages? Also, I'd have to pop the current screen to have the other one the background, but if I pop it, the current screen can't stay and get smaller as i swipe down.
So basically I need to animate a component pop.
If you haven't figured it out yet, you could show the card screen as an overlay or modal and add a swipe-down gesture to the Container component of the screen and when it reaches the bottom, you could dismissOverlay or dismissModal with no animation.

UICollectionView scrolling swipe direction on tvOS

I have a collection view in a tvOS project. The cells are fullscreen photos. The view has the default scrolling behaviour: in order to display the next photo, I have to swipe from left to right. This is completely opposite to the “natural” scrolling behaviour used elsewhere in the Apple ecosystem.
This behaviour (swipe left-to-right to display next) makes sense when there’s some apparent focus on the screen, but when there’s just the fullscreen content, it feels completely backwards. Is it possible to change it, swiping right-to-left to display next photo?
I have found a suggestions on the Apple Developer Forums to use UIPageViewController instead. That works, the scrolling direction is as expected.

interactiveGestureRecognizer and panGestureRecognizer together

I have problem. I want realize slide menu, but want keep swipe to back gesture. I add panGestureRecognizer to my View and I get undefined behavior in working app. When I swipe from edge, triggered then one or the other gesture. How can I control it or what I doing wrong?

Adding a scrollview and get it to zoom

In my iphone app, you get a UIView with a background image and a "start button".
When you hit the start button, the start button will be hidden, and your background aswell. You will see another image. You will also get a "back button".
You should be able to zoom the image and scroll around.
I want everything on the same UIView.
When you hit the back button, everything should get back to the first background image and the start button, and you should not be able to zoom or scroll.
How can I do this? And is it possible at all to hide a scroll view in order to just show a regular screen, in the same view?
Thanks in advance!
EDIT: Ok, I know how to hide the scroll view now, but when the scroll view is shown, you can't scroll! I have made the scroll view bigger than the screen and put a label below the "original screen". How to get it to scroll?
Add a UIScrollView to the main view in which you have the zoom/scrollable image. Simply remove it when the back button is pressed.

ios simulator: simulate swipe and drag

I have a UIView within a UIScrollView. When i want to simulate the drag event on the UIView, swipe event on the UIScrollView is being triggered.
As per the documentation , there isn't much of a difference between swipe and drag.
Swipe
1- Place the pointer at the start position.
2- Hold the mouse button.
3- Move the pointer in the swipe direction and release the mouse button.
Drag
1- Place the pointer at the start position.
2- Hold down the mouse button.
3- Move the pointer in the drag direction.
On an ipad I can use two fingers two swipe and one finger to drag. Now, how do i go about doing something similar on the simulator; drag instead of a swipe?
Edit 1:
I should have been clearer first up. Anyway, my problem is that the mouse drag is firing the swipe instead of drag, thereby scrolling the scroll view instead of passing on the drag event to the UIView contained by the scroll view.
I am on macbook pro. Two-finger swipe on the touchpad is being ignored. Touch and drag is causing the same thing as mouse-drag.
Thanks
See Jeff LaMarche's quick note on how to do this. It's documented in the same page you're reading, but Jeff's explanation is clearer.
If you want to simulate a two-finger gesture in the iPhone simulator, hold down the option key. You will get two dots on the screen instead of one. The two dots will default to pinching - if you bring the dot closer to the center of the screen, the other dot comes toward the center, making it easy to simulate a pinch in or pinch out.
If you want to do a different two-finger gesture, get the two dots the distance apart that you want them to be, then hold down the shift key, while still holding down the option key. That will lock the position of the two finger presses together so you can do, for example, a two-finger swipe.
see this documentation below:
iOS Simulator User Guide
Just use the mouse to drag the view, aka, left click the view then move the mouse
I ended up disabling the scrolling from the UI and added two buttons to scroll the scroll view. Since this is a work around only for the emulator, I have used #ifndef to hide the buttons while building for the device.