#include "chrome/browser/ui/webui/browser_command/browser_command_handler.h"
#include "base/metrics/histogram_functions.h"
#include "base/metrics/user_metrics.h"
#include "chrome/browser/command_updater_impl.h"
#include "chrome/browser/enterprise/util/managed_browser_utils.h"
#include "chrome/browser/feedback/show_feedback_page.h"
#include "chrome/browser/new_tab_page/promos/promo_service.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/search/search.h"
#include "chrome/browser/ui/browser.h"
#include "chrome/browser/ui/browser_finder.h"
#include "chrome/browser/ui/browser_navigator.h"
#include "chrome/browser/ui/browser_window.h"
#include "chrome/browser/ui/chrome_pages.h"
#include "chrome/browser/ui/tabs/tab_group_model.h"
#include "chrome/browser/ui/ui_features.h"
#include "chrome/browser/user_education/tutorial_identifiers.h"
#include "chrome/browser/user_education/user_education_service.h"
#include "chrome/browser/user_education/user_education_service_factory.h"
#include "chrome/common/chrome_features.h"
#include "chrome/common/webui_url_constants.h"
#include "components/password_manager/core/common/password_manager_features.h"
#include "components/performance_manager/public/features.h"
#include "components/safe_browsing/content/browser/web_ui/safe_browsing_ui.h"
#include "components/safe_browsing/core/common/safe_browsing_policy_handler.h"
#include "components/safe_browsing/core/common/safe_browsing_prefs.h"
#include "components/safe_browsing/core/common/safebrowsing_referral_methods.h"
#include "components/saved_tab_groups/features.h"
#include "components/user_education/common/tutorial_identifier.h"
#include "components/user_education/common/tutorial_service.h"
#include "ui/base/interaction/element_identifier.h"
#include "ui/base/page_transition_types.h"
#include "ui/base/ui_base_features.h"
#include "ui/base/window_open_disposition.h"
#include "ui/base/window_open_disposition_utils.h"
ClickInfoPtr;
Command;
CommandHandler;
const char BrowserCommandHandler::kPromoBrowserCommandHistogramName[] = …;
BrowserCommandHandler::BrowserCommandHandler(
mojo::PendingReceiver<CommandHandler> pending_page_handler,
Profile* profile,
std::vector<browser_command::mojom::Command> supported_commands)
: … { … }
BrowserCommandHandler::~BrowserCommandHandler() = default;
void BrowserCommandHandler::CanExecuteCommand(
browser_command::mojom::Command command_id,
CanExecuteCommandCallback callback) { … }
void BrowserCommandHandler::ExecuteCommand(Command command_id,
ClickInfoPtr click_info,
ExecuteCommandCallback callback) { … }
void BrowserCommandHandler::ExecuteCommandWithDisposition(
int id,
WindowOpenDisposition disposition) { … }
void BrowserCommandHandler::OnTutorialStarted(
user_education::TutorialIdentifier tutorial_id,
user_education::TutorialService* tutorial_service) { … }
void BrowserCommandHandler::StartTutorial(StartTutorialInPage::Params params) { … }
bool BrowserCommandHandler::TutorialServiceExists() { … }
bool BrowserCommandHandler::BrowserSupportsTabGroups() { … }
void BrowserCommandHandler::StartTabGroupTutorial() { … }
void BrowserCommandHandler::NavigateToEnhancedProtectionSetting() { … }
void BrowserCommandHandler::OpenPasswordManager() { … }
void BrowserCommandHandler::OpenAISettings() { … }
bool BrowserCommandHandler::DefaultSearchProviderIsGoogle() { … }
bool BrowserCommandHandler::BrowserSupportsSavedTabGroups() { … }
void BrowserCommandHandler::OpenNTPAndStartCustomizeChromeTutorial() { … }
void BrowserCommandHandler::StartPasswordManagerTutorial() { … }
void BrowserCommandHandler::StartSavedTabGroupTutorial() { … }
void BrowserCommandHandler::OpenFeedbackForm() { … }
void BrowserCommandHandler::ConfigureFeedbackCommand(
FeedbackCommandSettings settings) { … }
void BrowserCommandHandler::EnableSupportedCommands() { … }
CommandUpdater* BrowserCommandHandler::GetCommandUpdater() { … }
void BrowserCommandHandler::NavigateToURL(const GURL& url,
WindowOpenDisposition disposition) { … }