Re: [iPhone] Preprocessing events sent to UITableView

2010-06-06 Thread Matt Neuburg
're jumping through all these hoops in the first place. Just curious... Thx. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! AppleScript: the Definitive Guide - Second Edition! http://www.tidbits.com/m

Re: detecting touch and hold vs touch in UIButton

2010-06-06 Thread Matt Neuburg
thObject:nil afterDelay:0.4]; } - (void) userDidTouchUp: (id) sender event: (UIEvent*) e { double diff = [e timestamp] - downtime; if (diff < 0.3) { [[self class] cancelPreviousPerformRequestsWithTarget:self]; NSLog(@"respond to tap"); } } The numbers ar

Re: detecting touch and hold vs touch in UIButton

2010-06-06 Thread Matt Neuburg
performance *is* effectively using a timer. I tested on 3.1.2 and it seems to do exactly what the OP asked for. m. -- matt neuburg, phd = m...@tidbits.com, http://www.tidbits.com/matt/ pantes anthropoi tou eidenai oregontai phusei Among the 2007 MacTech Top 25, http://tinyurl.com/2rh4pf AppleScript

Re: NSTableView action & doubleAction...

2010-06-06 Thread Matt Neuburg
the row and catch the click from *that*. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! AppleScript: the Definitive Guide - Second Edition! http://www.tidbits.com/matt/default.html#applescriptthings __

Re: [iPhone] Preprocessing events sent to UITableView

2010-06-08 Thread Matt Neuburg
out whether to swipe > or allow the table to scroll, then pass the events back down to the table if > the user intended to scroll vertically. Well, of course I could be wrong, but to me this sounds like a reason to override sendEvent:. m. -- matt neuburg, phd = m...@tidbits.com, http://www.t

mutableArrayValueForKey: truth or dare

2010-06-17 Thread Matt Neuburg
ndex:, and -removeObjectFromItemsAtIndex:, then every change in the mutable array through the proxy replaces the whole array. Is this true? Thx - m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! AppleScript: the Definitiv

an oldie but a goodie: observing properties of collected objects

