diff --git a/service/key_command/include/key_command_handler.h b/service/key_command/include/key_command_handler.h index e3004e2349e39a5fb2824d15733a56cbbc42cf1c..b3154f863118d209362fa3b50e1269bb34de6c21 100755 --- a/service/key_command/include/key_command_handler.h +++ b/service/key_command/include/key_command_handler.h @@ -288,6 +288,8 @@ private: bool isDownStart_ { false }; bool isKeyCancel_ { false }; bool isHandleSequence_ { false }; + bool isParseMaxCount_ { false }; + bool isParseStatusConfig_ { false }; bool isDoubleClick_ { false }; }; } // namespace MMI diff --git a/service/key_command/src/key_command_handler.cpp b/service/key_command/src/key_command_handler.cpp index 124cb6c3be7954261245358e14a03c2aa614adc5..378d693035be4655ff2849fb80713ce27b38340f 100644 --- a/service/key_command/src/key_command_handler.cpp +++ b/service/key_command/src/key_command_handler.cpp @@ -812,6 +812,17 @@ bool KeyCommandHandler::PreHandleEvent(const std::shared_ptr key) } isParseConfig_ = true; } + if (!isParseMaxCount_) { + ParseRepeatKeyMaxCount(); + isParseMaxCount_ = true; + if (repeatKeys_.size() > 0) { + intervalTime_ = repeatKeys_[0].delay; + } + } + if (!isParseStatusConfig_) { + ParseStatusConfigObserver(); + isParseStatusConfig_ = true; + } return true; }