bookmark_stats.h revision 68043e1e95eeb07d5cae7aca370b26518b0867d6
1// Copyright 2013 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. 4 5#ifndef CHROME_BROWSER_BOOKMARKS_BOOKMARK_STATS_H_ 6#define CHROME_BROWSER_BOOKMARKS_BOOKMARK_STATS_H_ 7 8// This enum is used for the Bookmarks.EntryPoint histogram. 9enum BookmarkEntryPoint { 10 BOOKMARK_ENTRY_POINT_ACCELERATOR, 11 BOOKMARK_ENTRY_POINT_STAR_GESTURE, 12 BOOKMARK_ENTRY_POINT_STAR_KEY, 13 BOOKMARK_ENTRY_POINT_STAR_MOUSE, 14 15 BOOKMARK_ENTRY_POINT_LIMIT // Keep this last. 16}; 17 18// This enum is used for the Bookmarks.LaunchLocation histogram. 19enum BookmarkLaunchLocation { 20 BOOKMARK_LAUNCH_LOCATION_NONE, 21 BOOKMARK_LAUNCH_LOCATION_ATTACHED_BAR = 0, 22 BOOKMARK_LAUNCH_LOCATION_DETACHED_BAR, 23 // These two are kind of sub-categories of the bookmark bar. Generally 24 // a launch from a context menu or subfolder could be classified in one of 25 // the other two bar buckets, but doing so is difficult because the menus 26 // don't know of their greater place in Chrome. 27 BOOKMARK_LAUNCH_LOCATION_BAR_SUBFOLDER, 28 BOOKMARK_LAUNCH_LOCATION_CONTEXT_MENU, 29 30 // Bookmarks menu within wrench menu. 31 BOOKMARK_LAUNCH_LOCATION_WRENCH_MENU, 32 // Bookmark manager. 33 BOOKMARK_LAUNCH_LOCATION_MANAGER, 34 // Autocomplete suggestion. 35 BOOKMARK_LAUNCH_LOCATION_OMNIBOX, 36 37 BOOKMARK_LAUNCH_LOCATION_LIMIT // Keep this last. 38}; 39 40// Records the launch of a bookmark for UMA purposes. 41void RecordBookmarkLaunch(BookmarkLaunchLocation location); 42 43// Records the user opening a folder of bookmarks for UMA purposes. 44void RecordBookmarkFolderOpen(BookmarkLaunchLocation location); 45 46// Records the user opening the apps page for UMA purposes. 47void RecordBookmarkAppsPageOpen(BookmarkLaunchLocation location); 48 49#endif // CHROME_BROWSER_BOOKMARKS_BOOKMARK_STATS_H_ 50