chromium/device/bluetooth/floss/floss_features.cc

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

#include "device/bluetooth/floss/floss_features.h"

#include "base/system/sys_info.h"

#if BUILDFLAG(IS_CHROMEOS_LACROS)
#include "chromeos/startup/browser_params_proxy.h"
#endif

namespace floss {
namespace features {

#if BUILDFLAG(IS_CHROMEOS_ASH)
// Enables Floss client if supported by platform
BASE_FEATURE(kFlossEnabled, "Floss", base::FEATURE_DISABLED_BY_DEFAULT);
BASE_FEATURE(kFlossIsAvailable,
             "FlossIsAvailable",
             base::FEATURE_ENABLED_BY_DEFAULT);
BASE_FEATURE(kFlossIsAvailabilityCheckNeeded,
             "FlossIsAvailabilityCheckNeeded",
             base::FEATURE_ENABLED_BY_DEFAULT);
BASE_FEATURE(kLLPrivacyIsAvailable,
             "LLPrivacyIsAvailable",
             base::FEATURE_ENABLED_BY_DEFAULT);
#endif

#if BUILDFLAG(IS_CHROMEOS_ASH)
namespace {
const char* kLaunchedBoards[] = {
    "BRYA",     "ATLAS",  "BROX",   "CHERRY", "CORSOLA", "DEDEDE",
    "DRALLION", "GERALT", "HATCH",  "NISSA",  "OCTOPUS", "RAURU",
    "REX",      "SARIEN", "SKYRIM", "STARYU", "VOLTEER"};
}  // namespace

static bool IsDeviceLaunchedFloss() {
  std::string board = base::SysInfo::HardwareModelName();
  for (auto* b : kLaunchedBoards) {
    if (board.compare(b) == 0) {
      return true;
    }
  }

  return false;
}
#endif

bool IsFlossEnabled() {}

bool IsFlossAvailable() {}

bool IsFlossAvailabilityCheckNeeded() {}

bool IsLLPrivacyAvailable() {}
}  // namespace features
}  // namespace floss