| OLD | NEW | 
|---|
| (Empty) |  | 
|  | 1 // Copyright 2016 PDFium Authors. All rights reserved. | 
|  | 2 // Use of this source code is governed by a BSD-style license that can be | 
|  | 3 // found in the LICENSE file. | 
|  | 4 | 
|  | 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com | 
|  | 6 | 
|  | 7 #include "fpdfsdk/include/cpdfsdk_xfaannothandler.h" | 
|  | 8 | 
|  | 9 #ifdef PDF_ENABLE_XFA | 
|  | 10 | 
|  | 11 #include "core/fpdfdoc/include/cpdf_interform.h" | 
|  | 12 #include "fpdfsdk/fpdfxfa/include/fpdfxfa_doc.h" | 
|  | 13 #include "fpdfsdk/include/cpdfsdk_annot.h" | 
|  | 14 #include "fpdfsdk/include/fsdk_mgr.h" | 
|  | 15 #include "xfa/fxfa/include/fxfa_basic.h" | 
|  | 16 #include "xfa/fxfa/include/xfa_ffdocview.h" | 
|  | 17 #include "xfa/fxfa/include/xfa_ffpageview.h" | 
|  | 18 #include "xfa/fxfa/include/xfa_ffwidget.h" | 
|  | 19 #include "xfa/fxfa/include/xfa_ffwidgethandler.h" | 
|  | 20 #include "xfa/fxgraphics/include/cfx_graphics.h" | 
|  | 21 #include "xfa/fwl/core/include/fwl_widgethit.h" | 
|  | 22 | 
|  | 23 CPDFSDK_XFAAnnotHandler::CPDFSDK_XFAAnnotHandler(CPDFDoc_Environment* pApp) | 
|  | 24     : m_pApp(pApp) {} | 
|  | 25 | 
|  | 26 CPDFSDK_XFAAnnotHandler::~CPDFSDK_XFAAnnotHandler() {} | 
|  | 27 | 
|  | 28 CFX_ByteString CPDFSDK_XFAAnnotHandler::GetType() { | 
|  | 29   return FSDK_XFAWIDGET_TYPENAME; | 
|  | 30 } | 
|  | 31 | 
|  | 32 CFX_ByteString CPDFSDK_XFAAnnotHandler::GetName() { | 
|  | 33   return "XFAWidgetHandler"; | 
|  | 34 } | 
|  | 35 | 
|  | 36 FX_BOOL CPDFSDK_XFAAnnotHandler::CanAnswer(CPDFSDK_Annot* pAnnot) { | 
|  | 37   return !!pAnnot->GetXFAWidget(); | 
|  | 38 } | 
|  | 39 | 
|  | 40 CPDFSDK_Annot* CPDFSDK_XFAAnnotHandler::NewAnnot(CPDF_Annot* pAnnot, | 
|  | 41                                                  CPDFSDK_PageView* pPage) { | 
|  | 42   return nullptr; | 
|  | 43 } | 
|  | 44 | 
|  | 45 CPDFSDK_Annot* CPDFSDK_XFAAnnotHandler::NewAnnot(CXFA_FFWidget* pAnnot, | 
|  | 46                                                  CPDFSDK_PageView* pPage) { | 
|  | 47   CPDFSDK_Document* pSDKDoc = m_pApp->GetSDKDocument(); | 
|  | 48   CPDFSDK_InterForm* pInterForm = pSDKDoc->GetInterForm(); | 
|  | 49   CPDFSDK_XFAWidget* pWidget = new CPDFSDK_XFAWidget(pAnnot, pPage, pInterForm); | 
|  | 50   pInterForm->AddXFAMap(pAnnot, pWidget); | 
|  | 51   return pWidget; | 
|  | 52 } | 
|  | 53 | 
|  | 54 void CPDFSDK_XFAAnnotHandler::OnDraw(CPDFSDK_PageView* pPageView, | 
|  | 55                                      CPDFSDK_Annot* pAnnot, | 
|  | 56                                      CFX_RenderDevice* pDevice, | 
|  | 57                                      CFX_Matrix* pUser2Device, | 
|  | 58                                      uint32_t dwFlags) { | 
|  | 59   ASSERT(pPageView); | 
|  | 60   ASSERT(pAnnot); | 
|  | 61 | 
|  | 62   CPDFSDK_Document* pSDKDoc = pPageView->GetSDKDocument(); | 
|  | 63   CXFA_FFWidgetHandler* pWidgetHandler = GetXFAWidgetHandler(pAnnot); | 
|  | 64 | 
|  | 65   CFX_Graphics gs; | 
|  | 66   gs.Create(pDevice); | 
|  | 67 | 
|  | 68   CFX_Matrix mt; | 
|  | 69   mt = *pUser2Device; | 
|  | 70 | 
|  | 71   FX_BOOL bIsHighlight = FALSE; | 
|  | 72   if (pSDKDoc->GetFocusAnnot() != pAnnot) | 
|  | 73     bIsHighlight = TRUE; | 
|  | 74 | 
|  | 75   pWidgetHandler->RenderWidget(pAnnot->GetXFAWidget(), &gs, &mt, bIsHighlight); | 
|  | 76 | 
|  | 77   // to do highlight and shadow | 
|  | 78 } | 
|  | 79 | 
|  | 80 void CPDFSDK_XFAAnnotHandler::OnDrawSleep(CPDFSDK_PageView* pPageView, | 
|  | 81                                           CPDFSDK_Annot* pAnnot, | 
|  | 82                                           CFX_RenderDevice* pDevice, | 
|  | 83                                           CFX_Matrix* pUser2Device, | 
|  | 84                                           const CFX_FloatRect& rcWindow, | 
|  | 85                                           uint32_t dwFlags) {} | 
|  | 86 | 
|  | 87 void CPDFSDK_XFAAnnotHandler::OnCreate(CPDFSDK_Annot* pAnnot) {} | 
|  | 88 | 
|  | 89 void CPDFSDK_XFAAnnotHandler::OnLoad(CPDFSDK_Annot* pAnnot) {} | 
|  | 90 | 
|  | 91 void CPDFSDK_XFAAnnotHandler::OnDelete(CPDFSDK_Annot* pAnnot) {} | 
|  | 92 | 
|  | 93 void CPDFSDK_XFAAnnotHandler::OnRelease(CPDFSDK_Annot* pAnnot) {} | 
|  | 94 | 
|  | 95 void CPDFSDK_XFAAnnotHandler::ReleaseAnnot(CPDFSDK_Annot* pAnnot) { | 
|  | 96   CPDFSDK_XFAWidget* pWidget = reinterpret_cast<CPDFSDK_XFAWidget*>(pAnnot); | 
|  | 97   CPDFSDK_InterForm* pInterForm = pWidget->GetInterForm(); | 
|  | 98   pInterForm->RemoveXFAMap(pWidget->GetXFAWidget()); | 
|  | 99 | 
|  | 100   delete pWidget; | 
|  | 101 } | 
|  | 102 | 
|  | 103 void CPDFSDK_XFAAnnotHandler::DeleteAnnot(CPDFSDK_Annot* pAnnot) {} | 
|  | 104 | 
|  | 105 CFX_FloatRect CPDFSDK_XFAAnnotHandler::GetViewBBox(CPDFSDK_PageView* pPageView, | 
|  | 106                                                    CPDFSDK_Annot* pAnnot) { | 
|  | 107   ASSERT(pAnnot); | 
|  | 108 | 
|  | 109   CFX_RectF rcBBox; | 
|  | 110   XFA_Element eType = pAnnot->GetXFAWidget()->GetDataAcc()->GetUIType(); | 
|  | 111   if (eType == XFA_Element::Signature) | 
|  | 112     pAnnot->GetXFAWidget()->GetBBox(rcBBox, XFA_WidgetStatus_Visible, TRUE); | 
|  | 113   else | 
|  | 114     pAnnot->GetXFAWidget()->GetBBox(rcBBox, XFA_WidgetStatus_None); | 
|  | 115 | 
|  | 116   CFX_FloatRect rcWidget(rcBBox.left, rcBBox.top, rcBBox.left + rcBBox.width, | 
|  | 117                          rcBBox.top + rcBBox.height); | 
|  | 118   rcWidget.left -= 1.0f; | 
|  | 119   rcWidget.right += 1.0f; | 
|  | 120   rcWidget.bottom -= 1.0f; | 
|  | 121   rcWidget.top += 1.0f; | 
|  | 122 | 
|  | 123   return rcWidget; | 
|  | 124 } | 
|  | 125 | 
|  | 126 FX_BOOL CPDFSDK_XFAAnnotHandler::HitTest(CPDFSDK_PageView* pPageView, | 
|  | 127                                          CPDFSDK_Annot* pAnnot, | 
|  | 128                                          const CFX_FloatPoint& point) { | 
|  | 129   if (!pPageView || !pAnnot) | 
|  | 130     return FALSE; | 
|  | 131 | 
|  | 132   CPDFSDK_Document* pSDKDoc = pPageView->GetSDKDocument(); | 
|  | 133   if (!pSDKDoc) | 
|  | 134     return FALSE; | 
|  | 135 | 
|  | 136   CPDFXFA_Document* pDoc = pSDKDoc->GetXFADocument(); | 
|  | 137   if (!pDoc) | 
|  | 138     return FALSE; | 
|  | 139 | 
|  | 140   CXFA_FFDocView* pDocView = pDoc->GetXFADocView(); | 
|  | 141   if (!pDocView) | 
|  | 142     return FALSE; | 
|  | 143 | 
|  | 144   CXFA_FFWidgetHandler* pWidgetHandler = pDocView->GetWidgetHandler(); | 
|  | 145   if (!pWidgetHandler) | 
|  | 146     return FALSE; | 
|  | 147 | 
|  | 148   FWL_WidgetHit dwHitTest = | 
|  | 149       pWidgetHandler->OnHitTest(pAnnot->GetXFAWidget(), point.x, point.y); | 
|  | 150   return dwHitTest != FWL_WidgetHit::Unknown; | 
|  | 151 } | 
|  | 152 | 
|  | 153 void CPDFSDK_XFAAnnotHandler::OnMouseEnter(CPDFSDK_PageView* pPageView, | 
|  | 154                                            CPDFSDK_Annot* pAnnot, | 
|  | 155                                            uint32_t nFlag) { | 
|  | 156   if (!pPageView || !pAnnot) | 
|  | 157     return; | 
|  | 158   CXFA_FFWidgetHandler* pWidgetHandler = GetXFAWidgetHandler(pAnnot); | 
|  | 159   pWidgetHandler->OnMouseEnter(pAnnot->GetXFAWidget()); | 
|  | 160 } | 
|  | 161 | 
|  | 162 void CPDFSDK_XFAAnnotHandler::OnMouseExit(CPDFSDK_PageView* pPageView, | 
|  | 163                                           CPDFSDK_Annot* pAnnot, | 
|  | 164                                           uint32_t nFlag) { | 
|  | 165   if (!pPageView || !pAnnot) | 
|  | 166     return; | 
|  | 167 | 
|  | 168   CXFA_FFWidgetHandler* pWidgetHandler = GetXFAWidgetHandler(pAnnot); | 
|  | 169   pWidgetHandler->OnMouseExit(pAnnot->GetXFAWidget()); | 
|  | 170 } | 
|  | 171 | 
|  | 172 FX_BOOL CPDFSDK_XFAAnnotHandler::OnLButtonDown(CPDFSDK_PageView* pPageView, | 
|  | 173                                                CPDFSDK_Annot* pAnnot, | 
|  | 174                                                uint32_t nFlags, | 
|  | 175                                                const CFX_FloatPoint& point) { | 
|  | 176   if (!pPageView || !pAnnot) | 
|  | 177     return FALSE; | 
|  | 178 | 
|  | 179   CXFA_FFWidgetHandler* pWidgetHandler = GetXFAWidgetHandler(pAnnot); | 
|  | 180   return pWidgetHandler->OnLButtonDown(pAnnot->GetXFAWidget(), | 
|  | 181                                        GetFWLFlags(nFlags), point.x, point.y); | 
|  | 182 } | 
|  | 183 | 
|  | 184 FX_BOOL CPDFSDK_XFAAnnotHandler::OnLButtonUp(CPDFSDK_PageView* pPageView, | 
|  | 185                                              CPDFSDK_Annot* pAnnot, | 
|  | 186                                              uint32_t nFlags, | 
|  | 187                                              const CFX_FloatPoint& point) { | 
|  | 188   if (!pPageView || !pAnnot) | 
|  | 189     return FALSE; | 
|  | 190 | 
|  | 191   CXFA_FFWidgetHandler* pWidgetHandler = GetXFAWidgetHandler(pAnnot); | 
|  | 192   return pWidgetHandler->OnLButtonUp(pAnnot->GetXFAWidget(), | 
|  | 193                                      GetFWLFlags(nFlags), point.x, point.y); | 
|  | 194 } | 
|  | 195 | 
|  | 196 FX_BOOL CPDFSDK_XFAAnnotHandler::OnLButtonDblClk(CPDFSDK_PageView* pPageView, | 
|  | 197                                                  CPDFSDK_Annot* pAnnot, | 
|  | 198                                                  uint32_t nFlags, | 
|  | 199                                                  const CFX_FloatPoint& point) { | 
|  | 200   if (!pPageView || !pAnnot) | 
|  | 201     return FALSE; | 
|  | 202 | 
|  | 203   CXFA_FFWidgetHandler* pWidgetHandler = GetXFAWidgetHandler(pAnnot); | 
|  | 204   return pWidgetHandler->OnLButtonDblClk(pAnnot->GetXFAWidget(), | 
|  | 205                                          GetFWLFlags(nFlags), point.x, point.y); | 
|  | 206 } | 
|  | 207 | 
|  | 208 FX_BOOL CPDFSDK_XFAAnnotHandler::OnMouseMove(CPDFSDK_PageView* pPageView, | 
|  | 209                                              CPDFSDK_Annot* pAnnot, | 
|  | 210                                              uint32_t nFlags, | 
|  | 211                                              const CFX_FloatPoint& point) { | 
|  | 212   if (!pPageView || !pAnnot) | 
|  | 213     return FALSE; | 
|  | 214 | 
|  | 215   CXFA_FFWidgetHandler* pWidgetHandler = GetXFAWidgetHandler(pAnnot); | 
|  | 216   return pWidgetHandler->OnMouseMove(pAnnot->GetXFAWidget(), | 
|  | 217                                      GetFWLFlags(nFlags), point.x, point.y); | 
|  | 218 } | 
|  | 219 | 
|  | 220 FX_BOOL CPDFSDK_XFAAnnotHandler::OnMouseWheel(CPDFSDK_PageView* pPageView, | 
|  | 221                                               CPDFSDK_Annot* pAnnot, | 
|  | 222                                               uint32_t nFlags, | 
|  | 223                                               short zDelta, | 
|  | 224                                               const CFX_FloatPoint& point) { | 
|  | 225   if (!pPageView || !pAnnot) | 
|  | 226     return FALSE; | 
|  | 227 | 
|  | 228   CXFA_FFWidgetHandler* pWidgetHandler = GetXFAWidgetHandler(pAnnot); | 
|  | 229   return pWidgetHandler->OnMouseWheel( | 
|  | 230       pAnnot->GetXFAWidget(), GetFWLFlags(nFlags), zDelta, point.x, point.y); | 
|  | 231 } | 
|  | 232 | 
|  | 233 FX_BOOL CPDFSDK_XFAAnnotHandler::OnRButtonDown(CPDFSDK_PageView* pPageView, | 
|  | 234                                                CPDFSDK_Annot* pAnnot, | 
|  | 235                                                uint32_t nFlags, | 
|  | 236                                                const CFX_FloatPoint& point) { | 
|  | 237   if (!pPageView || !pAnnot) | 
|  | 238     return FALSE; | 
|  | 239 | 
|  | 240   CXFA_FFWidgetHandler* pWidgetHandler = GetXFAWidgetHandler(pAnnot); | 
|  | 241   return pWidgetHandler->OnRButtonDown(pAnnot->GetXFAWidget(), | 
|  | 242                                        GetFWLFlags(nFlags), point.x, point.y); | 
|  | 243 } | 
|  | 244 | 
|  | 245 FX_BOOL CPDFSDK_XFAAnnotHandler::OnRButtonUp(CPDFSDK_PageView* pPageView, | 
|  | 246                                              CPDFSDK_Annot* pAnnot, | 
|  | 247                                              uint32_t nFlags, | 
|  | 248                                              const CFX_FloatPoint& point) { | 
|  | 249   if (!pPageView || !pAnnot) | 
|  | 250     return FALSE; | 
|  | 251 | 
|  | 252   CXFA_FFWidgetHandler* pWidgetHandler = GetXFAWidgetHandler(pAnnot); | 
|  | 253   return pWidgetHandler->OnRButtonUp(pAnnot->GetXFAWidget(), | 
|  | 254                                      GetFWLFlags(nFlags), point.x, point.y); | 
|  | 255 } | 
|  | 256 | 
|  | 257 FX_BOOL CPDFSDK_XFAAnnotHandler::OnRButtonDblClk(CPDFSDK_PageView* pPageView, | 
|  | 258                                                  CPDFSDK_Annot* pAnnot, | 
|  | 259                                                  uint32_t nFlags, | 
|  | 260                                                  const CFX_FloatPoint& point) { | 
|  | 261   if (!pPageView || !pAnnot) | 
|  | 262     return FALSE; | 
|  | 263 | 
|  | 264   CXFA_FFWidgetHandler* pWidgetHandler = GetXFAWidgetHandler(pAnnot); | 
|  | 265   return pWidgetHandler->OnRButtonDblClk(pAnnot->GetXFAWidget(), | 
|  | 266                                          GetFWLFlags(nFlags), point.x, point.y); | 
|  | 267 } | 
|  | 268 | 
|  | 269 FX_BOOL CPDFSDK_XFAAnnotHandler::OnChar(CPDFSDK_Annot* pAnnot, | 
|  | 270                                         uint32_t nChar, | 
|  | 271                                         uint32_t nFlags) { | 
|  | 272   if (!pAnnot) | 
|  | 273     return FALSE; | 
|  | 274 | 
|  | 275   CXFA_FFWidgetHandler* pWidgetHandler = GetXFAWidgetHandler(pAnnot); | 
|  | 276   return pWidgetHandler->OnChar(pAnnot->GetXFAWidget(), nChar, | 
|  | 277                                 GetFWLFlags(nFlags)); | 
|  | 278 } | 
|  | 279 | 
|  | 280 FX_BOOL CPDFSDK_XFAAnnotHandler::OnKeyDown(CPDFSDK_Annot* pAnnot, | 
|  | 281                                            int nKeyCode, | 
|  | 282                                            int nFlag) { | 
|  | 283   if (!pAnnot) | 
|  | 284     return FALSE; | 
|  | 285 | 
|  | 286   CXFA_FFWidgetHandler* pWidgetHandler = GetXFAWidgetHandler(pAnnot); | 
|  | 287   return pWidgetHandler->OnKeyDown(pAnnot->GetXFAWidget(), nKeyCode, | 
|  | 288                                    GetFWLFlags(nFlag)); | 
|  | 289 } | 
|  | 290 | 
|  | 291 FX_BOOL CPDFSDK_XFAAnnotHandler::OnKeyUp(CPDFSDK_Annot* pAnnot, | 
|  | 292                                          int nKeyCode, | 
|  | 293                                          int nFlag) { | 
|  | 294   if (!pAnnot) | 
|  | 295     return FALSE; | 
|  | 296 | 
|  | 297   CXFA_FFWidgetHandler* pWidgetHandler = GetXFAWidgetHandler(pAnnot); | 
|  | 298   return pWidgetHandler->OnKeyUp(pAnnot->GetXFAWidget(), nKeyCode, | 
|  | 299                                  GetFWLFlags(nFlag)); | 
|  | 300 } | 
|  | 301 | 
|  | 302 void CPDFSDK_XFAAnnotHandler::OnDeSelected(CPDFSDK_Annot* pAnnot) {} | 
|  | 303 | 
|  | 304 void CPDFSDK_XFAAnnotHandler::OnSelected(CPDFSDK_Annot* pAnnot) {} | 
|  | 305 | 
|  | 306 FX_BOOL CPDFSDK_XFAAnnotHandler::OnSetFocus(CPDFSDK_Annot* pAnnot, | 
|  | 307                                             uint32_t nFlag) { | 
|  | 308   return TRUE; | 
|  | 309 } | 
|  | 310 | 
|  | 311 FX_BOOL CPDFSDK_XFAAnnotHandler::OnKillFocus(CPDFSDK_Annot* pAnnot, | 
|  | 312                                              uint32_t nFlag) { | 
|  | 313   return TRUE; | 
|  | 314 } | 
|  | 315 | 
|  | 316 FX_BOOL CPDFSDK_XFAAnnotHandler::OnXFAChangedFocus(CPDFSDK_Annot* pOldAnnot, | 
|  | 317                                                    CPDFSDK_Annot* pNewAnnot) { | 
|  | 318   CXFA_FFWidgetHandler* pWidgetHandler = nullptr; | 
|  | 319 | 
|  | 320   if (pOldAnnot) | 
|  | 321     pWidgetHandler = GetXFAWidgetHandler(pOldAnnot); | 
|  | 322   else if (pNewAnnot) | 
|  | 323     pWidgetHandler = GetXFAWidgetHandler(pNewAnnot); | 
|  | 324 | 
|  | 325   if (pWidgetHandler) { | 
|  | 326     FX_BOOL bRet = TRUE; | 
|  | 327     CXFA_FFWidget* hWidget = pNewAnnot ? pNewAnnot->GetXFAWidget() : nullptr; | 
|  | 328     if (hWidget) { | 
|  | 329       CXFA_FFPageView* pXFAPageView = hWidget->GetPageView(); | 
|  | 330       if (pXFAPageView) { | 
|  | 331         bRet = pXFAPageView->GetDocView()->SetFocus(hWidget); | 
|  | 332         if (pXFAPageView->GetDocView()->GetFocusWidget() == hWidget) | 
|  | 333           bRet = TRUE; | 
|  | 334       } | 
|  | 335     } | 
|  | 336     return bRet; | 
|  | 337   } | 
|  | 338 | 
|  | 339   return TRUE; | 
|  | 340 } | 
|  | 341 | 
|  | 342 CXFA_FFWidgetHandler* CPDFSDK_XFAAnnotHandler::GetXFAWidgetHandler( | 
|  | 343     CPDFSDK_Annot* pAnnot) { | 
|  | 344   if (!pAnnot) | 
|  | 345     return nullptr; | 
|  | 346 | 
|  | 347   CPDFSDK_PageView* pPageView = pAnnot->GetPageView(); | 
|  | 348   if (!pPageView) | 
|  | 349     return nullptr; | 
|  | 350 | 
|  | 351   CPDFSDK_Document* pSDKDoc = pPageView->GetSDKDocument(); | 
|  | 352   if (!pSDKDoc) | 
|  | 353     return nullptr; | 
|  | 354 | 
|  | 355   CPDFXFA_Document* pDoc = pSDKDoc->GetXFADocument(); | 
|  | 356   if (!pDoc) | 
|  | 357     return nullptr; | 
|  | 358 | 
|  | 359   CXFA_FFDocView* pDocView = pDoc->GetXFADocView(); | 
|  | 360   if (!pDocView) | 
|  | 361     return nullptr; | 
|  | 362 | 
|  | 363   return pDocView->GetWidgetHandler(); | 
|  | 364 } | 
|  | 365 | 
|  | 366 const uint32_t FWL_KEYFLAG_Ctrl = (1 << 0); | 
|  | 367 const uint32_t FWL_KEYFLAG_Alt = (1 << 1); | 
|  | 368 const uint32_t FWL_KEYFLAG_Shift = (1 << 2); | 
|  | 369 const uint32_t FWL_KEYFLAG_LButton = (1 << 3); | 
|  | 370 const uint32_t FWL_KEYFLAG_RButton = (1 << 4); | 
|  | 371 const uint32_t FWL_KEYFLAG_MButton = (1 << 5); | 
|  | 372 | 
|  | 373 uint32_t CPDFSDK_XFAAnnotHandler::GetFWLFlags(uint32_t dwFlag) { | 
|  | 374   uint32_t dwFWLFlag = 0; | 
|  | 375 | 
|  | 376   if (dwFlag & FWL_EVENTFLAG_ControlKey) | 
|  | 377     dwFWLFlag |= FWL_KEYFLAG_Ctrl; | 
|  | 378   if (dwFlag & FWL_EVENTFLAG_LeftButtonDown) | 
|  | 379     dwFWLFlag |= FWL_KEYFLAG_LButton; | 
|  | 380   if (dwFlag & FWL_EVENTFLAG_MiddleButtonDown) | 
|  | 381     dwFWLFlag |= FWL_KEYFLAG_MButton; | 
|  | 382   if (dwFlag & FWL_EVENTFLAG_RightButtonDown) | 
|  | 383     dwFWLFlag |= FWL_KEYFLAG_RButton; | 
|  | 384   if (dwFlag & FWL_EVENTFLAG_ShiftKey) | 
|  | 385     dwFWLFlag |= FWL_KEYFLAG_Shift; | 
|  | 386   if (dwFlag & FWL_EVENTFLAG_AltKey) | 
|  | 387     dwFWLFlag |= FWL_KEYFLAG_Alt; | 
|  | 388 | 
|  | 389   return dwFWLFlag; | 
|  | 390 } | 
|  | 391 | 
|  | 392 #endif  // PDF_ENABLE_XFA | 
| OLD | NEW | 
|---|