|
@@ -602,7 +602,7 @@ class CCommDevFSM : public FSMImpl<TFSM>
|
|
|
{
|
|
|
|
|
|
public:
|
|
|
- CCommDevFSM() : m_iInWhatPage(PageType_Init),m_bOpened(false), m_bOpening(true), m_eDevState(DEVICE_STATUS_NOT_READY),m_contiErrTimes(0)
|
|
|
+ CCommDevFSM() : m_iInWhatPage(PageType_Init),m_bOpened(false), m_bOpening(true), m_eDevState(DEVICE_STATUS_NOT_READY),m_contiErrTimes(0), m_preUIState('X')
|
|
|
{
|
|
|
|
|
|
}
|
|
@@ -849,6 +849,7 @@ public:
|
|
|
|
|
|
void OnUIState4SetWhatPage(const char* pcszValue) {
|
|
|
if (pcszValue != NULL && strlen(pcszValue) > 0) {
|
|
|
+ bool trigger(false);
|
|
|
//增加页面位置判断
|
|
|
if (_strnicmp(pcszValue, "M", strlen("M")) == 0) {
|
|
|
SetInWhatPage(PageType_MainPage);
|
|
@@ -859,6 +860,18 @@ public:
|
|
|
else {
|
|
|
SetInWhatPage(PageType_Other);
|
|
|
}
|
|
|
+
|
|
|
+ if (m_preUIState != pcszValue[0]) {
|
|
|
+ if (pcszValue[0] == 'M') {
|
|
|
+ trigger = true;
|
|
|
+ }
|
|
|
+ m_preUIState = pcszValue[0];
|
|
|
+ }
|
|
|
+
|
|
|
+ if (trigger) {
|
|
|
+ DbgWithLink(LOG_LEVEL_DEBUG, LOG_TYPE_SYSTEM)("just test EVT_MAINPAGE_DISPLAY");
|
|
|
+ this->PostEventFIFO(new FSMEvent(EVT_MAINPAGE_DISPLAY));
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
|
|
@@ -974,7 +987,7 @@ protected:
|
|
|
virtual void OnHardwareShakeHand(CSmartPointer<ITransactionContext> pTransactionContext);
|
|
|
|
|
|
private:
|
|
|
- std::map<std::string, DWORD> m_WarnCodeMap;
|
|
|
+ char m_preUIState;
|
|
|
};
|
|
|
|
|
|
template<class TFSM, class TDevClass>
|