Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Share Extension Status bar style

When creating a fullscreen share extension, is there a way to control the status bar?

I tried:

  • view controller based status bar + preferredStatusBarStyle
  • status bar style
  • status bar is initially hidden

Nothing seems to affect the status bar, it is just inherited from the view that opened the share extension. Is there a workaround or is that by design how it must work?

like image 735
Jacob K Avatar asked Sep 17 '14 17:09

Jacob K


People also ask

How do I use Preferredstatus Barstyle in Swift?

If you have preferredStatusBarStyle returning a different preferred status bar style based on something that changes inside of your view controller (for example, whether the scroll position or whether a displayed image is dark), then you will want to call setNeedsStatusBarAppearanceUpdate() when that state changes.

Where is the status bar on iPhone?

The icons in the status bar at the top of the screen provide information about iPhone. On an iPhone with Face ID, there are additional status icons at the top of Control Center.

What is preferredStatusBarStyle?

preferredStatusBarStyle (doc) - The preferred status bar style for the view controller. Subclass or extend UINavigationController class MyNavigationController: UINavigationController { override var preferredStatusBarStyle: UIStatusBarStyle { .lightContent } }


1 Answers

There's currently no way to change the status bar style for an extension view (http://openradar.appspot.com/radar?id=6397505050771456). It seems like the status bar for the extension uses the same style as the app that called the extension.

like image 138
Daniel Ramos Avatar answered Oct 17 '22 00:10

Daniel Ramos