Context: under most circumstances, UIKit will automatically dim the navigation bar when the keyboard pops up (unless tintAdjustmentMode is set to normal)
If ScrollingNavigationController's updateNavbarAlpha() is called while the keyboard is up, the line navigationBar.tintColor = navigationBar.tintColor.withAlphaComponent(alpha) will cause the dimmed tint to be permanent.
The events windowDidBecomeVisible and didRotate will typically be fired when the keyboard pops up. For both events showNavbar() will be invoked, which in turn will call updateNavbarAlpha() and exit immediately. This call to updateNavbarAlpha() can be harmful as described above, and I can't see a scenario where it would be helpful so I removed it completely.
Context: under most circumstances, UIKit will automatically dim the navigation bar when the keyboard pops up (unless tintAdjustmentMode is set to
normal
)If
ScrollingNavigationController
'supdateNavbarAlpha()
is called while the keyboard is up, the linenavigationBar.tintColor = navigationBar.tintColor.withAlphaComponent(alpha)
will cause the dimmed tint to be permanent.The events
windowDidBecomeVisible
anddidRotate
will typically be fired when the keyboard pops up. For both eventsshowNavbar()
will be invoked, which in turn will callupdateNavbarAlpha()
and exit immediately. This call toupdateNavbarAlpha()
can be harmful as described above, and I can't see a scenario where it would be helpful so I removed it completely.