mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-05-30 18:10:38 +00:00
Remove subviews AFTER next/previous key views have been cleaned up, in case any subviews were in the view chain
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@29529 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
57d07cbb6f
commit
129f0cd597
2 changed files with 15 additions and 6 deletions
|
@ -570,11 +570,6 @@ GSSetDragTypes(NSView* obj, NSArray *types)
|
|||
// Remove all key value bindings for this view.
|
||||
[GSKeyValueBinding unbindAllForObject: self];
|
||||
|
||||
while ([_sub_views count] > 0)
|
||||
{
|
||||
[[_sub_views lastObject] removeFromSuperviewWithoutNeedingDisplay];
|
||||
}
|
||||
|
||||
/*
|
||||
* Remove self from view chain. Try to mimic MacOS-X behavior ...
|
||||
* We send setNextKeyView: messages to all view for which we are the
|
||||
|
@ -669,6 +664,15 @@ GSSetDragTypes(NSView* obj, NSArray *types)
|
|||
_nextKeyView = 0;
|
||||
}
|
||||
|
||||
/*
|
||||
* Now remove our subviews, AFTER cleaning up the view chain, in case
|
||||
* any of our subviews were in the chain.
|
||||
*/
|
||||
while ([_sub_views count] > 0)
|
||||
{
|
||||
[[_sub_views lastObject] removeFromSuperviewWithoutNeedingDisplay];
|
||||
}
|
||||
|
||||
RELEASE(_matrixToWindow);
|
||||
RELEASE(_matrixFromWindow);
|
||||
TEST_RELEASE(_frameMatrix);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue