Switch to unified view

a/playlist/playlistohpl.h b/playlist/playlistohpl.h
...
...
22
22
23
#include "HelperStructs/MetaData.h"
23
#include "HelperStructs/MetaData.h"
24
#include "playlist.h"
24
#include "playlist.h"
25
#include "upadapt/ohpladapt.h"
25
#include "upadapt/ohpladapt.h"
26
26
27
class OHTimeQO;
28
27
class PlaylistOHPL : public Playlist {
29
class PlaylistOHPL : public Playlist {
28
    Q_OBJECT
30
    Q_OBJECT
29
31
30
public:
32
public:
31
    // We take ownership of the OHPlayer object
33
    // We take ownership of the OHPlayer object. We only borrow ohtmo.
32
    PlaylistOHPL(OHPlayer *ohpl, QObject * parent = 0);
34
    PlaylistOHPL(OHPlayer *ohpl, OHTimeQO *ohtm, QObject * parent = 0);
33
35
34
    virtual ~PlaylistOHPL() {
36
    virtual ~PlaylistOHPL() {
35
        delete m_ohplo;
37
        delete m_ohplo;
36
    }
38
    }
37
39
...
...
71
    void psl_seek(int);
73
    void psl_seek(int);
72
74
73
private:
75
private:
74
    // My link to the OpenHome Renderer
76
    // My link to the OpenHome Renderer
75
    OHPlayer *m_ohplo;
77
    OHPlayer *m_ohplo;
78
    // We use this to retrieve the duration if not set in the didl frag
79
    OHTimeQO *m_ohtmo;
76
    // Position in current song, 0 if unknown
80
    // Position in current song, 0 if unknown
77
    quint32 m_cursongsecs;
81
    quint32 m_cursongsecs;
78
    // Current song is last in playlist
82
    // Current song is last in playlist
79
    bool m_lastsong;
83
    bool m_lastsong;
80
    // Playing the last 5 S of last song
84
    // Playing the last 5 S of last song
...
...
82
    
86
    
83
    void resetPosState() {
87
    void resetPosState() {
84
        m_cursongsecs = 0;
88
        m_cursongsecs = 0;
85
        m_lastsong = m_closetoend = false;
89
        m_lastsong = m_closetoend = false;
86
    }
90
    }
91
    void maybeSetDuration(bool);
87
};
92
};
88
93
89
#endif /* PLAYLISTOHPL_H_ */
94
#endif /* PLAYLISTOHPL_H_ */