• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Blurry/flickery NSImage animation in ScreenSaverView
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Blurry/flickery NSImage animation in ScreenSaverView


  • Subject: Re: Blurry/flickery NSImage animation in ScreenSaverView
  • From: Matt Gemmell <email@hidden>
  • Date: Fri, 29 Mar 2002 23:33:47 +0000

On 29/3/02 9:09 pm, Jirtme Paschoud <email@hidden> wrote:

> I just read your post and instead of bringing you any solution, I'll ask you
> something. I'm playing with a screen saver too but I hardly don't know how
> to create a configuration pane for it. Could you tell me where you find an
> explanation or could you explain it to me directly.

Hi Jirtme,

Feel free to take a look at my source code for the screen saver I mentioned,
and use any of it that you want. Here's the URL again:

<http://www.scotlandsoftware.com/temp/src/helpneeded.sit.hqx>

Basically, do this:

- Create a nib file in Interface Builder containing an NSWindow which will
be your configuration sheet. Make an "Empty" nib file, then add an NSWindow.

- Either make some kind of controller object to mediate between the
configuration window/sheet and your ScreenSaverView subclass, or just make
the nib file's "File's Owner" be your ScreenSaverView subclass. To do that,
you'll need to first drag ScreenSaverView.h into the nib file, then drag
your subclass into the nib. You can find ScreenSaverView.h here:

/System/Library/Frameworks/ScreenSaver.framework/Versions/A/Headers/ScreenSa
verView.h

- Make sure you add a button to your sheet/window which triggers an action
in either your view or your controller object to end the sheet. The code to
end the sheet is just this:

[NSApp endSheet:sheetWindow];

(where "sheetWindow" is an outlet you've made and connected to the NSWindow
in your nib file.)

- Add appropriate code to set up the UI of your sheet before it's displayed,
and to grab values from the sheet before you end it. See my code for this,
if you like.

Basically, your ScreenSaverView subclass asks for the sheet by calling
configureSheet: (which it only calls if hasConfigureSheet: returns YES).
Remember to load your nib file in that method, if necessary. Again, see my
code.

You can find help for the ScreenSaverView and ScreenSaverDefaults classes
here:

/System/Library/Frameworks/ScreenSaver.framework/Versions/A/Resources/Englis
h.lproj/Documentation/Reference/ObjC_classic/ScreenSaverTOC.html

That should get you on your way. :-)

Best,
-Matt

--
Matt Gemmell
Scotland Software
<http://www.scotlandsoftware.com/>
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • Re: Blurry/flickery NSImage animation in ScreenSaverView
      • From: Matt Gemmell <email@hidden>
References: 
 >Re: Blurry/flickery NSImage animation in ScreenSaverView (From: Jérôme Paschoud <email@hidden>)

  • Prev by Date: Re: Frameworks in Bundles
  • Next by Date: Re: CPU Usage?
  • Previous by thread: Re: Blurry/flickery NSImage animation in ScreenSaverView
  • Next by thread: Re: Blurry/flickery NSImage animation in ScreenSaverView
  • Index(es):
    • Date
    • Thread