|
1 /* |
|
2 * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: Music Player engine stub for mpplaybackview. |
|
15 * |
|
16 */ |
|
17 |
|
18 #ifndef MPENGINE_H |
|
19 #define MPENGINE_H |
|
20 |
|
21 #include <QObject> |
|
22 #include <QStringList> |
|
23 |
|
24 |
|
25 class MpPlaybackData; |
|
26 |
|
27 class MpEngine : public QObject |
|
28 { |
|
29 Q_OBJECT |
|
30 |
|
31 friend class MpEngineFactory; |
|
32 |
|
33 public: |
|
34 enum EngineMode{ |
|
35 StandAlone, |
|
36 Fetch, |
|
37 Embedded, |
|
38 MediaBrowsing |
|
39 }; |
|
40 |
|
41 private: |
|
42 explicit MpEngine(); |
|
43 |
|
44 public: |
|
45 |
|
46 virtual ~MpEngine(); |
|
47 |
|
48 MpPlaybackData *playbackData(); |
|
49 void retrieveSongDetails(); |
|
50 |
|
51 // Equalizer related |
|
52 void applyPreset( int preset ); |
|
53 void disableEqualizer(); |
|
54 int activePreset(); |
|
55 QStringList presetNames(); |
|
56 |
|
57 public slots: |
|
58 // Playback related |
|
59 void stop(); |
|
60 void setShuffle(bool mode); |
|
61 void setRepeat( bool mode); |
|
62 void startSeekBackward(); |
|
63 void startSeekForward(); |
|
64 void stopSeeking(); |
|
65 void skipBackward(); |
|
66 void skipForward(); |
|
67 void playPause(); |
|
68 void setPosition( int position ); |
|
69 |
|
70 signals: |
|
71 |
|
72 // Equalizer related |
|
73 void libraryUpdated(); |
|
74 void corruptedStop(); |
|
75 |
|
76 private: |
|
77 Q_DISABLE_COPY( MpEngine ) |
|
78 |
|
79 public: |
|
80 int mActivePreset; |
|
81 int mApplyPresetCount; |
|
82 int mDisableEquqlizerCount; |
|
83 int retrieveSongDetailsCount; |
|
84 int stopCount; |
|
85 int startSeekBackwardCount; |
|
86 int startSeekForwardCount; |
|
87 int stopSeekingCount; |
|
88 int skipBackwardCount; |
|
89 int skipForwardCount; |
|
90 |
|
91 }; |
|
92 |
|
93 #endif // MPENGINE_H |