Revision: 5728
http://skim-app.svn.sourceforge.net/skim-app/?rev=5728&view=rev
Author: hofman
Date: 2009-09-09 16:40:39 +0000 (Wed, 09 Sep 2009)
Log Message:
-----------
declare methods in delegate protocol
Modified Paths:
--------------
trunk/SKMainWindowController_UI.m
trunk/SKNoteOutlineView.h
trunk/SKNoteOutlineView.m
trunk/SKTransitionController.m
Modified: trunk/SKMainWindowController_UI.m
===================================================================
--- trunk/SKMainWindowController_UI.m 2009-09-09 16:27:50 UTC (rev 5727)
+++ trunk/SKMainWindowController_UI.m 2009-09-09 16:40:39 UTC (rev 5728)
@@ -1045,6 +1045,10 @@
return nil;
}
+- (NSWindow *)outlineViewWindowForSheet:(NSOutlineView *)anOutlineView {
+ return [self window];
+}
+
- (void)outlineView:(NSOutlineView *)ov typeSelectHelper:(SKTypeSelectHelper
*)typeSelectHelper didFailToFindMatchForSearchString:(NSString *)searchString {
if ([ov isEqual:noteOutlineView]) {
[statusBar setRightStringValue:[NSString
stringWithFormat:NSLocalizedString(@"No match: \"%...@\"", @"Status message"),
searchString]];
Modified: trunk/SKNoteOutlineView.h
===================================================================
--- trunk/SKNoteOutlineView.h 2009-09-09 16:27:50 UTC (rev 5727)
+++ trunk/SKNoteOutlineView.h 2009-09-09 16:40:39 UTC (rev 5728)
@@ -48,6 +48,7 @@
- (void)outlineViewNoteTypesDidChange:(NSOutlineView *)anOutlineView;
- (void)outlineViewCommandKeyPressedDuringNavigation:(NSOutlineView
*)anOutlineView;
- (void)outlineViewInsertNewline:(NSOutlineView *)anOutlineView;
+- (NSWindow *)outlineViewWindowForSheet:(NSOutlineView *)anOutlineView;
@end
Modified: trunk/SKNoteOutlineView.m
===================================================================
--- trunk/SKNoteOutlineView.m 2009-09-09 16:27:50 UTC (rev 5727)
+++ trunk/SKNoteOutlineView.m 2009-09-09 16:40:39 UTC (rev 5728)
@@ -346,7 +346,7 @@
[[noteTypeMatrix cellWithTag:i] setState:[[menu itemAtIndex:i] state]];
[NSApp beginSheet:noteTypeSheet
- modalForWindow:[[self delegate] respondsToSelector:@selector(window)] ?
[(id)[self delegate] window] : [self window]
+ modalForWindow:[[self delegate]
respondsToSelector:@selector(outlineViewWindowForSheet:)] ? [[self delegate]
outlineViewWindowForSheet:self] : [self window]
modalDelegate:self
didEndSelector:@selector(noteTypeSheetDidEnd:returnCode:contextInfo:)
contextInfo:NULL];
Modified: trunk/SKTransitionController.m
===================================================================
--- trunk/SKTransitionController.m 2009-09-09 16:27:50 UTC (rev 5727)
+++ trunk/SKTransitionController.m 2009-09-09 16:40:39 UTC (rev 5728)
@@ -111,16 +111,25 @@
#pragma mark -
+...@protocol SKTransitionAnimationDelegate <NSAnimationDelegate>
+SKOPTIONAL(SKTransitionAnimationDelegate)
+- (void)display;
+...@end
+
@interface SKTransitionAnimation : NSAnimation {
CIFilter *filter;
}
- (id)initWithFilter:(CIFilter *)aFilter duration:(NSTimeInterval)duration;
- (CIImage *)currentImage;
+#if MAC_OS_X_VERSION_MAX_ALLOWED > MAC_OS_X_VERSION_10_5
+- (id <SKTransitionAnimationDelegate>)delegate;
+- (void)setDelegate:(id <SKTransitionAnimationDelegate>)newDelegate;
+#endif
@end
#pragma mark -
-...@interface SKTransitionView : NSOpenGLView <NSAnimationDelegate> {
+...@interface SKTransitionView : NSOpenGLView <SKTransitionAnimationDelegate> {
SKTransitionAnimation *animation;
CIImage *image;
CIContext *context;
@@ -568,13 +577,23 @@
- (void)setCurrentProgress:(NSAnimationProgress)progress {
[super setCurrentProgress:progress];
[filter setValue:[NSNumber numberWithDouble:[self currentValue]]
forKey:@"inputTime"];
- [(id)[self delegate] display];
+ [[self delegate] display];
}
- (CIImage *)currentImage {
return [filter valueForKey:@"outputImage"];
}
+#if MAC_OS_X_VERSION_MAX_ALLOWED > MAC_OS_X_VERSION_10_5
+- (id <SKTransitionAnimationDelegate>)delegate {
+ return (id <SKTransitionAnimationDelegate>)[super delegate];
+}
+
+- (void)setDelegate:(id <SKTransitionAnimationDelegate>)newDelegate {
+ [super setDelegate:newDelegate];
+}
+#endif
+
@end
#pragma mark -
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now. http://p.sf.net/sfu/bobj-july
_______________________________________________
Skim-app-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/skim-app-commit