On Apr 13, 2025, at 16:01, Gabriel Zachmann via Cocoa-dev 
<cocoa-dev@lists.apple.com> wrote:
> 
> 
> I don't see this on my side.
> I have let macOS launch my screensaver several times, 
> but still I see exactly one process:
>    legacyScreenSaver (Wallpaper) 
> Also, I don't see any process "ArtSaver" (the name of my plugin).

No, that's not what I mean. You won't see multiple legacyScreenSaver processes, 
but you should note that each time you start and stop your screensaver, you 
should see the memory and cpu (depending on how much cpu your screensaver 
actually uses) usage of legacyScreenSaver increase. You can easily illustrate 
this by logging when your ScreenSaverView starts and stops.

-(void) startAnimation
{
        [super startAnimation];
        NSLog(@"XXXXXXXXXXXXXXXXXXXXXX start %@", self);
        // Do whatever else you do in your screensaver.
}

-(void) stopAnimation
{
        [super stopAnimation];
         NSLog(@"XXXXXXXXXXXXXXXXXXXXXX stop %@", self);
        // Do whatever else you do in your screensaver.
}

Using something like those XXXXXXXXXXX will make it easier to filter them in 
Console.app. You should see the starts, but not the stops. And logging the 
address of self shows you that there are instances of your ScreenSaverView for 
every screen and for every launch.

A few minutes ago, legacyScreenSaver is using 1.29G. I then started and stopped 
the screensaver twice, letting it run for a bit each time. It's now up to 
1.95G. My code to force quit it doesn't always work, because legacyScreenSaver 
is just weird.

--
Steve Mills
Drummer, Mac geek

_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to