Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(682)

Unified Diff: chrome/browser/ui/libgtk2ui/select_file_dialog_impl_kde.cc

Issue 10829021: Use current gtk dialogs in linux_aura. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Make gtk window transient to aura window Created 8 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/libgtk2ui/select_file_dialog_impl_kde.cc
diff --git a/chrome/browser/ui/libgtk2ui/select_file_dialog_impl_kde.cc b/chrome/browser/ui/libgtk2ui/select_file_dialog_impl_kde.cc
index 594534c9372969fd2ba3bf8bc11db83dce0a8c0b..fc7f539a088f6d19cb4bcab06b843fe3cc6f6c9f 100644
--- a/chrome/browser/ui/libgtk2ui/select_file_dialog_impl_kde.cc
+++ b/chrome/browser/ui/libgtk2ui/select_file_dialog_impl_kde.cc
@@ -15,11 +15,11 @@
#include "base/string_util.h"
#include "base/threading/thread_restrictions.h"
#include "base/utf_string_conversions.h"
-//#include "chrome/browser/ui/gtk/select_file_dialog_impl.h"
+#include "chrome/browser/ui/libgtk2ui/select_file_dialog_impl.h"
-// TODO(erg): Move all of this into WorkerPool.
#include "content/public/browser/browser_thread.h"
#include "grit/generated_resources.h"
+#include "grit/ui_strings.h"
#include "ui/base/l10n/l10n_util.h"
// These conflict with base/tracked_objects.h, so need to come last.
@@ -38,6 +38,8 @@ const char kKdialogBinary[] = "kdialog";
} // namespace
+namespace libgtk2ui {
+
// Implementation of SelectFileDialog that shows a KDE common dialog for
// choosing a file or folder. This acts as a modal dialog.
class SelectFileDialogImplKDE : public SelectFileDialogImpl {
@@ -271,11 +273,14 @@ void SelectFileDialogImplKDE::CallKDialogOutput(const KDialogParams& params) {
base::GetAppOutputWithExitCode(command_line, &output, &exit_code);
if (!output.empty())
output.erase(output.size() - 1);
+
// Now the dialog is no longer showing. We can erase its parent from the
// parent set.
- std::set<GtkWindow*>::iterator iter = parents_.find(params.parent);
- if (iter != parents_.end())
- parents_.erase(iter);
+ // TODO(erg): FIX THIS.
+ // std::set<GtkWindow*>::iterator iter = parents_.find(params.parent);
+ // if (iter != parents_.end())
+ // parents_.erase(iter);
+
BrowserThread::PostTask(
BrowserThread::UI, FROM_HERE,
base::Bind(params.callback, this, output, exit_code,
@@ -465,3 +470,5 @@ void SelectFileDialogImplKDE::OnSelectMultiFileDialogResponse(
}
MultiFilesSelected(filenames_fp, params);
}
+
+} // namespace libgtk2ui

Powered by Google App Engine
This is Rietveld 408576698