Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit de08328a authored by Treehugger Robot's avatar Treehugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Copy KeyCharacterMap object when we fill InputDeviceInfo(2/n)" into main

parents 8a526b4a 7d508bb2
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -60,7 +60,7 @@ jobject android_view_InputDevice_create(JNIEnv* env, const InputDeviceInfo& devi
                                                                  ? layoutInfo->layoutType.c_str()
                                                                  : NULL));

    std::shared_ptr<KeyCharacterMap> map = deviceInfo.getKeyCharacterMap();
    const KeyCharacterMap* map = deviceInfo.getKeyCharacterMap();
    std::unique_ptr<KeyCharacterMap> mapCopy;
    if (map != nullptr) {
        mapCopy = std::make_unique<KeyCharacterMap>(*map);