ios7

How do I make my debug app version receive production push notifications on iOS?

Deadly 提交于 2020-01-01 04:06:11
问题 My server is sporting only one version of sending push notifications, and it has my production (release) push certificate. How do I test the notifications on my debug device and debug builds, using the same production certificate? My device is sending the token, but when I attempt to send a real push notification Apple servers return status 8 error, that means that device token is incorrect. 回答1: If you want to test your app in production mode, you will need distribute the Distribution

Cursor visibility issue in ios7

那年仲夏 提交于 2020-01-01 04:04:06
问题 Simply creating a UITextField in ios7 SDK but when I enter some input, text is shown UItextField but cursor isn't. Any clue about what can be the problem? 回答1: Change the tintColor of the UITextField with a cursor [mobileTextField setTintColor:[UIColor blueColor]]; if you are use the XIb please set the tin color of UITextField Note :- This is working on IOS 7+ 回答2: As @Deepesh said, it's a matter of choosing the proper tint color. However it was not enough in my case since I am creating the

Cursor visibility issue in ios7

早过忘川 提交于 2020-01-01 04:04:03
问题 Simply creating a UITextField in ios7 SDK but when I enter some input, text is shown UItextField but cursor isn't. Any clue about what can be the problem? 回答1: Change the tintColor of the UITextField with a cursor [mobileTextField setTintColor:[UIColor blueColor]]; if you are use the XIb please set the tin color of UITextField Note :- This is working on IOS 7+ 回答2: As @Deepesh said, it's a matter of choosing the proper tint color. However it was not enough in my case since I am creating the

UITableView scrollToRowAtIndexPath scrolls to wrong offset with estimatedRowHeight on iOS 7

泄露秘密 提交于 2020-01-01 03:59:06
问题 I am using the estimatedRowHeight method from UITableView in iOS 7, which works perfectly for fast loading of a UITableView with 5000 rows of variable heights. My UITableView consists of 50 sections. Every section has 100 rows, of variable height. At the start I use estimatedRowHeight for fast-loading, but after that when I call scrollToRowAtIndexPath , my UITableView scrolls to the wrong offset . I can understand why this is, because it has an estimatedRowHeight until I scroll the entire

How to get unchanged device id from ios7 device programmatically

不羁岁月 提交于 2020-01-01 03:50:12
问题 I need to get the unique device id to populate unique user id in the database. I have used the following code to get that. NSString *strApplicationUUID= [[[UIDevice currentDevice] identifierForVendor] UUIDString]; But when I am reinstalling the app, the UUID is changing all the time. But as far as I know the device id never changes. For that I used below code with the third party SSKeychain to save and retrieve the old UDID: NSString *Appname = [[[NSBundle mainBundle] infoDictionary]

iOS 6 vs 7 appearance build settings

余生长醉 提交于 2020-01-01 03:40:28
问题 Does the deployment target of an app need to be set to iOS 7 in order to get the iOS 7 appearance on and iOS 7 device? It was that way during the beta and it still seems like it is right now due to my testing. I am currently building using iOS 7 SDK and deployment target of - let just say < iOS 7. The app runs using the iOS 6 appearance on my iOS 7 device. If I build with iOS 7 as the deployment target, the device gets the iOS 7 UI. It would be great if someone could confirm. Thanks. Other

Creating a custom MCBrowserViewController

此生再无相见时 提交于 2020-01-01 03:29:09
问题 Is there a way to create a UITableView housing the same information found in an MCBrowserViewController ? My current code only allows a standard view to be pushed that is not in the same design as my app: self.browserVC = [[MCBrowserViewController alloc] initWithServiceType:@"chat" session:self.mySession]; [self presentViewController:self.browserVC animated:YES completion:nil]; Any ideas? Thanks in advance! 回答1: Set your View Controller as the delegate to MCNearbyServiceBrowser and MCSession

How Can I indent only first line of multiline UILabel in iOS?

余生颓废 提交于 2020-01-01 02:43:11
问题 I want to add an image in start of UILabel. Label is multiline. If I use contentInset, it indent the whole label but I want to indent first line only. I have tried this so far, this doesn't work for me. UIEdgeInsets titleInsets = UIEdgeInsetsMake(0.0, 40.0, 0.0, 0.0); valueLabel.contentInset = titleInsets; It should look like this. 回答1: @DavidCaunt suggestion worked for me. I am sharing code here. NSMutableParagraphStyle *style = [[NSMutableParagraphStyle alloc] init]; style

IOS 7 UITextField resignFirstResponder BAD

萝らか妹 提交于 2020-01-01 02:41:26
问题 Im getting a crash, when using a UItextField, inside my customCell, and when i resignFirstResponder the textfield, but its not visible anymore(the table view scrolled out of window). I still can find the textfield, the pointer continues accessible, it is no null, and the crash only occurs on IOS7, on IOS6 i dont have this problem. Heres some code : The textField is a global variable. - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {

Delay of button's highlighted state

对着背影说爱祢 提交于 2020-01-01 02:28:13
问题 I have the issue in two completely different situations, which makes it really weird. Situation: A UIButton in as a subView of another UIView. Situation: UIBarButtonItem's in a UIToolBar. In both situations the buttons's are only highlighted after a slight delay, approximately .5 - 1 second. Definitely to long to highlight the view when tapping it normally. They both work perfectly on the simulator, but not on a real device (I have an iPhone 5s with iOS 7.0.4). What I tried Setting the