X-Git-Url: http://git.hungrycats.org/cgi-bin/gitweb.cgi?p=xscreensaver;a=blobdiff_plain;f=OSX%2FSaverRunner.m;h=526f62eb0dc4071b3a0a8e19c1282a154cf7f207;hp=3fd451d9ae2b23cb7680e6d34cb3f3b93bc06e5c;hb=c141c2b05e374757b6499d12bb8a6d4d943b1529;hpb=6f5482d73adb0165c0130bb47d852644ab0c4869 diff --git a/OSX/SaverRunner.m b/OSX/SaverRunner.m index 3fd451d9..526f62eb 100644 --- a/OSX/SaverRunner.m +++ b/OSX/SaverRunner.m @@ -426,10 +426,20 @@ relabel_menus (NSObject *v, NSString *old_str, NSString *new_str) saverName = name; + if (! backgroundView) { + // This view is the parent of the XScreenSaverView, and exists only + // so that there is a black background behind it. Without this, when + // rotation is in progresss, the scrolling-list window's corners show + // through in the corners. + backgroundView = [[[NSView class] alloc] initWithFrame:[window frame]]; + [backgroundView setBackgroundColor:[NSColor blackColor]]; + } + if (saverView) { if ([saverView isAnimating]) [saverView stopAnimation]; [saverView removeFromSuperview]; + [backgroundView removeFromSuperview]; } NSSize size = [window frame].size; @@ -455,7 +465,8 @@ relabel_menus (NSObject *v, NSString *old_str, NSString *new_str) LAUNCH: if (launch) { [self saveScreenshot]; - [window addSubview: saverView]; + [window addSubview: backgroundView]; + [backgroundView addSubview: saverView]; [saverView becomeFirstResponder]; [saverView startAnimation]; }