Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1042)

Side by Side Diff: xfa/fwl/core/fwl_noteimp.cpp

Issue 1902083002: Remove fullscreen code. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « xfa/fwl/core/fwl_noteimp.h ('k') | xfa/fwl/core/fwl_sdadapterimp.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/include/fx_ext.h" 9 #include "core/fxcrt/include/fx_ext.h"
10 #include "xfa/fwl/basewidget/fwl_tooltipctrlimp.h" 10 #include "xfa/fwl/basewidget/fwl_tooltipctrlimp.h"
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
66 IFWL_Thread* pThread = m_pForm->GetOwnerThread(); 66 IFWL_Thread* pThread = m_pForm->GetOwnerThread();
67 if (!pThread) 67 if (!pThread)
68 return; 68 return;
69 IFWL_NoteDriver* pDriver = pThread->GetNoteDriver(); 69 IFWL_NoteDriver* pDriver = pThread->GetNoteDriver();
70 if (!pDriver) 70 if (!pDriver)
71 return; 71 return;
72 pDriver->SendNote(&ev); 72 pDriver->SendNote(&ev);
73 } 73 }
74 CFWL_NoteDriver::CFWL_NoteDriver() 74 CFWL_NoteDriver::CFWL_NoteDriver()
75 : m_sendEventCalled(0), 75 : m_sendEventCalled(0),
76 m_bFullScreen(FALSE),
77 m_pHover(nullptr), 76 m_pHover(nullptr),
78 m_pFocus(nullptr), 77 m_pFocus(nullptr),
79 m_pGrab(nullptr) { 78 m_pGrab(nullptr) {
80 m_pNoteLoop = new CFWL_NoteLoop; 79 m_pNoteLoop = new CFWL_NoteLoop;
81 PushNoteLoop(m_pNoteLoop); 80 PushNoteLoop(m_pNoteLoop);
82 } 81 }
83 CFWL_NoteDriver::~CFWL_NoteDriver() { 82 CFWL_NoteDriver::~CFWL_NoteDriver() {
84 delete m_pNoteLoop; 83 delete m_pNoteLoop;
85 ClearInvalidEventTargets(TRUE); 84 ClearInvalidEventTargets(TRUE);
86 } 85 }
(...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after
319 continue; 318 continue;
320 } 319 }
321 CFWL_WidgetImp* pSubFocus = pForm->GetSubFocus(); 320 CFWL_WidgetImp* pSubFocus = pForm->GetSubFocus();
322 if (!pSubFocus) 321 if (!pSubFocus)
323 return; 322 return;
324 if (pSubFocus && pSubFocus->GetInterface() == pNoteTarget) { 323 if (pSubFocus && pSubFocus->GetInterface() == pNoteTarget) {
325 pForm->SetSubFocus(NULL); 324 pForm->SetSubFocus(NULL);
326 } 325 }
327 } 326 }
328 } 327 }
329 void CFWL_NoteDriver::NotifyFullScreenMode(IFWL_Widget* pNoteTarget, 328
330 FX_BOOL bFullScreen) {
331 m_bFullScreen = bFullScreen;
332 }
333 FWL_ERR CFWL_NoteDriver::RegisterForm(CFWL_WidgetImp* pForm) { 329 FWL_ERR CFWL_NoteDriver::RegisterForm(CFWL_WidgetImp* pForm) {
334 if (!pForm) 330 if (!pForm)
335 return FWL_ERR_Indefinite; 331 return FWL_ERR_Indefinite;
336 if (m_forms.Find(pForm) >= 0) { 332 if (m_forms.Find(pForm) >= 0) {
337 return FWL_ERR_Indefinite; 333 return FWL_ERR_Indefinite;
338 } 334 }
339 m_forms.Add(pForm); 335 m_forms.Add(pForm);
340 if (m_forms.GetSize() == 1) { 336 if (m_forms.GetSize() == 1) {
341 CFWL_NoteLoop* pLoop = 337 CFWL_NoteLoop* pLoop =
342 static_cast<CFWL_NoteLoop*>(m_noteLoopQueue.GetAt(0)); 338 static_cast<CFWL_NoteLoop*>(m_noteLoopQueue.GetAt(0));
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after
461 if (bRet) { 457 if (bRet) {
462 IFWL_WidgetDelegate* pDelegate = pMessage->m_pDstTarget->SetDelegate(NULL); 458 IFWL_WidgetDelegate* pDelegate = pMessage->m_pDstTarget->SetDelegate(NULL);
463 if (pDelegate) { 459 if (pDelegate) {
464 pDelegate->OnProcessMessage(pMessage); 460 pDelegate->OnProcessMessage(pMessage);
465 } 461 }
466 } 462 }
467 return bRet; 463 return bRet;
468 } 464 }
469 FX_BOOL CFWL_NoteDriver::DoActivate(CFWL_MsgActivate* pMsg, 465 FX_BOOL CFWL_NoteDriver::DoActivate(CFWL_MsgActivate* pMsg,
470 IFWL_Widget* pMessageForm) { 466 IFWL_Widget* pMessageForm) {
471 if (m_bFullScreen) {
472 return FALSE;
473 }
474 pMsg->m_pDstTarget = pMessageForm; 467 pMsg->m_pDstTarget = pMessageForm;
475 return (pMsg->m_pDstTarget)->GetStates() & FWL_WGTSTATE_Deactivated; 468 return (pMsg->m_pDstTarget)->GetStates() & FWL_WGTSTATE_Deactivated;
476 } 469 }
477 FX_BOOL CFWL_NoteDriver::DoDeactivate(CFWL_MsgDeactivate* pMsg, 470 FX_BOOL CFWL_NoteDriver::DoDeactivate(CFWL_MsgDeactivate* pMsg,
478 IFWL_Widget* pMessageForm) { 471 IFWL_Widget* pMessageForm) {
479 if (m_bFullScreen) {
480 return FALSE;
481 }
482 int32_t iTrackLoop = m_noteLoopQueue.GetSize(); 472 int32_t iTrackLoop = m_noteLoopQueue.GetSize();
483 if (iTrackLoop <= 0) 473 if (iTrackLoop <= 0)
484 return FALSE; 474 return FALSE;
485 if (iTrackLoop == 1) { 475 if (iTrackLoop == 1) {
486 if (pMessageForm->IsInstance(FX_WSTRC(L"FWL_FORMPROXY"))) { 476 if (pMessageForm->IsInstance(FX_WSTRC(L"FWL_FORMPROXY"))) {
487 return FALSE; 477 return FALSE;
488 } 478 }
489 if (pMsg->m_pSrcTarget && 479 if (pMsg->m_pSrcTarget &&
490 pMsg->m_pSrcTarget->IsInstance(FX_WSTRC(L"FWL_FORMPROXY"))) { 480 pMsg->m_pSrcTarget->IsInstance(FX_WSTRC(L"FWL_FORMPROXY"))) {
491 return FALSE; 481 return FALSE;
(...skipping 494 matching lines...) Expand 10 before | Expand all | Expand 10 after
986 if (HasToolTip(pEvt->m_pDstTarget) && NULL != m_pToolTipImp) { 976 if (HasToolTip(pEvt->m_pDstTarget) && NULL != m_pToolTipImp) {
987 m_pToolTipImp->Hide(); 977 m_pToolTipImp->Hide();
988 pCurTarget = NULL; 978 pCurTarget = NULL;
989 return TRUE; 979 return TRUE;
990 } 980 }
991 return FALSE; 981 return FALSE;
992 } 982 }
993 IFWL_ToolTipTarget* CFWL_ToolTipContainer::GetCurrentToolTipTarget() { 983 IFWL_ToolTipTarget* CFWL_ToolTipContainer::GetCurrentToolTipTarget() {
994 return pCurTarget; 984 return pCurTarget;
995 } 985 }
OLDNEW
« no previous file with comments | « xfa/fwl/core/fwl_noteimp.h ('k') | xfa/fwl/core/fwl_sdadapterimp.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698