wip: setenabled crash to fix
This commit is contained in:
parent
1a4692533d
commit
f620a0575d
6 changed files with 111 additions and 17 deletions
|
|
@ -17,6 +17,16 @@ EndpointHandler::EndpointHandler(uint64_t idx) {
|
|||
}
|
||||
}
|
||||
|
||||
/* these two, currently unused. If I use them, I should feel bad.
|
||||
* Endpoint* EndpointHandler::getEndpoint() {
|
||||
* return this->ep;
|
||||
* }
|
||||
*
|
||||
* EndpointVolumeCallback* EndpointHandler::getEndpointVolumeCallback() {
|
||||
* return this->epc;
|
||||
* }
|
||||
*/
|
||||
|
||||
BackEndpointVolumeCallbackInfo* EndpointHandler::getCallbackInfo(){
|
||||
return &this->callbackInfo;
|
||||
}
|
||||
|
|
@ -50,6 +60,10 @@ std::wstring EndpointHandler::getName(){
|
|||
return ep->getName();
|
||||
}
|
||||
|
||||
std::wstring EndpointHandler::getId(){
|
||||
return ep->getId();
|
||||
}
|
||||
|
||||
float EndpointHandler::getVolume(int channel){
|
||||
return ep->getVolume(channel);
|
||||
}
|
||||
|
|
@ -74,6 +88,14 @@ void EndpointHandler::setRoles(Roles newRole){
|
|||
ep->setRoles(newRole);
|
||||
}
|
||||
|
||||
void EndpointHandler::assignRoles(Roles newRole){
|
||||
ep->assignRoles((uint8_t)newRole);
|
||||
}
|
||||
|
||||
void EndpointHandler::removeRoles(Roles newRole){
|
||||
ep->removeRoles((uint8_t)newRole);
|
||||
}
|
||||
|
||||
EndpointHandler::~EndpointHandler() {
|
||||
ep->removeVolumeCallback(epc);
|
||||
epc->Release();
|
||||
|
|
@ -122,10 +144,14 @@ NGuid OverseerHandler::getGuid() {
|
|||
return this->os->getGuid();
|
||||
}
|
||||
|
||||
void setChangeFrontDefaultsFunction(std::function<void(Roles, wchar* endpointId)> changeFrontDefaults){
|
||||
void OverseerHandler::setChangeFrontDefaultsFunction(std::function<void(Roles, std::wstring)> changeFrontDefaults){
|
||||
this->changeFrontDefaults = changeFrontDefaults;
|
||||
}
|
||||
|
||||
void OverseerHandler::changeFrontDefaultsCallback(Roles role, std::wstring endpointId) {
|
||||
this->changeFrontDefaults(role, endpointId);
|
||||
}
|
||||
|
||||
void OverseerHandler::setEndpointHandlers(std::vector<EndpointHandler*> ephs){
|
||||
this->endpointHandlers = ephs;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue