Merge branch 'bugfix/scrolling_indicator_fix' into 'develop'

scroll view indicator fix for defect: CXTDT-82115

See merge request BPHV_MIPS/mvm_core_ui!609
This commit is contained in:
Pfeil, Scott Robert 2020-10-09 14:25:47 -04:00
commit af7343b745

View File

@ -63,6 +63,16 @@ open class ScrollingViewController: ViewController {
registerForKeyboardNotifications()
}
open override func handleNewData() {
super.handleNewData()
// will change scrollView indicatorStyle automatically on the basis of backgroundColor
var greyScale: CGFloat = 0
if view.backgroundColor?.getWhite(&greyScale, alpha: nil) ?? false {
scrollView.indicatorStyle = greyScale > 0.5 ? .black : .white
}
scrollView.flashScrollIndicators()
}
//--------------------------------------------------
// MARK: - Keyboard Handling
//--------------------------------------------------