Re: Slow down a scroller?

2013-09-11 Thread Kyle Sluder
On Sep 11, 2013, at 9:59 AM, Steve Mills wrote: > > My mistake. I should've said that I was dividing by 100. I guess I also > neglected to mention that this scroller is the scroller in an NSScrollView. > In this mode, the document view is the same size as the scroll view, and we > change the

Re: Slow down a scroller?

2013-09-11 Thread Steve Mills
On Sep 11, 2013, at 11:30:45, Alex Zavatone wrote: > Think about this. > > When in iTunes on an iOS device, and you are scrubbing an audio track, the > farther down your finger is from the scrub knob, when you drag left and > right, there is a multiplier to make the scrubbing slower. > > I'm

Re: AuthorizationExecuteWithPrivileges deprecated

2013-09-11 Thread Jerry Krinock
On 2013 Sep 11, at 08:34, Charles Srstka wrote: > You have to use SMJobBless to install the tool as root, and then pick your > favorite form of IPC to communicate with it (XPC is best, if you can require > 10.7). That is correct. This example by Steve Streeting will probably help… https://b

Re: Slow down a scroller?

2013-09-11 Thread Steve Mills
I didn't get any responses when I sent this a few months ago. How about now? Is there any way to make a scroller less touchy? We have a couple cases where the horizontal scroller isn't controlling pixel movements of the view, but is used for more granular movements (rounded to the beginning of e

Re: 64-bit iOS

2013-09-11 Thread Roland King
On 11 Sep, 2013, at 11:01 pm, Vincent Habchi wrote: > Probably not. I fear many people will think that with 64-bit pointers they > get a lot of usable space, and then see their code crippled by low memory > warnings. > The conversion guide makes a particular point about memory pressure on s

Re: ARC vs Manual Reference Counting

2013-09-11 Thread Louis Gerbarg
On Wed, Sep 11, 2013 at 6:58 AM, Dave wrote: > > On 11 Sep 2013, at 05:04, Jens Alfke wrote: > > > > > On Sep 10, 2013, at 12:33 PM, Dave wrote: > > > >> You with all this talk of memory management, you'd think that Apple (or > someone) would have come up with a hardware solution for this by no

Re: 64-bit iOS

2013-09-11 Thread Vincent Habchi
Scott, > No, but it's great to device to access data, perhaps even bits pulled out > from a huge pile, and preferably pulled out extremely quickly. > And, anyway, why shouldn't it be a huge database machine??? I meant, it is not designed to serve as a database machine. I can’t possibly imagine

Re: 64-bit iOS

2013-09-11 Thread Stephane Sudre
On Wed, Sep 11, 2013 at 12:41 PM, Jean-Daniel Dupas wrote: > > Thanks for this remainder, but I think we all already know that 620k is > enough for anyone… Well, I must confess I didn't know that. I thought 640k was required. ___ Cocoa-dev mailing lis

Re: Slow down a scroller?

2013-09-11 Thread Steve Mills
On Sep 11, 2013, at 12:49:49, Steve Mills wrote: > On Sep 11, 2013, at 12:16:54, Kyle Sluder > wrote: > >> Furthermore, your document view is the same size as your scroll view? Is >> this intentional? Because that's not how the scrolling architecture is >> designed to work. > > Yes, it's ver

Re: Crashing Problem calling postNotificationName

2013-09-11 Thread dangerwillrobinsondanger
On Sep 11, 2013, at 10:52 PM, Dave wrote: > > On 11 Sep 2013, at 14:22, Graham Cox wrote: > >> >> On 11/09/2013, at 3:13 PM, Dave wrote: >> >>> Yes, but it doesn't remember the last value of a notification, which is >>> what I would like. >> [] >> >>> Yes, I am removing myself as a recei

Re: Crashing Problem calling postNotificationName

2013-09-11 Thread Gary L. Wade
On Sep 11, 2013, at 6:52 AM, Dave wrote: > I mean when the object is created - at this point I want the latest version > of the Notification, not the Notification when the Object Died. NSNotification and the various Center classes are meant to be used for loosely coupling between classes. If

Re: Slow down a scroller?

2013-09-11 Thread Steve Mills
On Sep 11, 2013, at 12:49:49, Steve Mills wrote: > Hmm, that's an idea. I've just added it and am getting results I didn't > expect. Here's the first event. Notice that deltaX is 0, but deviceDeltaX is > -1, and that's not a public member: Oh, I didn't know about the scrollingDelta* methods be

Re: Slow down a scroller?

2013-09-11 Thread Steve Mills
On Sep 11, 2013, at 12:16:54, Kyle Sluder wrote: > Does calling -[NSScrolView set{Vertical,Horizontal}LineScroll:] not affect > the scroll wheel behavior? Correct. It only affects the arrows that are no longer there. :) > If not, what about implementing -scrollWheel: in your document view? H

