comment out osx parent_window: it's broken anyway

This commit is contained in:
David Rose 2009-09-30 23:05:54 +00:00
parent 8f5102d889
commit 175b951440
2 changed files with 20 additions and 13 deletions

View File

@ -1142,7 +1142,8 @@ os_open_window(WindowProperties &req_properties) {
r.right = r.left + 512;
r.bottom = r.top + 512;
}
/*
if (req_properties.has_parent_window()) {
if (osxdisplay_cat.is_debug()) {
osxdisplay_cat.debug()
@ -1157,7 +1158,8 @@ os_open_window(WindowProperties &req_properties) {
osxdisplay_cat.debug()
<< "Child window created\n";
}
} else {
} else */
{
if (req_properties.has_undecorated() && req_properties.get_undecorated()) {
// create a unmovable .. no edge window..
@ -1210,9 +1212,9 @@ os_open_window(WindowProperties &req_properties) {
gWinEvtHandler = NewEventHandlerUPP(window_event_handler);
InstallWindowEventHandler(_osx_window, gWinEvtHandler, GetEventTypeCount(list), list, (void*)this, NULL); // add event handler
if(!req_properties.has_parent_window()) {
/*if(!req_properties.has_parent_window())*/ {
ShowWindow (_osx_window);
} else {
} /*else {
NSWindow *parentWindow = (NSWindow *)req_properties.get_parent_window();
// NSView* aView = [[parentWindow contentView] viewWithTag:378];
// NSRect aRect = [aView frame];
@ -1230,7 +1232,7 @@ os_open_window(WindowProperties &req_properties) {
_properties.set_parent_window(req_properties.get_parent_window());
req_properties.clear_parent_window();
}
} */
if (osxdisplay_cat.is_debug()) {
osxdisplay_cat.debug()
@ -1309,7 +1311,7 @@ process_events() {
EventRef theEvent;
EventTargetRef theTarget = GetEventDispatcherTarget();
if (!_properties.has_parent_window()) {
/*if (!_properties.has_parent_window()) */ {
while (ReceiveNextEvent(0, NULL, kEventDurationNoWait, true, &theEvent)== noErr) {
SendEventToEventTarget (theEvent, theTarget);
ReleaseEvent(theEvent);
@ -1795,6 +1797,7 @@ do_reshape_request(int x_origin, int y_origin, bool has_origin,
return false;
}
/*
if (_properties.has_parent_window()) {
if (has_origin) {
NSWindow* parentWindow = (NSWindow *)_properties.get_parent_window();
@ -1802,7 +1805,8 @@ do_reshape_request(int x_origin, int y_origin, bool has_origin,
MoveWindow(_osx_window, x_origin+parentFrame.origin.x, y_origin+parentFrame.origin.y, false);
}
} else {
} else */
{
// We sometimes get a bogus origin of (0, 0). As a special hack,
// treat this as a special case, and ignore it.
if (has_origin) {

View File

@ -945,7 +945,8 @@ bool TinyOsxGraphicsWindow::OSOpenWindow(WindowProperties &req_properties)
r.right = r.left + 512;
r.bottom = r.top + 512;
}
/*
if (req_properties.has_parent_window())
{
tinydisplay_cat.info() << "Creating child window\n";
@ -956,7 +957,7 @@ bool TinyOsxGraphicsWindow::OSOpenWindow(WindowProperties &req_properties)
_properties.set_fixed_size(true);
tinydisplay_cat.info() << "Child window created\n";
}
else
else */
{
if (req_properties.has_undecorated() && req_properties.get_undecorated())
{ // create a unmovable .. no edge window..
@ -1008,10 +1009,11 @@ bool TinyOsxGraphicsWindow::OSOpenWindow(WindowProperties &req_properties)
gWinEvtHandler = NewEventHandlerUPP(windowEvtHndlr);
InstallWindowEventHandler(_osx_window, gWinEvtHandler, GetEventTypeCount(list), list, (void*)this, NULL); // add event handler
if(!req_properties.has_parent_window())
/*if(!req_properties.has_parent_window()) */
{
ShowWindow (_osx_window);
}
/*
else
{
@ -1036,7 +1038,7 @@ bool TinyOsxGraphicsWindow::OSOpenWindow(WindowProperties &req_properties)
_properties.set_parent_window(req_properties.get_parent_window());
req_properties.clear_parent_window();
}
} */
if (req_properties.has_fullscreen())
{
@ -1090,7 +1092,7 @@ void TinyOsxGraphicsWindow::process_events()
EventRef theEvent;
EventTargetRef theTarget = GetEventDispatcherTarget();
if (!_properties.has_parent_window())
/*if (!_properties.has_parent_window())*/
{
while (ReceiveNextEvent(0, NULL, kEventDurationNoWait, true, &theEvent)== noErr)
{
@ -1582,6 +1584,7 @@ bool TinyOsxGraphicsWindow::do_reshape_request(int x_origin, int y_origin, bool
return false;
}
/*
if (_properties.has_parent_window())
{
if (has_origin)
@ -1592,7 +1595,7 @@ bool TinyOsxGraphicsWindow::do_reshape_request(int x_origin, int y_origin, bool
MoveWindow(_osx_window, x_origin+parentFrame.origin.x, y_origin+parentFrame.origin.y, false);
}
}
else
else*/
{
// We sometimes get a bogus origin of (0, 0). As a special hack,
// treat this as a special case, and ignore it.