Chromium Code Reviews| Index: base/win/metro.h |
| diff --git a/base/win/metro.h b/base/win/metro.h |
| index a43bbc31b23afd439526022816441ac691419ced..ea4fa2ccf3d1e98cb3c57704c4e08011c80a25ef 100644 |
| --- a/base/win/metro.h |
| +++ b/base/win/metro.h |
| @@ -9,6 +9,7 @@ |
| #include <wpcapi.h> |
| #include "base/base_export.h" |
| +#include "base/file_path.h" |
| #include "base/string16.h" |
| namespace base { |
| @@ -36,6 +37,25 @@ enum MetroPreviousExecutionState { |
| LASTEXECUTIONSTATE, |
| }; |
| +// Enum values for UMA histogram reporting of site-specific tile pinning. |
|
benwells
2012/11/27 08:56:39
Does this stuff all have to go in this file? It do
tapted
2012/11/28 00:33:43
It needs to go somewhere shared between /win8 and
benwells
2012/11/29 04:19:46
I was referring to all the secondary tile stuff yo
tapted
2012/11/29 07:19:27
** Presubmit ERRORS **
You added one or more #incl
MAD
2012/11/29 15:26:18
If these are specific to UMA I would leave them he
tapted
2012/11/30 00:30:31
Done.
|
| +enum MetroSecondaryTilePinState { |
| + METRO_PIN_STATE_NONE, |
| + METRO_PIN_INITIATED, |
| + METRO_PIN_LOGO_READY, |
| + METRO_PIN_REQUEST_SHOW_ERROR, |
| + METRO_PIN_RESULT_CANCEL, |
| + METRO_PIN_RESULT_OK, |
| + METRO_PIN_RESULT_OTHER, |
| + METRO_PIN_RESULT_ERROR, |
| + METRO_UNPIN_INITIATED, |
| + METRO_UNPIN_REQUEST_SHOW_ERROR, |
| + METRO_UNPIN_RESULT_CANCEL, |
| + METRO_UNPIN_RESULT_OK, |
| + METRO_UNPIN_RESULT_OTHER, |
| + METRO_UNPIN_RESULT_ERROR, |
| + METRO_PIN_STATE_LIMIT |
| +}; |
| + |
| // Contains information about the currently displayed tab in metro mode. |
| struct CurrentTabInfo { |
| wchar_t* title; |
| @@ -97,6 +117,23 @@ typedef void (*MetroNotification)(const char* origin_url, |
| MetroNotificationClickedHandler handler, |
| const wchar_t* handler_context); |
| +// Callback invoked by Metro Pin and UnPin functions after user gesture. |
| +typedef void (*MetroPinResultCallback)(void* callback_data, |
| + MetroSecondaryTilePinState result); |
| + |
| +// Function to pin a site-specific tile (bookmark) to the start screen. |
| +typedef void (*MetroPinToStartScreen)(const string16& tile_id, |
| + const string16& title, |
| + const string16& url, |
| + const FilePath& logo_path, |
| + MetroPinResultCallback callback, |
| + void* callback_data); |
| + |
| +// Function to un-pin a site-specific tile (bookmark) from the start screen. |
| +typedef void (*MetroUnPinFromStartScreen)(const string16& title_id, |
| + MetroPinResultCallback callback, |
| + void* callback_data); |
| + |
| } // namespace win |
| } // namespace base |