2010-06-17 Thread Matt Neuburg
ctionaries are added to and removed from the array (though, as mmalc shows, it can be done). My question is, does anyone have a *simple* approach to this common problem? (Assume I'm on iPhone OS where NSArrayController is absent.) What advice should one give a newbie on this topic? Just curio

Re: an oldie but a goodie: observing properties of collected objects

2010-06-17 Thread Matt Neuburg
On Thu, 17 Jun 2010 14:51:04 -0700, Jerry Krinock said: > >On 2010 Jun 17, at 12:21, Matt Neuburg wrote: > >> My question is, does anyone have a *simple* approach to this common problem? > >Not necessarily any simpler, but another technique which may be better than observin

Re: mutableArrayValueForKey: truth or dare

2010-06-17 Thread Matt Neuburg
t > and operates on the array variable directly. > > That's not such a rare case. In fact it is exactly the case I had in mind. :) That's really just what I wanted to hear. Someone asked "how do you think the proxy object works"; that *is* how I was thinking it

Re: an oldie but a goodie: observing properties of collected objects

2010-06-17 Thread Matt Neuburg
On Jun 17, 2010, at 7:02 PM, Ken Thomases wrote: > you could probably abstract it out into a custom class to facilitate array > observing, if you really wanted it. Maybe somebody already has, for all I > know. Yeah, that's kind of what I was wondering. Or I guess you could "just" roll your o

Re: AppleScript in a Co

2010-06-21 Thread Matt Neuburg
anks, I believe your complete repertory of options is covered in my book (supplemented by the addenda at my Web site). m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! AppleScript: the Definitive Guide - Second Edition!

docs, KVO and NSUserDefaults etc.

2010-06-21 Thread Matt Neuburg
lots of properties of other objects. But how is the user supposed to know this? Or is the user who discovers this supposed to ignore it? m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! AppleScript: the Definitive

Re: Memory management on returning nil in init

2010-06-21 Thread Matt Neuburg
guage. That is where most users will enounter the "suggested format". http://developer.apple.com/mac/library/documentation/Cocoa/Conceptual/Object iveC/Articles/ocAllocInit.html Unless that code changes, there is no meaningful sense in which any other format is "suggested".

Re: docs, KVO and NSUserDefaults etc.

2010-06-22 Thread Matt Neuburg
On Mon, 21 Jun 2010 19:40:27 -0400, Scott Anguish said: >If it isn't documented as being KVO compliant it is best not to assume it is guaranteed to be in the future. > > >On Jun 21, 2010, at 1:28 PM, Matt Neuburg wrote: > >> But how is the user supposed to know this? Or

Re: can we have own application logo for ad-hoc release.

2010-06-22 Thread Matt Neuburg
;. (1) Since it's just ad hoc, who cares? Only beta testers will see it this way. (2) The docs do say something about iTunesArtwork, do they not? m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! AppleScript: the

Re: force rendering of views off screen

2010-06-23 Thread Matt Neuburg
until "it slides into view". It isn't "offscreen" if it's being drawn into the scroll view's content. Also, although I have not checked this, the ScrollViewSuite example might be useful here. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.c

Re: Not sure what's wrong with this code to using NSUserDefaults...

2010-06-24 Thread Matt Neuburg
n the program is run in the iPhone simulator (v3.2, not using 4.0 yet), it just dies. These are irreproducible results. If you just copy and paste your code into the applicationDidFinishLaunching method of a completely new project, it works fine. So clearly something else is going on - something you

C arrays as __block variables

2010-06-26 Thread Matt Neuburg
to such an array inside a block, I get a compile error, "cannot access __block variable of array type inside block." Who's mistaken, the compiler or the docs? Thx - m. -- matt neuburg, phd = m...@tidbits.com, http://www.tidbits.com/matt/ pantes anthropoi tou eidenai oregontai phus

Re: C arrays as __block variables

2010-06-27 Thread Matt Neuburg
r[1];} str; ^(){ str.arr[0]=1;}; I would suggest the docs be a bit more forthcoming about this, unless it's documented and I just didn't spot it. Thx all - m. -- matt neuburg, phd = m...@tidbits.com, http://www.tidbits.com/matt/ pantes anthropoi tou eidenai oregontai phusei Among the 200

inference of block return type

2010-06-28 Thread Matt Neuburg
bug against the docs for failing to tell me about the syntax in the second example? m. -- matt neuburg, phd = m...@tidbits.com, http://www.tidbits.com/matt/ pantes anthropoi tou eidenai oregontai phusei Among the 2007 MacTech Top 25, http://tinyurl.com/2rh4pf AppleScript: the Definitive Guide, 2n

Re: inference of block return type

2010-06-28 Thread Matt Neuburg
list", skipping merrily past the return type and indeed apparently telling you NOT to use one. >I've filed asking for the documentation to treat the block literal syntax in detail Thanks a bunch for filing that. On an important technical matter like this, the failure to just state

Re: class_respondsToSelector() in runtime.h?

2010-07-01 Thread Matt Neuburg
, all class objects have access to the instance methods defined in the root class." m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! AppleScript: the Definitive G

Re: KVO question

2010-07-01 Thread Matt Neuburg
On Thu, 1 Jul 2010 08:26:00 -0700, Rainer Standke said: >Hello all, > >is it possible to determine if one object is observing another? observationInfo doesn't do this? m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool + a tool + an aut

Re: Finder-like conversion of a fileURL to 'user-friendly' path

2010-07-01 Thread Matt Neuburg
/Desktop/S&S%20material/hidden/' to some like: 'MacHD/Users/rainer/Desktop/S&S material/hidden'. The first one is not a path; it's a file URL. The second one is a path. NSURL converts between them. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.c

Re: NSAttributedString & iOS 4

2010-07-04 Thread Matt Neuburg
n now do Core Text (which lets you draw text in multiple styles). UITextView and UITextField still display text is a single font and size. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! AppleScript: the Definitive

Re: NSTextField fieldeditor subclass example? (and an unrelated other inquiry)

2010-07-06 Thread Matt Neuburg
defined". How about passing an NSValue? Surely valueWithPoint: must be good for something... :) m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! AppleScript: the Definitive Guide - Second Edition! http://ww

