Switch to unified view

a/upmpd/renderctl.hxx b/upmpd/renderctl.hxx
...
...
15
 *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
15
 *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
16
 */
16
 */
17
#ifndef _RENDERING_H_X_INCLUDED_
17
#ifndef _RENDERING_H_X_INCLUDED_
18
#define _RENDERING_H_X_INCLUDED_
18
#define _RENDERING_H_X_INCLUDED_
19
19
20
#include <string>
20
#include <string>                       // for string
21
#include <vector>                       // for vector
22
#include <unordered_map>                // for unordered_map
21
23
22
#include "libupnpp/device/device.hxx"
24
#include "libupnpp/device/device.hxx"   // for UpnpService
25
#include "libupnpp/soaphelp.hxx"        // for SoapArgs, SoapData
23
26
24
class UpMpd;
27
class UpMpd;
25
28
26
using namespace UPnPP;
29
using namespace UPnPP;
27
30
28
class UpMpdRenderCtl : public UpnpService {
31
class UpMpdRenderCtl : public UPnPProvider::UpnpService {
29
public:
32
public:
30
    UpMpdRenderCtl(UpMpd *dev);
33
    UpMpdRenderCtl(UpMpd *dev);
31
34
32
    virtual bool getEventData(bool all, std::vector<std::string>& names, 
35
    virtual bool getEventData(bool all, std::vector<std::string>& names, 
33
                              std::vector<std::string>& values);
36
                              std::vector<std::string>& values);
34
    int getvolume_i();
37
    int getvolume_i();
35
    void setvolume_i(int volume);
38
    void setvolume_i(int volume);
36
    void setmute_i(bool onoff);
39
    void setmute_i(bool onoff);
37
private:
40
private:
38
    bool rdstateMToU(unordered_map<string, string>& status);
41
    bool rdstateMToU(std::unordered_map<std::string, std::string>& status);
39
    int setMute(const SoapArgs& sc, SoapData& data);
42
    int setMute(const SoapArgs& sc, SoapData& data);
40
    int getMute(const SoapArgs& sc, SoapData& data);
43
    int getMute(const SoapArgs& sc, SoapData& data);
41
    int setVolume(const SoapArgs& sc, SoapData& data, bool isDb);
44
    int setVolume(const SoapArgs& sc, SoapData& data, bool isDb);
42
    int getVolume(const SoapArgs& sc, SoapData& data, bool isDb);
45
    int getVolume(const SoapArgs& sc, SoapData& data, bool isDb);
43
    int listPresets(const SoapArgs& sc, SoapData& data);
46
    int listPresets(const SoapArgs& sc, SoapData& data);
...
...
46
    UpMpd *m_dev;
49
    UpMpd *m_dev;
47
    // Desired volume target. We may delay executing small volume
50
    // Desired volume target. We may delay executing small volume
48
    // changes to avoid saturating with small requests.
51
    // changes to avoid saturating with small requests.
49
    int m_desiredvolume;
52
    int m_desiredvolume;
50
    // State variable storage
53
    // State variable storage
51
    unordered_map<string, string> m_rdstate;
54
    std::unordered_map<std::string, std::string> m_rdstate;
52
};
55
};
53
56
54
#endif /* _RENDERING_H_X_INCLUDED_ */
57
#endif /* _RENDERING_H_X_INCLUDED_ */