summaryrefslogtreecommitdiff
path: root/libs/input/PropertyMap.cpp
diff options
context:
space:
mode:
author Sebastian Pickl <spickl@google.com> 2023-03-10 09:51:56 +0000
committer Sebastian Pickl <spickl@google.com> 2023-03-10 13:07:33 +0000
commita53cb97af2b4cbb247094d6be93583712dbee3c4 (patch)
tree934ddd593ba832f0f21ca3324fef4a58117af0c1 /libs/input/PropertyMap.cpp
parent3ca39d03b022d2b0ca5a35ac249de1876749d79b (diff)
Revert "Support touchpad gesture properties in IDC files"
Revert submission 21750284-touchpad-specific-tuning Reason for revert: resolves flake b/272308130 according to culprit assistant https://android-build.googleplex.com/builds/culprit-assistant/run/6257e5da-1bb0-437a-8fab-f04c27d462b3 verified by 6 runs in abtd https://android-build.googleplex.com/builds/abtd/run/L75900000959044402 Reverted changes: /q/submissionid:21750284-touchpad-specific-tuning Change-Id: I62078104a96d588bd321459e5a069dd0de5933bd
Diffstat (limited to 'libs/input/PropertyMap.cpp')
-rw-r--r--libs/input/PropertyMap.cpp29
1 files changed, 0 insertions, 29 deletions
diff --git a/libs/input/PropertyMap.cpp b/libs/input/PropertyMap.cpp
index 9a4f10b21d..ed9ac9fc72 100644
--- a/libs/input/PropertyMap.cpp
+++ b/libs/input/PropertyMap.cpp
@@ -16,8 +16,6 @@
#define LOG_TAG "PropertyMap"
-#include <cstdlib>
-
#include <input/PropertyMap.h>
#include <log/log.h>
@@ -46,16 +44,6 @@ void PropertyMap::addProperty(const std::string& key, const std::string& value)
mProperties.emplace(key, value);
}
-std::unordered_set<std::string> PropertyMap::getKeysWithPrefix(const std::string& prefix) const {
- std::unordered_set<std::string> keys;
- for (const auto& [key, _] : mProperties) {
- if (key.starts_with(prefix)) {
- keys.insert(key);
- }
- }
- return keys;
-}
-
bool PropertyMap::hasProperty(const std::string& key) const {
return mProperties.find(key) != mProperties.end();
}
@@ -114,23 +102,6 @@ bool PropertyMap::tryGetProperty(const std::string& key, float& outValue) const
return true;
}
-bool PropertyMap::tryGetProperty(const std::string& key, double& outValue) const {
- std::string stringValue;
- if (!tryGetProperty(key, stringValue) || stringValue.length() == 0) {
- return false;
- }
-
- char* end;
- double value = strtod(stringValue.c_str(), &end);
- if (*end != '\0') {
- ALOGW("Property key '%s' has invalid value '%s'. Expected a double.", key.c_str(),
- stringValue.c_str());
- return false;
- }
- outValue = value;
- return true;
-}
-
void PropertyMap::addAll(const PropertyMap* map) {
for (const auto& [key, value] : map->mProperties) {
mProperties.emplace(key, value);