ZXing Mobile MobileBarcodeScanner with CustomOverlay - StatusBarStyle Color

swizzyswizzy CHMember ✭✭

Hi

I have a Problem with the ZXing Mobile MobileBarcodeScanner and a CustomOverlay.

My code:

var scanner = new ZXing.Mobile.MobileBarcodeScanner(this);
scanner.UseCustomOverlay = true;
UIView view = new UIView();
view.Frame = new CGRect(
0,
0,
(float)UIScreen.MainScreen.Bounds.Size.Width,
(float)UIScreen.MainScreen.Bounds.Size.Height
);
view.BackgroundColor = UIColor.Clear;

scanner.CustomOverlay = view;

Initial i have set the UIStatusBarStyle to LightContent in the Appdelegate.
When the scannoverlay is displayed, the StatusBarText is black. If I break the scann it will again white.

Set UIApplication.SharedApplication.SetStatusBarStyle(UIStatusBarStyle.LightContent, false); again, have no effect.
UIApplication.SharedApplication.StatusBarHidden = true; Would work but I do not need..

Does anyone have a solution that the text stay white?

thx for help

Tagged:
Sign In or Register to comment.