Home | History | Annotate | Download | only in core
      1 // Copyright 2014 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 "xfa/src/foxitlib.h"
      8 #include "xfa/src/fwl/src/core/include/fwl_targetimp.h"
      9 #include "xfa/src/fwl/src/core/include/fwl_threadimp.h"
     10 #include "xfa/src/fwl/src/core/include/fwl_noteimp.h"
     11 #include "xfa/src/fwl/src/core/include/fwl_widgetmgrimp.h"
     12 CFWL_SDAdapterWidgetMgr::CFWL_SDAdapterWidgetMgr() {}
     13 CFWL_SDAdapterWidgetMgr::~CFWL_SDAdapterWidgetMgr() {}
     14 FWL_ERR CFWL_SDAdapterWidgetMgr::CreateWidget(IFWL_Widget* pWidget,
     15                                               IFWL_Widget* pParent) {
     16   return FWL_ERR_Succeeded;
     17 }
     18 FWL_ERR CFWL_SDAdapterWidgetMgr::DestroyWidget(IFWL_Widget* pWidget) {
     19   return FWL_ERR_Succeeded;
     20 }
     21 FWL_ERR CFWL_SDAdapterWidgetMgr::SetWidgetRect(IFWL_Widget* pWidget,
     22                                                const CFX_RectF& rect) {
     23   return FWL_ERR_Succeeded;
     24 }
     25 FWL_ERR CFWL_SDAdapterWidgetMgr::SetWidgetPosition(IFWL_Widget* pWidget,
     26                                                    FX_FLOAT fx,
     27                                                    FX_FLOAT fy) {
     28   return FWL_ERR_Succeeded;
     29 }
     30 FWL_ERR CFWL_SDAdapterWidgetMgr::SetParentWidget(IFWL_Widget* pWidget,
     31                                                  IFWL_Widget* pParent) {
     32   return FWL_ERR_Succeeded;
     33 }
     34 FWL_ERR CFWL_SDAdapterWidgetMgr::ShowWidget(IFWL_Widget* pWidget) {
     35   return FWL_ERR_Succeeded;
     36 }
     37 FWL_ERR CFWL_SDAdapterWidgetMgr::HideWidget(IFWL_Widget* pWidget) {
     38   return FWL_ERR_Succeeded;
     39 }
     40 FWL_ERR CFWL_SDAdapterWidgetMgr::SetNormal(IFWL_Widget* pWidget) {
     41   return FWL_ERR_Succeeded;
     42 }
     43 FWL_ERR CFWL_SDAdapterWidgetMgr::SetMaximize(IFWL_Widget* pWidget) {
     44   return FWL_ERR_Succeeded;
     45 }
     46 FWL_ERR CFWL_SDAdapterWidgetMgr::SetMinimize(IFWL_Widget* pWidget) {
     47   return FWL_ERR_Succeeded;
     48 }
     49 FWL_ERR CFWL_SDAdapterWidgetMgr::RunWidget(IFWL_Widget* pWidget) {
     50   return FWL_ERR_Succeeded;
     51 }
     52 FWL_ERR CFWL_SDAdapterWidgetMgr::RepaintWidget(IFWL_Widget* pWidget,
     53                                                const CFX_RectF* pRect) {
     54   return FWL_ERR_Succeeded;
     55 }
     56 FWL_ERR CFWL_SDAdapterWidgetMgr::Exit(int32_t iExitCode) {
     57   return FWL_ERR_Succeeded;
     58 }
     59 FWL_ERR CFWL_SDAdapterWidgetMgr::CreateWidgetWithNativeId(IFWL_Widget* pWidget,
     60                                                           void* vp) {
     61   return FWL_ERR_Succeeded;
     62 }
     63 FWL_ERR CFWL_SDAdapterWidgetMgr::GetWidgetRect(IFWL_Widget* pWidget,
     64                                                CFX_RectF& rect) {
     65   return FWL_ERR_Succeeded;
     66 }
     67 FWL_ERR CFWL_SDAdapterWidgetMgr::SetWidgetIcon(IFWL_Widget* pWidget,
     68                                                const CFX_DIBitmap* pIcon,
     69                                                FX_BOOL bBig) {
     70   return FWL_ERR_Succeeded;
     71 }
     72 FWL_ERR CFWL_SDAdapterWidgetMgr::SetWidgetCaption(
     73     IFWL_Widget* pWidget,
     74     const CFX_WideStringC& wsCaption) {
     75   return FWL_ERR_Succeeded;
     76 }
     77 FWL_ERR CFWL_SDAdapterWidgetMgr::SetBorderRegion(IFWL_Widget* pWidget,
     78                                                  CFX_Path* pPath) {
     79   return FWL_ERR_Succeeded;
     80 }
     81 FWL_ERR CFWL_SDAdapterWidgetMgr::SetTransparent(IFWL_Widget* pWidget,
     82                                                 FX_DWORD dwAlpha) {
     83   return FWL_ERR_Succeeded;
     84 }
     85 FWL_ERR CFWL_SDAdapterWidgetMgr::SetFullScreen(IFWL_Widget* pWidget,
     86                                                FX_BOOL bFullScreen) {
     87   return FWL_ERR_Succeeded;
     88 }
     89 FX_BOOL CFWL_SDAdapterWidgetMgr::CheckMessage() {
     90   return TRUE;
     91 }
     92 FX_BOOL CFWL_SDAdapterWidgetMgr::IsIdleMessage() {
     93   return TRUE;
     94 }
     95 FWL_ERR CFWL_SDAdapterWidgetMgr::DispatchMessage() {
     96   return FWL_ERR_Succeeded;
     97 }
     98 FWL_ERR CFWL_SDAdapterWidgetMgr::GetWidgetDC(IFWL_Widget* pWidget, void*& pDC) {
     99   return FWL_ERR_Succeeded;
    100 }
    101 FWL_ERR CFWL_SDAdapterWidgetMgr::ReleaseWidgetDC(IFWL_Widget* pWidget,
    102                                                  void* pDC,
    103                                                  CFX_RectF* pClip) {
    104   return FWL_ERR_Succeeded;
    105 }
    106 void* CFWL_SDAdapterWidgetMgr::GetWindow(IFWL_Widget* pWidget) {
    107   return NULL;
    108 }
    109 FX_DWORD CFWL_SDAdapterWidgetMgr::GetKeyState(FX_DWORD dwVirtKey) {
    110   return 0;
    111 }
    112 FWL_ERR CFWL_SDAdapterWidgetMgr::RunLoop(IFWL_Widget* widget) {
    113   return FWL_ERR_Succeeded;
    114 }
    115 FWL_ERR CFWL_SDAdapterWidgetMgr::EndLoop() {
    116   return FWL_ERR_Succeeded;
    117 }
    118 FWL_ERR CFWL_SDAdapterWidgetMgr::InitMenu(IFWL_Menu* pMenu,
    119                                           IFWL_MenuDP* pMenuData) {
    120   return FWL_ERR_Succeeded;
    121 }
    122 FWL_ERR CFWL_SDAdapterWidgetMgr::UpdateMenu(IFWL_Menu* pMenu,
    123                                             const void* hItem,
    124                                             int32_t iType) {
    125   return FWL_ERR_Succeeded;
    126 }
    127 int32_t CFWL_SDAdapterWidgetMgr::TrackPopupMenu(IFWL_Menu* pMenu,
    128                                                 IFWL_MenuDP* pMenuData) {
    129   return 0;
    130 }
    131 FWL_ERR CFWL_SDAdapterWidgetMgr::SetMessageHook(IFWL_AdapterMessageHook* hook) {
    132   return FWL_ERR_Succeeded;
    133 }
    134 FWL_ERR CFWL_SDAdapterWidgetMgr::GetSystemBorder(FX_FLOAT& l,
    135                                                  FX_FLOAT& t,
    136                                                  FX_FLOAT& r,
    137                                                  FX_FLOAT& b) {
    138   return FWL_ERR_Succeeded;
    139 }
    140 FX_BOOL CFWL_SDAdapterWidgetMgr::GetPopupPos(IFWL_Widget* pWidget,
    141                                              FX_FLOAT fMinHeight,
    142                                              FX_FLOAT fMaxHeight,
    143                                              const CFX_RectF& rtAnchor,
    144                                              CFX_RectF& rtPopup) {
    145   return FWL_ERR_Succeeded;
    146 }
    147 CFWL_SDAdapterThreadMgr::CFWL_SDAdapterThreadMgr() {}
    148 CFWL_SDAdapterThreadMgr::~CFWL_SDAdapterThreadMgr() {}
    149 FWL_ERR CFWL_SDAdapterThreadMgr::Start(IFWL_Thread* pThread,
    150                                        FWL_HTHREAD& hThread,
    151                                        FX_BOOL bSuspended) {
    152   return FWL_ERR_Succeeded;
    153 }
    154 FWL_ERR CFWL_SDAdapterThreadMgr::Resume(FWL_HTHREAD hThread) {
    155   return FWL_ERR_Succeeded;
    156 }
    157 FWL_ERR CFWL_SDAdapterThreadMgr::Suspend(FWL_HTHREAD hThread) {
    158   return FWL_ERR_Succeeded;
    159 }
    160 FWL_ERR CFWL_SDAdapterThreadMgr::Kill(FWL_HTHREAD hThread, int32_t iExitCode) {
    161   return FWL_ERR_Succeeded;
    162 }
    163 FWL_ERR CFWL_SDAdapterThreadMgr::Stop(FWL_HTHREAD hThread, int32_t iExitCode) {
    164   return FWL_ERR_Succeeded;
    165 }
    166 IFWL_Thread* CFWL_SDAdapterThreadMgr::GetCurrentThread() {
    167   return FWL_GetApp();
    168 }
    169