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

Issue 2154843002: Clean up singleton implementation (Closed)

Created:
4 years, 5 months ago by Wei Li
Modified:
4 years, 5 months ago
Reviewers:
Lei Zhang
CC:
pdfium-reviews_googlegroups.com
Base URL:
https://pdfium.googlesource.com/pdfium.git@master
Target Ref:
refs/heads/master
Project:
pdfium
Visibility:
Public.

Description

Clean up singleton implementation Move the singleton instances into their namespaces, and use get()/getInstance() for uniform accesses. Committed: https://pdfium.googlesource.com/pdfium/+/47228aceb86744f858ab8bfa98f3f8b62054dfae

Patch Set 1 #

Total comments: 9

Patch Set 2 : address comments #

Patch Set 3 : rebase #

Patch Set 4 : address comments #

Patch Set 5 : namespace #

Patch Set 6 : rebase #

Total comments: 2

Patch Set 7 : fix name #

Patch Set 8 : rebase #

Unified diffs Side-by-side diffs Delta from patch set Stats (+412 lines, -324 lines) Patch
M BUILD.gn View 1 2 3 4 5 6 7 2 chunks +4 lines, -0 lines 0 comments Download
M core/fpdfapi/cpdf_modulemgr.cpp View 1 2 3 4 1 chunk +6 lines, -10 lines 0 comments Download
M core/fxge/ge/fx_ge.cpp View 1 2 3 4 3 chunks +19 lines, -15 lines 0 comments Download
M core/fxge/include/fx_ge.h View 1 2 3 3 chunks +3 lines, -4 lines 0 comments Download
M fpdfsdk/fpdfdoc_unittest.cpp View 1 chunk +0 lines, -1 line 0 comments Download
M fpdfsdk/fpdfview.cpp View 1 2 3 4 5 1 chunk +2 lines, -2 lines 0 comments Download
M fpdfsdk/fpdfxfa/fpdfxfa_app.cpp View 1 2 3 4 1 chunk +5 lines, -1 line 0 comments Download
M fpdfsdk/fpdfxfa/include/fpdfxfa_app.h View 1 2 3 1 chunk +0 lines, -2 lines 0 comments Download
M fpdfsdk/javascript/JS_GlobalData.h View 1 2 3 2 chunks +2 lines, -39 lines 0 comments Download
M fpdfsdk/javascript/JS_GlobalData.cpp View 1 2 3 11 chunks +40 lines, -105 lines 0 comments Download
A fpdfsdk/javascript/JS_KeyValue.h View 1 2 3 1 chunk +46 lines, -0 lines 0 comments Download
A fpdfsdk/javascript/JS_KeyValue.cpp View 1 2 3 1 chunk +70 lines, -0 lines 0 comments Download
M fpdfsdk/javascript/global.h View 1 2 3 3 chunks +3 lines, -2 lines 0 comments Download
M fpdfsdk/javascript/global.cpp View 1 2 3 13 chunks +54 lines, -54 lines 0 comments Download
M pdfium.gyp View 1 2 3 1 chunk +2 lines, -0 lines 0 comments Download
M xfa.gyp View 1 2 3 4 5 6 7 1 chunk +2 lines, -0 lines 0 comments Download
A xfa/fwl/theme/cfwl_arrowdata.h View 1 2 3 4 5 6 1 chunk +36 lines, -0 lines 0 comments Download
A xfa/fwl/theme/cfwl_arrowdata.cpp View 1 2 3 4 5 6 1 chunk +73 lines, -0 lines 0 comments Download
M xfa/fwl/theme/cfwl_widgettp.h View 1 2 3 2 chunks +0 lines, -22 lines 0 comments Download
M xfa/fwl/theme/cfwl_widgettp.cpp View 1 2 3 4 5 6 22 chunks +45 lines, -67 lines 0 comments Download

Messages

Total messages: 18 (4 generated)
Wei Li
pls review, thanks
4 years, 5 months ago (2016-07-15 19:50:17 UTC) #2
Lei Zhang
https://codereview.chromium.org/2154843002/diff/1/core/fpdfapi/include/cpdf_modulemgr.h File core/fpdfapi/include/cpdf_modulemgr.h (right): https://codereview.chromium.org/2154843002/diff/1/core/fpdfapi/include/cpdf_modulemgr.h#newcode59 core/fpdfapi/include/cpdf_modulemgr.h:59: static CPDF_ModuleMgr* m_pDefaultMgr; Leave it as a global, for ...
4 years, 5 months ago (2016-07-16 01:23:03 UTC) #3
Wei Li
ptal, thanks https://codereview.chromium.org/2154843002/diff/1/core/fpdfapi/include/cpdf_modulemgr.h File core/fpdfapi/include/cpdf_modulemgr.h (right): https://codereview.chromium.org/2154843002/diff/1/core/fpdfapi/include/cpdf_modulemgr.h#newcode59 core/fpdfapi/include/cpdf_modulemgr.h:59: static CPDF_ModuleMgr* m_pDefaultMgr; On 2016/07/16 01:23:03, Lei ...
4 years, 5 months ago (2016-07-18 19:07:07 UTC) #4
Lei Zhang
https://codereview.chromium.org/2154843002/diff/1/core/fpdfapi/include/cpdf_modulemgr.h File core/fpdfapi/include/cpdf_modulemgr.h (right): https://codereview.chromium.org/2154843002/diff/1/core/fpdfapi/include/cpdf_modulemgr.h#newcode59 core/fpdfapi/include/cpdf_modulemgr.h:59: static CPDF_ModuleMgr* m_pDefaultMgr; On 2016/07/18 19:07:07, Wei Li wrote: ...
4 years, 5 months ago (2016-07-18 19:35:00 UTC) #5
Wei Li
On 2016/07/18 19:35:00, Lei Zhang wrote: > https://codereview.chromium.org/2154843002/diff/1/core/fpdfapi/include/cpdf_modulemgr.h > File core/fpdfapi/include/cpdf_modulemgr.h (right): > > https://codereview.chromium.org/2154843002/diff/1/core/fpdfapi/include/cpdf_modulemgr.h#newcode59 ...
4 years, 5 months ago (2016-07-18 20:02:45 UTC) #6
Lei Zhang
On 2016/07/18 20:02:45, Wei Li wrote: > Any advantage of using anonymous global? It should ...
4 years, 5 months ago (2016-07-18 20:25:19 UTC) #7
Wei Li
On 2016/07/18 20:25:19, Lei Zhang wrote: > On 2016/07/18 20:02:45, Wei Li wrote: > > ...
4 years, 5 months ago (2016-07-18 21:20:33 UTC) #8
Lei Zhang
On 2016/07/18 21:20:33, Wei Li wrote: > Aren't private member variables already be encapsulated within ...
4 years, 5 months ago (2016-07-18 23:05:24 UTC) #9
Wei Li
On 2016/07/18 23:05:24, Lei Zhang wrote: > On 2016/07/18 21:20:33, Wei Li wrote: > > ...
4 years, 5 months ago (2016-07-19 21:18:37 UTC) #10
Lei Zhang
lgtm https://codereview.chromium.org/2154843002/diff/100001/xfa/fwl/theme/cfwl_arrowdata.h File xfa/fwl/theme/cfwl_arrowdata.h (right): https://codereview.chromium.org/2154843002/diff/100001/xfa/fwl/theme/cfwl_arrowdata.h#newcode25 xfa/fwl/theme/cfwl_arrowdata.h:25: static FX_BOOL IsInstance(); HasInstance
4 years, 5 months ago (2016-07-20 00:34:46 UTC) #11
Wei Li
thanks https://codereview.chromium.org/2154843002/diff/100001/xfa/fwl/theme/cfwl_arrowdata.h File xfa/fwl/theme/cfwl_arrowdata.h (right): https://codereview.chromium.org/2154843002/diff/100001/xfa/fwl/theme/cfwl_arrowdata.h#newcode25 xfa/fwl/theme/cfwl_arrowdata.h:25: static FX_BOOL IsInstance(); On 2016/07/20 00:34:46, Lei Zhang ...
4 years, 5 months ago (2016-07-20 17:33:15 UTC) #12
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2154843002/140001
4 years, 5 months ago (2016-07-20 17:33:56 UTC) #15
commit-bot: I haz the power
Committed patchset #8 (id:140001) as https://pdfium.googlesource.com/pdfium/+/47228aceb86744f858ab8bfa98f3f8b62054dfae
4 years, 5 months ago (2016-07-20 17:35:36 UTC) #17
commit-bot: I haz the power
4 years, 5 months ago (2016-07-20 17:35:38 UTC) #18
Message was sent while issue was closed.
CQ bit was unchecked.

Powered by Google App Engine
This is Rietveld 408576698