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

Side by Side Diff: xfa/fwl/lightwidget/cfwl_app.cpp

Issue 1834323003: Move xfa/include/fwl/{theme,lightwidget} to xfa/fwl (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
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/include/fwl/lightwidget/app.h" 7 #include "xfa/fwl/lightwidget/cfwl_app.h"
8 8
9 #include "core/fxcrt/include/fx_coordinates.h" 9 #include "core/fxcrt/include/fx_coordinates.h"
10 #include "xfa/fwl/core/fwl_error.h" 10 #include "xfa/fwl/core/fwl_error.h"
11 #include "xfa/fwl/core/ifwl_app.h" 11 #include "xfa/fwl/core/ifwl_app.h"
12 #include "xfa/include/fwl/lightwidget/theme.h" 12 #include "xfa/fwl/lightwidget/cfwl_theme.h"
13 13
14 CFWL_App::CFWL_App() : m_pIface(IFWL_App::Create(nullptr)), m_pTheme(nullptr) {} 14 CFWL_App::CFWL_App() : m_pIface(IFWL_App::Create(nullptr)), m_pTheme(nullptr) {}
15
15 CFWL_App::~CFWL_App() { 16 CFWL_App::~CFWL_App() {
16 if (m_pTheme) { 17 if (m_pTheme) {
17 m_pTheme->Finalize(); 18 m_pTheme->Finalize();
18 delete m_pTheme; 19 delete m_pTheme;
19 m_pTheme = NULL; 20 m_pTheme = NULL;
Tom Sepez 2016/03/29 16:45:31 nit: nulling it out not needed.
dsinclair 2016/03/29 19:22:23 Done.
20 } 21 }
21 m_pIface->Release(); 22 m_pIface->Release();
22 } 23 }
24
23 FWL_ERR CFWL_App::Initialize() { 25 FWL_ERR CFWL_App::Initialize() {
24 m_pTheme = new CFWL_Theme; 26 m_pTheme = new CFWL_Theme;
25 m_pTheme->Initialize(); 27 m_pTheme->Initialize();
26 m_pIface->SetThemeProvider(m_pTheme); 28 m_pIface->SetThemeProvider(m_pTheme);
27 return m_pIface->Initialize(); 29 return m_pIface->Initialize();
28 } 30 }
31
29 FWL_ERR CFWL_App::Exit(int32_t iExitCode) { 32 FWL_ERR CFWL_App::Exit(int32_t iExitCode) {
30 if (!m_pIface) 33 if (!m_pIface)
31 return FWL_ERR_Indefinite; 34 return FWL_ERR_Indefinite;
32 return m_pIface->Exit(iExitCode); 35 return m_pIface->Exit(iExitCode);
33 } 36 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698