Permalink
Browse files

[ios7] - fix backgroundcolor if textfield when showing the native key…

…board - this changed to transparent in ios7 which is non-readable with black characters - force it to white (as it was implicitly in older ios versions) - setting backgrouncolor doesn't work when having round colors - so just let the textfield be rough edged and be done
  • Loading branch information...
Memphiz committed Jan 14, 2014
1 parent fa6d90b commit 89d728d87c8c41a5934b95b8baa4a6c863aa26fd
Showing with 4 additions and 1 deletion.
  1. +4 −1 xbmc/osx/ios/IOSKeyboardView.mm
@@ -61,14 +61,17 @@ - (id)initWithFrame:(CGRect)frame
INPUT_BOX_HEIGHT);
_textField = [[UITextField alloc] initWithFrame:textFieldFrame];
_textField.clearButtonMode = UITextFieldViewModeAlways;
- _textField.borderStyle = UITextBorderStyleRoundedRect;
+ // UITextBorderStyleRoundedRect; - with round rect we can't control backgroundcolor
+ _textField.borderStyle = UITextBorderStyleNone;
_textField.returnKeyType = UIReturnKeyDone;
_textField.autocapitalizationType = UITextAutocapitalizationTypeNone;
+ _textField.backgroundColor = [UIColor whiteColor];
_textField.delegate = self;
CGRect labelFrame = textFieldFrame;
labelFrame.origin.x = 0;
_heading = [[UILabel alloc] initWithFrame:labelFrame];
+ _heading.backgroundColor = [UIColor whiteColor];
_heading.adjustsFontSizeToFitWidth = YES;
[self addSubview:_heading];

0 comments on commit 89d728d

Please sign in to comment.