|
Lumpy posted:and then I can release my reference to anObject and all is well. You wouldn't call delete because you aren't deleting the object. The actual erasing doesn't happen until the context is saved, but accessing certain properties can still cause issues IIRC due to faults. rjmccall posted:Xcode no longer installs anything by default in /usr, but it won't blow things away that previous installs have put there. You don't need anything in /usr at all if you work exclusively within Xcode and its build system, but if you also want to be able to (e.g.) work on open-source Unix software with a Makefile-based build system, you should install the command-line tools. Contrariwise, if you never use Xcode and its build system, you can now just install the command-line tools without needing a full Xcode package. Can you comment on Guard Malloc on the iOS 5 simulator issue I was having above? You are about the only person I know of who might have any clues.
|
# ? Feb 22, 2012 06:43 |
|
|
# ? May 16, 2024 10:35 |
|
Ender.uNF posted:Can you comment on Guard Malloc on the iOS 5 simulator issue I was having above? You are about the only person I know of who might have any clues. There seems to be a nasty order-of-initialization problem with running the iOS 5 simulator on Lion, and I don't see any user-level workarounds for it, sorry. Essentially, there are unmodelled dependencies between the component libraries in libSystem, and those dependencies go completely mad when the simulator shim libraries are added in. File a radar if you haven't already; it'll be duped internally, but those really do help us establish priorities. Unfortunately, there's nothing else I can do personally. ETA: also, I am going on vacation for a couple of weeks, so if you don't get any more responses from me for awhile, that's why. rjmccall fucked around with this message at 10:03 on Feb 22, 2012 |
# ? Feb 22, 2012 10:00 |
|
rjmccall posted:Xcode no longer installs anything by default in /usr, but it won't blow things away that previous installs have put there. You don't need anything in /usr at all if you work exclusively within Xcode and its build system, but if you also want to be able to (e.g.) work on open-source Unix software with a Makefile-based build system, you should install the command-line tools. Contrariwise, if you never use Xcode and its build system, you can now just install the command-line tools without needing a full Xcode package. The only problem I've ran into so far was compiling valgrind (with homebrew). It gave me a error saying /Developer wasn't there and that I needed to run some xcode program to fix the path, so I just pointed it inside Xcode.app and everything seems OK.
|
# ? Feb 22, 2012 12:25 |
|
rjmccall posted:There seems to be a nasty order-of-initialization problem with running the iOS 5 simulator on Lion, and I don't see any user-level workarounds for it, sorry. Essentially, there are unmodelled dependencies between the component libraries in libSystem, and those dependencies go completely mad when the simulator shim libraries are added in. File a radar if you haven't already; it'll be duped internally, but those really do help us establish priorities. Unfortunately, there's nothing else I can do personally. Ok, I will. At least I'm not crazy. Have a good vacation!
|
# ? Feb 22, 2012 13:48 |
|
Is anyone else getting this just about every time you run on a device? Hit okay, everything runs just fine.
|
# ? Feb 22, 2012 21:11 |
|
I did, but I had iTunes open. Ejecting the device in iTunes, unplugging it, closing iTunes, then plugging it back in (keeping iTunes closed) seemed to fix the problem. Maybe it has something to do with both iTunes and Xcode trying to access it at the same time...
|
# ? Feb 22, 2012 21:43 |
|
Boris Galerkin posted:I just updated Xcode from the MAS and then it told me that I need to install the Command Line Tools because they're not installed by default. I don't have a developer account so I didn't install it, but I still have access to things like gcc, clang, make, and other Unix tools located in /usr/bin. What exactly am I missing here? You don't need a paid developer account to download the command line tools installer, just a regular ol' apple id. AFAIK.
|
# ? Feb 22, 2012 21:51 |
|
Doc Block posted:I did, but I had iTunes open. Ejecting the device in iTunes, unplugging it, closing iTunes, then plugging it back in (keeping iTunes closed) seemed to fix the problem. This didn't work for me. iTunes is closed, I unplugged / replugged, still getting the error.
|
# ? Feb 22, 2012 22:04 |
|
This is really loving me off, because I cant defeat this stupid overengineered piece of poo poo class.code:
and out shits: 2012-02-19 01:30:00 +0000 Is there a way to just tell this retarded loving thing that I want my loving date to not be in GMT+0 time, like just loving leave the date alone and not gently caress with it.
|
# ? Feb 23, 2012 00:24 |
|
Add time zone info to the date string before sending it through the formatter?
|
# ? Feb 23, 2012 00:45 |
|
duck monster posted:This is really loving me off, because I cant defeat this stupid overengineered piece of poo poo class. You're logging an NSDate object, which means it calls -description on that object (like toString() in Java, etc). The docs specifically says that you shouldn't count on the description thing, but use an NSDateFormatter when outputting the date. quote:The representation is not guaranteed to remain constant across different releases of the operating system. To format a date, you should use a date formatter object instead (see NSDateFormatter and Data Formatting Guide). code:
- You can attach NSFormatters to your views in the Interface Builder part of XCode and configure them there. - If you don't set a TimeZone on the NSDateFormatter, it will use the one from the locale, ie. the one the system is currently set up with. Depending on what you need, you might not want to add them at all, if the date strings are assumed to be in the same locale as the system. - You can use different NSFormatters for input & output. For instance have one with a timezone when reading your data that assumes all dates are in your TZ, and then use a non-timezoned formatter for output. This will mean that any display of dates will follow timezones when shown in different countries, etc. E2: The Data Formatting Guide is a good read. Carthag Tuek fucked around with this message at 01:16 on Feb 23, 2012 |
# ? Feb 23, 2012 00:59 |
|
duck monster posted:This is really loving me off, because I cant defeat this stupid overengineered piece of poo poo class. If you don't love NSDate yet, just wait till you want to get tomorrow's date and find yourself starting off with code:
|
# ? Feb 23, 2012 01:09 |
|
Zhentar posted:If you don't love NSDate yet, just wait till you want to get tomorrow's date and find yourself starting off with Well at least I know that if I want klingon calendar, the hooks are there for it already. fucken engineers e: Also it turns out if I capitalized the H's in the string format, it all starts to work. I honestly have no idea why, but
|
# ? Feb 23, 2012 03:22 |
|
Look what I just found on the netcode:
|
# ? Feb 23, 2012 03:59 |
|
duck monster posted:Well at least I know that if I want klingon calendar, the hooks are there for it already. In the docs I linked they link further to the Unicode standard: http://unicode.org/reports/tr35/tr35-10.html#Date_Format_Patterns HH is 24 hour time, hh is 12 hour time. There's a reason date parsing/handling/output libraries & frameworks are hella complicated. There are thousands of things that can go wrong.
|
# ? Feb 23, 2012 04:13 |
|
Time is incredibly complicated and software engineers often get it wrong. I've seen people using tricks to get the current GMT offset in JavaScript then apply that to a user selecting a date for an appointment six months from now, when the user will be in DST, resulting in the wrong value being stored... Unless you are trying to store the expiration date of some food in which case you want absolute time as the sun rises, regardless of DST. Then you have all the standard mis-formatting crap like assuming four digit years (gregorian calendar), the order of months vs days, which cultures use 24hr time even in the same Timezone, etc. Also let me recommend RestKit again for those who need to make JSON web service calls and/or CoreData. It takes a long time to figure out how it works but once you do it kicks rear end. I do wish Objective-C supported real attributes ala C#... If it did, it would be trivial to use introspection to drive RestKit setup. Actually that's a general comment I would make about Objective-C... A lot of stuff would be much easier and smoother if you could just decorate classes and methods with attributes: code:
|
# ? Feb 23, 2012 05:26 |
|
Zhentar posted:If you don't love NSDate yet, just wait till you want to get tomorrow's date and find yourself starting off with [NSDate dateWithNaturalLanguageString:@"tomorrow"]; Who knows what time you'll get, but I imagine it would give you the correct date. disclaimer: This was mostly a joke
|
# ? Feb 23, 2012 06:13 |
|
Ender.uNF posted:Also let me recommend RestKit again for those who need to make JSON web service calls and/or CoreData. It takes a long time to figure out how it works but once you do it kicks rear end. I do wish Objective-C supported real attributes ala C#... If it did, it would be trivial to use introspection to drive RestKit setup. I was writing code to convert GEDCOM <-> Core Data code and the way I handled mapping between input/output at the time was to have the mappings in the userInfo dicts on the entities/attributes/relationships (setting them via the modeler). Then I had in/out methods on the top-most NSManagedObject that used these mappings, such that: code:
code:
With Core Data you can do a lot of runtime stuff via NSEntityDescription / NSAttributeDescription / NSRelationshipDescription Regarding non-CD introspection, this looks interesting: https://github.com/mikeash/MAObjCRuntime - basically it's just a wrapper around the objc-runtime, but it looks clean and gives access to property info etc.
|
# ? Feb 23, 2012 07:01 |
|
duck monster posted:Well at least I know that if I want klingon calendar, the hooks are there for it already. Yeah, I don't mean to be ethnocentric, but is there anyone at this point that doesn't use the Gregorian calendar for their day-to-day business? I mean, for the 10 possible apps that might use the Jewish/Islamic/Chinese/French Revolutionary/Juche calendar, is it really worth it to make everyone else's life more complicated? EDIT: But I know where it comes from. I had to deal with guys in university that would argue that we ought to over-engineer a one-month-long project because "what if we need it in the future?". All the while overlooking the myriad terrible flaws they'd introduced. PT6A fucked around with this message at 07:31 on Feb 23, 2012 |
# ? Feb 23, 2012 07:28 |
|
Ender.uNF posted:Actually that's a general comment I would make about Objective-C... A lot of stuff would be much easier and smoother if you could just decorate classes and methods with attributes: Christ that's ugly. (C# attributes in general, not just your suggested syntax here.) But I agree 100% with RestKit. I've set it up for two or three different projects now, spaced a few months apart, and each time I start banging my head against the wall by hour four of tweaking log levels to see why the hell it doesn't work. And then it works, and it just works so drat well, and it never stops working, and I love it.
|
# ? Feb 23, 2012 09:51 |
|
Just finished this: http://www.amazon.com/Teach-Yourself-Application-Development-Hours/dp/067233576X/ref=sr_1_1?s=books&ie=UTF8&qid=1330007676&sr=1-1 Any recommendations for a next step? I want to buy another book. Online material is fine for supplementation but I like something physical. I was thinking this: http://www.amazon.com/iOS-Developers-Cookbook-Essential-Programmers/dp/0321832078/ref=sr_1_3?ie=UTF8&qid=1330007758&sr=8-3 Anything better?
|
# ? Feb 23, 2012 15:36 |
|
Ender.uNF posted:Time is incredibly complicated and software engineers often get it wrong. I've seen people using tricks to get the current GMT offset in JavaScript then apply that to a user selecting a date for an appointment six months from now, when the user will be in DST, resulting in the wrong value being stored... Unless you are trying to store the expiration date of some food in which case you want absolute time as the sun rises, regardless of DST. And yet the ridiculous complexity of NSDate and friends don't even solve that. NSDate goes a lot farther than most to try to encompass all the complexity of things, but the end result is that it's harder to handle simple, common cases and all the opportunities to screw things up are still there.
|
# ? Feb 23, 2012 16:09 |
|
pokeyman posted:Christ that's ugly. (C# attributes in general, not just your suggested syntax here.) Well I agree the syntax needs work but is still think objc could use attributes for runtime introspection. The syntax for blocks is ugly as poo poo but drat if they aren't extremely useful. On NSDate: oh I agree, I was just trying to point out that "simple" concepts like dates and times are actually not simple at all. Similarly to file encodings... It took me a while to get my coworkers to understand that the character "A" is not 65... It is unicode code point latin capital A that just so happens to map to integer 65 in ASCII and UTF8. There is no reason an encoding couldn't map it to 85724. It was like I broke their brains... This was in reference to loading a file that had Latin code page accented characters in it as UTF8 and getting garbage... No 130 is not accented e, you just think that because envy computer you use defaults to the Latin code page for ASCII.
|
# ? Feb 23, 2012 17:04 |
|
I'll throw text rendering in there too. gently caress text rendering.
|
# ? Feb 23, 2012 17:21 |
|
Ender.uNF posted:Well I agree the syntax needs work but is still think objc could use attributes for runtime introspection. The syntax for blocks is ugly as poo poo but drat if they aren't extremely useful. The runtime support is there, just use objc_getAssociatedObject and friend on the class object. You'll have to get the compiler to play along though. edit: And the block syntax roughly mirrors the syntax for function pointers so, yes, while I always have to look up what the hell kind of pointer it is, it's got a language precedent at least.
|
# ? Feb 23, 2012 17:50 |
|
Built 4 Cuban Linux posted:Just finished this: http://www.amazon.com/Teach-Yourself-Application-Development-Hours/dp/067233576X/ref=sr_1_1?s=books&ie=UTF8&qid=1330007676&sr=1-1 I'd probably wait for this: http://www.amazon.com/iOS-Programming-Ranch-Guide-Guides/dp/0321821521/ref=sr_1_4?s=books&ie=UTF8&qid=1330034000&sr=1-4 Anything by Hillegass is excellent.
|
# ? Feb 23, 2012 22:54 |
|
I would like to preface this with the fact that I'm not a developer, nor do I play one on the internet, but I'd like to ask a quick question that proves my Google-fu is weak. With APNS, or the push service, is it possible to have an app that would require a logon to initially download and store data, then if the user ID expired send a kill bit to remove all data from the application...or if the application hasn't checked in in X days do the same?
|
# ? Feb 24, 2012 01:34 |
|
CaptainGimpy posted:I would like to preface this with the fact that I'm not a developer, nor do I play one on the internet, but I'd like to ask a quick question that proves my Google-fu is weak. In theory yes but the data wouldn't actually get removed until the user opened the app and the app processed the notification.
|
# ? Feb 24, 2012 03:14 |
|
Awesome. Thank you!
|
# ? Feb 24, 2012 07:55 |
|
Has anybody here played with HTML widgets in iBooks Author? I'm trying to find a way to launch Google Earth from an HTML widget embedded in an iBook. It's not my idea. A Dashboard widget would use widget.openURL, but that doesn't work in iBooks. With Mobile Safari you can use URLs like comgoogleearth://host/path/to/file.kml, but that doesn't work in iBooks either. I've tried setting window.location and similar variables with several URI schemes - http, comgoogleearth, x-ibooks-th, and apb - and had no luck there either. Any other suggestions? I'm pretty sure it isn't possible, but I'm new to this and also haven't been able to find many details online.
|
# ? Feb 24, 2012 09:15 |
|
Built 4 Cuban Linux posted:Any recommendations for a next step? I want to buy another book. Online material is fine for supplementation but I like something physical. I was thinking this: http://www.amazon.com/iOS-Developers-Cookbook-Essential-Programmers/dp/0321832078/ref=sr_1_3?ie=UTF8&qid=1330007758&sr=8-3 That's not a terrible book. It's a 'cookbook' so instead of explaining here's how you do this, blah blah, it just shows you with a real example.
|
# ? Feb 24, 2012 16:33 |
|
Is there a limit to the size of a URL? I'm sending binary data in a query parameter to an app's custom URL scheme and it has worked so far with around 400kb of data. Is there a maximum that I will eventually hit?
|
# ? Feb 24, 2012 16:52 |
|
bumnuts posted:Is there a limit to the size of a URL? I'm sending binary data in a query parameter to an app's custom URL scheme and it has worked so far with around 400kb of data. Is there a maximum that I will eventually hit? I don't think there's a standardized limit, but over the years web browsers have had a habit of placing arbitrary limits on the length of an url. I would suggest that for sending that much data, use the POST method and send the data in a variable.
|
# ? Feb 24, 2012 17:00 |
|
Not officially but most browsers and web servers have limits built in. Generally anything over 2048 and I call shennanigains.
|
# ? Feb 24, 2012 17:26 |
|
duck monster posted:This is really loving me off, because I cant defeat this stupid overengineered piece of poo poo class. Can't you just call [date descriptionWithLocale:[NSLocale currentLocale]]?
|
# ? Feb 24, 2012 17:54 |
|
As others have said, use a date formatter. Don't rely on -description
|
# ? Feb 24, 2012 19:35 |
|
I need a good tool to create "virtual tour" 360° view panoramas, complete with hotspots to go to a new location or view a photo for iOS only. I found a couple that blew me away with their demos, but after downloading the trial versions I wasn't so pleased: KRPano - The tools are just droplets that you can drag and drop images to. No tool that has a UI that I can see, which would actually make things like placing hotspots do-able. Easypano - Pano tool crashes 4/5 times that I attempt to publish. Don't see any way to place hotspots, but maybe I downloaded the wrong version. Any suggestions? LP0 ON FIRE fucked around with this message at 20:19 on Feb 24, 2012 |
# ? Feb 24, 2012 19:53 |
|
Did you try Photosynth? I can't remember if it does hotspots, but as a panoramic image creator it's one of the coolest things I've come across.
|
# ? Feb 24, 2012 20:12 |
|
Sorry I forgot to mention I need something for iOS. Photosynth is cool, but I thought it was limited to being made up of a bunch of pictures you take with your phone. I need a tool where you can import an entire panorama and view it and create hotspots for navigation, etc. edit: Panotour Pro seems pretty amazing to work with, but I can't test for iOS unless I buy the full version. LP0 ON FIRE fucked around with this message at 21:22 on Feb 24, 2012 |
# ? Feb 24, 2012 20:22 |
|
|
# ? May 16, 2024 10:35 |
|
xzzy posted:I don't think there's a standardized limit, but over the years web browsers have had a habit of placing arbitrary limits on the length of an url. I can't POST because its a URL scheme. I'm not even sure if an arbitrary limit would even apply since it doesn't really hit Mobile Safari or ever leave the device.
|
# ? Feb 24, 2012 21:22 |