Does iOS SDK provides an easy way to check if the currentDevice has an high-resolution display (retina) ?
The best way I've found to do it now is :
if ([[UIScreen mainScreen] respondsToSelector:@selector(scale)] == YES && [[UIScreen mainScreen] scale] == 2.00) {
// RETINA DISPLAY
}
...
if I have a nsmutablestring, I can set his string with the method setString. But this method only takes NSString, How I can put a nsmutablestring into my nsmutableString. If I do this: mutableStringA = mutableStringB, this will change the pointer of mutableStringA and not his string value, is it true?
Alex
...
I am supporting other languages in my game for its next release and would like to support Japanese. The issue I have is a I do all of my own font and bitmap rendering internal in the engine, I do support the full extended ASCII 0-256 character map with all of the special accents, so all roman based languages work fine. But with Japanes...
I am having an issue that I can't figure out.
I'm trying to run the rangeOfString method on a string, and I'm not sure how to determine if the string was not found. For example:
NSRange range = [@"abc" rangeOfString:@"d" options:NSCaseInsensitiveSearch range:NSMakeRange(0,3)];
Clearly, "d" is not contained in the string "abc." I'd li...
I reference AVCaptureSession an consequently the project will only build for the device. However, I still want to test the rest my app on the simulator as I develop. Do I have to comment out all AVCaptureSession references or is there another way to build for the simulator successfully?
...
For my project I've created an UIScrollView with an UIImage inside. The Scroll View is as big as the window frame (tab bar application). What I want is to resize the UIScrollView again when the user rotates the device. How can I do that?
...
I am using this:
//if in landscape mode
while(window.orientation == 90 || window.orientation == -90) {
if(!$('#page' + hiddenNextPage).hasClass('showUp')) {
$('#page' + hiddenNextPage).addClass('showUp');
$('#page' + hiddenNextPage).css('margin-left', '300px');
...
I am having a java script file(A) in Resource, which uses/references to another java script file(B),which is also in Resource. Now i want to load js (A)file in UIWebView from Resource.and (A) uses reference of (B) file. How can i load java script of file(A) as HTML string??
I know the method of
[ObjWebView stringByEvaluatingJavaScriptF...
I am trying to record Audio from my IPhone simulator and then save it into the directory and then playback. Since I cannot hear my recorded audio I am not even sure if it is being recording in the first place. Here is my code:
-(IBAction) playRecording:sender
{
NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirecto...
App has 4 view controllers; Menu, A, B and C, and a singleton class to hold data in 4 arrays that are written to disk at app termination. A selection from the Menu creates an instance of A, "a"; a selection from "a" creates an instance of B, "b", and from "b", a selection bring up a modal data entry view "c".
I simulate a memory warni...
I have a instance of ASINetworkQueue, and I added instances of ASIHTTPRequest to the queue; meanwhile I have delegate methods set for the Queue as well as each requests:
[submittingReportQueue setDelegate:self];
[submittingReportQueue setRequestDidFailSelector:@selector(submitReportQueueWentWrong:)];
[submittingReportQueue setQueueDidFi...
I just started fighting my way to Xcode and iPhone development, so this is probably a stupid question, but there is this strange behavior of Xcode that I can't seem to get behind.
When I change my code (.m, .h files) and press "Build and Run", the (already running) emulator seems to restart my app, but doesn't actually reflect my change...
Hi all,
Got a strange problem here.
I am able to get UILabel to render a multiple lines using the following snippet
- cell.label.text = @"hihi\nhihi";
But not when I call the same "hihi\nhihi" from Core Data like this
- cell.label.text = data.hihi;
data.hihi is contains "hihi\nhihi"
...
I don't want to show a history when the user starts typing into my UISearchBar. How can I tell the UISearchDisplayController not to show previous search results?
...
When trying to have my app open a facetime url (facetime://15555555555), it loads up a blank black screen.
NSURL *facetimeURL = [NSURL URLWithString:@"facetime://15555555555"];
[[UIApplication sharedApplication] openURL:facetimeURL];
Has anyone had any success with this?
...
Hi,
Can anyone confirm how an app like this is done?
PocketCam
Is the way to capture the camera's video stream using AVFoundation?
http://developer.apple.com/iphone/library/documentation/AVFoundation/Reference/AVCaptureVideoDataOutput_Class/Reference/Reference.html#//apple_ref/doc/uid/TP40009544
To be clear, I dont want to capture ...
I get the following error:
'NSInvalidArgumentException', reason:
'Illegal attempt to establish a
relationship 'condition' between
objects in different contexts
when running my iphone app. The relevant part of my model looks like this:
AssessmentTree
-has one TreeCrown
TreeCrown
-has one TreeCrownCondition
-has one Assessme...
Hello , i have poem application , my poem titles show on table view .. i have 495 cells based on Plist file, each cell have specific title , the poets show with navigation controller on AnotherViewController ., and i implement UISearchBar [based on iPhone beginning Development book]
before i implement UISearchbar and changed plist file ...
I want to build a spinner for menu selection like the one in where to? IPhone app as shown in image below. Any hints?
...
Hi there, in my iphone app, im trying to make my uinavigationbar act as a button, i mean do something when i touch it. Not back button o any nav item, the bar itself.
heres how i "categorized" it:
@implementation UINavigationBar (UINavigationBarCategory)
- (void)drawRect:(CGRect)rect {
UIColor *color = [UIColor blackColor];
UIIm...