chromium/chrome/browser/ui/views/media_preview/media_preview_metrics.cc

// Copyright 2024 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "chrome/browser/ui/views/media_preview/media_preview_metrics.h"

#include <string>

#include "base/check_op.h"
#include "base/metrics/histogram.h"
#include "base/metrics/histogram_functions.h"
#include "base/strings/strcat.h"

StrCat;

namespace media_preview_metrics {

namespace {

constexpr char kUiPrefix[] =;
constexpr char kDeviceSelection[] =;
constexpr char kPreview[] =;

base::HistogramBase* GetMediaPreviewDurationHistogram(const std::string& name) {}

base::HistogramBase* GetTotalVisiblePreviewDurationHistogram(
    const std::string& name) {}

base::HistogramBase* GetPreviewDelayTimeHistogram(const std::string& name) {}

const char* GetUiLocationString(UiLocation location) {}

const char* GetPreviewTypeString(const Context& context) {}

// Doesn't accept a Context with PreviewType::kCameraAndMic.
std::string GetUiLocationAndPreviewTypeString(const Context& context) {}

std::string GetUiLocationAndPreviewTypeStringAllowingBoth(
    const Context& context) {}

void UmaHistogramLinearCounts(const std::string& name,
                              int sample,
                              int minimum,
                              int maximum,
                              size_t bucket_count) {}

}  // anonymous namespace

Context::Context(UiLocation ui_location, PreviewType preview_type)
    :{}
Context::~Context() = default;

void RecordPageInfoNumInUseDevices(const Context& context, int devices) {}

void RecordMediaPreviewDuration(const Context& context,
                                const base::TimeDelta& delta) {}

void RecordDeviceSelectionTotalDevices(const Context& context, int devices) {}

void RecordDeviceSelectionAction(
    const Context& context,
    MediaPreviewDeviceSelectionUserAction user_action) {}

void RecordPreviewCameraPixelHeight(const Context& context, int pixel_height) {}

void RecordPreviewVideoExpectedFPS(const Context& context, int expected_fps) {}

void RecordPreviewVideoActualFPS(const Context& context, int actual_fps) {}

void RecordPreviewVideoFramesRenderedPercent(const Context& context,
                                             float percent) {}

void RecordTotalVisiblePreviewDuration(const Context& context,
                                       const base::TimeDelta& delta) {}

void RecordTimeToActionWithoutPreview(const Context& context,
                                      const base::TimeDelta& delta) {}

void RecordPreviewDelayTime(const Context& context,
                            const base::TimeDelta& delta) {}

void RecordOriginTrialAllowed(UiLocation location, bool allowed) {}

}  // namespace media_preview_metrics