mirror of
https://github.com/cappuccino/cappuccino.git
synced 2026-10-30 20:07:36 +00:00
Fixed: if a sheet's parent window frame was changed, the sheet did not reposition
Previously, sheets were only repositioned if the parent window's setFrameOrigin: method was called. This did not cover all possible cases for parent window repositioning. Now the sheet is repositioned any time the parent window's origin changes.
This commit is contained in:
1 parent
2f4b0f8563
commit
92fb9eade5
1 file changed
+4
-4
@@ -703,6 +703,10 @@ CPTexturedBackgroundWindowMask
|
||||
}
|
||||
#endif
|
||||
|
||||
// reposition sheet
|
||||
if ([self attachedSheet])
|
||||
[self _setAttachedSheetFrameOrigin];
|
||||
|
||||
[[CPNotificationCenter defaultCenter] postNotificationName:CPWindowDidMoveNotification object:self];
|
||||
}
|
||||
|
||||
@@ -843,10 +847,6 @@ CPTexturedBackgroundWindowMask
|
||||
{
|
||||
var frame = [self _constrainOriginOfFrame:CGRectMake(anOrigin.x, anOrigin.y, _frame.size.width, _frame.size.height)];
|
||||
[self _setFrame:frame display:YES animate:NO constrainWidth:NO constrainHeight:NO];
|
||||
|
||||
// reposition sheet
|
||||
if ([self attachedSheet])
|
||||
[self _setAttachedSheetFrameOrigin];
|
||||
}
|
||||
|
||||
/*!
|
||||
|
||||
Reference in new issue
Block a user