Open
Bug 257917
Opened 21 years ago
Updated 3 years ago
nsWindow::DispatchPendingEvents, Hwnd must not be NULL in call to EnumChildWindows
Categories
(Core :: XUL, defect)
Tracking
()
NEW
People
(Reporter: henrik, Unassigned)
References
()
Details
Attachments
(1 file)
3.31 KB,
text/plain
|
Details |
In widget\src\windows\nswindow.cpp, nsWindow::DispatchPendingEvents We are
calling ::EnumChildWindows() with a NULL Hwnd.
This is not allowed on Windows 95/98/ME.
If it is null in Win2000+ then its the same as a call to to ::EnumWindows, so
why not use this directly ?
Comment 1•21 years ago
|
||
it looks like this can only happen when GetTopLevelHWND returns NULL... why does it?
Reporter | ||
Comment 2•21 years ago
|
||
I believe when the call to ::GetParent(...) has a NULL for Hwnd. Thats what my
traces tell me.
However my tree is approx two days old, from before the GetTopLevelHwnd was used.
What currently is:
3747 // Quickly check to see if there are any
3748 // paint events pending.
3749 if (::GetQueueStatus(QS_PAINT)) {
3750 // Find the top level window.
3751 HWND topWnd = GetTopLevelHWND(mWnd);
3752
3753 // Dispatch pending paints for all topWnd's descendant windows.
3754 // Note: EnumChildWindows enumerates all descendant windows not just
3755 // it's children.
3756 ::EnumChildWindows(topWnd, nsWindow::DispatchStarvedPaints, NULL);
3757 }
is in my tree:
// Quickly check to see if there are any
// paint events pending.
if (::GetQueueStatus(QS_PAINT)) {
// Find the top level window.
HWND topWnd = mWnd;
// mWnd is somehow NULL !!??
HWND parentWnd = ::GetParent(mWnd);
while (parentWnd) {
topWnd = parentWnd;
parentWnd = ::GetParent(parentWnd);
}
// Dispatch pending paints for all topWnd's descendant windows.
// Note: EnumChildWindows enumerates all descendant windows not just
// it's children.
::EnumChildWindows(topWnd, nsWindow::DispatchStarvedPaints, NULL);
}
Reporter | ||
Comment 3•21 years ago
|
||
These tree stack traces shows the problem
Updated•17 years ago
|
Assignee: jag → nobody
Updated•3 years ago
|
Severity: normal → S3
You need to log in
before you can comment on or make changes to this bug.
Description
•