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
{
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(
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_