diff options
author | 2019-07-23 18:12:31 +0000 | |
---|---|---|
committer | 2019-07-23 18:12:31 +0000 | |
commit | c6f61190e7bb4579047f70f3c66282457c1e68d7 (patch) | |
tree | 4b91e4dd1d1fdeb4a6a735e054bc2a3f09173b55 /services/inputflinger/InputReader.cpp | |
parent | 2d8cc8945eb1c1be5ce6a262613a5aae6e257d06 (diff) |
Revert "Revert "Use std::set instead of SortedVector""
This reverts commit 2d8cc8945eb1c1be5ce6a262613a5aae6e257d06.
Reason for revert: Likely build was having issues, and the original CLs were fine. From looking into the issues more closely, it appears that the topic was not merged atomically.
Change-Id: I42393e615066b4cf10aa953757a3f43be5676a2f
Diffstat (limited to 'services/inputflinger/InputReader.cpp')
-rw-r--r-- | services/inputflinger/InputReader.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/services/inputflinger/InputReader.cpp b/services/inputflinger/InputReader.cpp index eee49d5e2a..2de5ffa0eb 100644 --- a/services/inputflinger/InputReader.cpp +++ b/services/inputflinger/InputReader.cpp @@ -1094,8 +1094,8 @@ void InputDevice::configure(nsecs_t when, const InputReaderConfiguration* config } if (!changes || (changes & InputReaderConfiguration::CHANGE_ENABLED_STATE)) { - ssize_t index = config->disabledDevices.indexOf(mId); - bool enabled = index < 0; + auto it = config->disabledDevices.find(mId); + bool enabled = it == config->disabledDevices.end(); setEnabled(enabled, when); } |