|
a/upmpd/ohvolume.cxx |
|
b/upmpd/ohvolume.cxx |
|
... |
|
... |
74 |
st["VolumeUnity"] = "100";
|
74 |
st["VolumeUnity"] = "100";
|
75 |
st["VolumeSteps"] = "100";
|
75 |
st["VolumeSteps"] = "100";
|
76 |
st["VolumeMilliDbPerSteps"] = "500";
|
76 |
st["VolumeMilliDbPerSteps"] = "500";
|
77 |
st["BalanceMax"] = "0";
|
77 |
st["BalanceMax"] = "0";
|
78 |
st["FadeMax"] = "0";
|
78 |
st["FadeMax"] = "0";
|
79 |
char cbuf[30];
|
|
|
80 |
int volume = m_ctl->getvolume_i();
|
79 |
int volume = m_ctl->getvolume_i();
|
81 |
sprintf(cbuf, "%d", volume);
|
80 |
st["Volume"] = SoapArgs::i2s(volume);
|
82 |
st["Volume"] = cbuf;
|
|
|
83 |
st["Mute"] = volume == 0 ? "1" : "0";
|
81 |
st["Mute"] = volume == 0 ? "1" : "0";
|
84 |
return true;
|
82 |
return true;
|
85 |
}
|
83 |
}
|
86 |
|
84 |
|
87 |
bool OHVolume::getEventData(bool all, std::vector<std::string>& names,
|
85 |
bool OHVolume::getEventData(bool all, std::vector<std::string>& names,
|
|
... |
|
... |
164 |
}
|
162 |
}
|
165 |
|
163 |
|
166 |
int OHVolume::volume(const SoapArgs& sc, SoapData& data)
|
164 |
int OHVolume::volume(const SoapArgs& sc, SoapData& data)
|
167 |
{
|
165 |
{
|
168 |
LOGDEB("OHVolume::volume" << endl);
|
166 |
LOGDEB("OHVolume::volume" << endl);
|
169 |
char cbuf[30];
|
167 |
data.addarg("Value", SoapArgs::i2s(m_ctl->getvolume_i()));
|
170 |
int volume = m_ctl->getvolume_i();
|
|
|
171 |
sprintf(cbuf, "%d", volume);
|
|
|
172 |
data.addarg("Value", cbuf);
|
|
|
173 |
return UPNP_E_SUCCESS;
|
168 |
return UPNP_E_SUCCESS;
|
174 |
}
|
169 |
}
|
175 |
|
170 |
|
176 |
int OHVolume::mute(const SoapArgs& sc, SoapData& data)
|
171 |
int OHVolume::mute(const SoapArgs& sc, SoapData& data)
|
177 |
{
|
172 |
{
|