#include "third_party/blink/renderer/core/css/remote_font_face_source.h"
#include "base/metrics/histogram_functions.h"
#include "base/task/single_thread_task_runner.h"
#include "third_party/blink/public/common/features.h"
#include "third_party/blink/public/platform/task_type.h"
#include "third_party/blink/public/platform/web_effective_connection_type.h"
#include "third_party/blink/renderer/core/css/css_custom_font_data.h"
#include "third_party/blink/renderer/core/css/css_font_face.h"
#include "third_party/blink/renderer/core/css/font_face_set_document.h"
#include "third_party/blink/renderer/core/dom/document.h"
#include "third_party/blink/renderer/core/frame/local_dom_window.h"
#include "third_party/blink/renderer/core/frame/local_frame.h"
#include "third_party/blink/renderer/core/frame/local_frame_client.h"
#include "third_party/blink/renderer/core/inspector/console_message.h"
#include "third_party/blink/renderer/core/lcp_critical_path_predictor/lcp_critical_path_predictor.h"
#include "third_party/blink/renderer/core/loader/subresource_integrity_helper.h"
#include "third_party/blink/renderer/core/probe/core_probes.h"
#include "third_party/blink/renderer/core/workers/worker_global_scope.h"
#include "third_party/blink/renderer/platform/fonts/font_cache.h"
#include "third_party/blink/renderer/platform/fonts/font_custom_platform_data.h"
#include "third_party/blink/renderer/platform/fonts/font_description.h"
#include "third_party/blink/renderer/platform/fonts/font_selector.h"
#include "third_party/blink/renderer/platform/fonts/simple_font_data.h"
#include "third_party/blink/renderer/platform/heap/garbage_collected.h"
#include "third_party/blink/renderer/platform/loader/fetch/resource_fetcher.h"
#include "third_party/blink/renderer/platform/loader/fetch/resource_load_priority.h"
#include "third_party/blink/renderer/platform/network/network_state_notifier.h"
#include "third_party/blink/renderer/platform/scheduler/public/post_cross_thread_task.h"
#include "third_party/blink/renderer/platform/scheduler/public/thread.h"
#include "third_party/blink/renderer/platform/wtf/cross_thread_copier.h"
#include "third_party/blink/renderer/platform/wtf/cross_thread_functional.h"
namespace blink {
bool RemoteFontFaceSource::NeedsInterventionToAlignWithLCPGoal() const { … }
RemoteFontFaceSource::DisplayPeriod
RemoteFontFaceSource::ComputeFontDisplayAutoPeriod() const { … }
RemoteFontFaceSource::DisplayPeriod RemoteFontFaceSource::ComputePeriod()
const { … }
RemoteFontFaceSource::RemoteFontFaceSource(
CSSFontFace* css_font_face,
FontSelector* font_selector,
FontDisplay display,
scoped_refptr<base::SingleThreadTaskRunner> task_runner)
: … { … }
RemoteFontFaceSource::~RemoteFontFaceSource() = default;
Document* RemoteFontFaceSource::GetDocument() const { … }
bool RemoteFontFaceSource::IsLoading() const { … }
bool RemoteFontFaceSource::IsLoaded() const { … }
bool RemoteFontFaceSource::IsValid() const { … }
void RemoteFontFaceSource::NotifyFinished(Resource* resource) { … }
void RemoteFontFaceSource::FontLoadShortLimitExceeded(FontResource*) { … }
void RemoteFontFaceSource::FontLoadLongLimitExceeded(FontResource*) { … }
void RemoteFontFaceSource::SetDisplay(FontDisplay display) { … }
bool RemoteFontFaceSource::UpdatePeriod() { … }
bool RemoteFontFaceSource::ShouldTriggerWebFontsIntervention() { … }
bool RemoteFontFaceSource::IsLowPriorityLoadingAllowedForRemoteFont() const { … }
const SimpleFontData* RemoteFontFaceSource::CreateFontData(
const FontDescription& font_description,
const FontSelectionCapabilities& font_selection_capabilities) { … }
const SimpleFontData* RemoteFontFaceSource::CreateLoadingFallbackFontData(
const FontDescription& font_description) { … }
void RemoteFontFaceSource::BeginLoadIfNeeded() { … }
void RemoteFontFaceSource::Trace(Visitor* visitor) const { … }
void RemoteFontFaceSource::FontLoadHistograms::LoadStarted() { … }
void RemoteFontFaceSource::FontLoadHistograms::FallbackFontPainted(
DisplayPeriod period) { … }
void RemoteFontFaceSource::FontLoadHistograms::LongLimitExceeded() { … }
bool RemoteFontFaceSource::IsPendingDataUrl() const { … }
void RemoteFontFaceSource::PaintRequested() { … }
void RemoteFontFaceSource::FontLoadHistograms::RecordFallbackTime() { … }
void RemoteFontFaceSource::FontLoadHistograms::RecordRemoteFont(
const FontResource* font) { … }
void RemoteFontFaceSource::FontLoadHistograms::MaySetDataSource(
DataSource data_source) { … }
void RemoteFontFaceSource::FontLoadHistograms::RecordLoadTimeHistogram(
const FontResource* font,
base::TimeDelta delta) { … }
RemoteFontFaceSource::FontLoadHistograms::CacheHitMetrics
RemoteFontFaceSource::FontLoadHistograms::DataSourceMetricsValue() { … }
}