TTKMusicPlayer  4.3.0.0
TTKMusicPlayer imitates Kugou UI, the music player uses of qmmp core library based on Qt for windows and linux
musicttkfmradioplaywidget.h
Go to the documentation of this file.
1 #ifndef MUSICTTKFMRADIOPLAYWIDGET_H
2 #define MUSICTTKFMRADIOPLAYWIDGET_H
3 
4 /***************************************************************************
5  * This file is part of the TTK Music Player project
6  * Copyright (C) 2015 - 2026 Greedysky Studio
7 
8  * This program is free software; you can redistribute it and/or modify
9  * it under the terms of the GNU General Public License as published by
10  * the Free Software Foundation; either version 3 of the License, or
11  * (at your option) any later version.
12 
13  * This program is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16  * GNU General Public License for more details.
17 
18  * You should have received a copy of the GNU General Public License along
19  * with this program; If not, see <http://www.gnu.org/licenses/>.
20  ***************************************************************************/
21 
22 #include "musicfmconfigmanager.h"
25 
26 class QTreeWidgetItem;
27 class MusicCoreMPlayer;
28 
29 namespace Ui {
32 }
33 
34 
39 {
40  Q_OBJECT
41 public:
45  explicit MusicTTKFMRadioInformationWidget(QWidget *parent = nullptr);
50 
54  void setReadOnly(bool mode);
58  void setChannelInformation(const MusicFMChannel &channel);
62  MusicFMChannel channelInformation() const;
63 
64 private:
65  Ui::MusicTTKFMRadioInformationWidget *m_ui;
66  bool m_readOnly;
67 
68 };
69 
70 
75 {
76  Q_OBJECT
77 public:
81  explicit MusicTTKFMRadioPlayWidget(QWidget *parent = nullptr);
86 
87 public Q_SLOTS:
91  void radioItemChanged(QTreeWidgetItem *item, int column);
95  void mediaPlayFinished(int code);
99  void radioPlay();
103  void radioPrevious();
107  void radioNext();
111  void radioVolume(int num);
115  void positionChanged(qint64 position);
119  void addButtonClicked();
123  void deleteButtonClicked();
127  void infoButtonClicked();
128 
129 private:
133  virtual void closeEvent(QCloseEvent *event) override final;
134 
138  void initialize();
142  void createCoreModule();
146  void startCoreModule();
150  int indexValid(QTreeWidgetItem *item) const;
151 
152  Ui::MusicTTKFMRadioPlayWidget *m_ui;
157  MusicFMChannelList m_items;
158  MusicFMChannelList m_favItems;
159 
160 };
161 
162 #endif // MUSICTTKFMRADIOPLAYWIDGET_H
#define TTK_MODULE_EXPORT
Ui::MusicTTKFMRadioInformationWidget * m_ui
The class of the web music radio information widget.
The class of the fm channel item.
Ui::MusicTTKFMRadioPlayWidget * m_ui
TTK_MODULE_EXPORT void initialize(TTK::Attribute attr)
The class of the moving dialog base.
The class of the mplayer core.
Definition: inftrees.h:24
The class of the web music radio widget.
const char int mode
Definition: ioapi.h:135
The class of the moving widget base.