summaryrefslogtreecommitdiffstats
path: root/media/mtp/MtpProperty.h
diff options
context:
space:
mode:
authorMike Lockwood <lockwood@android.com>2010-09-25 21:21:05 -0400
committerMike Lockwood <lockwood@android.com>2010-09-25 21:21:05 -0400
commitdde372033b4da75ebde7ea2afdec1c1b86ab5a42 (patch)
tree8ad7554185784f354f000d662ef993ba704420bc /media/mtp/MtpProperty.h
parent7cee5d3c3673d9a325d8096eea0ba48258fc656c (diff)
downloadframeworks_av-dde372033b4da75ebde7ea2afdec1c1b86ab5a42.zip
frameworks_av-dde372033b4da75ebde7ea2afdec1c1b86ab5a42.tar.gz
frameworks_av-dde372033b4da75ebde7ea2afdec1c1b86ab5a42.tar.bz2
MTP: Include current property value in GetDevicePropDesc
Change-Id: I05125c79ad58b6f75734fcedcc8af9b689fa9ff3 Signed-off-by: Mike Lockwood <lockwood@android.com>
Diffstat (limited to 'media/mtp/MtpProperty.h')
-rw-r--r--media/mtp/MtpProperty.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/media/mtp/MtpProperty.h b/media/mtp/MtpProperty.h
index 64cfb93..98b465a 100644
--- a/media/mtp/MtpProperty.h
+++ b/media/mtp/MtpProperty.h
@@ -23,6 +23,23 @@ namespace android {
class MtpDataPacket;
+struct MtpPropertyValue {
+ union {
+ int8_t i8;
+ uint8_t u8;
+ int16_t i16;
+ uint16_t u16;
+ int32_t i32;
+ uint32_t u32;
+ int64_t i64;
+ uint64_t u64;
+ int128_t i128;
+ uint128_t u128;
+ } u;
+ // string in UTF8 format
+ char* str;
+};
+
class MtpProperty {
public:
MtpPropertyCode mCode;
@@ -68,6 +85,9 @@ public:
void read(MtpDataPacket& packet);
void write(MtpDataPacket& packet);
+ void setDefaultValue(const uint16_t* string);
+ void setCurrentValue(const uint16_t* string);
+
void print();
inline bool isDeviceProperty() const {