OLD | NEW |
1 // Copyright 2014 PDFium Authors. All rights reserved. | 1 // Copyright 2014 PDFium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com | 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com |
6 | 6 |
7 #include "xfa/fwl/basewidget/fwl_datetimepickerimp.h" | 7 #include "xfa/fwl/basewidget/fwl_datetimepickerimp.h" |
8 | 8 |
9 #include "xfa/fwl/basewidget/fwl_editimp.h" | 9 #include "xfa/fwl/basewidget/fwl_editimp.h" |
10 #include "xfa/fwl/basewidget/fwl_formproxyimp.h" | 10 #include "xfa/fwl/basewidget/fwl_formproxyimp.h" |
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
158 m_pDelegate = new CFWL_DateTimeEditImpDelegate(this); | 158 m_pDelegate = new CFWL_DateTimeEditImpDelegate(this); |
159 if (CFWL_EditImp::Initialize() != FWL_ERR_Succeeded) | 159 if (CFWL_EditImp::Initialize() != FWL_ERR_Succeeded) |
160 return FWL_ERR_Indefinite; | 160 return FWL_ERR_Indefinite; |
161 return FWL_ERR_Succeeded; | 161 return FWL_ERR_Succeeded; |
162 } | 162 } |
163 FWL_ERR CFWL_DateTimeEdit::Finalize() { | 163 FWL_ERR CFWL_DateTimeEdit::Finalize() { |
164 delete m_pDelegate; | 164 delete m_pDelegate; |
165 m_pDelegate = nullptr; | 165 m_pDelegate = nullptr; |
166 return CFWL_EditImp::Finalize(); | 166 return CFWL_EditImp::Finalize(); |
167 } | 167 } |
| 168 |
168 CFWL_DateTimeEditImpDelegate::CFWL_DateTimeEditImpDelegate( | 169 CFWL_DateTimeEditImpDelegate::CFWL_DateTimeEditImpDelegate( |
169 CFWL_DateTimeEdit* pOwner) | 170 CFWL_DateTimeEdit* pOwner) |
170 : CFWL_EditImpDelegate(pOwner), m_pOwner(pOwner) {} | 171 : CFWL_EditImpDelegate(pOwner), m_pOwner(pOwner) {} |
| 172 |
171 int32_t CFWL_DateTimeEditImpDelegate::OnProcessMessage(CFWL_Message* pMessage) { | 173 int32_t CFWL_DateTimeEditImpDelegate::OnProcessMessage(CFWL_Message* pMessage) { |
172 if (m_pOwner->m_pWidgetMgr->IsFormDisabled()) { | 174 if (m_pOwner->m_pWidgetMgr->IsFormDisabled()) |
173 return DisForm_OnProcessMessage(pMessage); | 175 return DisForm_OnProcessMessage(pMessage); |
174 } | 176 |
175 uint32_t dwHashCode = pMessage->GetClassID(); | 177 CFWL_MessageType dwHashCode = pMessage->GetClassID(); |
176 if (dwHashCode == FWL_MSGHASH_SetFocus || | 178 if (dwHashCode == CFWL_MessageType::SetFocus || |
177 dwHashCode == FWL_MSGHASH_KillFocus) { | 179 dwHashCode == CFWL_MessageType::KillFocus) { |
178 IFWL_Widget* pOuter = m_pOwner->GetOuter(); | 180 IFWL_Widget* pOuter = m_pOwner->GetOuter(); |
179 IFWL_WidgetDelegate* pDelegate = pOuter->SetDelegate(NULL); | 181 IFWL_WidgetDelegate* pDelegate = pOuter->SetDelegate(NULL); |
180 pDelegate->OnProcessMessage(pMessage); | 182 pDelegate->OnProcessMessage(pMessage); |
181 } | 183 } |
182 return 1; | 184 return 1; |
183 } | 185 } |
| 186 |
184 int32_t CFWL_DateTimeEditImpDelegate::DisForm_OnProcessMessage( | 187 int32_t CFWL_DateTimeEditImpDelegate::DisForm_OnProcessMessage( |
185 CFWL_Message* pMessage) { | 188 CFWL_Message* pMessage) { |
186 uint32_t dwHashCode = pMessage->GetClassID(); | 189 CFWL_MessageType dwHashCode = pMessage->GetClassID(); |
187 if (m_pOwner->m_pWidgetMgr->IsFormDisabled()) { | 190 if (m_pOwner->m_pWidgetMgr->IsFormDisabled()) { |
188 if (dwHashCode == FWL_MSGHASH_Mouse) { | 191 if (dwHashCode == CFWL_MessageType::Mouse) { |
189 CFWL_MsgMouse* pMouse = static_cast<CFWL_MsgMouse*>(pMessage); | 192 CFWL_MsgMouse* pMouse = static_cast<CFWL_MsgMouse*>(pMessage); |
190 if (pMouse->m_dwCmd == FWL_MSGMOUSECMD_LButtonDown || | 193 if (pMouse->m_dwCmd == FWL_MSGMOUSECMD_LButtonDown || |
191 pMouse->m_dwCmd == FWL_MSGMOUSECMD_RButtonDown) { | 194 pMouse->m_dwCmd == FWL_MSGMOUSECMD_RButtonDown) { |
192 if ((m_pOwner->m_pProperties->m_dwStates & FWL_WGTSTATE_Focused) == 0) { | 195 if ((m_pOwner->m_pProperties->m_dwStates & FWL_WGTSTATE_Focused) == 0) { |
193 m_pOwner->m_pProperties->m_dwStates |= FWL_WGTSTATE_Focused; | 196 m_pOwner->m_pProperties->m_dwStates |= FWL_WGTSTATE_Focused; |
194 } | 197 } |
195 CFWL_DateTimePickerImp* pDateTime = | 198 CFWL_DateTimePickerImp* pDateTime = |
196 static_cast<CFWL_DateTimePickerImp*>(m_pOwner->m_pOuter->GetImpl()); | 199 static_cast<CFWL_DateTimePickerImp*>(m_pOwner->m_pOuter->GetImpl()); |
197 if (pDateTime->IsMonthCalendarShowed()) { | 200 if (pDateTime->IsMonthCalendarShowed()) { |
198 CFX_RectF rtInvalidate; | 201 CFX_RectF rtInvalidate; |
199 pDateTime->GetWidgetRect(rtInvalidate); | 202 pDateTime->GetWidgetRect(rtInvalidate); |
200 pDateTime->ShowMonthCalendar(FALSE); | 203 pDateTime->ShowMonthCalendar(FALSE); |
201 rtInvalidate.Offset(-rtInvalidate.left, -rtInvalidate.top); | 204 rtInvalidate.Offset(-rtInvalidate.left, -rtInvalidate.top); |
202 pDateTime->Repaint(&rtInvalidate); | 205 pDateTime->Repaint(&rtInvalidate); |
203 } | 206 } |
204 } | 207 } |
205 } else if (dwHashCode == FWL_MSGHASH_Key) { | 208 } else if (dwHashCode == CFWL_MessageType::Key) { |
206 return CFWL_EditImpDelegate::OnProcessMessage(pMessage); | 209 return CFWL_EditImpDelegate::OnProcessMessage(pMessage); |
207 } | 210 } |
208 } | 211 } |
209 return CFWL_EditImpDelegate::OnProcessMessage(pMessage); | 212 return CFWL_EditImpDelegate::OnProcessMessage(pMessage); |
210 } | 213 } |
| 214 |
211 CFWL_DateTimeCalendar::CFWL_DateTimeCalendar( | 215 CFWL_DateTimeCalendar::CFWL_DateTimeCalendar( |
212 const CFWL_WidgetImpProperties& properties, | 216 const CFWL_WidgetImpProperties& properties, |
213 IFWL_Widget* pOuter) | 217 IFWL_Widget* pOuter) |
214 : CFWL_MonthCalendarImp(properties, pOuter) {} | 218 : CFWL_MonthCalendarImp(properties, pOuter) {} |
215 FWL_ERR CFWL_DateTimeCalendar::Initialize() { | 219 FWL_ERR CFWL_DateTimeCalendar::Initialize() { |
216 if (CFWL_MonthCalendarImp::Initialize() != FWL_ERR_Succeeded) | 220 if (CFWL_MonthCalendarImp::Initialize() != FWL_ERR_Succeeded) |
217 return FWL_ERR_Indefinite; | 221 return FWL_ERR_Indefinite; |
218 delete m_pDelegate; | 222 delete m_pDelegate; |
219 m_pDelegate = new CFWL_DateTimeCalendarImpDelegate(this); | 223 m_pDelegate = new CFWL_DateTimeCalendarImpDelegate(this); |
220 return FWL_ERR_Succeeded; | 224 return FWL_ERR_Succeeded; |
221 } | 225 } |
222 FWL_ERR CFWL_DateTimeCalendar::Finalize() { | 226 FWL_ERR CFWL_DateTimeCalendar::Finalize() { |
223 delete m_pDelegate; | 227 delete m_pDelegate; |
224 m_pDelegate = nullptr; | 228 m_pDelegate = nullptr; |
225 return CFWL_MonthCalendarImp::Finalize(); | 229 return CFWL_MonthCalendarImp::Finalize(); |
226 } | 230 } |
| 231 |
227 CFWL_DateTimeCalendarImpDelegate::CFWL_DateTimeCalendarImpDelegate( | 232 CFWL_DateTimeCalendarImpDelegate::CFWL_DateTimeCalendarImpDelegate( |
228 CFWL_DateTimeCalendar* pOwner) | 233 CFWL_DateTimeCalendar* pOwner) |
229 : CFWL_MonthCalendarImpDelegate(pOwner), m_pOwner(pOwner) { | 234 : CFWL_MonthCalendarImpDelegate(pOwner), m_pOwner(pOwner) { |
230 m_bFlag = FALSE; | 235 m_bFlag = FALSE; |
231 } | 236 } |
| 237 |
232 int32_t CFWL_DateTimeCalendarImpDelegate::OnProcessMessage( | 238 int32_t CFWL_DateTimeCalendarImpDelegate::OnProcessMessage( |
233 CFWL_Message* pMessage) { | 239 CFWL_Message* pMessage) { |
234 uint32_t dwCode = pMessage->GetClassID(); | 240 CFWL_MessageType dwCode = pMessage->GetClassID(); |
235 if (dwCode == FWL_MSGHASH_SetFocus || dwCode == FWL_MSGHASH_KillFocus) { | 241 if (dwCode == CFWL_MessageType::SetFocus || |
| 242 dwCode == CFWL_MessageType::KillFocus) { |
236 IFWL_Widget* pOuter = m_pOwner->GetOuter(); | 243 IFWL_Widget* pOuter = m_pOwner->GetOuter(); |
237 IFWL_WidgetDelegate* pDelegate = pOuter->SetDelegate(NULL); | 244 IFWL_WidgetDelegate* pDelegate = pOuter->SetDelegate(NULL); |
238 return pDelegate->OnProcessMessage(pMessage); | 245 return pDelegate->OnProcessMessage(pMessage); |
239 } else if (dwCode == FWL_MSGHASH_Mouse) { | 246 } else if (dwCode == CFWL_MessageType::Mouse) { |
240 CFWL_MsgMouse* pMsg = static_cast<CFWL_MsgMouse*>(pMessage); | 247 CFWL_MsgMouse* pMsg = static_cast<CFWL_MsgMouse*>(pMessage); |
241 if (pMsg->m_dwCmd == FWL_MSGMOUSECMD_LButtonDown) { | 248 if (pMsg->m_dwCmd == FWL_MSGMOUSECMD_LButtonDown) { |
242 OnLButtonDownEx(pMsg); | 249 OnLButtonDownEx(pMsg); |
243 return 1; | 250 return 1; |
244 } else if (pMsg->m_dwCmd == FWL_MSGMOUSECMD_LButtonUp) { | 251 } else if (pMsg->m_dwCmd == FWL_MSGMOUSECMD_LButtonUp) { |
245 OnLButtonUpEx(pMsg); | 252 OnLButtonUpEx(pMsg); |
246 return 1; | 253 return 1; |
247 } | 254 } |
248 } | 255 } |
249 return CFWL_MonthCalendarImpDelegate::OnProcessMessage(pMessage); | 256 return CFWL_MonthCalendarImpDelegate::OnProcessMessage(pMessage); |
250 } | 257 } |
| 258 |
251 void CFWL_DateTimeCalendarImpDelegate::OnLButtonDownEx(CFWL_MsgMouse* pMsg) { | 259 void CFWL_DateTimeCalendarImpDelegate::OnLButtonDownEx(CFWL_MsgMouse* pMsg) { |
252 if (m_pOwner->m_rtLBtn.Contains(pMsg->m_fx, pMsg->m_fy)) { | 260 if (m_pOwner->m_rtLBtn.Contains(pMsg->m_fx, pMsg->m_fy)) { |
253 m_pOwner->m_iLBtnPartStates = CFWL_PartState_Pressed; | 261 m_pOwner->m_iLBtnPartStates = CFWL_PartState_Pressed; |
254 m_pOwner->PrevMonth(); | 262 m_pOwner->PrevMonth(); |
255 m_pOwner->Repaint(&m_pOwner->m_rtClient); | 263 m_pOwner->Repaint(&m_pOwner->m_rtClient); |
256 } else if (m_pOwner->m_rtRBtn.Contains(pMsg->m_fx, pMsg->m_fy)) { | 264 } else if (m_pOwner->m_rtRBtn.Contains(pMsg->m_fx, pMsg->m_fy)) { |
257 m_pOwner->m_iRBtnPartStates |= CFWL_PartState_Pressed; | 265 m_pOwner->m_iRBtnPartStates |= CFWL_PartState_Pressed; |
258 m_pOwner->NextMonth(); | 266 m_pOwner->NextMonth(); |
259 m_pOwner->Repaint(&m_pOwner->m_rtClient); | 267 m_pOwner->Repaint(&m_pOwner->m_rtClient); |
260 } else if (m_pOwner->m_rtToday.Contains(pMsg->m_fx, pMsg->m_fy)) { | 268 } else if (m_pOwner->m_rtToday.Contains(pMsg->m_fx, pMsg->m_fy)) { |
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
357 bRepaint = m_pOwner->m_iHovered > 0; | 365 bRepaint = m_pOwner->m_iHovered > 0; |
358 if (bRepaint) { | 366 if (bRepaint) { |
359 m_pOwner->GetDayRect(m_pOwner->m_iHovered, rtInvalidate); | 367 m_pOwner->GetDayRect(m_pOwner->m_iHovered, rtInvalidate); |
360 } | 368 } |
361 m_pOwner->m_iHovered = -1; | 369 m_pOwner->m_iHovered = -1; |
362 } | 370 } |
363 if (bRepaint && !rtInvalidate.IsEmpty()) { | 371 if (bRepaint && !rtInvalidate.IsEmpty()) { |
364 m_pOwner->Repaint(&rtInvalidate); | 372 m_pOwner->Repaint(&rtInvalidate); |
365 } | 373 } |
366 } | 374 } |
| 375 |
367 int32_t CFWL_DateTimeCalendarImpDelegate::DisForm_OnProcessMessage( | 376 int32_t CFWL_DateTimeCalendarImpDelegate::DisForm_OnProcessMessage( |
368 CFWL_Message* pMessage) { | 377 CFWL_Message* pMessage) { |
369 if (pMessage->GetClassID() == FWL_MSGHASH_Mouse) { | 378 if (pMessage->GetClassID() == CFWL_MessageType::Mouse) { |
370 CFWL_MsgMouse* pMsg = static_cast<CFWL_MsgMouse*>(pMessage); | 379 CFWL_MsgMouse* pMsg = static_cast<CFWL_MsgMouse*>(pMessage); |
371 if (pMsg->m_dwCmd == FWL_MSGMOUSECMD_LButtonUp) { | 380 if (pMsg->m_dwCmd == FWL_MSGMOUSECMD_LButtonUp) { |
372 DisForm_OnLButtonUpEx(pMsg); | 381 DisForm_OnLButtonUpEx(pMsg); |
373 return 1; | 382 return 1; |
374 } | 383 } |
375 } | 384 } |
376 return CFWL_MonthCalendarImpDelegate::OnProcessMessage(pMessage); | 385 return CFWL_MonthCalendarImpDelegate::OnProcessMessage(pMessage); |
377 } | 386 } |
| 387 |
378 void CFWL_DateTimeCalendarImpDelegate::DisForm_OnLButtonUpEx( | 388 void CFWL_DateTimeCalendarImpDelegate::DisForm_OnLButtonUpEx( |
379 CFWL_MsgMouse* pMsg) { | 389 CFWL_MsgMouse* pMsg) { |
380 if (m_pOwner->m_rtLBtn.Contains(pMsg->m_fx, pMsg->m_fy)) { | 390 if (m_pOwner->m_rtLBtn.Contains(pMsg->m_fx, pMsg->m_fy)) { |
381 m_pOwner->m_iLBtnPartStates = 0; | 391 m_pOwner->m_iLBtnPartStates = 0; |
382 m_pOwner->Repaint(&(m_pOwner->m_rtLBtn)); | 392 m_pOwner->Repaint(&(m_pOwner->m_rtLBtn)); |
383 return; | 393 return; |
384 } | 394 } |
385 if (m_pOwner->m_rtRBtn.Contains(pMsg->m_fx, pMsg->m_fy)) { | 395 if (m_pOwner->m_rtRBtn.Contains(pMsg->m_fx, pMsg->m_fy)) { |
386 m_pOwner->m_iRBtnPartStates = 0; | 396 m_pOwner->m_iRBtnPartStates = 0; |
387 m_pOwner->Repaint(&(m_pOwner->m_rtRBtn)); | 397 m_pOwner->Repaint(&(m_pOwner->m_rtRBtn)); |
(...skipping 615 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1003 m_pMonthCal->GetWidgetRect(rtMonth); | 1013 m_pMonthCal->GetWidgetRect(rtMonth); |
1004 CFX_Matrix mt; | 1014 CFX_Matrix mt; |
1005 mt.Set(1, 0, 0, 1, rtMonth.left, rtMonth.top); | 1015 mt.Set(1, 0, 0, 1, rtMonth.left, rtMonth.top); |
1006 if (pMatrix) { | 1016 if (pMatrix) { |
1007 mt.Concat(*pMatrix); | 1017 mt.Concat(*pMatrix); |
1008 } | 1018 } |
1009 m_pMonthCal->DrawWidget(pGraphics, &mt); | 1019 m_pMonthCal->DrawWidget(pGraphics, &mt); |
1010 } | 1020 } |
1011 return FWL_ERR_Succeeded; | 1021 return FWL_ERR_Succeeded; |
1012 } | 1022 } |
| 1023 |
1013 CFWL_DateTimePickerImpDelegate::CFWL_DateTimePickerImpDelegate( | 1024 CFWL_DateTimePickerImpDelegate::CFWL_DateTimePickerImpDelegate( |
1014 CFWL_DateTimePickerImp* pOwner) | 1025 CFWL_DateTimePickerImp* pOwner) |
1015 : m_pOwner(pOwner) {} | 1026 : m_pOwner(pOwner) {} |
| 1027 |
1016 int32_t CFWL_DateTimePickerImpDelegate::OnProcessMessage( | 1028 int32_t CFWL_DateTimePickerImpDelegate::OnProcessMessage( |
1017 CFWL_Message* pMessage) { | 1029 CFWL_Message* pMessage) { |
1018 if (!pMessage) | 1030 if (!pMessage) |
1019 return 0; | 1031 return 0; |
1020 uint32_t dwMsgCode = pMessage->GetClassID(); | 1032 |
1021 switch (dwMsgCode) { | 1033 switch (pMessage->GetClassID()) { |
1022 case FWL_MSGHASH_SetFocus: | 1034 case CFWL_MessageType::SetFocus: { |
1023 case FWL_MSGHASH_KillFocus: { | 1035 OnFocusChanged(pMessage, TRUE); |
1024 OnFocusChanged(pMessage, dwMsgCode == FWL_MSGHASH_SetFocus); | |
1025 break; | 1036 break; |
1026 } | 1037 } |
1027 case FWL_MSGHASH_Mouse: { | 1038 case CFWL_MessageType::KillFocus: { |
| 1039 OnFocusChanged(pMessage, FALSE); |
| 1040 break; |
| 1041 } |
| 1042 case CFWL_MessageType::Mouse: { |
1028 CFWL_MsgMouse* pMouse = static_cast<CFWL_MsgMouse*>(pMessage); | 1043 CFWL_MsgMouse* pMouse = static_cast<CFWL_MsgMouse*>(pMessage); |
1029 uint32_t dwCmd = pMouse->m_dwCmd; | 1044 switch (pMouse->m_dwCmd) { |
1030 switch (dwCmd) { | |
1031 case FWL_MSGMOUSECMD_LButtonDown: { | 1045 case FWL_MSGMOUSECMD_LButtonDown: { |
1032 OnLButtonDown(pMouse); | 1046 OnLButtonDown(pMouse); |
1033 break; | 1047 break; |
1034 } | 1048 } |
1035 case FWL_MSGMOUSECMD_LButtonUp: { | 1049 case FWL_MSGMOUSECMD_LButtonUp: { |
1036 OnLButtonUp(pMouse); | 1050 OnLButtonUp(pMouse); |
1037 break; | 1051 break; |
1038 } | 1052 } |
1039 case FWL_MSGMOUSECMD_MouseMove: { | 1053 case FWL_MSGMOUSECMD_MouseMove: { |
1040 OnMouseMove(pMouse); | 1054 OnMouseMove(pMouse); |
1041 break; | 1055 break; |
1042 } | 1056 } |
1043 case FWL_MSGMOUSECMD_MouseLeave: { | 1057 case FWL_MSGMOUSECMD_MouseLeave: { |
1044 OnMouseLeave(pMouse); | 1058 OnMouseLeave(pMouse); |
1045 break; | 1059 break; |
1046 } | 1060 } |
1047 default: {} | 1061 default: |
| 1062 break; |
| 1063 } |
| 1064 break; |
| 1065 } |
| 1066 case CFWL_MessageType::Key: { |
| 1067 if (m_pOwner->m_pEdit->GetStates() & FWL_WGTSTATE_Focused) { |
| 1068 IFWL_WidgetDelegate* pDelegate = m_pOwner->m_pEdit->SetDelegate(NULL); |
| 1069 return pDelegate->OnProcessMessage(pMessage); |
1048 } | 1070 } |
1049 break; | 1071 break; |
1050 } | 1072 } |
1051 default: | 1073 default: |
1052 break; | 1074 break; |
1053 } | 1075 } |
1054 if (dwMsgCode == FWL_MSGHASH_Key && | 1076 |
1055 m_pOwner->m_pEdit->GetStates() & FWL_WGTSTATE_Focused) { | |
1056 IFWL_WidgetDelegate* pDelegate = m_pOwner->m_pEdit->SetDelegate(NULL); | |
1057 return pDelegate->OnProcessMessage(pMessage); | |
1058 } | |
1059 return CFWL_WidgetImpDelegate::OnProcessMessage(pMessage); | 1077 return CFWL_WidgetImpDelegate::OnProcessMessage(pMessage); |
1060 } | 1078 } |
| 1079 |
1061 FWL_ERR CFWL_DateTimePickerImpDelegate::OnDrawWidget( | 1080 FWL_ERR CFWL_DateTimePickerImpDelegate::OnDrawWidget( |
1062 CFX_Graphics* pGraphics, | 1081 CFX_Graphics* pGraphics, |
1063 const CFX_Matrix* pMatrix) { | 1082 const CFX_Matrix* pMatrix) { |
1064 return m_pOwner->DrawWidget(pGraphics, pMatrix); | 1083 return m_pOwner->DrawWidget(pGraphics, pMatrix); |
1065 } | 1084 } |
1066 void CFWL_DateTimePickerImpDelegate::OnFocusChanged(CFWL_Message* pMsg, | 1085 void CFWL_DateTimePickerImpDelegate::OnFocusChanged(CFWL_Message* pMsg, |
1067 FX_BOOL bSet) { | 1086 FX_BOOL bSet) { |
1068 if (!pMsg) | 1087 if (!pMsg) |
1069 return; | 1088 return; |
1070 if (m_pOwner->m_pWidgetMgr->IsFormDisabled()) { | 1089 if (m_pOwner->m_pWidgetMgr->IsFormDisabled()) { |
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1154 } | 1173 } |
1155 if (m_pOwner->m_pEdit->GetStates() & FWL_WGTSTATE_Focused) { | 1174 if (m_pOwner->m_pEdit->GetStates() & FWL_WGTSTATE_Focused) { |
1156 pMsg->m_pSrcTarget = m_pOwner->m_pEdit.get(); | 1175 pMsg->m_pSrcTarget = m_pOwner->m_pEdit.get(); |
1157 IFWL_WidgetDelegate* pDelegate = m_pOwner->m_pEdit->SetDelegate(NULL); | 1176 IFWL_WidgetDelegate* pDelegate = m_pOwner->m_pEdit->SetDelegate(NULL); |
1158 pDelegate->OnProcessMessage(pMsg); | 1177 pDelegate->OnProcessMessage(pMsg); |
1159 } | 1178 } |
1160 } | 1179 } |
1161 rtInvalidate.Inflate(2, 2); | 1180 rtInvalidate.Inflate(2, 2); |
1162 m_pOwner->Repaint(&rtInvalidate); | 1181 m_pOwner->Repaint(&rtInvalidate); |
1163 } | 1182 } |
OLD | NEW |