mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-23 20:01:11 +00:00
Minor changes to better support the toolbar validation
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@19391 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
031f8b56bc
commit
aca8e03fed
3 changed files with 25 additions and 10 deletions
|
@ -1,3 +1,12 @@
|
|||
2004-05-23 Quentin Mathe <qmathe@lub-internet.fr>
|
||||
|
||||
* Source/NSWindow.m: Added a method -_windowView: which returns the root
|
||||
view (variable _wv).
|
||||
* Source/NSControl.m: Modified to call the associated superclass method
|
||||
each time -mouseDown: is called to have the possibility to add behaviors
|
||||
to the related NSView method.
|
||||
Two modifications needed to fully support toolbar validation mechanism.
|
||||
|
||||
2004-05-23 Quentin Mathe <qmathe@lub-internet.fr>
|
||||
|
||||
* Source/GSToolbarView.m:
|
||||
|
|
|
@ -552,11 +552,10 @@ static Class actionCellClass;
|
|||
if (![self isEnabled])
|
||||
return;
|
||||
|
||||
[super mouseDown: theEvent];
|
||||
|
||||
if (_ignoresMultiClick && ([theEvent clickCount] > 1))
|
||||
{
|
||||
[super mouseDown: theEvent];
|
||||
return;
|
||||
}
|
||||
return;
|
||||
|
||||
if ([_cell isContinuous])
|
||||
{
|
||||
|
|
|
@ -87,12 +87,14 @@ static NSArray *modes = nil;
|
|||
@end
|
||||
|
||||
/*
|
||||
* Catagory for internal methods (for use only within the
|
||||
* NSWindow class itsself)
|
||||
* Category for internal methods (for use only within the NSWindow class itself
|
||||
* or with other AppKit classes in the case of the _windowView method)
|
||||
*/
|
||||
@interface NSWindow (GNUstepPrivate)
|
||||
- (void) _handleWindowNeedsDisplay: (id)bogus;
|
||||
- (void) _lossOfKeyOrMainWindow;
|
||||
- (NSView *) _windowView;
|
||||
// Method used to support validation in the toolbar implementation
|
||||
@end
|
||||
|
||||
@implementation NSWindow (GNUstepPrivate)
|
||||
|
@ -219,6 +221,11 @@ has blocked and waited for events.
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
- (NSView *) _windowView
|
||||
{
|
||||
return _wv;
|
||||
}
|
||||
@end
|
||||
|
||||
|
||||
|
@ -2709,11 +2716,11 @@ resetCursorRectsForView(NSView *theView)
|
|||
[r->owner mouseEntered: e];
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if ((last) && (!now)) // Mouse exited event
|
||||
{
|
||||
if (r->flags.checked == NO)
|
||||
{
|
||||
{
|
||||
if ([r->owner respondsToSelector:
|
||||
@selector(mouseEntered:)])
|
||||
r->flags.ownerRespondsToMouseEntered = YES;
|
||||
|
@ -3018,7 +3025,7 @@ Code shared with [NSPanel -sendEvent:], remember to update both places.
|
|||
* a tracking rectangle then we need to determine if we should send
|
||||
* a NSMouseEntered or NSMouseExited event.
|
||||
*/
|
||||
(*ctImp)(self, ctSel, _contentView, theEvent);
|
||||
(*ctImp)(self, ctSel, _wv, theEvent);
|
||||
|
||||
if (_f.is_key)
|
||||
{
|
||||
|
@ -3162,7 +3169,7 @@ Code shared with [NSPanel -sendEvent:], remember to update both places.
|
|||
* We need to go through all of the views, and if there
|
||||
* is any with a tracking rectangle then we need to
|
||||
* determine if we should send a NSMouseExited event. */
|
||||
(*ctImp)(self, ctSel, _contentView, theEvent);
|
||||
(*ctImp)(self, ctSel, _wv, theEvent);
|
||||
|
||||
if (_f.is_key)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue