Merge lp:~abreu-alexandre/oxide/v8-deprecations into lp:~oxide-developers/oxide/oxide.trunk
- v8-deprecations
- Merge into oxide.trunk
Status: | Merged | ||||
---|---|---|---|---|---|
Merged at revision: | 1471 | ||||
Proposed branch: | lp:~abreu-alexandre/oxide/v8-deprecations | ||||
Merge into: | lp:~oxide-developers/oxide/oxide.trunk | ||||
Diff against target: |
141 lines (+27/-17) 7 files modified
shared/renderer/oxide_script_message_handler_renderer.cc (+5/-4) shared/renderer/oxide_script_message_manager.cc (+1/-1) shared/renderer/oxide_script_message_request_impl_renderer.cc (+1/-1) shared/renderer/oxide_script_referenced_object.cc (+16/-7) shared/renderer/oxide_script_referenced_object.h (+1/-1) shared/renderer/oxide_user_script_slave.cc (+1/-1) shared/renderer/oxide_v8_scoped_persistent.h (+2/-2) |
||||
To merge this branch: | bzr merge lp:~abreu-alexandre/oxide/v8-deprecations | ||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Chris Coulson | Approve | ||
Review via email: mp+285633@code.launchpad.net |
Commit message
Fix v8::SetHiddenValue, v8::CallbackData & v8::TryCatch() deprecations
Description of the change
Fix v8::SetHiddenValue, v8::CallbackData & v8::TryCatch() deprecations
- 1341. By Chris Coulson
-
Install CMake package config files in to the correct place
- 1342. By Chris Coulson
-
Make CMake package config files work correctly - OxideQtCoreConf
ig.cmake needs to export -rpath-link option for libffmpeg.so - 1343. By Chris Coulson
-
Hopefully fix CMake 2.8 build
- 1344. By Chris Coulson
-
PYTHON needs to be defined in OxideCommonProp
erties. cmake now - 1345. By Chris Coulson
-
Switch from DelegatedRender
erLayer to SurfaceLayer in RenderWidgetHos tView, as the former has been deleted from Chromium - 1346. By Chris Coulson
-
Add an expliciy std::move when returning a scoped_ptr. It seems that current compilers figure this out, but older compilers don't
- 1347. By Chris Coulson
-
Depend on cc_surfaces
- 1348. By Chris Coulson
-
Merge r1107 from lp:oxide/crmaster
- 1349. By Chris Coulson
-
Increase timeout for tst_CustomURLSc
hemes.txt - it's a slow test anyway but it's hitting the timeout on my laptop now - 1350. By Alexandre Abreu
-
Support vibration api
- 1351. By Alexandre Abreu
-
Update WebSecurityOrig
in.h's location due to upstream reorg - 1352. By Alexandre Abreu
-
Fix new media hub binding build issues due to upstream changes
- 1353. By Chris Coulson
-
Don't call in to RWHV on the compositor thread
- 1354. By Chris Coulson
-
Merge r1112 from lp:oxide/crmaster
- 1355. By Chris Coulson
-
Fix 32-bit builds
- 1356. By Chris Coulson
-
Fix a typo, else the checked_cast is useless
- 1357. By Chris Coulson
-
Fix component builds with vibration support
- 1358. By Olivier Tilloy
-
Override OxideQQuickWebV
iew::touchUngra bEvent( ). - 1359. By Chris Coulson
-
Ensure we package all of the libraries
- 1360. By Chris Coulson
-
Move compositing, input event and windowing event handling out of WebView
- 1361. By Chris Coulson
-
Switch to a single-threaded webview compositor
- 1362. By Chris Coulson
-
Merge -r1116 from lp:oxide/crmaster
- 1363. By Chris Coulson
-
Fix some test failures
- 1364. By Loïc Molinari
-
Add support for scale factor retrieved from the Ubuntu QPA plugin
- 1365. By Chris Coulson
-
Fix device scaling mess. This makes scaling work correctly with Qt platforms other than ubuntu
- 1366. By Chris Coulson
-
Always prefer EGLImage over texture sharing. Also, ensure we correctly blacklist share group usage when necessary - this seems to have regressed because of a Chromium change
- 1367. By Olivier Tilloy
-
Hardcode selection colors to match the current Ambiance theme from the Ubuntu UI Toolkit.
- 1368. By Chris Coulson
-
Add some compositor trace events
- 1369. By Chris Coulson
-
Merge r1122 from lp:oxide/crmaster
- 1370. By Chris Coulson
-
Bump Chromium rev to 42b754c (50.0.2661.11)
- 1371. By Chris Coulson
-
Don't asynchronously request GPU info at startup - it races with webview construction, resulting in crashes because we can get different results from subsequent calls to CompositorUtils
::GetCompositin gMode on GPU's where GPU compositing is blacklisted - 1372. By Olivier Tilloy
-
Reset the touch selection state when the RenderWidgetHos
tView changes. - 1373. By Alexandre Abreu
-
Remove chromedriver build since to avoid issues with conflicting resources, upstreams chromedriver works
- 1374. By Chris Coulson
-
Make net::CookieStore access single threaded
- 1375. By Chris Coulson
-
Bump Chromium rev to 2c28ebf (50.0.2661.26)
- 1376. By Chris Coulson
-
Bump qt version to 1.15.0
- 1377. By Chris Coulson
-
Convert QTouchEvent directly to ui::MotionEvent.
Omitting ui::TouchEvent means we no longer have to round the touch coordinates, which should make scroll / pinch gestures smoother on high DPI screens
- 1378. By Chris Coulson
-
Fix crash in oxide::
InputMethodCont ext::SetImeBrid ge - 1379. By Alexandre Abreu
-
Fix media hub build following upstream prefixed EME removal
- 1380. By Chris Coulson
-
Clean up MotionEventFact
ory::UpdateTouc hPoint a bit - 1381. By Chris Coulson
-
Merge r1136 from lp:oxide/crmaster
- 1382. By Chris Coulson
-
Depend on //url/ipc to unbreak component builds
- 1383. By Chris Coulson
-
In fullscreen mode, the size of the view is based on the screen geometry rather than the actual view size to work around a Flash bug. In this case, we need to update the browser compositor size when the screen geometry changes
- 1384. By Chris Coulson
-
Rename some functions after 13afe03 landed upstream
- 1385. By Chris Coulson
-
Update for changes to WebMediaPlayerD
elegate: :Observer - 1386. By Chris Coulson
-
#include media/base/
timestamp_ constants. h - 1387. By Olivier Tilloy
-
Do not show the insertion handle on a tap for an empty editable text.
This aligns with upstream, and anticipates the removal of the config flag (crbug.com/554568). - 1388. By Olivier Tilloy
-
Touch selection API updates:
- enable adaptive handle orientation
- add an 'handleDragInProgress' property to OxideQQuickTouc hSelectionContr oller
- add a hide() method to OxideQQuickTouchSelectionContr oller - 1389. By Chris Coulson
-
Add CookieStoreUIProxy, which is an implementation of net::CookieStore that proxies calls from the UI thread to the real cookie store on the IO thread
- 1390. By Chris Coulson
-
LP: #1561450
- 1391. By Chris Coulson
-
Merge r1147 from lp:oxide/crmaster
- 1392. By Chris Coulson
-
Fix a shutdown abort in single-process mode
- 1393. By Chris Coulson
-
Unbreak document-start / document-end script injection
- 1394. By Chris Coulson
-
Some updates to the way tests run:
- runtests.py is now driven with a simple yaml config. This makes it easier to invoke tests manually for debugging.
- runtests.py makes it easy to run tests inside gdb
- All QML test sequences get their own test binary.
- The QML test runners now have a --file option for running a single test, which is useful for debugging.
- Various cleanups to the test support QML module. - 1395. By Chris Coulson
-
Try to reduce test flakiness in tst_Geolocation
PermissionReque st.qml - in test_Geolocatio nPermissionRequ est5_subframe_ delete_ cancel, the RFH isn't always deleted before the test times out - 1396. By Chris Coulson
-
Fix a test failure in tst_WebView_
downloadRequest ed.qml - 1397. By Chris Coulson
-
Merge r1153 from lp:oxide/crmaster
- 1398. By Chris Coulson
-
Fix flakiness in tst_bug1324909.qml
- 1399. By Chris Coulson
-
Pick up Chromium rev 73269de - "Ensure the suggested name for downloads gets passed to Oxide"
- 1400. By Chris Coulson
-
Make entire test cases skippable so that we can disable specific tests in certain environments (eg, single-process mode). This is achieved by adding SkippableTestCase (an implementation of TestCase) and exposing a (currently empty) TestProperties object to QML. Whilst this isn't adding support for driving tests with a manifest, it should be a sufficient solution for LP: #1399207
- 1401. By Chris Coulson
-
Re-organize the qml tests:
- qml-ssl-test folds in to qml-api-test - these were only separate because we never used to run the former with HTTPS servers.
- Add qml-web-platform- test for testing integration of web facing features. - 1402. By Chris Coulson
-
Fix a test shutdown crash
- 1403. By Chris Coulson
-
Revert unintentional change
- 1404. By Chris Coulson
-
Have the test runner create and expose a TestWebContext for each test case. This will make it easier to introduce single process test sequences
- 1405. By Chris Coulson
-
Disable profiler timing - we don't have chrome://profiler/, and this is disabled by default on Chrome/Android too
- 1406. By Chris Coulson
-
Allow the first created WebContext to become the default context in single process mode
- 1407. By Chris Coulson
-
Add QML test sequences for single-process. Currently there are quite a few failures that will be fixed in follow-ups. In the meantime, you can skip the single-process tests by passing ARGS="-E single-process" to make test
- 1408. By Chris Coulson
-
Revert addition of SkippableTestCase - this doesn't work as expected. As we don't allow the test case to complete, it doesn't get removed from Qt.testResults (see testlogger.js) which causes the test sequence to hang later on. Fixing this will either require us to depend on the internals of TestCase (and still may not even behave how we want), or have a complete reimplementation of TestCase which isn't really worth the effort
- 1409. By Chris Coulson
-
Add the ability to exclude entire test cases by adding them to a simple text file
- 1410. By Chris Coulson
-
Exclude tst_Incognito_
cleanup. qml and tst_Incognito_ cookies. qml from single process tests - 1411. By Chris Coulson
-
Fix test failure in tst_WebContext_
doNotTrack. qml. Not particularly sure why this fails or is unique to single process, but the fix seems to work - 1412. By Chris Coulson
-
Fix tst_WebContext_
defaultVideoCap tureDevice. qml in single process - 1413. By Chris Coulson
-
Exclude tst_WebContext_
sessionCookies. qml in single process. This isn't testable without restarting the app - 1414. By Chris Coulson
-
Exclude tst_WebContext_
semi_construct_ only_properties .qml from single-process tests - 1415. By Chris Coulson
-
Hopefully fix flakiness in tst_WebView_
closeRequested. qml - 1416. By Chris Coulson
-
Drop tst_bug1349510 - this has failed for ages because it relies on navigating to a URL longer than url::kMaxURLChars, which causes the render process to abort. If this was still a real problem, we'd know about it by now
- 1417. By Chris Coulson
-
Fix component builds
- 1418. By Chris Coulson
-
Make tst_SecuritySta
tus.qml work in single process - 1419. By Chris Coulson
-
Make WebContext only take ownership of WebContextDeleg
ateWorker if it's unowned when it's first attached, rather than unconditionally taking ownership. This ensures they get cleaned up at the end of test cases. Prior to this, they leak in single process tests, causing subsequent test failures - 1420. By Chris Coulson
-
Fix test failure in tst_WebContext_
userAgentOverri des.qml - 1421. By Chris Coulson
-
Ensure WebContext.
popupBlockerEna bled is restored during test case cleanup - 1422. By Chris Coulson
-
Hopefully fix tst_NetworkCall
backEvents. qml test flakiness - 1423. By Chris Coulson
-
Ensure WebContext.
userAgent is reset at the end of tests - 1424. By Chris Coulson
-
Another case where WebContext.
userAgent needs to be reset - 1425. By Chris Coulson
-
Don't run tst_WebView_
context. qml and tst_WebView_ incognito. qml in single process - 1426. By Chris Coulson
-
Fix tst_WebView_
mixedContentOve rrides. qml in single-process - ensure we reset the override settings on the main frame when a load commits that wasn't initiated from a reload - 1427. By Chris Coulson
-
Fix tst_WebContext_
userScripts. qml in single process - 1428. By Chris Coulson
-
Drop the warning when changing the process model. At this point, single process works well enough to properly support now
- 1429. By Chris Coulson
-
Put shared/ and qt/core/ in to separate components
- 1430. By Chris Coulson
-
Add missing file
- 1431. By Chris Coulson
-
Hide surface_id from Compositor clients
- 1432. By Chris Coulson
-
Remove RendererFrameEv
ictor - it's redundant anyway because we destroy the webview compositor when it's hidden. Now we just drive eviction from the webview compositor. This removes a bogus dependency on GetFormFactorHint - 1433. By Chris Coulson
-
Get rid of CompositorProxy and its implementation - this was only really required when we used a threaded compositor
- 1434. By Chris Coulson
-
Handle null callbacks in CookieStoreUIProxy
- 1435. By Chris Coulson
-
Merge r1169 from lp:oxide/crmaster
- 1436. By Chris Coulson
-
Bump Chromium rev to 638cb45 (51.0.2704.4)
- 1437. By Chris Coulson
-
Move GetGLES2Decoder in to Oxide
- 1438. By Chris Coulson
-
Revert r1433 for causing crashes
- 1439. By Chris Coulson
-
Extend test timeout again, as it still times out occasionally for me
- 1440. By Chris Coulson
-
Get rid of CompositorProxy and its implementation - this was only really required when we used a threaded compositor
- 1441. By Chris Coulson
-
Fix tst_NavigationR
equest triggers renderer crash - 1442. By Olivier Tilloy
-
Add a 'version' and a 'chromiumVersion' properties to the Oxide global object.
- 1443. By Chris Coulson
-
Depend on gles2_utils
- 1444. By Chris Coulson
-
Get rid of Compositor:
:IsActive - 1445. By Olivier Tilloy
-
Add a WebView.zoomFactor property to the QML API.
- 1446. By Chris Coulson
-
Bump Chromium rev to da6ce57 (51.0.2704.7)
- 1447. By Chris Coulson
-
Expand testing capability - this adds 2 new test suites:
- API unit tests (qt/tests/unit). These are compiled unit tests for public APIs and are expected to be fairly limited in scope, and not require a full browser process.
- Internal unit tests. This will allow unit testing of internal classes that can be tested without requiring a full browser process.
I've not added many tests yet - future commits will expand on these.There's still a hole in test capability - testing internal classes that require a full browser process. For these, I plan to add a test shell binary that will allow this.
- 1448. By Olivier Tilloy
-
Gracefully handle the case where glGetString(
GL_SHADING_ LANGUAGE_ VERSION) returns a null pointer. - 1449. By Chris Coulson
-
CertificateErro
rDispatcherClie nt only has a single method, so just convert it in to a callback. In addition to that, add thorough unit tests for CertificateErro rDispatcher - 1450. By Chris Coulson
-
Fix mistake in shared.gyp
- 1451. By Chris Coulson
-
Bump Chromium rev to 87b5ef8 (51.0.2704.19)
- 1452. By Chris Coulson
-
Switch from scoped_ptr to std::unique_ptr
- 1453. By Alexandre Abreu
-
Add support for device id constraint support in getusermedia
- 1454. By Chris Coulson
-
Move various files to shared/browser/ssl
- 1455. By Chris Coulson
-
When creating a new WebContents via CreateNewWindow, WebContentsView
::RenderViewHos tChanged is called before the associated RWHV is created which means we don't attach its surface layer to the webview compositor. Fix this by ensuring this happens when we create the RWHV - 1456. By Chris Coulson
-
Provide a dummy message for BeforeUnloadDialog components for compatibility purposes
- 1457. By Chris Coulson
-
Bump qt version to 1.16.0
- 1458. By Chris Coulson
-
Ensure we resize / rescale the webview compositor viewport when the screen is updated
- 1459. By Chris Coulson
-
Merge r1188 from lp:oxide/crmaster
- 1460. By Olivier Tilloy
-
Internationalize the user-facing strings for the names of the cameras.
- 1461. By Olivier Tilloy
-
Fix FTBFS with media-hub enabled.
- 1462. By Chris Coulson
-
Scale the location bar height when the screen changes
- 1463. By Chris Coulson
-
Split SecurityStatus out of WebView, and add extensive unit tests for this code
- 1464. By Chris Coulson
-
Correctly namespace the exising unit tests, and also get the arguments to the EXPECT_* and ASSERT_* macros the correct way around
- 1465. By Chris Coulson
-
Update oxide_enum_flags.h with the code from Firefox
- 1466. By Chris Coulson
-
Add simple unit tests for SSLHostStateDel
egate - 1467. By Chris Coulson
-
Use the proper cmake variables for imported libraries rather than using the names directly
- 1468. By Chris Coulson
-
QOpenGLFunctions uses GLESv2 symbols inline in Qt builds that define QT_OPENGL_ES_2. Ensure libOxideQtQuick
.so.0 links against libGLESv2 in this case - 1469. By Chris Coulson
-
Add missing find_package(
Qt5Gui) - 1470. By Alexandre Abreu
-
Fix the name of the archive created by test-package - it's not bzip2 compressed
- 1471. By Alexandre Abreu
-
Fix v8::SetHiddenValue, v8::CallbackData & v8::TryCatch() deprecations
Chris Coulson (chrisccoulson) : | # |
Preview Diff
1 | === modified file 'shared/renderer/oxide_script_message_handler_renderer.cc' | |||
2 | --- shared/renderer/oxide_script_message_handler_renderer.cc 2016-04-20 22:09:41 +0000 | |||
3 | +++ shared/renderer/oxide_script_message_handler_renderer.cc 2016-05-10 18:23:17 +0000 | |||
4 | @@ -46,10 +46,11 @@ | |||
5 | 46 | bool ScriptMessageHandlerRenderer::ReceiveMessageCallback( | 46 | bool ScriptMessageHandlerRenderer::ReceiveMessageCallback( |
6 | 47 | ScriptMessage* message, | 47 | ScriptMessage* message, |
7 | 48 | std::unique_ptr<base::Value>* error_payload) { | 48 | std::unique_ptr<base::Value>* error_payload) { |
9 | 49 | v8::HandleScope handle_scope(manager_->isolate()); | 49 | v8::Isolate* isolate = manager_->isolate(); |
10 | 50 | v8::HandleScope handle_scope(isolate); | ||
11 | 50 | v8::Context::Scope context_scope(manager_->GetV8Context()); | 51 | v8::Context::Scope context_scope(manager_->GetV8Context()); |
12 | 51 | 52 | ||
14 | 52 | v8::Handle<v8::Function> function(callback_.NewHandle(manager_->isolate())); | 53 | v8::Handle<v8::Function> function(callback_.NewHandle(isolate)); |
15 | 53 | 54 | ||
16 | 54 | ScriptMessageImplRenderer* m = | 55 | ScriptMessageImplRenderer* m = |
17 | 55 | static_cast<ScriptMessageImplRenderer *>(message); | 56 | static_cast<ScriptMessageImplRenderer *>(message); |
18 | @@ -58,9 +59,9 @@ | |||
19 | 58 | m->GetHandle() | 59 | m->GetHandle() |
20 | 59 | }; | 60 | }; |
21 | 60 | 61 | ||
23 | 61 | v8::TryCatch try_catch; | 62 | v8::TryCatch try_catch(isolate); |
24 | 62 | { | 63 | { |
26 | 63 | v8::MicrotasksScope microtasks(manager_->isolate(), | 64 | v8::MicrotasksScope microtasks(isolate, |
27 | 64 | v8::MicrotasksScope::kDoNotRunMicrotasks); | 65 | v8::MicrotasksScope::kDoNotRunMicrotasks); |
28 | 65 | manager_->frame()->GetWebFrame()->callFunctionEvenIfScriptDisabled( | 66 | manager_->frame()->GetWebFrame()->callFunctionEvenIfScriptDisabled( |
29 | 66 | function, manager_->GetV8Context()->Global(), arraysize(argv), argv); | 67 | function, manager_->GetV8Context()->Global(), arraysize(argv), argv); |
30 | 67 | 68 | ||
31 | === modified file 'shared/renderer/oxide_script_message_manager.cc' | |||
32 | --- shared/renderer/oxide_script_message_manager.cc 2016-04-20 22:09:41 +0000 | |||
33 | +++ shared/renderer/oxide_script_message_manager.cc 2016-05-10 18:23:17 +0000 | |||
34 | @@ -124,7 +124,7 @@ | |||
35 | 124 | v8::MicrotasksScope microstasks(isolate, | 124 | v8::MicrotasksScope microstasks(isolate, |
36 | 125 | v8::MicrotasksScope::kDoNotRunMicrotasks); | 125 | v8::MicrotasksScope::kDoNotRunMicrotasks); |
37 | 126 | 126 | ||
39 | 127 | v8::TryCatch try_catch; | 127 | v8::TryCatch try_catch(isolate); |
40 | 128 | v8::Local<v8::Function> function(script->Run().As<v8::Function>()); | 128 | v8::Local<v8::Function> function(script->Run().As<v8::Function>()); |
41 | 129 | if (try_catch.HasCaught()) { | 129 | if (try_catch.HasCaught()) { |
42 | 130 | LOG(ERROR) << "Caught exception when running script"; | 130 | LOG(ERROR) << "Caught exception when running script"; |
43 | 131 | 131 | ||
44 | === modified file 'shared/renderer/oxide_script_message_request_impl_renderer.cc' | |||
45 | --- shared/renderer/oxide_script_message_request_impl_renderer.cc 2016-04-20 22:09:41 +0000 | |||
46 | +++ shared/renderer/oxide_script_message_request_impl_renderer.cc 2016-05-10 18:23:17 +0000 | |||
47 | @@ -40,7 +40,7 @@ | |||
48 | 40 | v8::Handle<v8::Function> function, | 40 | v8::Handle<v8::Function> function, |
49 | 41 | int argc, | 41 | int argc, |
50 | 42 | v8::Local<v8::Value> argv[]) { | 42 | v8::Local<v8::Value> argv[]) { |
52 | 43 | v8::TryCatch try_catch; | 43 | v8::TryCatch try_catch(manager()->isolate()); |
53 | 44 | { | 44 | { |
54 | 45 | v8::MicrotasksScope microtasks(manager()->isolate(), | 45 | v8::MicrotasksScope microtasks(manager()->isolate(), |
55 | 46 | v8::MicrotasksScope::kDoNotRunMicrotasks); | 46 | v8::MicrotasksScope::kDoNotRunMicrotasks); |
56 | 47 | 47 | ||
57 | === modified file 'shared/renderer/oxide_script_referenced_object.cc' | |||
58 | --- shared/renderer/oxide_script_referenced_object.cc 2015-01-16 22:46:17 +0000 | |||
59 | +++ shared/renderer/oxide_script_referenced_object.cc 2016-05-10 18:23:17 +0000 | |||
60 | @@ -39,9 +39,12 @@ | |||
61 | 39 | data_.reset(isolate, v8::External::New(isolate, this)); | 39 | data_.reset(isolate, v8::External::New(isolate, this)); |
62 | 40 | 40 | ||
63 | 41 | if (!handle.IsEmpty()) { | 41 | if (!handle.IsEmpty()) { |
67 | 42 | handle->SetHiddenValue( | 42 | handle->SetPrivate( |
68 | 43 | v8::String::NewFromUtf8(isolate, kWrappedNativeObject), | 43 | manager_->GetV8Context(), |
69 | 44 | data_.NewHandle(isolate)); | 44 | v8::Private::ForApi( |
70 | 45 | isolate, | ||
71 | 46 | v8::String::NewFromUtf8(isolate, kWrappedNativeObject)), | ||
72 | 47 | data_.NewHandle(isolate)).FromJust(); | ||
73 | 45 | } | 48 | } |
74 | 46 | } | 49 | } |
75 | 47 | 50 | ||
76 | @@ -60,14 +63,20 @@ | |||
77 | 60 | v8::Isolate* isolate = v8::Isolate::GetCurrent(); | 63 | v8::Isolate* isolate = v8::Isolate::GetCurrent(); |
78 | 61 | v8::HandleScope handle_scope(isolate); | 64 | v8::HandleScope handle_scope(isolate); |
79 | 62 | 65 | ||
83 | 63 | v8::Local<v8::Value> val(handle->GetHiddenValue( | 66 | v8::Local<v8::Value> value; |
84 | 64 | v8::String::NewFromUtf8(isolate, kWrappedNativeObject))); | 67 | handle->GetPrivate( |
85 | 65 | if (val.IsEmpty() || !val->IsExternal()) { | 68 | isolate->GetCallingContext(), |
86 | 69 | v8::Private::ForApi( | ||
87 | 70 | isolate, | ||
88 | 71 | v8::String::NewFromUtf8(isolate, kWrappedNativeObject))) | ||
89 | 72 | .ToLocal(&value); | ||
90 | 73 | |||
91 | 74 | if (value.IsEmpty() || !value->IsExternal()) { | ||
92 | 66 | return nullptr; | 75 | return nullptr; |
93 | 67 | } | 76 | } |
94 | 68 | 77 | ||
95 | 69 | return reinterpret_cast<ScriptReferencedObjectBase *>( | 78 | return reinterpret_cast<ScriptReferencedObjectBase *>( |
97 | 70 | val.As<v8::External>()->Value()); | 79 | value.As<v8::External>()->Value()); |
98 | 71 | } | 80 | } |
99 | 72 | 81 | ||
100 | 73 | } // namespace oxide | 82 | } // namespace oxide |
101 | 74 | 83 | ||
102 | === modified file 'shared/renderer/oxide_script_referenced_object.h' | |||
103 | --- shared/renderer/oxide_script_referenced_object.h 2016-01-04 13:40:25 +0000 | |||
104 | +++ shared/renderer/oxide_script_referenced_object.h 2016-05-10 18:23:17 +0000 | |||
105 | @@ -53,7 +53,7 @@ | |||
106 | 53 | private: | 53 | private: |
107 | 54 | template <class U> | 54 | template <class U> |
108 | 55 | static void NearDeathCallback( | 55 | static void NearDeathCallback( |
110 | 56 | const v8::WeakCallbackData<v8::Object, scoped_refptr<U> >& data) { | 56 | const v8::WeakCallbackInfo<scoped_refptr<U> >& data) { |
111 | 57 | scoped_refptr<U>* refptr = data.GetParameter(); | 57 | scoped_refptr<U>* refptr = data.GetParameter(); |
112 | 58 | (*refptr)->handle_.reset(); | 58 | (*refptr)->handle_.reset(); |
113 | 59 | delete refptr; | 59 | delete refptr; |
114 | 60 | 60 | ||
115 | === modified file 'shared/renderer/oxide_user_script_slave.cc' | |||
116 | --- shared/renderer/oxide_user_script_slave.cc 2016-04-20 22:09:41 +0000 | |||
117 | +++ shared/renderer/oxide_user_script_slave.cc 2016-05-10 18:23:17 +0000 | |||
118 | @@ -141,7 +141,7 @@ | |||
119 | 141 | 141 | ||
120 | 142 | v8::Local<v8::Script> script(v8::Script::Compile(wrapped_src)); | 142 | v8::Local<v8::Script> script(v8::Script::Compile(wrapped_src)); |
121 | 143 | 143 | ||
123 | 144 | v8::TryCatch try_catch; | 144 | v8::TryCatch try_catch(isolate); |
124 | 145 | { | 145 | { |
125 | 146 | v8::MicrotasksScope microtasks(isolate, | 146 | v8::MicrotasksScope microtasks(isolate, |
126 | 147 | v8::MicrotasksScope::kDoNotRunMicrotasks); | 147 | v8::MicrotasksScope::kDoNotRunMicrotasks); |
127 | 148 | 148 | ||
128 | === modified file 'shared/renderer/oxide_v8_scoped_persistent.h' | |||
129 | --- shared/renderer/oxide_v8_scoped_persistent.h 2014-02-28 12:53:41 +0000 | |||
130 | +++ shared/renderer/oxide_v8_scoped_persistent.h 2016-05-10 18:23:17 +0000 | |||
131 | @@ -62,8 +62,8 @@ | |||
132 | 62 | 62 | ||
133 | 63 | template <typename P> | 63 | template <typename P> |
134 | 64 | void SetWeak(P* parameters, | 64 | void SetWeak(P* parameters, |
137 | 65 | typename v8::WeakCallbackData<T, P>::Callback callback) { | 65 | typename v8::WeakCallbackInfo<P>::Callback callback) { |
138 | 66 | handle_.SetWeak(parameters, callback); | 66 | handle_.SetWeak(parameters, callback, v8::WeakCallbackType::kParameter); |
139 | 67 | } | 67 | } |
140 | 68 | 68 | ||
141 | 69 | private: | 69 | private: |