Merge "Remove length arg from transmit() in IR HAL"

This commit is contained in:
Connor O'Brien 2016-12-20 18:28:46 +00:00 committed by Gerrit Code Review
commit 9b37defc5d
3 changed files with 4 additions and 4 deletions

View file

@ -28,7 +28,7 @@ interface IConsumerIr {
*
* returns: true on success, false on error.
*/
transmit(int32_t carrierFreq, vec<int32_t> pattern, int32_t patternLen) generates (bool success);
transmit(int32_t carrierFreq, vec<int32_t> pattern) generates (bool success);
/*
* getCarrierFreqs() enumerates which frequencies the IR transmitter supports.

View file

@ -32,8 +32,8 @@ ConsumerIr::ConsumerIr(consumerir_device_t *device) {
}
// Methods from ::android::hardware::consumerir::V1_0::IConsumerIr follow.
Return<bool> ConsumerIr::transmit(int32_t carrierFreq, const hidl_vec<int32_t>& pattern, int32_t patternLen) {
return mDevice->transmit(mDevice, carrierFreq, pattern.data(), patternLen) == 0;
Return<bool> ConsumerIr::transmit(int32_t carrierFreq, const hidl_vec<int32_t>& pattern) {
return mDevice->transmit(mDevice, carrierFreq, pattern.data(), pattern.size()) == 0;
}
Return<void> ConsumerIr::getCarrierFreqs(getCarrierFreqs_cb _hidl_cb) {

View file

@ -40,7 +40,7 @@ using ::android::sp;
struct ConsumerIr : public IConsumerIr {
ConsumerIr(consumerir_device_t *device);
// Methods from ::android::hardware::ir::V1_0::IConsumerIr follow.
Return<bool> transmit(int32_t carrierFreq, const hidl_vec<int32_t>& pattern, int32_t patternLen) override;
Return<bool> transmit(int32_t carrierFreq, const hidl_vec<int32_t>& pattern) override;
Return<void> getCarrierFreqs(getCarrierFreqs_cb _hidl_cb) override;
private:
consumerir_device_t *mDevice;