| 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/fwl_noteimp.h" | 7 #include "xfa/fwl/core/fwl_noteimp.h" |
| 8 | 8 |
| 9 #include "core/fxcrt/fx_ext.h" | 9 #include "core/fxcrt/fx_ext.h" |
| 10 #include "third_party/base/stl_util.h" | 10 #include "third_party/base/stl_util.h" |
| (...skipping 742 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 753 case CFWL_EventType::Idle: | 753 case CFWL_EventType::Idle: |
| 754 return !!(dwFilter & FWL_EVENT_IDLE_MASK); | 754 return !!(dwFilter & FWL_EVENT_IDLE_MASK); |
| 755 default: | 755 default: |
| 756 return !!(dwFilter & FWL_EVENT_CONTROL_MASK); | 756 return !!(dwFilter & FWL_EVENT_CONTROL_MASK); |
| 757 } | 757 } |
| 758 } | 758 } |
| 759 | 759 |
| 760 CFWL_ToolTipContainer* CFWL_ToolTipContainer::s_pInstance = nullptr; | 760 CFWL_ToolTipContainer* CFWL_ToolTipContainer::s_pInstance = nullptr; |
| 761 | 761 |
| 762 CFWL_ToolTipContainer::CFWL_ToolTipContainer() | 762 CFWL_ToolTipContainer::CFWL_ToolTipContainer() |
| 763 : m_pToolTipImp(nullptr), m_pToolTipDp(new CFWL_CoreToolTipDP(0, 2000)) {} | 763 : m_pToolTipDp(new CFWL_CoreToolTipDP(0, 2000)) {} |
| 764 | 764 |
| 765 CFWL_ToolTipContainer::~CFWL_ToolTipContainer() { | 765 CFWL_ToolTipContainer::~CFWL_ToolTipContainer() {} |
| 766 if (m_pToolTipImp) { | |
| 767 IFWL_ToolTip* pToolTip = static_cast<IFWL_ToolTip*>(m_pToolTipImp); | |
| 768 pToolTip->Finalize(); | |
| 769 delete pToolTip; | |
| 770 } | |
| 771 } | |
| 772 | 766 |
| 773 // static | 767 // static |
| 774 CFWL_ToolTipContainer* CFWL_ToolTipContainer::getInstance() { | 768 CFWL_ToolTipContainer* CFWL_ToolTipContainer::getInstance() { |
| 775 if (!s_pInstance) | 769 if (!s_pInstance) |
| 776 s_pInstance = new CFWL_ToolTipContainer; | 770 s_pInstance = new CFWL_ToolTipContainer; |
| 777 return s_pInstance; | 771 return s_pInstance; |
| 778 } | 772 } |
| 779 | 773 |
| 780 // static | 774 // static |
| 781 void CFWL_ToolTipContainer::DeleteInstance() { | 775 void CFWL_ToolTipContainer::DeleteInstance() { |
| 782 delete s_pInstance; | 776 delete s_pInstance; |
| 783 s_pInstance = nullptr; | 777 s_pInstance = nullptr; |
| 784 } | 778 } |
| OLD | NEW |