xbmc
xbmc
video
ContextMenus.h
1
/*
2
* Copyright (C) 2016-2018 Team Kodi
3
* This file is part of Kodi - https://kodi.tv
4
*
5
* SPDX-License-Identifier: GPL-2.0-or-later
6
* See LICENSES/README.md for more information.
7
*/
8
9
#pragma once
10
11
#include "ContextMenuItem.h"
12
#include "VideoLibraryQueue.h"
13
#include "media/MediaType.h"
14
15
#include <memory>
16
17
namespace
CONTEXTMENU
18
{
19
20
class
CVideoInfo
:
public
CStaticContextMenuAction
21
{
22
public
:
23
explicit
CVideoInfo
(MediaType mediaType);
24
bool
IsVisible(
const
CFileItem
& item)
const override
;
25
bool
Execute(
const
std::shared_ptr<CFileItem>& item)
const override
;
26
27
private
:
28
const
MediaType m_mediaType;
29
};
30
31
struct
CTVShowInfo
:
CVideoInfo
32
{
33
CTVShowInfo
() :
CVideoInfo
(MediaTypeTvShow) {}
34
};
35
36
struct
CEpisodeInfo
:
CVideoInfo
37
{
38
CEpisodeInfo
() :
CVideoInfo
(MediaTypeEpisode) {}
39
};
40
41
struct
CMusicVideoInfo
:
CVideoInfo
42
{
43
CMusicVideoInfo
() :
CVideoInfo
(MediaTypeMusicVideo) {}
44
};
45
46
struct
CMovieInfo
:
CVideoInfo
47
{
48
CMovieInfo
() :
CVideoInfo
(MediaTypeMovie) {}
49
};
50
51
struct
CVideoRemoveResumePoint
:
CStaticContextMenuAction
52
{
53
CVideoRemoveResumePoint
() :
CStaticContextMenuAction
(38209) {}
54
bool
IsVisible(
const
CFileItem
& item)
const override
;
55
bool
Execute(
const
std::shared_ptr<CFileItem>& item)
const override
;
56
};
57
58
struct
CVideoMarkWatched
:
CStaticContextMenuAction
59
{
60
CVideoMarkWatched
() :
CStaticContextMenuAction
(16103) {}
61
bool
IsVisible(
const
CFileItem
& item)
const override
;
62
bool
Execute(
const
std::shared_ptr<CFileItem>& item)
const override
;
63
};
64
65
struct
CVideoMarkUnWatched
:
CStaticContextMenuAction
66
{
67
CVideoMarkUnWatched
() :
CStaticContextMenuAction
(16104) {}
68
bool
IsVisible(
const
CFileItem
& item)
const override
;
69
bool
Execute(
const
std::shared_ptr<CFileItem>& item)
const override
;
70
};
71
72
struct
CVideoBrowse
:
CStaticContextMenuAction
73
{
74
CVideoBrowse
() :
CStaticContextMenuAction
(37015) {}
// Browse into
75
bool
IsVisible(
const
CFileItem
& item)
const override
;
76
bool
Execute(
const
std::shared_ptr<CFileItem>& item)
const override
;
77
};
78
79
struct
CVideoResume
:
IContextMenuItem
80
{
81
std::string GetLabel(
const
CFileItem
& item)
const override
;
82
bool
IsVisible(
const
CFileItem
& item)
const override
;
83
bool
Execute(
const
std::shared_ptr<CFileItem>& _item)
const override
;
84
};
85
86
struct
CVideoPlay
:
IContextMenuItem
87
{
88
std::string GetLabel(
const
CFileItem
& item)
const override
;
89
bool
IsVisible(
const
CFileItem
& item)
const override
;
90
bool
Execute(
const
std::shared_ptr<CFileItem>& _item)
const override
;
91
};
92
93
struct
CVideoQueue
:
CStaticContextMenuAction
94
{
95
CVideoQueue
() :
CStaticContextMenuAction
(13347) {}
// Queue item
96
bool
IsVisible(
const
CFileItem
& item)
const override
;
97
bool
Execute(
const
std::shared_ptr<CFileItem>& item)
const override
;
98
};
99
100
struct
CVideoPlayNext
:
CStaticContextMenuAction
101
{
102
CVideoPlayNext
() :
CStaticContextMenuAction
(10008) {}
// Play next
103
bool
IsVisible(
const
CFileItem
& item)
const override
;
104
bool
Execute(
const
std::shared_ptr<CFileItem>& item)
const override
;
105
};
106
107
struct
CVideoPlayAndQueue
:
CStaticContextMenuAction
108
{
109
CVideoPlayAndQueue
() :
CStaticContextMenuAction
(13412) {}
// Play from here
110
bool
IsVisible(
const
CFileItem
& item)
const override
;
111
bool
Execute(
const
std::shared_ptr<CFileItem>& item)
const override
;
112
};
113
114
}
CONTEXTMENU::CVideoQueue
Definition:
ContextMenus.h:93
CONTEXTMENU::CVideoInfo
Definition:
ContextMenus.h:20
CONTEXTMENU::CTVShowInfo
Definition:
ContextMenus.h:31
CONTEXTMENU::CVideoBrowse
Definition:
ContextMenus.h:72
CONTEXTMENU::CVideoPlayAndQueue
Definition:
ContextMenus.h:107
CONTEXTMENU
Definition:
ContextMenus.cpp:21
CONTEXTMENU::CVideoMarkUnWatched
Definition:
ContextMenus.h:65
CONTEXTMENU::CVideoPlayNext
Definition:
ContextMenus.h:100
CONTEXTMENU::CVideoPlay
Definition:
ContextMenus.h:86
IContextMenuItem
Definition:
ContextMenuItem.h:28
CONTEXTMENU::CMovieInfo
Definition:
ContextMenus.h:46
CONTEXTMENU::CEpisodeInfo
Definition:
ContextMenus.h:36
CONTEXTMENU::CMusicVideoInfo
Definition:
ContextMenus.h:41
CStaticContextMenuAction
Definition:
ContextMenuItem.h:39
CONTEXTMENU::CVideoMarkWatched
Definition:
ContextMenus.h:58
CONTEXTMENU::CVideoResume
Definition:
ContextMenus.h:79
CONTEXTMENU::CVideoRemoveResumePoint
Definition:
ContextMenus.h:51
CFileItem
Represents a file on a share.
Definition:
FileItem.h:102
Generated by
1.8.13