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

Unified Diff: chrome/browser/ui/webui/task_manager/task_manager_dialog.cc

Issue 9749003: Revert 127660 - WebUI TaskManager: Add method to set minimum window size on HTMLDialog. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 9 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
« no previous file with comments | « chrome/browser/ui/webui/html_dialog_ui.cc ('k') | ui/views/widget/widget.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/webui/task_manager/task_manager_dialog.cc
===================================================================
--- chrome/browser/ui/webui/task_manager/task_manager_dialog.cc (revision 127670)
+++ chrome/browser/ui/webui/task_manager/task_manager_dialog.cc (working copy)
@@ -29,14 +29,6 @@
#include "ui/views/widget/widget.h"
#endif
-namespace {
-
-// The minimum size of task manager window in px.
-const int kMinimumTaskManagerWidth = 640;
-const int kMinimumTaskManagerHeight = 480;
-
-} // namespace
-
using content::BrowserThread;
using content::WebContents;
using content::WebUIMessageHandler;
@@ -61,9 +53,6 @@
virtual string16 GetDialogTitle() const OVERRIDE {
return l10n_util::GetStringUTF16(IDS_TASK_MANAGER_TITLE);
}
- virtual std::string GetDialogName() const OVERRIDE {
- return prefs::kTaskManagerWindowPlacement;
- }
virtual GURL GetDialogContentURL() const OVERRIDE {
std::string url_string(chrome::kChromeUITaskManagerURL);
url_string += "?";
@@ -79,7 +68,6 @@
std::vector<WebUIMessageHandler*>* handlers) const OVERRIDE {
}
virtual void GetDialogSize(gfx::Size* size) const OVERRIDE {
-#if !defined(TOOLKIT_VIEWS)
// If dialog's bounds are previously saved, use them.
if (g_browser_process->local_state()) {
const DictionaryValue* placement_pref =
@@ -95,12 +83,8 @@
}
// Otherwise set default size.
- size->SetSize(kMinimumTaskManagerWidth, kMinimumTaskManagerHeight);
-#endif
+ size->SetSize(640, 480);
}
- virtual void GetMinimumDialogSize(gfx::Size* size) const OVERRIDE {
- size->SetSize(kMinimumTaskManagerWidth, kMinimumTaskManagerHeight);
- }
virtual std::string GetDialogArgs() const OVERRIDE {
return std::string();
}
@@ -118,7 +102,6 @@
const content::ContextMenuParams& params) OVERRIDE {
return true;
}
-#if !defined(TOOLKIT_VIEWS)
virtual void StoreDialogSize(const gfx::Size& dialog_size) OVERRIDE {
// Store the dialog's bounds so that it can be restored with the same bounds
// the next time it's opened.
@@ -130,7 +113,6 @@
placement_pref->SetInteger("height", dialog_size.height());
}
}
-#endif
private:
void ShowDialog(bool is_background_page_mode);
« no previous file with comments | « chrome/browser/ui/webui/html_dialog_ui.cc ('k') | ui/views/widget/widget.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698