forked from chromium/chromium
-
Notifications
You must be signed in to change notification settings - Fork 0
/
first_run_helper_impl.h
50 lines (36 loc) · 1.34 KB
/
first_run_helper_impl.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
// Copyright 2013 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.
#ifndef ASH_FIRST_RUN_FIRST_RUN_HELPER_IMPL_H_
#define ASH_FIRST_RUN_FIRST_RUN_HELPER_IMPL_H_
#include "ash/ash_export.h"
#include "ash/public/cpp/first_run_helper.h"
#include "ash/public/cpp/session/session_observer.h"
#include "base/callback.h"
#include "base/macros.h"
namespace ash {
class DesktopCleaner;
// Interface used by first-run tutorial to manipulate and retrieve information
// about shell elements.
class ASH_EXPORT FirstRunHelperImpl : public FirstRunHelper,
public SessionObserver {
public:
explicit FirstRunHelperImpl(base::OnceClosure on_cancelled);
~FirstRunHelperImpl() override;
// FirstRunHelper:
gfx::Rect GetAppListButtonBounds() override;
gfx::Rect OpenTrayBubble() override;
void CloseTrayBubble() override;
// SessionObserver:
void OnLockStateChanged(bool locked) override;
void OnChromeTerminating() override;
void FlushForTesting();
private:
// Notifies the client to cancel the tutorial.
void Cancel();
base::OnceClosure on_cancelled_;
std::unique_ptr<DesktopCleaner> cleaner_;
DISALLOW_COPY_AND_ASSIGN(FirstRunHelperImpl);
};
} // namespace ash
#endif // ASH_FIRST_RUN_FIRST_RUN_HELPER_IMPL_H_