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

Side by Side Diff: chrome/browser/ui/webui/options/chromeos/storage_manager_handler.h

Issue 2041343002: Storage manager: Show overall size information and size of Downloads. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 6 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 unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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_UI_WEBUI_OPTIONS_CHROMEOS_STORAGE_MANAGER_HANDLER_H_ 5 #ifndef CHROME_BROWSER_UI_WEBUI_OPTIONS_CHROMEOS_STORAGE_MANAGER_HANDLER_H_
6 #define CHROME_BROWSER_UI_WEBUI_OPTIONS_CHROMEOS_STORAGE_MANAGER_HANDLER_H_ 6 #define CHROME_BROWSER_UI_WEBUI_OPTIONS_CHROMEOS_STORAGE_MANAGER_HANDLER_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "chrome/browser/ui/webui/options/options_ui.h" 9 #include "chrome/browser/ui/webui/options/options_ui.h"
10 10
11 namespace chromeos { 11 namespace chromeos {
12 namespace options { 12 namespace options {
13 13
14 // Storage manager overlay page UI handler. 14 // Storage manager overlay page UI handler.
15 class StorageManagerHandler : public ::options::OptionsPageUIHandler { 15 class StorageManagerHandler : public ::options::OptionsPageUIHandler {
16 public: 16 public:
17 StorageManagerHandler(); 17 StorageManagerHandler();
18 ~StorageManagerHandler() override; 18 ~StorageManagerHandler() override;
19 19
20 // OptionsPageUIHandler implementation. 20 // OptionsPageUIHandler implementation.
21 void GetLocalizedValues(base::DictionaryValue* localized_strings) override; 21 void GetLocalizedValues(base::DictionaryValue* localized_strings) override;
22 void InitializePage() override; 22 void InitializePage() override;
23 23
24 // WebUIMessageHandler implementation. 24 // WebUIMessageHandler implementation.
25 void RegisterMessages() override; 25 void RegisterMessages() override;
26 26
27 private: 27 private:
28 // Handlers of JS messages.
29 void HandleUpdateStorageInfo(const base::ListValue* unused_args);
30 void HandleOpenDownloads(const base::ListValue* unused_args);
31
32 void UpdateSizeStat();
33 void OnGetSizeStat(int64_t* total_size, int64_t* available_size);
34 void UpdateDownloadsSize();
35 void OnGetDownloadsSize(int64_t size);
Dan Beam 2016/06/09 04:49:40 can you document these?
fukino 2016/06/09 15:39:38 Done.
36
37 base::WeakPtrFactory<StorageManagerHandler> weak_ptr_factory_;
Dan Beam 2016/06/09 04:49:40 IWYU: #include "base/memory/weak_ptr.h"
fukino 2016/06/09 15:39:38 Done.
38
28 DISALLOW_COPY_AND_ASSIGN(StorageManagerHandler); 39 DISALLOW_COPY_AND_ASSIGN(StorageManagerHandler);
29 }; 40 };
30 41
31 } // namespace options 42 } // namespace options
32 } // namespace chromeos 43 } // namespace chromeos
33 44
34 #endif // CHROME_BROWSER_UI_WEBUI_OPTIONS_CHROMEOS_STORAGE_MANAGER_HANDLER_H_ 45 #endif // CHROME_BROWSER_UI_WEBUI_OPTIONS_CHROMEOS_STORAGE_MANAGER_HANDLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698