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
51
ash / public / cpp / media_client.h [blame]
// Copyright 2019 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef ASH_PUBLIC_CPP_MEDIA_CLIENT_H_
#define ASH_PUBLIC_CPP_MEDIA_CLIENT_H_
#include "ash/public/cpp/ash_public_export.h"
namespace ash {
// This delegate allows the UI code in ash to forward UI commands.
class ASH_PUBLIC_EXPORT MediaClient {
public:
// Handles the Next Track Media shortcut key.
virtual void HandleMediaNextTrack() = 0;
// Handles the Play/Pause Toggle Media shortcut key.
virtual void HandleMediaPlayPause() = 0;
// Handles the Play Media shortcut key.
virtual void HandleMediaPlay() = 0;
// Handles the Pause Media shortcut key.
virtual void HandleMediaPause() = 0;
// Handles the Stop Media shortcut key.
virtual void HandleMediaStop() = 0;
// Handles the Previous Track Media shortcut key.
virtual void HandleMediaPrevTrack() = 0;
// Handles the Seek Backward Media shortcut key.
virtual void HandleMediaSeekBackward() = 0;
// Handles the Seek Forward Media shortcut key.
virtual void HandleMediaSeekForward() = 0;
// Requests that the client resends the NotifyMediaCaptureChanged() message.
virtual void RequestCaptureState() = 0;
// Suspends all WebContents-associated media sessions to stop managed players.
virtual void SuspendMediaSessions() = 0;
protected:
virtual ~MediaClient() = default;
};
} // namespace ash
#endif // ASH_PUBLIC_CPP_MEDIA_CLIENT_H_