Sayonara Player
Loading...
Searching...
No Matches
LibraryContainer.h
1/* LibraryContainer.h
2 *
3 * Copyright (C) 2011-2024 Michael Lugmair
4 *
5 * This file is part of sayonara player
6 *
7 * This program is free software: you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation, either version 3 of the License, or
10 * (at your option) any later version.
11
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
16
17 * You should have received a copy of the GNU General Public License
18 * along with this program. If not, see <http://www.gnu.org/licenses/>.
19 */
20
21#ifndef SAYONARA_PLAYER_COMPONENTS_LIBRARY_CONTAINER_H
22#define SAYONARA_PLAYER_COMPONENTS_LIBRARY_CONTAINER_H
23
24class QWidget;
25class QFrame;
26class QIcon;
27class QMenu;
28class QAction;
29
30#include <QObject>
31
32namespace Library
33{
35 {
36 public:
37 virtual ~LibraryContainer() = default;
38
39 [[nodiscard]] virtual QFrame* header() const = 0;
40 [[nodiscard]] virtual QIcon icon() const = 0;
41 [[nodiscard]] virtual QMenu* menu() = 0;
42 [[nodiscard]] virtual QString displayName() const = 0;
43 [[nodiscard]] virtual QString name() const = 0;
44 [[nodiscard]] virtual QWidget* widget() const = 0;
45 [[nodiscard]] virtual bool isLocal() const = 0;
46 virtual void init() = 0;
47 virtual void rename(const QString& newName) = 0;
48 };
49}
50
51using LibraryContainerInterface = Library::LibraryContainer;
52
53Q_DECLARE_INTERFACE(LibraryContainerInterface, "com.sayonara-player.library")
54
55#endif // SAYONARA_PLAYER_COMPONENTS_LIBRARY_CONTAINER_H
Definition LibraryContainer.h:35