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

Unified Diff: chrome/browser/download/download_util.h

Issue 7664019: Move download UMA functions to their own file in content. Also fire the chrome-only notification ... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 4 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/download/download_util.h
===================================================================
--- chrome/browser/download/download_util.h (revision 96993)
+++ chrome/browser/download/download_util.h (working copy)
@@ -112,60 +112,6 @@
BIG
};
-// We keep a count of how often various events occur in the
-// histogram "Download.Counts".
-enum DownloadCountTypes {
- // The download was initiated by navigating to a URL (e.g. by user
- // click).
- INITIATED_BY_NAVIGATION_COUNT = 0,
-
- // The download was initiated by invoking a context menu within a page.
- INITIATED_BY_CONTEXT_MENU_COUNT,
-
- // The download was initiated when the SavePackage system rejected
- // a Save Page As ... by returning false from
- // SavePackage::IsSaveableContents().
- INITIATED_BY_SAVE_PACKAGE_FAILURE_COUNT,
-
- // The download was initiated by a drag and drop from a drag-and-drop
- // enabled web application.
- INITIATED_BY_DRAG_N_DROP_COUNT,
-
- // The download was initiated by explicit RPC from the renderer process
- // (e.g. by Alt-click).
- INITIATED_BY_RENDERER_COUNT,
-
- // Downloads that made it to DownloadResourceHandler -- all of the
- // above minus those blocked by DownloadThrottlingResourceHandler.
- UNTHROTTLED_COUNT,
-
- // Downloads that actually complete.
- COMPLETED_COUNT,
-
- // Downloads that are cancelled before completion (user action or error).
- CANCELLED_COUNT,
-
- // Downloads that are started. Should be equal to UNTHROTTLED_COUNT.
- START_COUNT,
-
- // Downloads that were interrupted by the OS.
- INTERRUPTED_COUNT,
-
- DOWNLOAD_COUNT_TYPES_LAST_ENTRY
-};
-
-// Increment one of the above counts.
-void RecordDownloadCount(DownloadCountTypes type);
-
-// Record COMPLETED_COUNT and how long the download took.
-void RecordDownloadCompleted(const base::TimeTicks& start);
-
-// Record INTERRUPTED_COUNT, |error|, |received| and |total| bytes.
-void RecordDownloadInterrupted(int error, int64 received, int64 total);
-
-// Records the mime type of the download.
-void RecordDownloadMimeType(const std::string& mime_type);
-
// Paint the common download animation progress foreground and background,
// clipping the foreground to 'percent' full. If percent is -1, then we don't
// know the total size, so we just draw a rotating segment until we're done.
@@ -249,10 +195,6 @@
int render_view_id,
const content::ResourceContext* context);
-// Sends a notification on downloads being initiated
-// Must be called on the UI thread.
-void NotifyDownloadInitiated(int render_process_id, int render_view_id);
-
// Same as GetUniquePathNumber, except that it also checks the existence
// of its .crdownload intermediate path.
// If |path| does not exist, 0 is returned. If it fails to find such

Powered by Google App Engine
This is Rietveld 408576698