You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
session-ios/SignalMessaging/utils
Michael Kirk 3850ca29b0 Bigger hack to fix problem with lesser hack.
There were two symptoms to this bad "leave app while dismissing keyboard"
state...

The first, most noticeable symptom was that the main window no longer respected
the device orientation. This was caused by UIKit temporarily disabling
autorotate during an interactive keyboard dismissal, and not cleaning up after
itself when we hid the window mid dismissal due to our screen protection
feature. This was solved previously in: ca0a555f8

The second symptom remained, and is solved by this commit. Wherein after
getting in this bad state, the interactive keyboard dismiss function behaves
oddly. Normally when interactively dismissing the keyboard in a scroll view,
the keyboard top follows your finger, until you lift up your finger, at which
point, depending on how close you are to the bottom, the keyboard should
completely dismiss, or cancel and return to its fully popped position. In the
degraded state, the keyboard would follow your finger, but when you lifted your
finger, it would stay where your finger left it, it would not complete/cancel
the dismiss.

The solution is, instead of only re-enabling autorotate, to use a higher level
private method which is called upon complete/cancellation of the interactive
dismissal. The method, `UIScrollToDismissSupport#finishScrollViewTransition`,
as well as re-enabling autorotate, does some other work to restore the UI to
it's normal post interactive-keyboard-dismiss gesture state.

For posterity here's the decompiled pseudocode:

```
/* @class UIScrollToDismissSupport */
-(void)finishScrollViewTransition {
    *(int8_t *)&self->_scrollViewTransitionFinishing = 0x0;
    [self->_controller setInterfaceAutorotationDisabled:0x0];
    [self hideScrollViewHorizontalScrollIndicator:0x0];
    ebx = *ivar_offset(_scrollViewNotificationInfo);
    [*(self + ebx) release];
    *(self + ebx) = 0x0;
    esi = *ivar_offset(_scrollViewForTransition);
    [*(self + esi) release];
    *(self + esi) = 0x0;
    return;
}
```
6 years ago
..
AppPreferences.swift Apply design feedback from Myles. 6 years ago
Bench.swift in-conversation search 6 years ago
BlockListCache.swift Fix compiler warnings 6 years ago
BlockListUIUtils.h Use cached group details when rendering blocklist 7 years ago
BlockListUIUtils.m Apply presentAlert() throughout codebase. 6 years ago
ConversationStyle.swift Change conversation bubble colors. 7 years ago
DebugLogger.h Revert "Revert "Merge branch 'charlesmchen/debugLogs' into hotfix/2.20.1"" 7 years ago
DebugLogger.m Pull out SignalCoreKit. 7 years ago
DeviceSleepManager.swift Use swift macros for main thread assert 7 years ago
DisplayableText.swift link checks 6 years ago
FullTextSearcher.swift in-conversation search 6 years ago
ImageCache.swift Fix tests broken by SAE. 8 years ago
OWSAnyTouchGestureRecognizer.h Add stroke drawing to the image editor. 6 years ago
OWSAnyTouchGestureRecognizer.m Add stroke drawing to the image editor. 6 years ago
OWSAudioPlayer.h audio player type 7 years ago
OWSAudioPlayer.m audio player type 7 years ago
OWSAvatarBuilder.h Rework group avatars to reflect conversation colors. 7 years ago
OWSAvatarBuilder.m Constantize ConversationColorName, map previous incorrect values 7 years ago
OWSContactAvatarBuilder.h Constantize ConversationColorName, map previous incorrect values 7 years ago
OWSContactAvatarBuilder.m CR: clean up graphics context code 6 years ago
OWSFormat.h Respond to CR. 8 years ago
OWSFormat.m Respond to CR. 8 years ago
OWSGroupAvatarBuilder.h Rework group avatars to reflect conversation colors. 7 years ago
OWSGroupAvatarBuilder.m Merge remote-tracking branch 'origin/release/2.30.2' 7 years ago
OWSPreferences.h Add accessibility identifiers to notification settings views. 6 years ago
OWSPreferences.m Add accessibility identifiers to other settings views. 6 years ago
OWSScreenLock.swift Rename fail macros in Swift. 7 years ago
OWSScrubbingLogFormatter.h Sketch out SAE load screen; make a number of infrastructure changes. 8 years ago
OWSScrubbingLogFormatter.m cherry-pick Merge branch 'charlesmchen/logSdp' 7 years ago
OWSUnreadIndicator.h Revert "Revert 'new sort id'." 6 years ago
OWSUnreadIndicator.m Revert "Revert 'new sort id'." 6 years ago
OWSWindowManager.h Improve background screenshots v. orientation. 6 years ago
OWSWindowManager.m Bigger hack to fix problem with lesser hack. 6 years ago
ProximityMonitoringManager.swift Fix build break. 7 years ago
Searcher.swift Fix searching for 'note to self'. 6 years ago
ThreadUtil.h simplify completion checking - make nonnull 6 years ago
ThreadUtil.m simplify completion checking - make nonnull 6 years ago
UIGestureRecognizer+OWS.swift Pinch to change text size in image editor text tool. 6 years ago
UIImage+OWS.swift Respond to CR. 6 years ago
UIUtil.h Move the accessibility identifier macros into UIUtil.h. 6 years ago
UIUtil.m Rework conversation message bubble colors; add "conversation colors" class. 7 years ago
Weak.swift Don't de-activate audio sesion when other audio activities are happening 7 years ago