[prev in list] [next in list] [prev in thread] [next in thread]
List: wine-cvs
Subject: Dmitry Timoshkov : notepad:
From: Alexandre Julliard <julliard () wine ! codeweavers ! com>
Date: 2007-08-31 12:22:19
Message-ID: E1IR5Vz-0008Gc-81 () wine ! codeweavers ! com
[Download RAW message or body]
Module: wine
Branch: master
Commit: 4ea5fce0831ebbe188c88e03fbdda00e6481eecf
URL: http://source.winehq.org/git/wine.git/?a=commit;h=4ea5fce0831ebbe188c88e03fbdda00e6481eecf
Author: Dmitry Timoshkov <dmitry@codeweavers.com>
Date: Fri Aug 31 16:02:01 2007 +0900
notepad: We pass OFN_FILEMUSTEXIST | OFN_PATHMUSTEXIST to GetOpenFileName, so there \
is no point in testing file existence.
---
programs/notepad/dialog.c | 10 +++-------
1 files changed, 3 insertions(+), 7 deletions(-)
diff --git a/programs/notepad/dialog.c b/programs/notepad/dialog.c
index 0a62c5e..c21c2d7 100644
--- a/programs/notepad/dialog.c
+++ b/programs/notepad/dialog.c
@@ -217,7 +217,7 @@ void DoOpenFile(LPCWSTR szFileName)
OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, NULL);
if(hFile == INVALID_HANDLE_VALUE)
{
- ShowLastError();
+ AlertFileNotFound(szFileName);
return;
}
@@ -318,12 +318,8 @@ VOID DIALOG_FileOpen(VOID)
openfilename.lpstrDefExt = szDefaultExt;
- if (GetOpenFileName(&openfilename)) {
- if (FileExists(openfilename.lpstrFile))
- DoOpenFile(openfilename.lpstrFile);
- else
- AlertFileNotFound(openfilename.lpstrFile);
- }
+ if (GetOpenFileName(&openfilename))
+ DoOpenFile(openfilename.lpstrFile);
}
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic