| 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/core/ifwl_pushbutton.h" | 7 #include "xfa/fwl/core/ifwl_pushbutton.h" |
| 8 | 8 |
| 9 #include "third_party/base/ptr_util.h" | 9 #include "third_party/base/ptr_util.h" |
| 10 #include "xfa/fde/tto/fde_textout.h" | 10 #include "xfa/fde/tto/fde_textout.h" |
| (...skipping 351 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 362 break; | 362 break; |
| 363 } | 363 } |
| 364 case FWL_STYLEEXT_PSB_Center | FWL_STYLEEXT_PSB_Bottom: { | 364 case FWL_STYLEEXT_PSB_Center | FWL_STYLEEXT_PSB_Bottom: { |
| 365 m_iTTOAlign = FDE_TTOALIGNMENT_BottomCenter; | 365 m_iTTOAlign = FDE_TTOALIGNMENT_BottomCenter; |
| 366 break; | 366 break; |
| 367 } | 367 } |
| 368 case FWL_STYLEEXT_PSB_Right | FWL_STYLEEXT_PSB_Bottom: { | 368 case FWL_STYLEEXT_PSB_Right | FWL_STYLEEXT_PSB_Bottom: { |
| 369 m_iTTOAlign = FDE_TTOALIGNMENT_BottomRight; | 369 m_iTTOAlign = FDE_TTOALIGNMENT_BottomRight; |
| 370 break; | 370 break; |
| 371 } | 371 } |
| 372 default: {} | 372 default: |
| 373 break; |
| 373 } | 374 } |
| 374 m_dwTTOStyles = FDE_TTOSTYLE_SingleLine; | 375 m_dwTTOStyles = FDE_TTOSTYLE_SingleLine; |
| 375 if (m_pProperties->m_dwStyleExes & FWL_WGTSTYLE_RTLReading) { | 376 if (m_pProperties->m_dwStyleExes & FWL_WGTSTYLE_RTLReading) { |
| 376 m_dwTTOStyles |= FDE_TTOSTYLE_RTL; | 377 m_dwTTOStyles |= FDE_TTOSTYLE_RTL; |
| 377 } | 378 } |
| 378 } | 379 } |
| 379 | 380 |
| 380 void IFWL_PushButton::OnProcessMessage(CFWL_Message* pMessage) { | 381 void IFWL_PushButton::OnProcessMessage(CFWL_Message* pMessage) { |
| 381 if (!pMessage) | 382 if (!pMessage) |
| 382 return; | 383 return; |
| (...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 514 CFWL_EvtClick wmClick; | 515 CFWL_EvtClick wmClick; |
| 515 wmClick.m_pSrcTarget = this; | 516 wmClick.m_pSrcTarget = this; |
| 516 DispatchEvent(&wmClick); | 517 DispatchEvent(&wmClick); |
| 517 return; | 518 return; |
| 518 } | 519 } |
| 519 if (pMsg->m_dwKeyCode != FWL_VKEY_Tab) | 520 if (pMsg->m_dwKeyCode != FWL_VKEY_Tab) |
| 520 return; | 521 return; |
| 521 | 522 |
| 522 DispatchKeyEvent(pMsg); | 523 DispatchKeyEvent(pMsg); |
| 523 } | 524 } |
| OLD | NEW |