OLD | NEW |
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CHROME_BROWSER_VIEWS_IMPORTING_PROGRESS_VIEW_H_ | 5 #ifndef CHROME_BROWSER_VIEWS_IMPORTING_PROGRESS_VIEW_H_ |
6 #define CHROME_BROWSER_VIEWS_IMPORTING_PROGRESS_VIEW_H_ | 6 #define CHROME_BROWSER_VIEWS_IMPORTING_PROGRESS_VIEW_H_ |
7 | 7 |
8 #include "chrome/browser/importer/importer.h" | 8 #include "chrome/browser/importer/importer.h" |
9 #include "chrome/views/dialog_delegate.h" | 9 #include "chrome/views/dialog_delegate.h" |
10 #include "chrome/views/view.h" | 10 #include "chrome/views/view.h" |
11 #include "chrome/views/window.h" | 11 #include "chrome/views/window.h" |
12 | 12 |
13 namespace views { | 13 namespace views { |
14 class CheckmarkThrobber; | 14 class CheckmarkThrobber; |
15 class Label; | 15 class Label; |
16 } | 16 } |
17 | 17 |
18 class ImportingProgressView : public views::View, | 18 class ImportingProgressView : public views::View, |
19 public views::DialogDelegate, | 19 public views::DialogDelegate, |
20 public ImporterHost::Observer { | 20 public ImporterHost::Observer { |
21 public: | 21 public: |
| 22 // |items| is a bitmask of ImportItems being imported. |
| 23 // |bookmark_import| is true if we're importing bookmarks from a |
| 24 // bookmarks.html file. |
22 ImportingProgressView(const std::wstring& source_name, | 25 ImportingProgressView(const std::wstring& source_name, |
23 int16 items, | 26 int16 items, |
24 ImporterHost* coordinator, | 27 ImporterHost* coordinator, |
25 ImportObserver* observer, | 28 ImportObserver* observer, |
26 HWND parent_window); | 29 HWND parent_window, |
| 30 bool bookmarks_import); |
27 virtual ~ImportingProgressView(); | 31 virtual ~ImportingProgressView(); |
28 | 32 |
29 protected: | 33 protected: |
30 // Overridden from ImporterHost::Observer: | 34 // Overridden from ImporterHost::Observer: |
31 virtual void ImportItemStarted(ImportItem item); | 35 virtual void ImportItemStarted(ImportItem item); |
32 virtual void ImportItemEnded(ImportItem item); | 36 virtual void ImportItemEnded(ImportItem item); |
33 virtual void ImportStarted(); | 37 virtual void ImportStarted(); |
34 virtual void ImportEnded(); | 38 virtual void ImportEnded(); |
35 | 39 |
36 // Overridden from views::DialogDelegate: | 40 // Overridden from views::DialogDelegate: |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
72 | 76 |
73 // An object that wants to be notified when the import is complete. | 77 // An object that wants to be notified when the import is complete. |
74 ImportObserver* import_observer_; | 78 ImportObserver* import_observer_; |
75 | 79 |
76 // The ImportItems we are importing. | 80 // The ImportItems we are importing. |
77 int16 items_; | 81 int16 items_; |
78 | 82 |
79 // True if the import operation is in progress. | 83 // True if the import operation is in progress. |
80 bool importing_; | 84 bool importing_; |
81 | 85 |
| 86 // Are we importing a bookmarks.html file? |
| 87 bool bookmarks_import_; |
| 88 |
82 DISALLOW_EVIL_CONSTRUCTORS(ImportingProgressView); | 89 DISALLOW_EVIL_CONSTRUCTORS(ImportingProgressView); |
83 }; | 90 }; |
84 | 91 |
85 #endif // CHROME_BROWSER_VIEWS_IMPORTING_PROGRESS_VIEW_H_ | 92 #endif // CHROME_BROWSER_VIEWS_IMPORTING_PROGRESS_VIEW_H_ |
86 | 93 |
OLD | NEW |