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

Side by Side Diff: public/platform/Platform.h

Issue 1017433002: Add RAPPOR metric recording for Device{Orientation,Motion} in blink. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: merge comments in Platform.h Created 5 years, 8 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 unified diff | Download patch
« no previous file with comments | « Source/modules/device_orientation/DeviceOrientationController.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2012 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 552 matching lines...) Expand 10 before | Expand all | Expand 10 after
563 // Set the duration field of a COMPLETE trace event. 563 // Set the duration field of a COMPLETE trace event.
564 virtual void updateTraceEventDuration(const unsigned char* categoryEnabledFl ag, const char* name, TraceEventHandle) { } 564 virtual void updateTraceEventDuration(const unsigned char* categoryEnabledFl ag, const char* name, TraceEventHandle) { }
565 565
566 // Callbacks for reporting histogram data. 566 // Callbacks for reporting histogram data.
567 // CustomCounts histogram has exponential bucket sizes, so that min=1, max=1 000000, bucketCount=50 would do. 567 // CustomCounts histogram has exponential bucket sizes, so that min=1, max=1 000000, bucketCount=50 would do.
568 virtual void histogramCustomCounts(const char* name, int sample, int min, in t max, int bucketCount) { } 568 virtual void histogramCustomCounts(const char* name, int sample, int min, in t max, int bucketCount) { }
569 // Enumeration histogram buckets are linear, boundaryValue should be larger than any possible sample value. 569 // Enumeration histogram buckets are linear, boundaryValue should be larger than any possible sample value.
570 virtual void histogramEnumeration(const char* name, int sample, int boundary Value) { } 570 virtual void histogramEnumeration(const char* name, int sample, int boundary Value) { }
571 // Unlike enumeration histograms, sparse histograms only allocate memory for non-empty buckets. 571 // Unlike enumeration histograms, sparse histograms only allocate memory for non-empty buckets.
572 virtual void histogramSparse(const char* name, int sample) { } 572 virtual void histogramSparse(const char* name, int sample) { }
573 // Record to RAPPOR. 573
574 // Record to a RAPPOR privacy-preserving metric, see: https://www.chromium.o rg/developers/design-documents/rappor.
575 // recordRappor records a sample string, while recordRapporURL records the d omain and registry of a url.
574 virtual void recordRappor(const char* metric, const WebString& sample) { } 576 virtual void recordRappor(const char* metric, const WebString& sample) { }
577 virtual void recordRapporURL(const char* metric, const blink::WebURL& url) { }
575 578
576 // GPU ---------------------------------------------------------------- 579 // GPU ----------------------------------------------------------------
577 // 580 //
578 // May return null if GPU is not supported. 581 // May return null if GPU is not supported.
579 // Returns newly allocated and initialized offscreen WebGraphicsContext3D in stance. 582 // Returns newly allocated and initialized offscreen WebGraphicsContext3D in stance.
580 // Passing an existing context to shareContext will create the new context i n the same share group as the passed context. 583 // Passing an existing context to shareContext will create the new context i n the same share group as the passed context.
581 virtual WebGraphicsContext3D* createOffscreenGraphicsContext3D(const WebGrap hicsContext3D::Attributes&, WebGraphicsContext3D* shareContext) { return 0; } 584 virtual WebGraphicsContext3D* createOffscreenGraphicsContext3D(const WebGrap hicsContext3D::Attributes&, WebGraphicsContext3D* shareContext) { return 0; }
582 virtual WebGraphicsContext3D* createOffscreenGraphicsContext3D(const WebGrap hicsContext3D::Attributes&, WebGraphicsContext3D* shareContext, WebGLInfo* glInf o) { return 0; } 585 virtual WebGraphicsContext3D* createOffscreenGraphicsContext3D(const WebGrap hicsContext3D::Attributes&, WebGraphicsContext3D* shareContext, WebGLInfo* glInf o) { return 0; }
583 virtual WebGraphicsContext3D* createOffscreenGraphicsContext3D(const WebGrap hicsContext3D::Attributes&) { return 0; } 586 virtual WebGraphicsContext3D* createOffscreenGraphicsContext3D(const WebGrap hicsContext3D::Attributes&) { return 0; }
584 587
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after
701 protected: 704 protected:
702 BLINK_PLATFORM_EXPORT Platform(); 705 BLINK_PLATFORM_EXPORT Platform();
703 virtual ~Platform() { } 706 virtual ~Platform() { }
704 707
705 WebThread* m_mainThread; 708 WebThread* m_mainThread;
706 }; 709 };
707 710
708 } // namespace blink 711 } // namespace blink
709 712
710 #endif 713 #endif
OLDNEW
« no previous file with comments | « Source/modules/device_orientation/DeviceOrientationController.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698