예제 #1
0
/**
 *  Report success for frames that report cancel operations
 *  @param  name            Consumer tag that is cancelled
 *  @return Deferred
 */
const std::shared_ptr<Deferred> &DeferredCancel::reportSuccess(const std::string &name) const
{
    // in the channel, we should uninstall the consumer
    _channel->uninstall(name);
    
    // skip if no special callback was installed
    if (!_cancelCallback) return Deferred::reportSuccess();
    
    // call the callback
    _cancelCallback(name);
    
    // return next object
    return _next;
}
예제 #2
0
파일: menu.cpp 프로젝트: DrWindu/lof3
void Menu::cancel() {
	if(_cancelCallback) {
		_cancelCallback();
	}
}