Typo fix and revert formatting on untouched file

This commit is contained in:
fauxpark 2023-10-14 22:33:54 +11:00
parent 5d3f783c12
commit f3132549d8
2 changed files with 5 additions and 6 deletions

View File

@ -28,12 +28,11 @@ class KeyboardReportMatcher : public testing::MatcherInterface<report_keyboard_t
virtual bool MatchAndExplain(report_keyboard_t& report, testing::MatchResultListener* listener) const override; virtual bool MatchAndExplain(report_keyboard_t& report, testing::MatchResultListener* listener) const override;
virtual void DescribeTo(::std::ostream* os) const override; virtual void DescribeTo(::std::ostream* os) const override;
virtual void DescribeNegationTo(::std::ostream* os) const override; virtual void DescribeNegationTo(::std::ostream* os) const override;
private: private:
report_keyboard_t m_report; report_keyboard_t m_report;
}; };
template <typename... Ts> template<typename... Ts>
inline testing::Matcher<report_keyboard_t&> KeyboardReport(Ts... keys) { inline testing::Matcher<report_keyboard_t&> KeyboardReport(Ts... keys) {
return testing::MakeMatcher(new KeyboardReportMatcher(std::vector<uint8_t>({keys...}))); return testing::MakeMatcher(new KeyboardReportMatcher(std::vector<uint8_t>({keys...})));
} }

View File

@ -97,7 +97,7 @@ bool is_key_pressed(uint8_t key) {
} }
} }
#endif #endif
for (int i = 0; i < NKRO_REPORT_BITS; i++) { for (int i = 0; i < KEYBOARD_REPORT_KEYS; i++) {
if (keyboard_report->keys[i] == key) { if (keyboard_report->keys[i] == key) {
return true; return true;
} }