diff options
author | hclam@chromium.org <hclam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-04-15 20:43:44 +0000 |
---|---|---|
committer | hclam@chromium.org <hclam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-04-15 20:43:44 +0000 |
commit | 3ee88ee11b8fd2092ca1287e7c48f9f6c4ed886e (patch) | |
tree | 951a04950724ccc925f45e5a9d264b7ee49d09b3 /chrome/browser/views/password_manager_exceptions_view.h | |
parent | 7f858d1032720f471991db19c383e1af19c24088 (diff) | |
download | chromium_src-3ee88ee11b8fd2092ca1287e7c48f9f6c4ed886e.zip chromium_src-3ee88ee11b8fd2092ca1287e7c48f9f6c4ed886e.tar.gz chromium_src-3ee88ee11b8fd2092ca1287e7c48f9f6c4ed886e.tar.bz2 |
Use tab to group "Show saved passwords" and "Exceptions"
BUG=9026
"Show saved passwords" and "Exceptions" were splited into
2 dialogs, group together in one single dialog with
different pages by tabbing.
Review URL: http://codereview.chromium.org/67055
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@13786 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/views/password_manager_exceptions_view.h')
-rw-r--r-- | chrome/browser/views/password_manager_exceptions_view.h | 96 |
1 files changed, 0 insertions, 96 deletions
diff --git a/chrome/browser/views/password_manager_exceptions_view.h b/chrome/browser/views/password_manager_exceptions_view.h deleted file mode 100644 index 5dacbb6..0000000 --- a/chrome/browser/views/password_manager_exceptions_view.h +++ /dev/null @@ -1,96 +0,0 @@ -// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#ifndef CHROME_BROWSER_PASSWORD_MANAGER_EXCEPTIONS_VIEW_H__ -#define CHROME_BROWSER_PASSWORD_MANAGER_EXCEPTIONS_VIEW_H__ - -#include <vector> - -#include "chrome/browser/views/password_manager_view.h" -#include "chrome/browser/webdata/web_data_service.h" -#include "chrome/common/stl_util-inl.h" -#include "chrome/common/gfx/text_elider.h" -#include "chrome/views/controls/label.h" -#include "chrome/views/controls/table/table_view.h" -#include "chrome/views/window/dialog_delegate.h" -#include "chrome/views/window/window.h" -#include "webkit/glue/password_form.h" - -class PasswordManagerExceptionsTableModel : public PasswordManagerTableModel { - public: - explicit PasswordManagerExceptionsTableModel(Profile* profile); - virtual ~PasswordManagerExceptionsTableModel(); - - // TableModel methods. - virtual std::wstring GetText(int row, int column); - virtual int CompareValues(int row1, int row2, int col_id); - - // WebDataServiceConsumer implementation. - virtual void OnWebDataServiceRequestDone(WebDataService::Handle h, - const WDTypedResult* result); - // Request all logins data. - void GetAllExceptionsForProfile(); -}; - -class PasswordManagerExceptionsView : public views::View, - public views::DialogDelegate, - public views::TableViewObserver, - public views::ButtonListener, - public PasswordManagerTableModelObserver { - public: - explicit PasswordManagerExceptionsView(Profile* profile); - virtual ~PasswordManagerExceptionsView(); - - // Show the PasswordManagerExceptionsView for the given profile. - static void Show(Profile* profile); - - // View methods. - virtual void Layout(); - virtual gfx::Size GetPreferredSize(); - virtual void ViewHierarchyChanged(bool is_add, views::View* parent, - views::View* child); - - // views::TableViewObserver implementation. - virtual void OnSelectionChanged(); - - // ButtonListener implementation. - virtual void ButtonPressed(views::Button* sender); - - // views::DialogDelegate methods: - virtual int GetDialogButtons() const; - virtual bool CanResize() const { return true; } - virtual bool CanMaximize() const { return false; } - virtual bool IsAlwaysOnTop() const { return false; } - virtual bool HasAlwaysOnTopMenu() const { return false; } - virtual std::wstring GetWindowTitle() const; - virtual void WindowClosing(); - virtual views::View* GetContentsView(); - - // PasswordManagerTableModelObserver implementation. - virtual void OnRowCountChanged(size_t rows); - - private: - // Wire up buttons, the model, and the table view, and query the DB for - // exception data tied to the given profile. - void Init(); - - // Helper to configure our buttons and labels. - void SetupButtons(); - - // Helper to configure our table view. - void SetupTable(); - - // Components in this view. - PasswordManagerExceptionsTableModel table_model_; - views::TableView* table_view_; - - // The buttons and labels. - views::NativeButton remove_button_; - views::NativeButton remove_all_button_; - - static PasswordManagerExceptionsView* instance_; - - DISALLOW_EVIL_CONSTRUCTORS(PasswordManagerExceptionsView); -}; -#endif // CHROME_BROWSER_PASSWORD_MANAGER_EXCEPTIONS_VIEW_H__ |