mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-06-01 19:01:54 +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
6471f6b02e
commit
11281063c0
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>
|
2004-05-23 Quentin Mathe <qmathe@lub-internet.fr>
|
||||||
|
|
||||||
* Source/GSToolbarView.m:
|
* Source/GSToolbarView.m:
|
||||||
|
|
|
@ -552,11 +552,10 @@ static Class actionCellClass;
|
||||||
if (![self isEnabled])
|
if (![self isEnabled])
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
[super mouseDown: theEvent];
|
||||||
|
|
||||||
if (_ignoresMultiClick && ([theEvent clickCount] > 1))
|
if (_ignoresMultiClick && ([theEvent clickCount] > 1))
|
||||||
{
|
return;
|
||||||
[super mouseDown: theEvent];
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if ([_cell isContinuous])
|
if ([_cell isContinuous])
|
||||||
{
|
{
|
||||||
|
|
|
@ -87,12 +87,14 @@ static NSArray *modes = nil;
|
||||||
@end
|
@end
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Catagory for internal methods (for use only within the
|
* Category for internal methods (for use only within the NSWindow class itself
|
||||||
* NSWindow class itsself)
|
* or with other AppKit classes in the case of the _windowView method)
|
||||||
*/
|
*/
|
||||||
@interface NSWindow (GNUstepPrivate)
|
@interface NSWindow (GNUstepPrivate)
|
||||||
- (void) _handleWindowNeedsDisplay: (id)bogus;
|
- (void) _handleWindowNeedsDisplay: (id)bogus;
|
||||||
- (void) _lossOfKeyOrMainWindow;
|
- (void) _lossOfKeyOrMainWindow;
|
||||||
|
- (NSView *) _windowView;
|
||||||
|
// Method used to support validation in the toolbar implementation
|
||||||
@end
|
@end
|
||||||
|
|
||||||
@implementation NSWindow (GNUstepPrivate)
|
@implementation NSWindow (GNUstepPrivate)
|
||||||
|
@ -219,6 +221,11 @@ has blocked and waited for events.
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
- (NSView *) _windowView
|
||||||
|
{
|
||||||
|
return _wv;
|
||||||
|
}
|
||||||
@end
|
@end
|
||||||
|
|
||||||
|
|
||||||
|
@ -2709,11 +2716,11 @@ resetCursorRectsForView(NSView *theView)
|
||||||
[r->owner mouseEntered: e];
|
[r->owner mouseEntered: e];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((last) && (!now)) // Mouse exited event
|
if ((last) && (!now)) // Mouse exited event
|
||||||
{
|
{
|
||||||
if (r->flags.checked == NO)
|
if (r->flags.checked == NO)
|
||||||
{
|
{
|
||||||
if ([r->owner respondsToSelector:
|
if ([r->owner respondsToSelector:
|
||||||
@selector(mouseEntered:)])
|
@selector(mouseEntered:)])
|
||||||
r->flags.ownerRespondsToMouseEntered = YES;
|
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 tracking rectangle then we need to determine if we should send
|
||||||
* a NSMouseEntered or NSMouseExited event.
|
* a NSMouseEntered or NSMouseExited event.
|
||||||
*/
|
*/
|
||||||
(*ctImp)(self, ctSel, _contentView, theEvent);
|
(*ctImp)(self, ctSel, _wv, theEvent);
|
||||||
|
|
||||||
if (_f.is_key)
|
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
|
* We need to go through all of the views, and if there
|
||||||
* is any with a tracking rectangle then we need to
|
* is any with a tracking rectangle then we need to
|
||||||
* determine if we should send a NSMouseExited event. */
|
* determine if we should send a NSMouseExited event. */
|
||||||
(*ctImp)(self, ctSel, _contentView, theEvent);
|
(*ctImp)(self, ctSel, _wv, theEvent);
|
||||||
|
|
||||||
if (_f.is_key)
|
if (_f.is_key)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue