blob: ba4a13b67209b792f39c7bf09ee6aeccd3cb474e [file] [log] [blame]
[email protected]2381ed22012-01-26 04:05:291// Copyright (c) 2012 The Chromium Authors. All rights reserved.
[email protected]9de26c9b2011-04-18 22:32:182// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#ifndef CHROME_BROWSER_FIRST_RUN_FIRST_RUN_DIALOG_H_
6#define CHROME_BROWSER_FIRST_RUN_FIRST_RUN_DIALOG_H_
[email protected]9de26c9b2011-04-18 22:32:187
Trent Apted4d7d11d42017-11-17 07:42:518#include "base/callback_forward.h"
9#include "build/build_config.h"
Yuta Hijikatae05049fd2020-11-27 07:50:2110#include "build/chromeos_buildflags.h"
Trent Apted4d7d11d42017-11-17 07:42:5111
12// Hide this function on platforms where the dialog does not exist.
Yuta Hijikatae05049fd2020-11-27 07:50:2113// TODO(crbug.com/1052397): Revisit the macro expression once build flag switch
14// of lacros-chrome is complete.
15#if defined(OS_MAC) || (defined(OS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS))
Trent Apted4d7d11d42017-11-17 07:42:5116
[email protected]9de26c9b2011-04-18 22:32:1817class Profile;
18
19namespace first_run {
20
Trent Apted4d7d11d42017-11-17 07:42:5121// Shows the first run dialog. Only called for organic first runs on Mac and
22// desktop Linux official builds when metrics reporting is not already enabled.
23// Invokes ChangeMetricsReportingState() if consent is given to enable crash
24// reporting, and may initiate the flow to set the default browser.
25void ShowFirstRunDialog(Profile* profile);
26
27// Returns a Closure invoked before calling ShowFirstRunDialog(). For testing.
28base::OnceClosure& GetBeforeShowFirstRunDialogHookForTesting();
[email protected]9de26c9b2011-04-18 22:32:1829
30} // namespace first_run
31
Avi Drissman97346182020-07-30 16:36:1432#endif // OS_MAC || DESKTOP_LINUX
Trent Apted4d7d11d42017-11-17 07:42:5133
[email protected]9de26c9b2011-04-18 22:32:1834#endif // CHROME_BROWSER_FIRST_RUN_FIRST_RUN_DIALOG_H_