Re: NSTextField fieldeditor subclass example? (and an unrelated other inquiry)

2010-07-06 Thread Matt Neuburg
Phone instead. m. -- matt neuburg, phd = m...@tidbits.com, http://www.tidbits.com/matt/ pantes anthropoi tou eidenai oregontai phusei Among the 2007 MacTech Top 25, http://tinyurl.com/2rh4pf AppleScript: the Definitive Guide, 2nd edition http://www.tidbits.com/matt/default.html#applescriptthings

Re: Pass-by value? warning (was: NSTextField fieldeditor subclass example? (and an unrelated other inquiry))

2010-07-07 Thread Matt Neuburg
t as a list of suggested things to maybe think about; it isn't a definitive list of bugs or anything like that. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! AppleScript: the Definitive Guide - Second Edition! ht

static analyzer

2010-07-07 Thread Matt Neuburg
right out of Apple's own examples here.) I know how NSURLConnections work; the static analyzer doesn't. But I would hardly call that a bug. m. -- matt neuburg, phd = m...@tidbits.com, http://www.tidbits.com/matt/ pantes anthropoi tou eidenai oregontai phusei Among the 2007 MacTech Top

Re: static analyzer

2010-07-07 Thread Matt Neuburg
ginner might not realize that - and, as I say, my code is copied and pasted right out of Apple's example; it's up to Apple to change the example if it's dangerous... http://developer.apple.com/iphone/library/documentation/Cocoa/Conceptual/URL LoadingSystem/Tasks/UsingNSURLConnection.html

Re: NSWindowController window returns nil

2010-07-07 Thread Matt Neuburg
ne in an init. Set instance variables and that's all. And set them directly; don't pass through a setter. Remember, the instance (self) is not ready until you have *returned* from the init. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool + a

Another static analyzer mistake

2010-07-12 Thread Matt Neuburg
presentMoviePlayerViewControllerAnimated:mpvc]; m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! AppleScript: the Definitive Guide - Second Edition! http://www.tidbits.com/matt/default.html#applescript

Still another static analyzer (and LLVM parser) mistake

2010-07-12 Thread Matt Neuburg
There's no warning if you do this: NSArray* arr = [NSArray arrayWithObjects: @"howdy"]; GCC's parser is smart enough to know that the missing nil terminator is just asking for trouble. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool

memory management of app delegate on iOS

2010-07-19 Thread Matt Neuburg
MainWindow nib loading. It is a top-level nib object. So it should be autoreleased. Yet the UIApplication object does NOT retain its delegate. So why doesn't the app delegate vanish in a puff of smoke? Is the MainWindow nib subject to different memory management rules? Thx - m. -- m

Re: Initializing unichar variable with a human readable letter

2010-07-20 Thread Matt Neuburg
rnings that remain in the docs are outdated incorrect. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! AppleScript: the Definitive Guide - Second Edition! http://www.tidbits.com

Re: WebView pagination for printing

2010-07-20 Thread Matt Neuburg
;t beat real printing if what you want is control over what's printed. The machinery with which you are familiar gives you that control. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! AppleScript: the Definitive Gu

Re: WebView pagination for printing

2010-07-20 Thread Matt Neuburg
pieces of the view effectively print themselves. m. -- matt neuburg, phd = m...@tidbits.com, http://www.tidbits.com/matt/ pantes anthropoi tou eidenai oregontai phusei Among the 2007 MacTech Top 25, http://tinyurl.com/2rh4pf AppleScript: the Definitive Guide, 2nd edition http://www.tidbits.com/

Re: [iOS] Block animation kills performance

2011-08-04 Thread Matt Neuburg
"User touch interactions are disabled during the animation, by default [i.e., when using what you call the block style]. This is not the case with an animation block [i.e. when using what you call the traditional way]. The optionUIViewAnimationOptionAllowUserInteraction lets you reverse this sett

Re: finding my UIViewController

2011-08-04 Thread Matt Neuburg
class]]) r = [r nextResponder]; m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/> A fool + a tool + an autorelease pool = cool! Programming iOS 4! http://www.apeth.net/matt/default.html#iosbook___ Cocoa-dev mailing lis

Re: UITableViewController, with table view not the root of its nib?

2011-08-04 Thread Matt Neuburg
e the table view fill the screen between the navigation bar and the tab bar (if either are present)." However, use of a UITableViewController doesn't really net you any functionality you can't implement yourself, so this should not be a big issue. m. -- matt neuburg

Re: Problems with UIAlertView

2011-08-15 Thread Matt Neuburg
> Date: Mon, 15 Aug 2011 19:45:03 -0700 > From: Laurent Daudelin > Subject: Problems with UIAlertView > [loginAlertView addSubview:emailAddressTextField]; > [loginAlertView addSubview:passwordTextField]; > [loginAlertView addSubview:iPadNumberTextField]; Not that it necessaril

Re: Problems with UIAlertView

2011-08-16 Thread Matt Neuburg
On Aug 15, 2011, at 9:49 PM, Laurent Daudelin wrote: > On Aug 15, 2011, at 21:39, Matt Neuburg wrote: > >>> >>> Date: Mon, 15 Aug 2011 19:45:03 -0700 >>> From: Laurent Daudelin >>> Subject: Problems with UIAlertView >> >>

Re: Autoscrolling when dragging?

2011-08-25 Thread Matt Neuburg
github, demonstrates one approach. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/> A fool + a tool + an autorelease pool = cool! Programming iOS 4! http://www.apeth.net/matt/default.html#iosbook___ Cocoa-dev mailing list (Co

Re: Introductions to OOP? [was: Re: Large over 100K pixel high ruler scroll view]

2011-09-09 Thread Matt Neuburg
w off-list if you'd like a copy). There's also a fun OOP explanation in my Ruby intro, but it's rather tightly tied to Ruby: http://www.apeth.com/rbappscript/02justenoughruby.html m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/&

Re: How to write song tags with iTunes and Scripting Bridge

2011-09-09 Thread Matt Neuburg
you're not providing any specific information about what you're doing. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/> A fool + a tool + an autorelease pool = cool! Programming iOS 4! http://www.apeth.net/matt/default.html#iosbook__

Re: How to write song tags with iTunes and Scripting Bridge

2011-09-09 Thread Matt Neuburg
ly, as I discovered the very first (and, not coincidentally, the last) time I tried using it: http://lists.apple.com/archives/applescript-implementors/2007/Nov/msg00034.html But it isn't getting *this* Apple event wrong. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/mat

Re: NSBrowser column titles disappear when scrolled [SOLVED]

2011-09-09 Thread Matt Neuburg
hen the corresponding methods do not work correctly. To add to the >mystery, the documentation for -setSeparatesColumns: says its value "is >ignored if -isTitled: does not return no." The double negative must have >confused the author of that sentence, because the value of YES does

Re: nonatomic vs atomic assign/retain

2011-09-09 Thread Matt Neuburg
his repeated loading situation to use UINib instead of NSBundle to load the nib: UINib* theCellNib = [UINib nibWithNibName:@"ComplexTableViewCell" bundle:nil]; [theCellNib instantiateWithOwner:self options:nil]; m. -- matt neuburg, phd = m...@tidbits.c

Re: Set a view's delegate using IB

2011-09-09 Thread Matt Neuburg
On Wed, 07 Sep 2011 14:12:26 -0700, Quincey Morris said: > There's something code-smelly about putting a view controller ... in a nib > file at all. I don't see why. On iOS this is so common that it is in fact built into many of Apple's own included project templates

Re: Responder-Chain question.

2011-09-13 Thread Matt Neuburg
with menus. I've been doing this for years and nothing bad has happened. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/> A fool + a tool + an autorelease pool = cool! Programming iOS 4! http://www.apeth.net/matt/default.html#iosbook__

Re: Responder-Chain question.

2011-09-14 Thread Matt Neuburg
ake assumptions about "never"; the window delegate can indeed be in the responder chain, but it might not be in the responder chain you're talking about. :) m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/> A fool + a tool + an autoreleas

Re: What does CMDeviceMotion do if there is no gyro?

2011-09-14 Thread Matt Neuburg
what does it do if the device does not have a >gyroscope If the device lacks a gyroscope, the question doesn't arise - isDeviceMotionAvailable returns NO, device-motion services will be unavailable, and you're back to dealing directly with the accelerometer and interpreting it you

Re: Why does Xcode define IBOutlet with @synthesize?

2011-09-27 Thread Matt Neuburg
emory management behavior. I don't remember whether there are similar memory management considerations on OS X, but presumably not. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/> A fool + a tool + an autorelease pool = cool! Programming iOS 4

Re: adding something to a setter

2011-10-07 Thread Matt Neuburg
the same as the discussion we had here? <http://www.cocoabuilder.com/archive/cocoa/304465-synthesised-properties-and-additional-actions.html> If so, let's pretend I just repeat my answer. :) m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/> A fool + a too

Re: Why doesn't UIViewController retain its UISearchDisplayController

2011-10-07 Thread Matt Neuburg
p557p571automaticSearchPopover> (But, as my book says, I find that second arrangement very unpleasant, because you're not given access to the stuff you need access to, like the popover controller.) m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/> A fool +

Re: Problem with AVFoundation

2011-10-07 Thread Matt Neuburg
can't hear you! :) Sorry, you can't speak of iOS 5 (or Xcode 4.2) on this list until they are out of golden master and into the public. You'd do better to ask this question on Apple's discussion board (yecch, but that's the only legal venue)... m. -- matt neuburg, phd =

Re: Retain/Release and Properties clarification

2011-10-11 Thread Matt Neuburg
; see, for instance, this note: http://www.cocoabuilder.com/archive/cocoa/298320-inherited-implicitly-created-member-is-no-member.html m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/> A fool + a tool + an autorelease pool = cool! Programming iOS 4! http://www.apeth.ne

Re: Scripting Bridge Finder

2011-10-11 Thread Matt Neuburg
pleScript list. m. PS But the answer to your first question is obvious: a closed window doesn't exist - you can't refer to it, so of course you can't change its size. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/> A fool + a tool + an autorel

Re: -viewDidUnload not always called?

2011-10-14 Thread Matt Neuburg
a really great idea - an idea so great, in fact, that I'm thinking of stealing it... :) I can think of a *lot* of places in the book that would benefit from this kind of visual summary. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/> A fool + a tool + an a

Re: IBOutlet getter/setter pattern question

2011-10-18 Thread Matt Neuburg
code, not in the nib at all? How about giving the label, if created in the nib, a tag number (how much trouble can that be, since you had to go into the nib in order to make the label in the first place) so that no ivar is needed in order to find it? I could probably go on and on... m.

Re: IBOutlet getter/setter pattern question

2011-10-20 Thread Matt Neuburg
what good this would accomplish, but there's no harm in it. However, it does seem to me that the real key to happiness for you is probably using the numeric tags. :) m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/> A fool +

Re: ARC + return of autoreleased CFType

2011-10-20 Thread Matt Neuburg
doesn't really cut it. So, maybe call this something like MyCGColorCreateWithCalibratedSpace (or something - I'm not entirely clear on the purpose of the method). m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/> A fool + a tool + an autorelease pool = c

Re: ARC + return of autoreleased CFType

2011-10-20 Thread Matt Neuburg
On Oct 20, 2011, at 1:20 PM, Greg Parker wrote: > On Oct 20, 2011, at 10:11 AM, Matt Neuburg wrote: >> You know there's a rule that Create means a retained ref is returned > > There is no such rule in the Cocoa memory management conventions. > > http://devel

Re: Scripting Bridge warning: 'no class for scripting class "iTunesBrowserWindow"'

2011-10-22 Thread Matt Neuburg
On Thu, 20 Oct 2011 15:39:54 -0400, Gabriel Roth said: >if ( [theWindow isKindOfClass:[iTunes >classForScriptingClass:@"iTunesBrowserWindow"]] ) I think iTunesBrowserWindow *is* the classForScriptingClass and that you want to ask for classForScriptingClass:@"browser

Re: Scripting Bridge warning: 'no class for scripting class "iTunesBrowserWindow"'

2011-10-24 Thread Matt Neuburg
;I think" I was just being polite. :) Feel free to file a bug on the docs, which do not do a very good job of explaining what the parameter needs to be here. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/> A fool + a tool + an autorelease pool = cool! Programming i

NSAssert no longer displaying reason in console

2011-10-24 Thread Matt Neuburg
ame project in exactly the same Xcode; all I did was switch destination between simulators. m. -- matt neuburg, phd = m...@tidbits.com, http://www.apeth.net/matt/ pantes anthropoi tou eidenai oregontai phusei Among the 2007 MacTech Top 25, http://tinyurl.com/2rh4pf Programming iOS 4! http:

Re: minor ARC casting question

2011-10-30 Thread Matt Neuburg
On Sun, 30 Oct 2011 08:46:02 -0700, Kyle Sluder said: >On Oct 30, 2011, at 8:15 AM, Matt Neuburg wrote: > >> And this is legal: >> >>id ref = (id)[[UIImage imageNamed:@"boat.gif"] CGImage]; >>self.view.layer.contents = ref; > >It's my

Re: NSAssert no longer displaying reason in console

2011-10-30 Thread Matt Neuburg
On Mon, 24 Oct 2011 16:01:30 -0700, Ben Kennedy said: >On 24 Oct 2011, at 3:53 pm, Matt Neuburg wrote: > >> That's all! Dude, where's my reason? And without a printing of the reason, >> what's the good of the assert? (And hey, I wouldn't mind

Re: NSAssert no longer displaying reason in console

2011-10-30 Thread Matt Neuburg
On Mon, 24 Oct 2011 16:01:30 -0700, Ben Kennedy said: >On 24 Oct 2011, at 3:53 pm, Matt Neuburg wrote: > >> That's all! Dude, where's my reason? And without a printing of the reason, >> what's the good of the assert? (And hey, I wouldn't mind

Re: NSAssert no longer displaying reason in console

2011-11-01 Thread Matt Neuburg
On Sun, 30 Oct 2011 09:45:25 -0700, Matt Neuburg said: >On Mon, 24 Oct 2011 16:01:30 -0700, Ben Kennedy said: >>On 24 Oct 2011, at 3:53 pm, Matt Neuburg wrote: >> >>> That's all! Dude, where's my reason? And without a printing of the reason, >>>

Re: minor ARC casting question

2011-11-01 Thread Matt Neuburg
On Sun, 30 Oct 2011 15:55:39 +, Igor Mozolevsky said: >On 30 October 2011 15:15, Matt Neuburg wrote: >> In ARC, this is legal: >> >> self.view.layer.contents = (id)[[UIImage imageNamed:@"boat.gif"] CGImage]; >> >> And this is legal: >>

Re: NSAssert no longer displaying reason in console

2011-11-01 Thread Matt Neuburg
On Nov 1, 2011, at 5:25 PM, Kyle Sluder wrote: > On Nov 1, 2011, at 7:38 PM, Matt Neuburg wrote: > >> >> Sorry to keep harping on this, but this is a serious bug. As Ben Kennedy >> says, it isn't just NSAssert. iOS often throws a fatal exception with an >>

Re: NSAssert no longer displaying reason in console

2011-11-02 Thread Matt Neuburg
ective-c > Yes, that's the part that isn't appearing on Snow Leopard. It *still* isn't as good as it used to be; on Xcode 4.0, instead of hex addresses, I got an actual call stack in English. m. -- matt neuburg, phd = m...@tidbits.com, http://www.apeth.net/matt/ pantes anthropoi to

Re: minor ARC casting question

2011-11-02 Thread Matt Neuburg
e? No. I was not saying anything about validity of anything. I was asking about the specific cases I'm asking about. You're the one who keeps elevating it to some sort of global warfare. Rather unhelpfully, I might add. m. -- matt neuburg, phd = m...@tidbits.com, http://www.apeth

Re: NSAssert no longer displaying reason in console

2011-11-02 Thread Matt Neuburg
On Nov 2, 2011, at 9:55 AM, Ben Kennedy wrote: > On 02 Nov 2011, at 8:22 am, Matt Neuburg wrote: > >> On Nov 2, 2011, at 3:39 AM, Kyle Sluder wrote: >> >>> I have to ask why you're printing $eax >> >> You tell me. I'm doing it because Ben Ken

Re: UISplitViewController some of the time

2011-11-03 Thread Matt Neuburg
w controller. So go nuts. Roll your own variant on a split view controller, and now none of Apple's rules apply to you. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/> A fool + a tool + an autorelease pool = c

Re: UIViewController containment and storyboarding

2011-11-10 Thread Matt Neuburg
y, there's nothing wrong with some or all of your segues turning out to be custom segues where you end up writing just as much code as before - perhaps more - but in different places. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/> A fool + a tool + an autorel

Re: UITextField and UIGestureRecognizers

2011-11-10 Thread Matt Neuburg
ng to disrupt that. I recommend you show a menu item instead, which the user can tap to show the list. Or some other alternate interface. *Use* the framework (by letting the framework use you) - don't fight it. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/> A

Re: Different deployment target for iPhone & iPad

2011-11-10 Thread Matt Neuburg
On Tue, 08 Nov 2011 21:59:59 +0530, Sasikumar JP said: >Is it possible to set the iPad minimum deployment target as iOS 5 and iPhone >deployment target as ios 4.2 I don't think so. Most apps that I'm familiar with, if they have issues like this, simply have two different a

Re: Why does changing a UIScrollView's contentInset change contentOffset?

2011-11-10 Thread Matt Neuburg
does what the documentation says it's supposed to do, for the first time ever.) m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/> A fool + a tool + an autorelease pool = cool! Programming iOS 4! http://www.apeth.net/matt/default.html#iosbook

Re: UITapGestureRecognizer and state/action w/rt numberOfTapsRequired

2011-11-10 Thread Matt Neuburg
le, as Apple's own apps show (like Mobile Safari). But it eliminates the delay from the user's point of view. This is all *very* well covered in my book, by the way. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/> A fool + a tool + an autorelease pool

Re: Logging in Xcode 4.2

2011-11-10 Thread Matt Neuburg
doesn't pop back down. It's non-deterministic programming! Trust me, you will wear out your mouse hand just dealing with the fact that there's no universal console window any more. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/> A fool + a tool

Re: Logging in Xcode 4.2

2011-11-10 Thread Matt Neuburg
On Nov 10, 2011, at 9:13 AM, Kyle Sluder wrote: > On Thu, Nov 10, 2011 at 8:44 AM, Richard Somers > wrote: >> I think they will eventually get it right. No way am I going back to Xcode 3. > > Xcode brought with it some massive improvements (workspaces with > multiple projects!) at some serious

Re: Different deployment target for iPhone & iPad

2011-11-11 Thread Matt Neuburg
On Thu, 10 Nov 2011 07:43:01 -0800, Matt Neuburg said: >On Tue, 08 Nov 2011 21:59:59 +0530, Sasikumar JP said: >>Is it possible to set the iPad minimum deployment target as iOS 5 and iPhone >>deployment target as ios 4.2 > >I don't think so. Most apps that I'm fam

Re: NSDateFormatter not working on iOS 5.

2011-11-11 Thread Matt Neuburg
utput); NSDate* date = [dateFormatter dateFromString: output]; NSLog(@"%@", date); It can on my machine (PST). If it can't on your machine, that sounds like a bug. Also, do try -[dateFormatter getObjectValue:forString:errorDescription:]; It is definitely throwing a

