summaryrefslogtreecommitdiffstats
path: root/chrome
diff options
context:
space:
mode:
authorfinnur@google.com <finnur@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-09-22 22:12:28 +0000
committerfinnur@google.com <finnur@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-09-22 22:12:28 +0000
commit393c02e5a411707d7a5e15432ce7328386292f5a (patch)
tree1d6d80546eb75eef6ab79a97997849614dda3e62 /chrome
parent7ef840ffc387eb1c1f3e3fd8a41840caf51d3628 (diff)
downloadchromium_src-393c02e5a411707d7a5e15432ce7328386292f5a.zip
chromium_src-393c02e5a411707d7a5e15432ce7328386292f5a.tar.gz
chromium_src-393c02e5a411707d7a5e15432ce7328386292f5a.tar.bz2
Fix for issue 2617: After using Ctrl+O to open a local file the directory is locked.
Review URL: http://codereview.chromium.org/3194 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2457 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
-rw-r--r--chrome/browser/views/shell_dialogs.cc12
1 files changed, 7 insertions, 5 deletions
diff --git a/chrome/browser/views/shell_dialogs.cc b/chrome/browser/views/shell_dialogs.cc
index 7e41937..b2dbf1c 100644
--- a/chrome/browser/views/shell_dialogs.cc
+++ b/chrome/browser/views/shell_dialogs.cc
@@ -38,7 +38,7 @@ class ShellDialogThread : public base::Thread {
}
private:
- DISALLOW_EVIL_CONSTRUCTORS(ShellDialogThread);
+ DISALLOW_COPY_AND_ASSIGN(ShellDialogThread);
};
///////////////////////////////////////////////////////////////////////////////
@@ -115,7 +115,7 @@ class BaseShellDialogImpl {
static Owners owners_;
static int instance_count_;
- DISALLOW_EVIL_CONSTRUCTORS(BaseShellDialogImpl);
+ DISALLOW_COPY_AND_ASSIGN(BaseShellDialogImpl);
};
// static
@@ -231,7 +231,7 @@ class SelectFileDialogImpl : public SelectFileDialog,
// The listener to be notified of selection completion.
Listener* listener_;
- DISALLOW_EVIL_CONSTRUCTORS(SelectFileDialogImpl);
+ DISALLOW_COPY_AND_ASSIGN(SelectFileDialogImpl);
};
SelectFileDialogImpl::SelectFileDialogImpl(Listener* listener)
@@ -346,7 +346,9 @@ bool SelectFileDialogImpl::RunOpenFileDialog(const std::wstring& title,
ofn.lpstrFile = filename;
ofn.nMaxFile = MAX_PATH;
- ofn.Flags = OFN_FILEMUSTEXIST;
+ // We use OFN_NOCHANGEDIR so that the user can rename or delete the directory
+ // without having to close Chrome first.
+ ofn.Flags = OFN_FILEMUSTEXIST | OFN_NOCHANGEDIR;
// TODO(beng): (http://b/issue?id=1126563) edit the filter options in the
// dropdown list.
@@ -403,7 +405,7 @@ class SelectFontDialogImpl : public SelectFontDialog,
// The listener to be notified of selection completion.
Listener* listener_;
- DISALLOW_EVIL_CONSTRUCTORS(SelectFontDialogImpl);
+ DISALLOW_COPY_AND_ASSIGN(SelectFontDialogImpl);
};
SelectFontDialogImpl::SelectFontDialogImpl(Listener* listener)