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

Issue 1332973002: Remove some abstractions in fxjs_v8.h. (Closed)

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

Description

Remove some abstractions in fxjs_v8.h. It's too hard to keep mapping between v8 and fx abstractions; the lack of transparency prevents those skilled in v8 only from working on this code. Apparently, the original intention was to confine v8 types to fpdfsdk/{include,src}/jsapi, but fpdfsdk/{include,src}/javascript is already well-polluted with v8 types. Also remove no-op JS_SetThisObj(). Also remove unused ParserParams() [noticed because it was incorrectly passing handles as pointers]. Also remove cast operator from CJS_Runtime and call GetIsolate() explicitly. R=thestig@chromium.org Committed: https://pdfium.googlesource.com/pdfium/+/6df59849472958e7de96da6d9fc7b223b7c1f1c3

Patch Set 1 #

Patch Set 2 : Stray file. #

Patch Set 3 : Remove no-op JS_SetThisObj() #

Patch Set 4 : Remove isolate abstraction as well. #

Patch Set 5 : Remove unused ParserParams #

Patch Set 6 : Manually rename some parameters to reflect type. #

Patch Set 7 : remove no-op casts. #

Patch Set 8 : Remove implicit cast operator from CJS_Runtime. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+473 lines, -516 lines) Patch
M fpdfsdk/include/javascript/Consts.h View 1 2 3 4 5 9 chunks +13 lines, -15 lines 0 comments Download
M fpdfsdk/include/javascript/Document.h View 1 2 3 4 3 chunks +2 lines, -3 lines 0 comments Download
M fpdfsdk/include/javascript/Field.h View 1 chunk +1 line, -1 line 0 comments Download
M fpdfsdk/include/javascript/Icon.h View 1 chunk +1 line, -1 line 0 comments Download
M fpdfsdk/include/javascript/JS_Define.h View 1 2 3 4 5 9 chunks +63 lines, -61 lines 0 comments Download
M fpdfsdk/include/javascript/JS_Object.h View 2 chunks +2 lines, -2 lines 0 comments Download
M fpdfsdk/include/javascript/JS_Runtime.h View 1 2 3 4 5 6 7 3 chunks +3 lines, -7 lines 0 comments Download
M fpdfsdk/include/javascript/JS_Value.h View 2 chunks +3 lines, -3 lines 0 comments Download
M fpdfsdk/include/javascript/PublicMethods.h View 1 chunk +1 line, -1 line 0 comments Download
M fpdfsdk/include/javascript/app.h View 2 chunks +2 lines, -2 lines 0 comments Download
M fpdfsdk/include/javascript/color.h View 1 chunk +1 line, -1 line 0 comments Download
M fpdfsdk/include/javascript/console.h View 1 chunk +1 line, -1 line 0 comments Download
M fpdfsdk/include/javascript/event.h View 1 chunk +1 line, -1 line 0 comments Download
M fpdfsdk/include/javascript/global.h View 2 chunks +2 lines, -2 lines 0 comments Download
M fpdfsdk/include/javascript/report.h View 1 chunk +1 line, -1 line 0 comments Download
M fpdfsdk/include/javascript/util.h View 1 chunk +1 line, -1 line 0 comments Download
M fpdfsdk/include/jsapi/fxjs_v8.h View 1 2 3 4 5 3 chunks +46 lines, -56 lines 0 comments Download
M fpdfsdk/src/javascript/Consts.cpp View 1 2 3 4 5 6 chunks +24 lines, -24 lines 0 comments Download
M fpdfsdk/src/javascript/Document.cpp View 1 2 3 4 5 6 7 10 chunks +21 lines, -20 lines 0 comments Download
M fpdfsdk/src/javascript/Field.cpp View 1 2 3 4 5 6 7 2 chunks +6 lines, -4 lines 0 comments Download
M fpdfsdk/src/javascript/JS_Context.cpp View 1 2 3 4 5 6 7 1 chunk +2 lines, -2 lines 0 comments Download
M fpdfsdk/src/javascript/JS_EventHandler.cpp View 1 2 3 4 5 6 7 2 chunks +12 lines, -8 lines 0 comments Download
M fpdfsdk/src/javascript/JS_Object.cpp View 1 chunk +1 line, -1 line 0 comments Download
M fpdfsdk/src/javascript/JS_Runtime.cpp View 1 2 3 4 5 6 7 4 chunks +28 lines, -33 lines 0 comments Download
M fpdfsdk/src/javascript/JS_Value.cpp View 4 chunks +6 lines, -6 lines 0 comments Download
M fpdfsdk/src/javascript/app.cpp View 1 2 3 4 5 6 7 8 chunks +21 lines, -15 lines 0 comments Download
M fpdfsdk/src/javascript/global.cpp View 1 2 3 6 chunks +20 lines, -17 lines 0 comments Download
M fpdfsdk/src/jsapi/fxjs_v8.cpp View 1 2 3 4 5 6 25 chunks +188 lines, -227 lines 0 comments Download

Messages

Total messages: 4 (1 generated)
Tom Sepez
Lei, for review. I was trying to write fxjs_v8 tests, but couldn't keep all the ...
5 years, 3 months ago (2015-09-10 18:03:40 UTC) #2
Lei Zhang
lgtm
5 years, 3 months ago (2015-09-10 18:47:14 UTC) #3
Tom Sepez
5 years, 3 months ago (2015-09-10 18:56:43 UTC) #4
Message was sent while issue was closed.
Committed patchset #8 (id:140001) manually as
6df59849472958e7de96da6d9fc7b223b7c1f1c3 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698