Signal-iOS/SignalMessaging/appearance
Michelle Linington a2791717fd IOS-782: +[Theme sharedInstance] re-enterant initialization
This bug fixes an issue where if the +[Theme sharedInstance] was first
initialized after AppReady and while in dark mode, we'd reenterantly
call +sharedInstance and crash on a dispatch_once assert.

This has been an existing issue that's only manifest recently due to
unrelated changes (will document below). To workaround this limitation,
we need to break the synchronous chain from +sharedInstance to
-themeDidChange. The most straightforward way to do that is to re-async.

This is a tiny bit of fallout from dc543ce. That commit did a bunch of
work to simplify OWSNavigationController's handling of its navigation
bar. Before, the navigation bar would be configured during
-[OWSNavigationController init]. It looks like UIKit lazily initializes
the navigation bar at first access, and the navigation bar would call
out to +[Theme sharedInstance].

Now, that work doesn't happen during -init. This means that the
sharesheet extension used to indirectly call +[Theme sharedInstance]
before AppReady, but now it doesn't. Now, its first call to +[Theme
sharedInstance] happens after AppReady.
2020-08-19 10:28:43 -07:00
..
OWSConversationColor.h Update and apply palette. Consolidate dupes. 2019-09-24 15:12:51 -07:00
OWSConversationColor.m Fix a bug when receiving a reaction from a user without a thread. 2020-02-04 17:15:13 -08:00
Theme.h Adjust ActionSheetController dark theme style 2020-06-25 19:04:12 -03:00
Theme.m IOS-782: +[Theme sharedInstance] re-enterant initialization 2020-08-19 10:28:43 -07:00
Theme+OWS.swift Updated icoons and design feedback 2020-08-17 22:58:39 -07:00