diff options
author | Jeff Brown <jeffbrown@google.com> | 2010-09-26 22:20:12 -0700 |
---|---|---|
committer | Jeff Brown <jeffbrown@google.com> | 2010-09-26 22:20:12 -0700 |
commit | d1b0a2bfe50e61241fab6a571941c207232d9212 (patch) | |
tree | 68de1f752582e7cbdc4c4b46b2e97d2abcb2d11d /include/utils | |
parent | a939afe2124b8e5be01be46f97b1bbf2fad5d65b (diff) | |
download | frameworks_native-d1b0a2bfe50e61241fab6a571941c207232d9212.zip frameworks_native-d1b0a2bfe50e61241fab6a571941c207232d9212.tar.gz frameworks_native-d1b0a2bfe50e61241fab6a571941c207232d9212.tar.bz2 |
Add suuport for splitting touch events across windows.
This feature is currently used to enable dragging the start and end
selection handles of a TextView at the same time. Could be used for
other things later.
Deleted some dead code in ArrowKeyMovementMethod and CursorControllers.
Change-Id: I930accd97ca1ca1917aab8a807db2c950fc7b409
Diffstat (limited to 'include/utils')
-rw-r--r-- | include/utils/BitSet.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/utils/BitSet.h b/include/utils/BitSet.h index 19c8bf0..f5dbcd9 100644 --- a/include/utils/BitSet.h +++ b/include/utils/BitSet.h @@ -38,6 +38,9 @@ struct BitSet32 { // Clears the bit set. inline void clear() { value = 0; } + // Returns the number of marked bits in the set. + inline uint32_t count() const { return __builtin_popcount(value); } + // Returns true if the bit set does not contain any marked bits. inline bool isEmpty() const { return ! value; } |