mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-23 20:01:11 +00:00
Post appropriate notifications after the user finished dragging
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@8913 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
494e75a247
commit
284aef1ae9
1 changed files with 8 additions and 1 deletions
|
@ -83,6 +83,7 @@
|
|||
unsigned int eventMask = NSLeftMouseUpMask | NSLeftMouseDraggedMask;
|
||||
/* YES if delegate implements splitView:constrainSplitPosition:ofSubviewAt:*/
|
||||
BOOL delegateConstrains = NO;
|
||||
NSNotificationCenter *nc = [NSNotificationCenter defaultCenter];
|
||||
|
||||
|
||||
/* if there are less the two subviews, there is nothing to do */
|
||||
|
@ -323,6 +324,9 @@
|
|||
|
||||
[self unlockFocus];
|
||||
|
||||
[nc postNotificationName: NSSplitViewWillResizeSubviewsNotification
|
||||
object: self];
|
||||
|
||||
/* resize the subviews accordingly */
|
||||
r = [prev frame];
|
||||
if (_isVertical == NO)
|
||||
|
@ -379,6 +383,9 @@
|
|||
|
||||
[_window invalidateCursorRectsForView: self];
|
||||
|
||||
[nc postNotificationName: NSSplitViewDidResizeSubviewsNotification
|
||||
object: self];
|
||||
|
||||
|
||||
[self setNeedsDisplay: YES];
|
||||
|
||||
|
@ -650,7 +657,7 @@ static inline NSPoint centerSizeInRect(NSSize innerSize, NSRect outerRect)
|
|||
|
||||
if (_delegate)
|
||||
{
|
||||
[nc removeObserver: _delegate name: nil object: self];
|
||||
[nc removeObserver: _delegate name: nil object: self];
|
||||
}
|
||||
_delegate = anObject;
|
||||
|
||||
|
|
Loading…
Reference in a new issue