Re: ARC vs Manual Reference Counting

2013-09-11 Thread Andy Lee
On Sep 11, 2013, at 6:37 AM, Jean-Daniel Dupas wrote: >>> and that while in most code those would be lost in the noise, in some cases >>> people would need to help ARC out with things like __unsafe_unretained. >> >> Hmm…I always thought that __unsafe_unretained was for instance variables, >> bu

Re: Slow down a scroller?

2013-09-11 Thread Alex Zavatone
Think about this. When in iTunes on an iOS device, and you are scrubbing an audio track, the farther down your finger is from the scrub knob, when you drag left and right, there is a multiplier to make the scrubbing slower. I'm thinking that in your case, you could use a scroll rate multiplier

Re: Slow down a scroller?

2013-09-11 Thread Richard Somers
The "Change Time Scale" slider in Apple's Instruments application implements a novel self centering time based algorithm. A very interesting approach to a slider. Perhaps you also need to think outside the box and implement the desired behavior in a custom control. --Richard Somers On Jul 31,

Re: AuthorizationExecuteWithPrivileges deprecated

2013-09-11 Thread Charles Srstka
On Sep 11, 2013, at 5:53 AM, Gerriet M. Denkmann wrote: > I have this code: > > AuthorizationRef auth; > OSStatus aa = AuthorizationCreate( NULL, kAuthorizationEmptyEnvironment, > kAuthorizationFlagDefaults, &auth); > > const char *pathToTool = [ theHelperPath fileSystemRepresentation ];

Re: ARC vs Manual Reference Counting

2013-09-11 Thread Jean-Daniel Dupas
ARC is a combination of compiler and runtime technologie. The compiler generates call to the runtime, so if you see a lot of ARC specific calls in the profiler, you can know if the impact is due to ARC or not. http://clang.llvm.org/docs/AutomaticReferenceCounting.html#runtime-support Le 11 sep

Re: Crashing Problem calling postNotificationName

2013-09-11 Thread Dave
On 11 Sep 2013, at 14:22, Graham Cox wrote: > > On 11/09/2013, at 3:13 PM, Dave wrote: > >> Yes, but it doesn't remember the last value of a notification, which is what >> I would like. > [] > >> Yes, I am removing myself as a receiver, but ideally I want to receive these >> notification e

Re: Crashing Problem calling postNotificationName

2013-09-11 Thread Graham Cox
On 11/09/2013, at 3:13 PM, Dave wrote: > Yes, but it doesn't remember the last value of a notification, which is what > I would like. [] > Yes, I am removing myself as a receiver, but ideally I want to receive these > notification even if the object is dead. By this I mean, I want the last >

Re: Crashing Problem calling postNotificationName

2013-09-11 Thread Dave
On 11 Sep 2013, at 13:55, Graham Cox wrote: > > On 11/09/2013, at 1:35 PM, Dave wrote: > >> Is there any problem with having all notifications handled by one object >> that doesn't go away, > > Well, [NSNotificationCenter defaultCenter] is that object… Yes, but it doesn't remember the last

Re: Crashing Problem calling postNotificationName

2013-09-11 Thread Graham Cox
On 11/09/2013, at 1:35 PM, Dave wrote: > Is there any problem with having all notifications handled by one object that > doesn't go away, Well, [NSNotificationCenter defaultCenter] is that object... > and have this ship the notificationa off to the correct object as long as it > is still al

Re: Crashing Problem calling postNotificationName

2013-09-11 Thread Jerry Krinock
On 2013 Sep 11, at 04:35, Dave wrote: > the problem it was a Notification being sent to a dead object Yup. > Is there any problem with having all notifications handled by one object that > doesn't go away, and have this ship the notificationa off to the correct > object as long as it is stil

Re: 64-bit iOS

2013-09-11 Thread Roland King
On 11 Sep, 2013, at 5:31 pm, Vincent Habchi wrote: > But what bother me most, is that I don’t really see the point. A smartphone > is a phone, it is neither a web server nor a huge database machine nor a > supercomputer. Who wants to mmap 5 GiB files on a phone? Which process needs > more tha

Re: 64-bit iOS

2013-09-11 Thread Vincent Habchi
> Thanks for this remainder, but I think we all already know that 620k is > enough for anyone… Frankly, Jean-Daniel, I don’t want to get involved in a pointless bickering, but all I need on a phone was almost already running twenty-five years ago on my first Atari 520ST with, yes, 512 KiB of RA

Re: Crashing Problem calling postNotificationName

2013-09-11 Thread Dave
Hi, Sorry for the lack of data in my original post! I Found the problem it was a Notification being sent to a dead object, it didn't happen very often, one crash after over an hour running continuously. I was more worried about the data I was passing not belonging to same thread (I recently add

Re: ARC vs Manual Reference Counting

2013-09-11 Thread Dave
On 11 Sep 2013, at 11:37, Jean-Daniel Dupas wrote: > > Yes. it works to disable ARC for arguments and other local variables. I > managed to reduce the ARC impact a little further by applying it to some > arguments in hot paths. > > > -- Jean-Daniel I would have thought that you would get m

Re: ARC vs Manual Reference Counting

2013-09-11 Thread Dave
On 11 Sep 2013, at 05:04, Jens Alfke wrote: > > On Sep 10, 2013, at 12:33 PM, Dave wrote: > >> You with all this talk of memory management, you'd think that Apple (or >> someone) would have come up with a hardware solution for this by now. In the >> 70's and 80's I worked on some firmware a

AuthorizationExecuteWithPrivileges deprecated

2013-09-11 Thread Gerriet M. Denkmann
I have this code: AuthorizationRefauth; OSStatus aa = AuthorizationCreate( NULL, kAuthorizationEmptyEnvironment, kAuthorizationFlagDefaults, &auth); const char *pathToTool = [ theHelperPath fileSystemRepresentation ]; const char *const arguments[] = { "--self-repair", NULL }; FILE *commu

Re: 64-bit iOS

2013-09-11 Thread Jean-Daniel Dupas
Le 11 sept. 2013 à 11:31, Vincent Habchi a écrit : > Mostly, this is not going to change anything. You will see your code size > increase, because unless you use PIC, you’ll have to store 64-bit addresses > instead of 32. There will be more cache misses as your memory space becomes > sparse.

Re: ARC vs Manual Reference Counting

2013-09-11 Thread Jean-Daniel Dupas
Le 11 sept. 2013 à 09:03, Marcel Weiher a écrit : > Hi John! > > On Sep 10, 2013, at 19:26 , John McCall wrote: > >> On Sep 9, 2013, at 4:15 AM, Marcel Weiher wrote: >>> [Optimizations in ARC are there to mitigate pessimizations] >> >> For what it’s worth, the autorelease optimization was p

Re: 64-bit iOS

2013-09-11 Thread Vincent Habchi
Mostly, this is not going to change anything. You will see your code size increase, because unless you use PIC, you’ll have to store 64-bit addresses instead of 32. There will be more cache misses as your memory space becomes sparse. It will surely run faster, but not because the bus size has be

Re: ARC vs Manual Reference Counting

2013-09-11 Thread John McCall
On Sep 11, 2013, at 12:03 AM, Marcel Weiher wrote: > On Sep 10, 2013, at 19:26 , John McCall wrote: >> On Sep 9, 2013, at 4:15 AM, Marcel Weiher wrote: >>> [Optimizations in ARC are there to mitigate pessimizations] >> >> For what it’s worth, the autorelease optimization was planned; the >> pe

Re: NSWindowCloseButton and friends mouse over highlight

2013-09-11 Thread dangerwillrobinsondanger
On Sep 11, 2013, at 4:15 PM, Kyle Sluder wrote: > On Sep 10, 2013, at 10:34 PM, dangerwillrobinsondan...@gmail.com wrote: > >> >> However, sending highlight:YES to the button or setHighlighted:YES to the >> button cell, both give the mouse down image of the traffic light buttons. >> >> Is th

Re: NSWindowCloseButton and friends mouse over highlight

2013-09-11 Thread Kyle Sluder
On Sep 10, 2013, at 10:34 PM, dangerwillrobinsondan...@gmail.com wrote: > > However, sending highlight:YES to the button or setHighlighted:YES to the > button cell, both give the mouse down image of the traffic light buttons. > > Is there something I'm missing in the docs or documented in a hea

Re: ARC vs Manual Reference Counting

2013-09-11 Thread Marcel Weiher
Hi John! On Sep 10, 2013, at 19:26 , John McCall wrote: > On Sep 9, 2013, at 4:15 AM, Marcel Weiher wrote: >> [Optimizations in ARC are there to mitigate pessimizations] > > For what it’s worth, the autorelease optimization was planned; the > performance problem it solves was extremely predic