From 0fa848d780cf990a2860637f40432d28594c85a3 Mon Sep 17 00:00:00 2001 From: Mike Lockwood Date: Fri, 7 Mar 2014 13:29:59 -0800 Subject: MTP: Add support for device property changed events Also fixed bug in MtpProperty::write() for device properties Bug: 7342482 Change-Id: If0099095d101409d131564e55b1939895c69c202 --- media/mtp/MtpProperty.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'media/mtp/MtpProperty.cpp') diff --git a/media/mtp/MtpProperty.cpp b/media/mtp/MtpProperty.cpp index 375ed9a..3838ce8 100644 --- a/media/mtp/MtpProperty.cpp +++ b/media/mtp/MtpProperty.cpp @@ -190,9 +190,9 @@ void MtpProperty::write(MtpDataPacket& packet) { if (deviceProp) writeValue(packet, mCurrentValue); } - packet.putUInt32(mGroupCode); if (!deviceProp) - packet.putUInt8(mFormFlag); + packet.putUInt32(mGroupCode); + packet.putUInt8(mFormFlag); if (mFormFlag == kFormRange) { writeValue(packet, mMinimumValue); writeValue(packet, mMaximumValue); -- cgit v1.1