Closed
Bug 328306
Opened 19 years ago
Closed 19 years ago
Open/Save dialogs no longer work on Win9x/Me/NT4 even if cairo is disabled
Categories
(Core :: Widget: Win32, defect)
Tracking
()
RESOLVED
FIXED
People
(Reporter: emk, Assigned: emk)
References
Details
(Keywords: regression)
Attachments
(1 file)
(deleted),
patch
|
roc
:
review+
roc
:
superreview+
|
Details | Diff | Splinter Review |
Because _WIN32_WINNT=0x500 changed the sizeof(OPENFILENAME) value.
Assignee | ||
Comment 1•19 years ago
|
||
Assignee: win32 → VYV03354
Status: NEW → ASSIGNED
Attachment #212888 -
Flags: superreview?(roc)
Attachment #212888 -
Flags: review?(roc)
Attachment #212888 -
Flags: superreview?(roc)
Attachment #212888 -
Flags: superreview+
Attachment #212888 -
Flags: review?(roc)
Attachment #212888 -
Flags: review+
Updated•19 years ago
|
Keywords: regression
Comment 2•19 years ago
|
||
checked-in to trunk. Thanks.
Status: ASSIGNED → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
Comment 3•19 years ago
|
||
Are there any other side-effects like this?
Assignee | ||
Comment 4•19 years ago
|
||
(In reply to comment #3)
> Are there any other side-effects like this?
sizeof(RASSCONN) will be changed if WINVER >= 0x401.
Therefore nsRASAutodial::IsRASConnected may not work correctly.
However, I can't test it because I have no dialup modems.
And please file another bug about this problem.
Comment 5•19 years ago
|
||
Comment on attachment 212888 [details] [diff] [review]
trivial patch
>+#if _WIN32_WINNT >= 0x0500
>+ ofnA.lStructSize = OPENFILENAME_SIZE_VERSION_400;
>+#else
> ofnA.lStructSize = sizeof(OPENFILENAME);
>+#endif
Out of interest, how does this differ from
ofnA.lStructSize = OPENFILENAME_SIZE_VERSION_400;
without #if?
Assignee | ||
Comment 6•19 years ago
|
||
(In reply to comment #5)
> Out of interest, how does this differ from
> ofnA.lStructSize = OPENFILENAME_SIZE_VERSION_400;
> without #if?
Commdlg.h from MSVC6 or MINGW doesn't define OPENFILENAME_SIZE_VERSION_400.
So it may cause the build bustage.
Comment 7•19 years ago
|
||
According to MSDN
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winui/winui/windowsuserinterface/userinput/commondialogboxlibrary/commondialogboxreference/commondialogboxstructures/openfilename.asp
|lStructSize| should be set as follows.
Windows NT 4.0: In an application that is compiled with WINVER and
_WIN32_WINNT >= 0x0500, use
OPENFILENAME_SIZE_VERSION_400 for this member.
Windows 2000/XP: Use sizeof (OPENFILENAME) for this parameter.
Therefore, the present fix seems to be somewhat incomplete, as no test for a newer system is made (namely, OPENFILENAME_SIZE_VERSION_400 should only be used for older systems).
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Assignee | ||
Comment 8•19 years ago
|
||
OPENFILENAME_SIZE_VERSION_400 can work on Win2k/XP for compatibility. Otherwise, old apps can not open Common Dialogs on Win2k/XP.
OPENFILENAME_SIZE_VERSION_400 does simply emulate the sizeof (OPENFILENAME) with _WIN32_WINNT=0x400. Mozilla build worked perfectly before cairo enabled.
Please reopen only after you found a specific problem.
Status: REOPENED → RESOLVED
Closed: 19 years ago → 19 years ago
Resolution: --- → FIXED
Assignee | ||
Comment 9•19 years ago
|
||
Also, I already confirmed non-cairo build works on Win2k/XP.
FYI, I'm planing to use sizeof (OPENFILENAME) on cairo build (see bug 330276).
We don't have to bothered to adding runtime version check for non-cairo build because it is not supported.
You need to log in
before you can comment on or make changes to this bug.
Description
•