Hide wallet checkbox when there's no wallet data
[chromium-blink-merge.git] / win8 / metro_driver / settings_handler.h
blob5b234ad12e1d2a7aa08b328e81faf094f6034336
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef CHROME_BROWSER_UI_METRO_DRIVER_SETTINGS_HANDLER_H_
6 #define CHROME_BROWSER_UI_METRO_DRIVER_SETTINGS_HANDLER_H_
8 #include <windows.ui.applicationsettings.h>
9 #include <windows.ui.popups.h>
11 #include "winrt_utils.h"
13 // This class handles the settings charm.
14 class SettingsHandler {
15 public:
16 SettingsHandler();
17 ~SettingsHandler();
19 HRESULT Initialize();
21 private:
22 typedef winfoundtn::Collections::IVector<
23 winui::ApplicationSettings::SettingsCommand*> ISettingsCommandVector;
25 HRESULT OnSettingsCommandsRequested(
26 winui::ApplicationSettings::ISettingsPane* settings_pane,
27 winui::ApplicationSettings::
28 ISettingsPaneCommandsRequestedEventArgs* args);
30 HRESULT AppendNewSettingsCommand(
31 const wchar_t* id,
32 const wchar_t* name,
33 winui::ApplicationSettings::ISettingsCommandFactory*
34 settings_command_factory,
35 ISettingsCommandVector* settings_command_vector);
37 static HRESULT OnSettings(winui::Popups::IUICommand* command);
38 static HRESULT GetSettingsId(const wchar_t* value,
39 winfoundtn::IPropertyValue** settings_id);
41 EventRegistrationToken settings_token_;
44 #endif // CHROME_BROWSER_UI_METRO_DRIVER_SETTINGS_HANDLER_H_