Search Results

Search found 474 results on 19 pages for 'uikit'.

Page 1/19 | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • UIKit/UiKit.h missing, on a newer version

    - by letsee
    Dear Everyone, I've a application which has been written for 2.1. Now I'm running that app on xcode 3.2.5 and SDK 4.2. Here's the problem, When I try to Build and Run, I get the following error: UIKit.framework/UIKit.h: No such file or directory In file included from users/.../classes/Radio.m UIKit.framework/UIKit.h: no such file or directory in users/.../classes/Radio.h I don't know why I'm facing that error, because the UIKit.framework is included in my projects "Frameworks" group. I've updated the OS target and other similar options, and application runs clearly without UIKit. I would appreciate it if anyone could help me through. Regards,

    Read the article

  • dyld: Library not loaded: /System/Library/Frameworks/UIKit.framework/UIKit

    - by jimbo
    Hi All, Please bear with me, newbie just learning the ropes. I am getting the below message, when I try and run my app, it quiets, but then does let me re-open fine after the first quit. I tried a few things and if I turn on if i 'activate breakpoints' it all works fine... Tried a few suggestions, 'deleting build folder', 'restarting xCode' nothing seems to work... dyld: Library not loaded: /System/Library/Frameworks/UIKit.framework/UIKit Referenced from: /Volumes/MyBook/Apps/CToolBox/build/Debug-iphonesimulator/CToolBox.app/CToolBox Reason: image not found The Debugger has exited due to signal 5 (SIGTRAP).The Debugger has exited due to signal 5 (SIGTRAP). Thanks in advance.

    Read the article

  • Strange UIKit bug, table view row stays selected

    - by Can Berk Güder
    I'm facing what appears to be a UIKit bug, and it takes the combination of two less commonly used features to reproduce it, so please bear with me here. I have quite the common view hierarchy: UITabBarController -> UINavigationController -> UITableViewController and the table view controller pushes another table view controller onto the navigation controller's stack when a row is selected. There's absolutely nothing special or fancy in the code here. However, the second UITableViewController, the "detail view controller" if you will, does two things: It sets hidesBottomBarWhenPushed to YES in its init method, so the tab bar is hidden when this controller is pushed: - (id)initWithStyle:(UITableViewStyle)style { if(self = [super initWithStyle:style]) { self.hidesBottomBarWhenPushed = YES; } return self; } It calls setToolbarHidden:NO animated:YES and setToolbarHidden:YES animated:YES on self.navigationController in viewWillAppear: and viewWillDisappear: respectively, causing the UIToolbar provided by UINavigationController to be displayed and hidden with animations: - (void)viewWillAppear:(BOOL)animated { [super viewWillAppear:animated]; [self.navigationController setToolbarHidden:NO animated:YES]; } - (void)viewWillDisappear:(BOOL)animated { [super viewWillDisappear:animated]; [self.navigationController setToolbarHidden:YES animated:YES]; } Now, if the second UITableViewController was pushed by selecting the row at the bottom of the screen (it doesn't have to be the last row) in the first controller, this row does not automatically get deselected when the user immediately or eventually returns to the first controller. Further, the row cannot be deselected by calling deselectRowAtIndexPath:animated: on self.tableView in viewWillAppear: or viewDidAppear: in the first controller. I'm guessing this is a bug in UITableViewController's drawing code which of course only draws visible rows, but unfortunately fails to determine correctly if the bottommost row will be visible in this case. I failed to find anything on this on Google or OpenRadar, and was wondering if anyone else on SO had this problem or knew a solution/workaround.

    Read the article

  • Great UIKit/Objective-C code snippets

    - by Nissan Fan
    New to Objective-C iPhone/iPod touch/iPad development, but I'm starting to discover lots of power in one-liners of code such as this: [UIApplication sharedApplication].applicationIconBadgeNumber = 10; Which will display that distinctive red notification badge on your app iphone with the number 10. Please share you favorite one or two-liners in Objective-C for the iPhone/iPod touch/iPad here. PUBLIC APIs ONLY.

    Read the article

  • Great UIKit/Objective-C one-Liners

    - by Nissan Fan
    New to Objective-C iPhone/iPod touch/iPad development, but I'm starting to discover lots of power in one-liners of code such as this: [UIApplication sharedApplication].applicationIconBadgeNumber = 10; Which will display that distinctive red notification badge on your app iphone with the number 10. Please share you favorite one-liners in Objective-C for the iPhone/iPod touch/iPad here.

    Read the article

  • Custom event loop and UIKit controls. What extra magic Apple's event loop does?

    - by tequilatango
    Does anyone know or have good links that explain what iPhone's event loop does under the hood? We are using a custom event loop in our OpenGL-based iPhone game framework. It calls our game rendering system, calls presentRenderbuffer and pumps events using CFRunLoopRunInMode. See the code below for details. It works well when we are not using UIKit controls (as a proof, try Facetap, our first released game). However, when using UIKit controls, everything almost works, but not quite. Specifically, scrolling of UIKit controls doesn't work properly. For example, let's consider following scenario. We show UIImagePickerController on top of our own view. UIImagePickerController covers our custom view We also pause our own rendering, but keep on using the custom event loop. As said, everything works, except scrolling. Picking photos works. Drilling down to photo albums works and transition animations are smooth. When trying to scroll photo album view, the view follows your finger. Problem: when scrolling, scrolling stops immediately after you lift your finger. Normally, it continues smoothly based on the speed of your movement, but not when we are using the custom event loop. It seems that iPhone's event loop is doing some magic related to UIKit scrolling that we haven't implemented ourselves. Now, we can get UIKit controls to work just fine and dandy together with our own system by using Apple's event loop and calling our own rendering via NSTimer callbacks. However, I'd still like to understand, what is possibly happening inside iPhone's event loop that is not implemented in our custom event loop. - (void)customEventLoop { OBJC_METHOD; float excess = 0.0f; while(isRunning) { animationInterval = 1.0f / openGLapp->ticks_per_second(); // Calculate the target time to be used in this run of loop float wait = max(0.0, animationInterval - excess); Systemtime target = Systemtime::now().after_seconds(wait); Scope("event loop"); NSAutoreleasePool* pool = [[ NSAutoreleasePool alloc] init]; // Call our own render system and present render buffer [self drawView]; // Pump system events [self handleSystemEvents:target]; [pool release]; excess = target.seconds_to_now(); } } - (void)drawView { OBJC_METHOD; // call our own custom rendering bool bind = openGLapp->app_render(); // bind the buffer to be THE renderbuffer and present its contents if (bind) { opengl::bind_renderbuffer(renderbuffer); [context presentRenderbuffer:GL_RENDERBUFFER_OES]; } } - (void) handleSystemEvents:(Systemtime)target { OBJC_METHOD; SInt32 reason = 0; double time_left = target.seconds_since_now(); if (time_left <= 0.0) { while((reason = CFRunLoopRunInMode(kCFRunLoopDefaultMode, 0, TRUE)) == kCFRunLoopRunHandledSource) {} } else { float dt = time_left; while((reason = CFRunLoopRunInMode(kCFRunLoopDefaultMode, dt, FALSE)) == kCFRunLoopRunHandledSource) { double time_left = target.seconds_since_now(); if (time_left <= 0.0) break; dt = (float) time_left; } } }

    Read the article

  • Semantic Fish-eye zoom on table cells in UIKit?

    - by niblha
    How would I go about implementing a table view that looks and works something as illustrated in the link below, with UIKit for the iPhone? http://img442.imageshack.us/img442/4177/uifisheyeview.png I was thinking of using UITableView, and was looking a bit at the UITableViewDelegate methods tableView:willDisplayCell:forRowAtIndexPath: tableView:heightForRowAtIndexPath: But it seems as the UITableView will modify the cell frames after these methods are called and just before the cells are drawn? Maybe skipping the UITableView and go straight for some subclassing of a UIScrollView would be a better approach? So my question is basically that I would just like some overall thought in what might be the best ways to use existing UIKit components to implement this type of table view.

    Read the article

  • Sanity check: UIBarButtonItem crashes trying to perform action

    - by Giao
    One of my users is reporting a crash on his device, an iPhone 3GS. Other devices of the same type are not reporting similar behavior. He's sent me a crash log and based on reading it, I'm not sure how to proceed. I hope I'm not interpreting the crash log incorrectly but it doesn't look like my action has been called yet. This is how I'm creating and setting up the UIBarButtonItem: - (void)viewDidLoad { [super viewDidLoad]; UIBarButtonItem *addButton = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemAdd target:self action:@selector(addLog:)]; self.navigationItem.rightBarButtonItem = addButton; [addButton release]; } This is the my action method: - (IBAction)addLog:(id)sender { MyViewController *myController = [[MyViewController alloc] initWithNibName:@"MyNib" bundle:nil]; UINavigationController *subNavigationController = [[UINavigationController alloc] initWithRootViewController: myController]; [self presentModalViewController:subNavigationController animated:YES]; [myController release]; [subNavigationController release]; } This is the crash log: Exception Type: EXC_CRASH (SIGABRT) Exception Codes: 0x00000000, 0x00000000Crashed Thread: 0 Thread 0 Crashed: 0 libSystem.B.dylib 0x0007e98c __kill + 81 libSystem.B.dylib 0x0007e97c kill + 4 2 libSystem.B.dylib 0x0007e96e raise + 10 3 libSystem.B.dylib 0x0009361a abort + 34 4 MyApp 0x000042e8 0x1000 + 13032 5 CoreFoundation 0x00058ede -[NSObject performSelector:withObject:withObject:] + 18 6 UIKit 0x0004205e -[UIApplication sendAction:to:from:forEvent:] + 78 7 UIKit 0x00094d4e -[UIBarButtonItem(Internal) _sendAction:withEvent:] + 86 8 CoreFoundation 0x00058ede -[NSObject performSelector:withObject:withObject:] + 18 9 UIKit 0x0004205e -[UIApplication sendAction:to:from:forEvent:] + 78 10 UIKit 0x00041ffe -[UIApplication sendAction:toTarget:fromSender:forEvent:] + 26 11 UIKit 0x00041fd0 -[UIControl sendAction:to:forEvent:] + 32 12 UIKit 0x00041d2a -[UIControl(Internal) _sendActionsForEvents:withEvent:] + 350 13 UIKit 0x0004263e -[UIControl touchesEnded:withEvent:] + 330 14 UIKit 0x00041656 -[UIWindow _sendTouchesForEvent:] + 318 15 UIKit 0x00041032 -[UIWindow sendEvent:] + 74

    Read the article

  • [NSCFNumber _isNaturallyRTL]: unrecognized selector sent to instance 0x605ac10

    - by Risma
    my app got crashed an showed that keyword. There is no error and warning. can some body help me?? this is stack that showed : Call stack at first throw: ( 0 CoreFoundation 0x012ccbe9 __exceptionPreprocess + 185 1 libobjc.A.dylib 0x014215c2 objc_exception_throw + 47 2 CoreFoundation 0x012ce6fb -[NSObject(NSObject) doesNotRecognizeSelector:] + 187 3 CoreFoundation 0x0123e366 ___forwarding___ + 966 4 CoreFoundation 0x0123df22 _CF_forwarding_prep_0 + 50 5 UIKit 0x0042d35e -[UITextField setText:] + 53 6 Koder232_risma_edited 0x0006427a -[FilePropertiesViewController viewWillAppear:] + 442 7 UIKit 0x003c4d52 -[UIView(Hierarchy) _willMoveToWindow:withAncestorView:] + 207 8 UIKit 0x003cfa2b -[UIView(Hierarchy) _makeSubtreePerformSelector:withObject:withObject:copySublayers:] + 378 9 UIKit 0x003cfa5c -[UIView(Hierarchy) _makeSubtreePerformSelector:withObject:withObject:copySublayers:] + 427 10 UIKit 0x003cfa5c -[UIView(Hierarchy) _makeSubtreePerformSelector:withObject:withObject:copySublayers:] + 427 11 UIKit 0x003c6b36 -[UIView(Internal) _addSubview:positioned:relativeTo:] + 370 12 UIKit 0x003c514f -[UIView(Hierarchy) addSubview:] + 57 13 UIKit 0x006ad8ae -[UIPopoverView presentFromRect:inView:contentSize:backgroundStyle:animated:] + 1920 14 UIKit 0x006a0a4c -[UIPopoverView presentFromRect:inView:animated:] + 236 15 UIKit 0x006d9b20 -[UIPopoverController presentPopoverFromRect:inView:permittedArrowDirections:animated:] + 1046 16 Koder232_risma_edited 0x0001f90f -[codeViewController arrangeTabWithTypeGesture:andNumtag:] + 4683 17 Koder232_risma_edited 0x0001e68f -[codeViewController setTap2:] + 99 18 UIKit 0x0061e9c7 -[UIGestureRecognizer _updateGestureWithEvent:] + 727 19 UIKit 0x0061a9d6 -[UIGestureRecognizer _delayedUpdateGesture] + 47 20 UIKit 0x00620fa5 _UIGestureRecognizerUpdateObserver + 584 21 UIKit 0x0062118a _UIGestureRecognizerUpdateGesturesFromSendEvent + 51 22 UIKit 0x003bc6b4 -[UIWindow _sendGesturesForEvent:] + 1292 23 UIKit 0x003b7f87 -[UIWindow sendEvent:] + 105 24 UIKit 0x0039b37a -[UIApplication sendEvent:] + 447 25 UIKit 0x003a0732 _UIApplicationHandleEvent + 7576 26 GraphicsServices 0x0191fa36 PurpleEventCallback + 1550 27 CoreFoundation 0x012ae064 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 52 28 CoreFoundation 0x0120e6f7 __CFRunLoopDoSource1 + 215 29 CoreFoundation 0x0120b983 __CFRunLoopRun + 979 30 CoreFoundation 0x0120b240 CFRunLoopRunSpecific + 208 31 CoreFoundation 0x0120b161 CFRunLoopRunInMode + 97 32 GraphicsServices 0x0191e268 GSEventRunModal + 217 33 GraphicsServices 0x0191e32d GSEventRun + 115 34 UIKit 0x003a442e UIApplicationMain + 1160 35 Koder232_risma_edited 0x00002680 main + 102 36 Koder232_risma_edited 0x00002611 start + 53 37 ??? 0x00000001 0x0 + 1 )

    Read the article

  • iphone problem - UIKit precompile error

    - by tigermain
    I've been working on a project for a few weeks now and today is the last day before it goes to client (typical). For some reason Im suddenly getting the following error when building my project (sim or device), even though other projects build fine /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator3.1.3.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIKit.h:61:42: error: UIKit/UIVideoEditorController.h: No such file or directory The last thing I was trying to do was use the UIMessage framework for email, but I have stripped that out!?!? N.B I have checked and the .h file does appear to be in the same folder as the UIKit.h file

    Read the article

  • Is there a visual guide to the UIKit components?

    - by Tim Büthe
    My Problem is this, I want to add some component to my App I saw in some other App. Everytime I wnat to do this, I start googling around for the name. It took me some time to find the name of UIActionSheet. Now I'm looking for that transparent overlay that appears when you turn the volume up and down. So, is there a good visual guide to the UIKit components? As an example, see the visual guide to swing components or this visual guide which is way to short/incomplete. And secondly, what's the name of the component I'm looking for?

    Read the article

  • iOS static Framework crash when animating view

    - by user1439216
    I'm encountering a difficult to debug issue with a static library project when attempting to animate a view. It works fine when debugging (and even when debugging in the release configuration), but throws an error archived as a release: Exception Type: EXC_CRASH (SIGSYS) Exception Codes: 0x00000000, 0x00000000 Crashed Thread: 0 Thread 0 name: Dispatch queue: com.apple.main-thread Thread 0 Crashed: 0 TestApp 0x000d04fc 0x91000 + 259324 1 UIKit 0x336d777e +[UIView(UIViewAnimationWithBlocks) animateWithDuration:animations:] + 42 2 TestApp 0x000d04de 0x91000 + 259294 3 TestApp 0x000d0678 0x91000 + 259704 4 Foundation 0x355f04f8 __57-[NSNotificationCenter addObserver:selector:name:object:]_block_invoke_0 + 12 5 CoreFoundation 0x35aae540 ___CFXNotificationPost_block_invoke_0 + 64 6 CoreFoundation 0x35a3a090 _CFXNotificationPost + 1400 7 Foundation 0x355643e4 -[NSNotificationCenter postNotificationName:object:userInfo:] + 60 8 UIKit 0x33599112 -[UIInputViewTransition postNotificationsForTransitionStart] + 846 9 UIKit 0x335988cc -[UIPeripheralHost(UIKitInternal) executeTransition:] + 880 10 UIKit 0x3351bb8c -[UIPeripheralHost(UIKitInternal) setInputViews:animationStyle:] + 304 11 UIKit 0x3351b260 -[UIPeripheralHost(UIKitInternal) _reloadInputViewsForResponder:] + 952 12 UIKit 0x3351ae54 -[UIResponder(UIResponderInputViewAdditions) reloadInputViews] + 160 13 UIKit 0x3351a990 -[UIResponder becomeFirstResponder] + 452 14 UIKit 0x336194a0 -[UITextInteractionAssistant setFirstResponderIfNecessary] + 168 15 UIKit 0x33618d6a -[UITextInteractionAssistant oneFingerTap:] + 1602 16 UIKit 0x33618630 _UIGestureRecognizerSendActions + 100 17 UIKit 0x335a8d5e -[UIGestureRecognizer _updateGestureWithEvent:] + 298 18 UIKit 0x337d9472 ___UIGestureRecognizerUpdate_block_invoke_0541 + 42 19 UIKit 0x33524f4e _UIGestureRecognizerApplyBlocksToArray + 170 20 UIKit 0x33523a9c _UIGestureRecognizerUpdate + 892 21 UIKit 0x335307e2 _UIGestureRecognizerUpdateGesturesFromSendEvent + 22 22 UIKit 0x33530620 -[UIWindow _sendGesturesForEvent:] + 768 23 UIKit 0x335301ee -[UIWindow sendEvent:] + 82 24 UIKit 0x3351668e -[UIApplication sendEvent:] + 350 25 UIKit 0x33515f34 _UIApplicationHandleEvent + 5820 26 GraphicsServices 0x376d5224 PurpleEventCallback + 876 27 CoreFoundation 0x35ab651c __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 32 28 CoreFoundation 0x35ab64be __CFRunLoopDoSource1 + 134 29 CoreFoundation 0x35ab530c __CFRunLoopRun + 1364 30 CoreFoundation 0x35a3849e CFRunLoopRunSpecific + 294 31 CoreFoundation 0x35a38366 CFRunLoopRunInMode + 98 32 GraphicsServices 0x376d4432 GSEventRunModal + 130 33 UIKit 0x33544cce UIApplicationMain + 1074 Thread 0 crashed with ARM Thread State: r0: 0x0000004e r1: 0x000d04f8 r2: 0x338fed47 r3: 0x3f523340 r4: 0x00000000 r5: 0x2fe8da00 r6: 0x00000001 r7: 0x2fe8d9d0 r8: 0x3f54cad0 r9: 0x00000000 r10: 0x3fd00000 r11: 0x3f523310 ip: 0x3f497048 sp: 0x2fe8d988 lr: 0x33539a41 pc: 0x000d04fc cpsr: 0x60000010 To give some background info: The static library is part of an 'iOS fake-framework', built using the templates from here: https://github.com/kstenerud/iOS-Universal-Framework The framework presents a registration UI as a modal view on top of whatever the client application is doing at the time. It pushes these views using a handle to a UIViewController provided by the client application. It doesn't do anything special, but here's the animation code: -(void)keyboardWillShowNotification:(NSNotification *)notification { double animationDuration = [[[notification userInfo] objectForKey:UIKeyboardAnimationDurationUserInfoKey] doubleValue]; dispatch_async(dispatch_get_main_queue(), ^(void) { [self animateViewsToState:kUMAnimationStateKeyboardVisible forIdiom:[UIDevice currentDevice].userInterfaceIdiom forDuration:animationDuration]; }); } -(void)animateViewsToState:(kUMAnimationState)state forIdiom:(UIUserInterfaceIdiom)idiom forDuration:(double)duration { float fieldOffset; if (idiom == UIUserInterfaceIdiomPhone) { if (state == kUMAnimationStateKeyboardVisible) { fieldOffset = -KEYBOARD_HEIGHT_IPHONE_PORTRAIT; } else { fieldOffset = KEYBOARD_HEIGHT_IPHONE_PORTRAIT; } } else { if (state == kUMAnimationStateKeyboardVisible) { fieldOffset = -IPAD_FIELD_OFFSET; } else { fieldOffset = IPAD_FIELD_OFFSET; } } [UIView animateWithDuration:duration animations:^(void) { mUserNameField.frame = CGRectOffset(mUserNameField.frame, 0, fieldOffset); mUserPasswordField.frame = CGRectOffset(mUserPasswordField.frame, 0, fieldOffset); }]; } Further printf-style debugging shows that it crashes whenever I do anything much with UIKit - specifically, it crashes when I replace -animateViewsToState with: if (0 == UIUserInterfaceIdiomPhone) { NSLog(@""); } and [[[[UIAlertView alloc] initWithTitle:@"test" message:@"123" delegate:nil cancelButtonTitle:@"OK" otherButtonTitles:nil] autorelease] show]; To me, this sounds like a linker problem, but I don't understand how such problems would only manifest here, and not beforehand. Any help would be greatly appreciated.

    Read the article

  • What's the correct way to represent a linear process in CocoaTouch (UIKit)?

    - by UloPe
    I need to represent a linear process (think wizard) in an iPad app. In principle I could use a UINavigationController and just keep pushing new controllers for each step of the process. But this seems rather inefficient since the process I'm modeling has no notion of navigating backwards so all previous views would pointlessly stay around and use up resources. At the moment I keep adding and removing a subview to one "master" viewcontroller and basically swapping out the contents. This works but feels rather clunky and I hope there is some nicer way to achieve this. Additionally there needs to be an animated transition between the views. (I have this working at the moment via beginAnimations / commitAnimations)

    Read the article

  • iOS Simulator is black on app execution

    - by Terryn
    I am running xcode 5.1.1 and have been trying to learn objective C / iOS development. Right now whenever I try to run my code on the emulator (I do not have an actual device atm) it comes up with a black screen. Code can be found here. Compiling and running gives me the following error: 2014-08-23 10:42:57.429 Calculator[1862:60b] *** Terminating app due to uncaught exception 'NSUnknownKeyException', reason: '[<XYZViewController 0xe436640> setValue:forUndefinedKey:]: this class is not key value coding-compliant for the key didgetPressed.' *** First throw call stack: ( 0 CoreFoundation 0x017ed1e4 __exceptionPreprocess + 180 1 libobjc.A.dylib 0x0156c8e5 objc_exception_throw + 44 2 CoreFoundation 0x0187cfe1 -[NSException raise] + 17 3 Foundation 0x0122cd9e -[NSObject(NSKeyValueCoding) setValue:forUndefinedKey:] + 282 4 Foundation 0x011991d7 _NSSetUsingKeyValueSetter + 88 5 Foundation 0x01198731 -[NSObject(NSKeyValueCoding) setValue:forKey:] + 267 6 Foundation 0x011fab0a -[NSObject(NSKeyValueCoding) setValue:forKeyPath:] + 412 7 UIKit 0x004e31f4 -[UIRuntimeOutletConnection connect] + 106 8 libobjc.A.dylib 0x0157e7de -[NSObject performSelector:] + 62 9 CoreFoundation 0x017e876a -[NSArray makeObjectsPerformSelector:] + 314 10 UIKit 0x004e1d4d -[UINib instantiateWithOwner:options:] + 1417 11 UIKit 0x0034a6f5 -[UIViewController _loadViewFromNibNamed:bundle:] + 280 12 UIKit 0x0034ae9d -[UIViewController loadView] + 302 13 UIKit 0x0034b0d3 -[UIViewController loadViewIfRequired] + 78 14 UIKit 0x0034b5d9 -[UIViewController view] + 35 15 UIKit 0x0026b267 -[UIWindow addRootViewControllerViewIfPossible] + 66 16 UIKit 0x0026b5ef -[UIWindow _setHidden:forced:] + 312 17 UIKit 0x0026b86b -[UIWindow _orderFrontWithoutMakingKey] + 49 18 UIKit 0x002763c8 -[UIWindow makeKeyAndVisible] + 65 19 UIKit 0x00226bc0 -[UIApplication _callInitializationDelegatesForURL:payload:suspended:] + 2097 20 UIKit 0x0022b667 -[UIApplication _runWithURL:payload:launchOrientation:statusBarStyle:statusBarHidden:] + 824 21 UIKit 0x0023ff92 -[UIApplication handleEvent:withNewEvent:] + 3517 22 UIKit 0x00240555 -[UIApplication sendEvent:] + 85 23 UIKit 0x0022d250 _UIApplicationHandleEvent + 683 24 GraphicsServices 0x037e2f02 _PurpleEventCallback + 776 25 GraphicsServices 0x037e2a0d PurpleEventCallback + 46 26 CoreFoundation 0x01768ca5 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 53 27 CoreFoundation 0x017689db __CFRunLoopDoSource1 + 523 28 CoreFoundation 0x0179368c __CFRunLoopRun + 2156 29 CoreFoundation 0x017929d3 CFRunLoopRunSpecific + 467 30 CoreFoundation 0x017927eb CFRunLoopRunInMode + 123 31 UIKit 0x0022ad9c -[UIApplication _run] + 840 32 UIKit 0x0022cf9b UIApplicationMain + 1225 33 Calculator 0x00002c8d main + 141 34 libdyld.dylib 0x01e34701 start + 1 35 ??? 0x00000001 0x0 + 1 ) libc++abi.dylib: terminating with uncaught exception of type NSException (lldb) I have attempted the following things, and so far nothing has worked 1) checked the deployment info, it has the main interface set to main 2) double checked all break points to turn them off and disabled all of them through Debug-Disable Breakpoints 3) Reset Content and Settings on the iOS Simulator. 4) Checked the issue with the LLDB Debugger, however from what I have read the issue is no longer present with the 5.1.1 xcode. 5) checked the local host is still set to 127.0.0.1 Thanks! - Terryn

    Read the article

  • how to change UIKit UIImage:drawInRect method to AppKIt NSImage:drawInRect Method

    - by user322111
    Hi, i'm porting an iphone app to Mac app,there i have to change all the UIKit related class to AppKit. if you can help me on this really appreciate. is this the best way to do below part.. Iphone App--using UIKit UIGraphicsPushContext(ctx); [image drawInRect:rect]; UIGraphicsPopContext(); Mac Os--Using AppKit [NSGraphicsContext saveGraphicsState]; NSGraphicsContext * nscg = [NSGraphicsContext graphicsContextWithGraphicsPort:ctx flipped:YES]; [NSGraphicsContext setCurrentContext:nscg]; NSRect rect = NSMakeRect(offset.x * scale, offset.y * scale, scale * size.width, scale * size.height); [NSGraphicsContext restoreGraphicsState]; [image drawInRect:rect fromRect:NSMakeRect( 0, 0, [image size].width, [image size].height ) operation:NSCompositeClear fraction:1.0];

    Read the article

  • NSOperation and UIKit problem

    - by Infinity
    Hello guys! I am doing my download with an object which was inherited from NSOperation. I have read the documentation and when my operation finished I must call the [self.delegate performSelectorOnMainThread:@selector(operationDidFinish:) withObject:self waitUntilDone:YES]; method. It needs to be called on the main thread, because the UIKit is not thread safe and the documentation says this in these non thread safe frameworks cases. In the delegate method I am drawing a pdf or an image, but because it is drawn on the main thread the User Interface is very laggy until the drawing is finished. Maybe can you suggest me a good way to avoid this problem?

    Read the article

  • Instruments memory leak iphone

    - by dubbeat
    Hi, I posted this problem a few days ago but it was very muddled and my question wasnt very clear so I removed it. I've been digging around and the memory leak is still persiting. Hopefully this attempt will be clearer. First off I've run the static analyzer and it reports no memory leaks. I then ran Instruments and it pointed to a memory leak at this line of code. As far as I can see there is no memory leak. featured=[[UILabel alloc]initWithFrame:CGRectMake(130,15, 200, 15)]; //[featured setFont:[UIFont UIFontboldSystemFontOfSize:20]]; featured.font = [UIFont boldSystemFontOfSize:20]; featured.backgroundColor= [UIColor clearColor]; featured.textColor=[UIColor blackColor]; featured.text= @"Featured Promo"; [self.view addSubview:featured]; [featured release]; featured=nil; If I comment out the above code Instruments reports another memory leak in another block of code where there is no discernible leak. UIButton *populartbutton = [[UIButton buttonWithType:UIButtonTypeRoundedRect]]; populartbutton.frame = CGRectMake(112, 145, 90, 22); // size and position of button [populartbutton setTitle:@"Popular" forState:UIControlStateNormal]; populartbutton.backgroundColor = [UIColor clearColor]; populartbutton.adjustsImageWhenHighlighted = YES; [populartbutton addTarget:self action:@selector(getpopular:) forControlEvents:UIControlEventTouchUpInside]; [self.view addSubview:populartbutton]; Instruments also says Responsible Library = Core Graphics Responsible Frame = open_handle_to_dylib_path This Is the stack trace. 53 Promo start 52 Promo main /Users/..2/main.m:14 51 UIKit UIApplicationMain 50 UIKit -[UIApplication _run] 49 CoreFoundation CFRunLoopRunInMode 48 CoreFoundation CFRunLoopRunSpecific 47 GraphicsServices PurpleEventCallback 46 UIKit _UIApplicationHandleEvent 45 UIKit -[UIApplication sendEvent:] 44 UIKit -[UIApplication handleEvent:withNewEvent:] 43 UIKit -[UIApplication _reportAppLaunchFinished] 42 QuartzCore CA::Transaction::commit() 41 QuartzCore CA::Context::commit_transaction(CA::Transaction*) 40 QuartzCore CALayerLayoutIfNeeded 39 QuartzCore -[CALayer layoutSublayers] 38 UIKit -[UILayoutContainerView layoutSubviews] 37 UIKit -[UINavigationController _startDeferredTransitionIfNeeded] 36 UIKit -[UINavigationController _startTransition:fromViewController:toViewController:] 35 UIKit -[UINavigationController _layoutViewController:] 34 UIKit -[UINavigationController_computeAndApplyScrollContentInsetDeltaForViewController:] 33 UIKit -[UIViewController contentScrollView] 32 UIKit -[UIViewController view] 31 Promo -[FeaturedLevelViewController viewDidLoad] /Users/..s/FeaturedLevelViewController.m:67 // THIS IS MY CLASS WHERE THE CODE SAMPLES ABOVE ARE FROM 30 UIKit -[UILabel initWithFrame:] 29 UIKit -[UILabel _commonInit] 28 UIKit +[UILabel defaultFont] 27 UIKit +[UIFont systemFontOfSize:] 26 GraphicsServices GSFontCreateWithName 25 CoreGraphics CGFontCreateWithName 24 CoreGraphics CGFontCreateWithFontName 23 CoreGraphics CGFontFinderGetDefault 22 CoreGraphics CGFontGetVTable 21 libSystem.B.dylib pthread_once 20 CoreGraphics load_vtable 19 CoreGraphics load_library 18 CoreGraphics CGLibraryLoadFunction 17 CoreGraphics load_function 16 CoreGraphics open_handle_to_dylib_path 15 libSystem.B.dylib dlopen 14 dyld dlopen 13 dyld dyld::link(ImageLoader*, bool, ImageLoader::RPathChain const&) 12 dyld ImageLoader::link(ImageLoader::LinkContext const&, bool, bool, ImageLoader::RPathChain const&) 11 dyld ImageLoader::recursiveLoadLibraries(ImageLoader::LinkContext const&, bool, ImageLoader::RPathChain const&) 10 dyld dyld::libraryLocator(char const*, bool, char const*, ImageLoader::RPathChain const*) 9 dyld dyld::load(char const*, dyld::LoadContext const&) 8 dyld dyld::loadPhase0(char const*, dyld::LoadContext const&, std::vector<char const*, std::allocator<char const*> >*) 7 dyld dyld::loadPhase1(char const*, dyld::LoadContext const&, std::vector<char const*, std::allocator<char const*> >*) 6 dyld dyld::loadPhase3(char const*, dyld::LoadContext const&, std::vector<char const*, std::allocator<char const*> >*) 5 dyld dyld::loadPhase4(char const*, dyld::LoadContext const&, std::vector<char const*, std::allocator<char const*> >*) 4 dyld dyld::loadPhase5(char const*, dyld::LoadContext const&, std::vector<char const*, std::allocator<char const*> >*) 3 dyld dyld::mkstringf(char const*, ...) 2 dyld strdup 1 dyld malloc 0 libSystem.B.dylib malloc I'm really not too sure how to use this information to fix the problem so any guidance would be appreciated. Perhaps the answer is in the trace but I just don't know what to look for? EDIT:: The above stack trace is when running on the simulator. The following is from running on a device. This trace does not point to any of my own classes 23 Promo 0x0 22 libSystem.B.dylib _pthread_body 21 Foundation __NSThread__main__ 20 Foundation +[NSThread exit] 19 libSystem.B.dylib _pthread_exit 18 libSystem.B.dylib _pthread_tsd_cleanup 17 QuartzCore CA::Transaction::release_thread(void*) 16 QuartzCore CA::Transaction::commit() 15 QuartzCore CA::Context::commit_transaction(CA::Transaction*) 14 QuartzCore CALayerDisplayIfNeeded 13 QuartzCore -[CALayer display] 12 QuartzCore -[CALayer _display] 11 QuartzCore CABackingStoreUpdate 10 QuartzCore backing_callback(CGContext*, void*) 9 QuartzCore -[CALayer drawInContext:] 8 UIKit -[UIView(CALayerDelegate) drawLayer:inContext:] 7 UIKit -[UILabel drawRect:] 6 UIKit -[UILabel drawTextInRect:] 5 UIKit -[UILabel _drawTextInRect:baselineCalculationOnly:] 4 UIKit -[NSString(UIStringDrawing) drawAtPoint:forWidth:withFont:lineBreakMode:] 3 UIKit -[NSString(UIStringDrawing) drawAtPoint:forWidth:withFont:lineBreakMode:letterSpacing:includeEmoji:] 2 WebCore WKSetCurrentGraphicsContext 1 WebCore CurrentThreadContext() 0 libSystem.B.dylib calloc

    Read the article

  • iPhone app crashes on start-up, in stack-trace only messages from built-in frameworks

    - by Aleksejs
    My app some times crashes at start-up. In stack-trace only messages from built-in frameworks. An excerpt from a crash log: OS Version: iPhone OS 3.1.3 (7E18) Report Version: 104 Exception Type: EXC_BAD_ACCESS (SIGBUS) Exception Codes: KERN_PROTECTION_FAILURE at 0x000e6000 Crashed Thread: 0 Thread 0 Crashed: 0 CoreGraphics 0x339305d8 argb32_image_mark_RGB32 + 704 1 CoreGraphics 0x338dbcd4 argb32_image + 1640 2 libRIP.A.dylib 0x320d99f0 ripl_Mark 3 libRIP.A.dylib 0x320db3ac ripl_BltImage 4 libRIP.A.dylib 0x320cc2a0 ripc_RenderImage 5 libRIP.A.dylib 0x320d5238 ripc_DrawImage 6 CoreGraphics 0x338d7da4 CGContextDelegateDrawImage + 80 7 CoreGraphics 0x338d7d14 CGContextDrawImage + 364 8 UIKit 0x324ee68c compositeCGImageRefInRect 9 UIKit 0x324ee564 -[UIImage(UIImageDeprecated) compositeToRect:fromRect:operation:fraction:] 10 UIKit 0x32556f44 -[UINavigationBar drawBackButtonBackgroundInRect:withStyle:pressed:] 11 UIKit 0x32556b00 -[UINavigationItemButtonView drawRect:] 12 UIKit 0x324ecbc4 -[UIView(CALayerDelegate) drawLayer:inContext:] 13 QuartzCore 0x311cacfc -[CALayer drawInContext:] 14 QuartzCore 0x311cab00 backing_callback 15 QuartzCore 0x311ca388 CABackingStoreUpdate 16 QuartzCore 0x311c978c -[CALayer _display] 17 QuartzCore 0x311c941c -[CALayer display] 18 QuartzCore 0x311c9368 CALayerDisplayIfNeeded 19 QuartzCore 0x311c8848 CA::Context::commit_transaction(CA::Transaction*) 20 QuartzCore 0x311c846c CA::Transaction::commit() 21 QuartzCore 0x311c8318 +[CATransaction flush] 22 UIKit 0x324f5e94 -[UIApplication _reportAppLaunchFinished] 23 UIKit 0x324a7a80 -[UIApplication _runWithURL:sourceBundleID:] 24 UIKit 0x324f8df8 -[UIApplication handleEvent:withNewEvent:] 25 UIKit 0x324f8634 -[UIApplication sendEvent:] 26 UIKit 0x324f808c _UIApplicationHandleEvent 27 GraphicsServices 0x335067dc PurpleEventCallback 28 CoreFoundation 0x323f5524 CFRunLoopRunSpecific 29 CoreFoundation 0x323f4c18 CFRunLoopRunInMode 30 UIKit 0x324a6c00 -[UIApplication _run] 31 UIKit 0x324a5228 UIApplicationMain 32 Journaler 0x000029ac main (main.m:14) 33 Journaler 0x00002948 start + 44 File main.m is simple as possible: #import <UIKit/UIKit.h> int main(int argc, char *argv[]) { NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init]; int retVal = UIApplicationMain(argc, argv, nil, nil); // line 14 [pool release]; return retVal; } What my cause the app to crash?

    Read the article

  • Looking for marg_setValue in UIKit

    - by John Smith
    I am trying to compile a library originally written for Cocoa. Things are good until it looks for the function marg_setValue(). It says it can't find it. I have googled and found it is defined in How can I use this file in cocoa-touch? Or does cocoa-touch not support runtime.

    Read the article

  • Calculating string sizes on iPhone on a background thread

    - by jbrennan
    I've got some somewhat hefty string size calculations happening in my app (each one takes close to 500ms, and happens when the user scrolls to a new "page" in my app (like the Weather app). The delay only happens once per page, as the calculation only needs to be run once (and can even be cached for subsequent launches with the same data). Anyway, I still like to not block the UI for this type of work, as to me it screams using threads, but I know UIKit is not meant to be used from other threads. (I know NSString is not part of UIKit, but the string sizing methods are part of the UIKitAdditions...) So how should I go about doing this? What's the best way to not block the UI and do so safely?

    Read the article

  • How does the height of a UITableViewCell get set

    - by Brian
    I know that when UIKit renders a cell, it uses tableView:heightForRowAtIndexPath: to calculate the height. My question is, how and when does that get set on the actual UITableViewCell. I want to build dynamic cells and will need to calculate the placement of text within the cell. I believe I can just use self.bounds and self.frame - I was just curious about at what point those are set - even with the use of dequeueReusableCellWithIdentifier. Thanks.

    Read the article

  • Adding Emboss to a UILabel in a navigationItem.titleView (as seen with navigationItem.title)

    - by Sahil
    I'm trying to mimic the default emboss that automatically gets applied to navigationItem.title, as well as many other UIKit controls. As seen in this screenshot's title ("Table Cells"): I'm essentially trying to add 2 UILabels to the navigationItem.titleView, however the UILabels just show up as flatly drawn and it really just doesn't feel/look right :P I've thought about playing with shadows, but that would only give the embossed look (if even that) on one side of the label. Any ideas would be great! Thanks

    Read the article

  • Struggling to make sense of some Objective-C code

    - by Matt
    I'm an Objective-C newbie and am enjoying reading/learning Objective-C in order to do iPhone development but I'm struggling to understand some of the code, especially the code that comes with the UIKit framework. For example, take this line: - (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSelection:(NSInteger)section { ... I understand the parameters passed in but am struggling to understand the return parameter. Any help appreciated.

    Read the article

1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >