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

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

Merge "Mark some functions in InputReader code as const" into main

parents 406adf01 c19c66ab
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1085,7 +1085,7 @@ EventHubInterface* InputReader::ContextImpl::getEventHub() {
    return mReader->mEventHub.get();
}

int32_t InputReader::ContextImpl::getNextId() {
int32_t InputReader::ContextImpl::getNextId() const {
    return mIdGenerator.nextId();
}

+1 −1
Original line number Diff line number Diff line
@@ -154,7 +154,7 @@ protected:
                REQUIRES(mReader->mLock) override;
        InputReaderPolicyInterface* getPolicy() REQUIRES(mReader->mLock) override;
        EventHubInterface* getEventHub() REQUIRES(mReader->mLock) override;
        int32_t getNextId() NO_THREAD_SAFETY_ANALYSIS override;
        int32_t getNextId() const NO_THREAD_SAFETY_ANALYSIS override;
        void updateLedMetaState(int32_t metaState) REQUIRES(mReader->mLock) override;
        int32_t getLedMetaState() REQUIRES(mReader->mLock) REQUIRES(mLock) override;
        void setPreventingTouchpadTaps(bool prevent) REQUIRES(mReader->mLock)
+1 −1
Original line number Diff line number Diff line
@@ -55,7 +55,7 @@ public:
    virtual InputReaderPolicyInterface* getPolicy() = 0;
    virtual EventHubInterface* getEventHub() = 0;

    virtual int32_t getNextId() = 0;
    virtual int32_t getNextId() const = 0;

    virtual void updateLedMetaState(int32_t metaState) = 0;
    virtual int32_t getLedMetaState() = 0;
+1 −1
Original line number Diff line number Diff line
@@ -419,7 +419,7 @@ int32_t CursorInputMapper::getScanCodeState(uint32_t sourceMask, int32_t scanCod
    }
}

std::optional<ui::LogicalDisplayId> CursorInputMapper::getAssociatedDisplayId() {
std::optional<ui::LogicalDisplayId> CursorInputMapper::getAssociatedDisplayId() const {
    return mDisplayId;
}

+1 −1
Original line number Diff line number Diff line
@@ -63,7 +63,7 @@ public:

    virtual int32_t getScanCodeState(uint32_t sourceMask, int32_t scanCode) override;

    virtual std::optional<ui::LogicalDisplayId> getAssociatedDisplayId() override;
    virtual std::optional<ui::LogicalDisplayId> getAssociatedDisplayId() const override;

private:
    // Amount that trackball needs to move in order to generate a key event.
Loading