summaryrefslogtreecommitdiffstats
path: root/xbmc/video/ContextMenus.h
diff options
context:
space:
mode:
Diffstat (limited to 'xbmc/video/ContextMenus.h')
-rw-r--r--xbmc/video/ContextMenus.h114
1 files changed, 114 insertions, 0 deletions
diff --git a/xbmc/video/ContextMenus.h b/xbmc/video/ContextMenus.h
new file mode 100644
index 0000000..1cbffe4
--- /dev/null
+++ b/xbmc/video/ContextMenus.h
@@ -0,0 +1,114 @@
+/*
+ * Copyright (C) 2016-2018 Team Kodi
+ * This file is part of Kodi - https://kodi.tv
+ *
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ * See LICENSES/README.md for more information.
+ */
+
+#pragma once
+
+#include "ContextMenuItem.h"
+#include "VideoLibraryQueue.h"
+#include "media/MediaType.h"
+
+#include <memory>
+
+namespace CONTEXTMENU
+{
+
+class CVideoInfo : public CStaticContextMenuAction
+{
+public:
+ explicit CVideoInfo(MediaType mediaType);
+ bool IsVisible(const CFileItem& item) const override;
+ bool Execute(const std::shared_ptr<CFileItem>& item) const override;
+
+private:
+ const MediaType m_mediaType;
+};
+
+struct CTVShowInfo : CVideoInfo
+{
+ CTVShowInfo() : CVideoInfo(MediaTypeTvShow) {}
+};
+
+struct CEpisodeInfo : CVideoInfo
+{
+ CEpisodeInfo() : CVideoInfo(MediaTypeEpisode) {}
+};
+
+struct CMusicVideoInfo : CVideoInfo
+{
+ CMusicVideoInfo() : CVideoInfo(MediaTypeMusicVideo) {}
+};
+
+struct CMovieInfo : CVideoInfo
+{
+ CMovieInfo() : CVideoInfo(MediaTypeMovie) {}
+};
+
+struct CVideoRemoveResumePoint : CStaticContextMenuAction
+{
+ CVideoRemoveResumePoint() : CStaticContextMenuAction(38209) {}
+ bool IsVisible(const CFileItem& item) const override;
+ bool Execute(const std::shared_ptr<CFileItem>& item) const override;
+};
+
+struct CVideoMarkWatched : CStaticContextMenuAction
+{
+ CVideoMarkWatched() : CStaticContextMenuAction(16103) {}
+ bool IsVisible(const CFileItem& item) const override;
+ bool Execute(const std::shared_ptr<CFileItem>& item) const override;
+};
+
+struct CVideoMarkUnWatched : CStaticContextMenuAction
+{
+ CVideoMarkUnWatched() : CStaticContextMenuAction(16104) {}
+ bool IsVisible(const CFileItem& item) const override;
+ bool Execute(const std::shared_ptr<CFileItem>& item) const override;
+};
+
+struct CVideoBrowse : CStaticContextMenuAction
+{
+ CVideoBrowse() : CStaticContextMenuAction(37015) {} // Browse into
+ bool IsVisible(const CFileItem& item) const override;
+ bool Execute(const std::shared_ptr<CFileItem>& item) const override;
+};
+
+struct CVideoResume : IContextMenuItem
+{
+ std::string GetLabel(const CFileItem& item) const override;
+ bool IsVisible(const CFileItem& item) const override;
+ bool Execute(const std::shared_ptr<CFileItem>& _item) const override;
+};
+
+struct CVideoPlay : IContextMenuItem
+{
+ std::string GetLabel(const CFileItem& item) const override;
+ bool IsVisible(const CFileItem& item) const override;
+ bool Execute(const std::shared_ptr<CFileItem>& _item) const override;
+};
+
+struct CVideoQueue : CStaticContextMenuAction
+{
+ CVideoQueue() : CStaticContextMenuAction(13347) {} // Queue item
+ bool IsVisible(const CFileItem& item) const override;
+ bool Execute(const std::shared_ptr<CFileItem>& item) const override;
+};
+
+struct CVideoPlayNext : CStaticContextMenuAction
+{
+ CVideoPlayNext() : CStaticContextMenuAction(10008) {} // Play next
+ bool IsVisible(const CFileItem& item) const override;
+ bool Execute(const std::shared_ptr<CFileItem>& item) const override;
+};
+
+struct CVideoPlayAndQueue : CStaticContextMenuAction
+{
+ CVideoPlayAndQueue() : CStaticContextMenuAction(13412) {} // Play from here
+ bool IsVisible(const CFileItem& item) const override;
+ bool Execute(const std::shared_ptr<CFileItem>& item) const override;
+};
+
+}