mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-23 07:00:46 +00:00
Added new NSResponder method declarations and implemented shouldBeTreatedAsInkEvent:.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@21238 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
fe0e6ce497
commit
29db6affc8
7 changed files with 66 additions and 0 deletions
12
ChangeLog
12
ChangeLog
|
@ -1,3 +1,15 @@
|
|||
2005-05-20 Fred Kiefer <FredKiefer@gmx.de>
|
||||
|
||||
* Headers/AppKit/NSResponder.h: Added new MacOSX methods.
|
||||
* Source/NSResponder.m (-encodeWithCoder:, initWithCoder:) Handle
|
||||
NSNextResponder for keyed encoding.
|
||||
* Source/NSResponder.m
|
||||
* Source/NSApplication.m
|
||||
* Source/NSWindow.m
|
||||
* Source/NSView.m
|
||||
* Source/NSControl.m:
|
||||
Implemented shouldBeTreatedAsInkEvent:.
|
||||
|
||||
2005-05-19 Fred Kiefer <FredKiefer@gmx.de>
|
||||
|
||||
* Source/NSImageCell.m (-setObjectValue:) Nil parameter now unsets
|
||||
|
|
|
@ -169,6 +169,8 @@
|
|||
*/
|
||||
- (NSInterfaceStyle) interfaceStyle;
|
||||
- (void) setInterfaceStyle: (NSInterfaceStyle)aStyle;
|
||||
|
||||
- (BOOL) shouldBeTreatedAsInkEvent: (NSEvent *)theEvent;
|
||||
#endif
|
||||
@end
|
||||
|
||||
|
@ -232,6 +234,13 @@
|
|||
- (void) transposeWords: (id)sender;
|
||||
- (void) uppercaseWord: (id)sender;
|
||||
- (void) yank: (id)sender;
|
||||
|
||||
// New in MacOSX 10.3
|
||||
- (void) cancelOperation: (id)sender;
|
||||
- (void) deleteBackwardByDecomposingPreviousCharacter: (id)sender;
|
||||
- (void) moveLeftAndModifySelection: (id)sender;
|
||||
- (void) moveRightAndModifySelection: (id)sender;
|
||||
|
||||
@end
|
||||
#endif
|
||||
|
||||
|
|
|
@ -1633,6 +1633,11 @@ See -runModalForWindow:
|
|||
return _current_event;
|
||||
}
|
||||
|
||||
- (BOOL) shouldBeTreatedAsInkEvent: (NSEvent *)theEvent
|
||||
{
|
||||
return [[theEvent window] shouldBeTreatedAsInkEvent: theEvent];
|
||||
}
|
||||
|
||||
- (void) discardEventsMatchingMask: (unsigned int)mask
|
||||
beforeEvent: (NSEvent *)lastEvent
|
||||
{
|
||||
|
|
|
@ -687,6 +687,11 @@ static Class actionCellClass;
|
|||
[self sendAction: [self action] to: [self target]];
|
||||
}
|
||||
|
||||
- (BOOL) shouldBeTreatedAsInkEvent: (NSEvent *)theEvent
|
||||
{
|
||||
return NO;
|
||||
}
|
||||
|
||||
- (void) resetCursorRects
|
||||
{
|
||||
[_cell resetCursorRect: _bounds inView: self];
|
||||
|
|
|
@ -351,6 +351,11 @@
|
|||
[aCoder encodeObject: [self menu]
|
||||
forKey: @"NSMenu"];
|
||||
}
|
||||
if([self nextResponder] != nil)
|
||||
{
|
||||
[aCoder encodeConditionalObject: [self nextResponder]
|
||||
forKey: @"NSNextResponder"];
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -375,6 +380,11 @@
|
|||
{
|
||||
obj = [aDecoder decodeObjectForKey: @"NSMenu"];
|
||||
}
|
||||
|
||||
if([aDecoder containsValueForKey: @"NSNextResponder"])
|
||||
{
|
||||
[self setNextResponder: [aDecoder decodeObjectForKey: @"NSNextResponder"]];
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -416,4 +426,10 @@
|
|||
{
|
||||
return nil;
|
||||
}
|
||||
|
||||
- (BOOL) shouldBeTreatedAsInkEvent: (NSEvent *)theEvent
|
||||
{
|
||||
return NO;
|
||||
}
|
||||
|
||||
@end
|
||||
|
|
|
@ -4247,5 +4247,10 @@ static NSView* findByTag(NSView *view, int aTag, unsigned *level)
|
|||
}
|
||||
}
|
||||
|
||||
- (BOOL) shouldBeTreatedAsInkEvent: (NSEvent *)theEvent
|
||||
{
|
||||
return YES;
|
||||
}
|
||||
|
||||
@end
|
||||
|
||||
|
|
|
@ -3429,6 +3429,20 @@ resetCursorRectsForView(NSView *theView)
|
|||
}
|
||||
}
|
||||
|
||||
- (BOOL) shouldBeTreatedAsInkEvent: (NSEvent *)theEvent
|
||||
{
|
||||
NSView *v;
|
||||
|
||||
v = [_wv hitTest: [theEvent locationInWindow]];
|
||||
if (![self isMainWindow])
|
||||
{
|
||||
return (v != _wv);
|
||||
}
|
||||
else
|
||||
{
|
||||
return [v shouldBeTreatedAsInkEvent: theEvent];
|
||||
}
|
||||
}
|
||||
|
||||
- (BOOL) tryToPerform: (SEL)anAction with: (id)anObject
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue