blob: 22ddfcd0e6f04c4d2af0574c35f5a0920d5d594d [file] [log] [blame]
// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include <memory>
#include "android_webview/browser/aw_field_trial_creator.h"
#include "base/compiler_specific.h"
#include "base/macros.h"
#include "content/public/browser/browser_main_parts.h"
namespace base {
class MessageLoop;
namespace android_webview {
class AwContentBrowserClient;
class AwBrowserMainParts : public content::BrowserMainParts {
explicit AwBrowserMainParts(AwContentBrowserClient* browser_client);
~AwBrowserMainParts() override;
// Overriding methods from content::BrowserMainParts.
bool ShouldContentCreateFeatureList() override;
int PreEarlyInitialization() override;
int PreCreateThreads() override;
void PreMainMessageLoopRun() override;
bool MainMessageLoopRun(int* result_code) override;
void ServiceManagerConnectionStarted(
content::ServiceManagerConnection* connection) override;
// Android specific UI MessageLoop.
std::unique_ptr<base::MessageLoop> main_message_loop_;
AwContentBrowserClient* browser_client_;
// Responsible for creating a feature list from the seed. This object must
// exist for the lifetime of the process as it contains the FieldTrialList
// that can be queried for the state of experiments.
AwFieldTrialCreator aw_field_trial_creator_;
} // namespace android_webview