Re: Why does changing a UIScrollView's contentInset change contentOffset?

2011-11-11 Thread Matt Neuburg
On Thu, 10 Nov 2011 07:48:56 -0800, Matt Neuburg said: >On Tue, 08 Nov 2011 12:05:55 -0500, David Hoerl said: >>when I set "contentInset" that contentOffset was getting set to >>0,0. >> >>Is this known behavior (or desired behavior?) > >Don't beat

Re: UITextField and UIGestureRecognizers

2011-11-11 Thread Matt Neuburg
ing the framework. This means that your approach is fragile and highly implementation-dependent. I would suggest that you should go with things that are documented. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/> A fool + a tool + an autorelease pool = cool! Pr

Re: NSDateFormatter not working on iOS 5.

2011-11-15 Thread Matt Neuburg
> >It can on my machine (PST). If it can't on your machine, that sounds like a >bug. > >Also, do try -[dateFormatter getObjectValue:forString:errorDescription:]; It >is definitely throwing an error (not very helpful, "The operation couldn't be &

Re: capturing self is likely to lead to a retain cycle ..

2011-11-15 Thread Matt Neuburg
present an alert sheet > } > else > { > // onCancel is also the callback from the 'cancel' > button and dismissed this modally presented viewcontroller > [ self onCancel:nil ]; // <-- ARC not t

Re: About iVars declaration and property

2011-11-15 Thread Matt Neuburg
ut once in a while I need it to show up in the debugger or to be available in a subclass, and then I must declare it explicitly. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/> A fool + a tool + an autorelease pool = cool! Programming

Re: NSDateFormatter not working on iOS 5.

2011-11-17 Thread Matt Neuburg
ations that the system itself gives you: NSDictionary* d = (NSDictionary*)CFTimeZoneCopyAbbreviationDictionary(); for (NSString* aZone in d.keyEnumerator) NSLog(@"%@ %@", aZone, [dateFormatter dateFromString: [NSString stringWithFormat:@"2011-11

Re: About iVars declaration and property

2011-11-17 Thread Matt Neuburg
On Thu, 17 Nov 2011 12:40:32 +1100, Graham Cox said: > >So which were you, Kon or Bal? > >(Those of use with extremely long memories might get the reference ;-) I get the reference, and I resent the implication! :) m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.ne

Re: Cannot modify autoresizing with some iOS views

2011-11-19 Thread Matt Neuburg
iew" outlet - have "fixed" autoresizing masks, and while I can set or >unset the four outter attachments, I cannot set the inner two lines. The rule is that when you create a View nib, the view is not resizable, because it is assumed to be a root view. If that isn't what you want, delet

Re: Intermittent scrolling problem in UITableView

2011-11-19 Thread Matt Neuburg
d could be executed in the operation queue we're using to load the >data. And not just in the operation queue itself. You are probably communicating back from the operation to some controller, to let it know when the operation is completed. That communic

Re: NSDateFormatter not working on iOS 5.

2011-11-22 Thread Matt Neuburg
On Sun, 20 Nov 2011 23:54:45 -0800, Peter Edberg said: > >On Nov 17, 2011, at 10:14 AM, Matt Neuburg wrote: > >> On Wed, 16 Nov 2011 14:43:55 -0800, Peter Edberg said: >>> ... >>> >>> The issue is this: With the *short* timezone formats as specified by

Re: ARC and dealloc

2011-12-08 Thread Matt Neuburg
e of a view controller on iOS, I usually register in viewDidAppear and unregister in viewWillDisappear. But you still have to use one of these solutions to make sure the observer isn't also retained by self, or you'll leak. -- matt neuburg, phd = m...@tidbits.com,

Re: ARC and dealloc

2011-12-08 Thread Matt Neuburg
a happy camper. I'm not saying it isn't possible, I'm not saying you shouldn't do it, I'm just saying. :) m. -- matt neuburg, phd = m...@tidbits.com, <http://www.apeth.net/matt/> A fool + a tool + an autorelease pool

Re: why does this method return an id?

2011-12-12 Thread Matt Neuburg
On Sun, 11 Dec 2011 12:34:57 -0600, Charles Srstka said: >On Dec 11, 2011, at 10:58 AM, Matt Neuburg wrote: > >> There seems to be a small hole in my understanding of Objective-C. I sort of >> understand why alloc-init returns an id, but why do so many class method >> c

Re: Why does my app suddenly return nil for the version string?

2011-12-12 Thread Matt Neuburg
e values. The documentation is about as coy and opaque as it gets (and that's pretty darned coy and opaque). My policy is to disbelieve everything everybody says on this topic and supply the same value for both fields and pray we get past the Guardians. m. -- matt neuburg, phd = m...@ti

Re: Updating an app's help

2011-12-15 Thread Matt Neuburg
efore launching the new version. m. PS I've also quite often seen it happen that I'll update my code for an iOS app I'm developing and run it and an older version of the app will run, but this is for a different reason, I think. -- matt neuburg, phd = m...@tidbits.com, <htt

<    1   2   3   4   5   6   7   8   9   >