1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // 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_
7 
8 #include "base/callback_forward.h"
9 #include "build/build_config.h"
10 
11 // Hide this function on platforms where the dialog does not exist.
12 #if defined(OS_MAC) || (defined(OS_LINUX) && !defined(OS_CHROMEOS)) || defined(OS_BSD)
13 
14 class Profile;
15 
16 namespace first_run {
17 
18 // Shows the first run dialog. Only called for organic first runs on Mac and
19 // desktop Linux official builds when metrics reporting is not already enabled.
20 // Invokes ChangeMetricsReportingState() if consent is given to enable crash
21 // reporting, and may initiate the flow to set the default browser.
22 void ShowFirstRunDialog(Profile* profile);
23 
24 // Returns a Closure invoked before calling ShowFirstRunDialog(). For testing.
25 base::OnceClosure& GetBeforeShowFirstRunDialogHookForTesting();
26 
27 }  // namespace first_run
28 
29 #endif  // OS_MAC || DESKTOP_LINUX
30 
31 #endif  // CHROME_BROWSER_FIRST_RUN_FIRST_RUN_DIALOG_H_
32