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

Issue 490783002: Handle closing web contents in ExtensionOptionsGuest (Closed)

Created:
6 years, 4 months ago by ericzeng
Modified:
6 years, 4 months ago
CC:
chromium-reviews, chromium-apps-reviews_chromium.org, arv+watch_chromium.org, extensions-reviews_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Project:
chromium
Visibility:
Public.

Description

Handle closing web contents in ExtensionOptionsGuest Implement CloseContents for ExtensionOptionsGuest. CloseContents propagates a 'close' event up to the <extensionoptions> node. In WebUI, when the extension options overlay receives this event, it will close the overlay. Extension options pages that used window.close() to close their tab in the old options page UI will now close their embedder overlay. BUG=386842, 386838 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=291554

Patch Set 1 #

Total comments: 7

Patch Set 2 : Address comments #

Patch Set 3 : Add tests for detecting onclose event in WebUI #

Total comments: 2

Patch Set 4 : Address nit #

Patch Set 5 : Rebase #

Patch Set 6 : Rebase #

Patch Set 7 : Fix rebasing error #

Patch Set 8 : Fix rebasing again #

Patch Set 9 : Still cleaning up bad rebase #

Patch Set 10 : Rebase #

Unified diffs Side-by-side diffs Delta from patch set Stats (+89 lines, -4 lines) Patch
M chrome/browser/extensions/extension_webui_apitest.cc View 1 2 3 4 1 chunk +18 lines, -0 lines 0 comments Download
M chrome/browser/guest_view/extension_options/extension_options_guest.h View 1 2 3 4 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/guest_view/extension_options/extension_options_guest.cc View 1 2 3 4 1 chunk +6 lines, -0 lines 0 comments Download
M chrome/browser/resources/extensions/extension_options_overlay.html View 1 6 7 8 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/resources/extensions/extension_options_overlay.js View 1 6 7 2 chunks +10 lines, -3 lines 0 comments Download
M chrome/common/extensions/api/extension_options_internal.idl View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/renderer/resources/extensions/extension_options_events.js View 1 chunk +4 lines, -0 lines 0 comments Download
A chrome/test/data/extensions/api_test/extension_options/close_self/manifest.json View 1 2 1 chunk +10 lines, -0 lines 0 comments Download
A chrome/test/data/extensions/api_test/extension_options/close_self/options.html View 1 2 1 chunk +10 lines, -0 lines 0 comments Download
A chrome/test/data/extensions/api_test/extension_options/close_self/options.js View 1 2 1 chunk +5 lines, -0 lines 0 comments Download
A chrome/test/data/extensions/webui/receives_extension_options_on_close.js View 1 2 3 1 chunk +23 lines, -0 lines 0 comments Download

Messages

Total messages: 35 (0 generated)
ericzeng
PTAL
6 years, 4 months ago (2014-08-20 00:53:33 UTC) #1
not at google - send to devlin
Test that the event fires for the embedder? https://codereview.chromium.org/490783002/diff/1/chrome/browser/guest_view/extension_options/extension_options_guest.cc File chrome/browser/guest_view/extension_options/extension_options_guest.cc (right): https://codereview.chromium.org/490783002/diff/1/chrome/browser/guest_view/extension_options/extension_options_guest.cc#newcode184 chrome/browser/guest_view/extension_options/extension_options_guest.cc:184: extension_options_internal::OnClose::kEventName, ...
6 years, 4 months ago (2014-08-20 02:16:37 UTC) #2
Fady Samuel
https://codereview.chromium.org/490783002/diff/1/chrome/browser/resources/extensions/extension_options_overlay.js File chrome/browser/resources/extensions/extension_options_overlay.js (right): https://codereview.chromium.org/490783002/diff/1/chrome/browser/resources/extensions/extension_options_overlay.js#newcode50 chrome/browser/resources/extensions/extension_options_overlay.js:50: var extensionoptions = document.querySelector('extensionoptions'); This is weird to me. ...
6 years, 4 months ago (2014-08-20 14:53:55 UTC) #3
not at google - send to devlin
https://codereview.chromium.org/490783002/diff/1/chrome/browser/resources/extensions/extension_options_overlay.js File chrome/browser/resources/extensions/extension_options_overlay.js (right): https://codereview.chromium.org/490783002/diff/1/chrome/browser/resources/extensions/extension_options_overlay.js#newcode50 chrome/browser/resources/extensions/extension_options_overlay.js:50: var extensionoptions = document.querySelector('extensionoptions'); On 2014/08/20 14:53:55, Fady Samuel ...
6 years, 4 months ago (2014-08-20 14:56:48 UTC) #4
ericzeng
https://codereview.chromium.org/490783002/diff/1/chrome/browser/guest_view/extension_options/extension_options_guest.cc File chrome/browser/guest_view/extension_options/extension_options_guest.cc (right): https://codereview.chromium.org/490783002/diff/1/chrome/browser/guest_view/extension_options/extension_options_guest.cc#newcode184 chrome/browser/guest_view/extension_options/extension_options_guest.cc:184: extension_options_internal::OnClose::kEventName, args.Pass())); On 2014/08/20 02:16:37, kalman wrote: > Inline ...
6 years, 4 months ago (2014-08-20 17:26:01 UTC) #5
ericzeng
ping, added a simple test to check if WebUI can see the onclose event from ...
6 years, 4 months ago (2014-08-21 18:58:55 UTC) #6
Fady Samuel
guest_view lgtm
6 years, 4 months ago (2014-08-21 19:00:04 UTC) #7
not at google - send to devlin
lgtm https://codereview.chromium.org/490783002/diff/40001/chrome/test/data/extensions/webui/receives_extension_options_on_close.js File chrome/test/data/extensions/webui/receives_extension_options_on_close.js (right): https://codereview.chromium.org/490783002/diff/40001/chrome/test/data/extensions/webui/receives_extension_options_on_close.js#newcode18 chrome/test/data/extensions/webui/receives_extension_options_on_close.js:18: } ;
6 years, 4 months ago (2014-08-21 19:05:18 UTC) #8
ericzeng
https://codereview.chromium.org/490783002/diff/40001/chrome/test/data/extensions/webui/receives_extension_options_on_close.js File chrome/test/data/extensions/webui/receives_extension_options_on_close.js (right): https://codereview.chromium.org/490783002/diff/40001/chrome/test/data/extensions/webui/receives_extension_options_on_close.js#newcode18 chrome/test/data/extensions/webui/receives_extension_options_on_close.js:18: } On 2014/08/21 19:05:18, kalman wrote: > ; Done.
6 years, 4 months ago (2014-08-21 19:07:53 UTC) #9
ericzeng
The CQ bit was checked by ericzeng@chromium.org
6 years, 4 months ago (2014-08-21 19:10:32 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/ericzeng@chromium.org/490783002/60001
6 years, 4 months ago (2014-08-21 19:12:29 UTC) #11
commit-bot: I haz the power
FYI, CQ is re-trying this CL (attempt #1). The failing builders are: linux_chromium_rel_swarming on tryserver.chromium.linux ...
6 years, 4 months ago (2014-08-21 23:45:16 UTC) #12
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 4 months ago (2014-08-21 23:50:58 UTC) #13
commit-bot: I haz the power
Try jobs failed on following builders: linux_chromium_rel_swarming on tryserver.chromium.linux (http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_rel_swarming/builds/8868)
6 years, 4 months ago (2014-08-21 23:50:59 UTC) #14
ericzeng
The CQ bit was checked by ericzeng@chromium.org
6 years, 4 months ago (2014-08-22 00:48:20 UTC) #15
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/ericzeng@chromium.org/490783002/80001
6 years, 4 months ago (2014-08-22 00:50:43 UTC) #16
commit-bot: I haz the power
FYI, CQ is re-trying this CL (attempt #1). The failing builders are: android_chromium_gn_compile_rel on tryserver.chromium.linux ...
6 years, 4 months ago (2014-08-22 01:48:10 UTC) #17
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 4 months ago (2014-08-22 01:51:42 UTC) #18
commit-bot: I haz the power
Try jobs failed on following builders: android_chromium_gn_compile_rel on tryserver.chromium.linux (http://build.chromium.org/p/tryserver.chromium.linux/builders/android_chromium_gn_compile_rel/builds/8325)
6 years, 4 months ago (2014-08-22 01:51:43 UTC) #19
ericzeng
The CQ bit was checked by ericzeng@chromium.org
6 years, 4 months ago (2014-08-22 02:00:56 UTC) #20
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/ericzeng@chromium.org/490783002/80001
6 years, 4 months ago (2014-08-22 02:02:28 UTC) #21
commit-bot: I haz the power
FYI, CQ is re-trying this CL (attempt #1). The failing builders are: android_chromium_gn_compile_rel on tryserver.chromium.linux ...
6 years, 4 months ago (2014-08-22 02:06:23 UTC) #22
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 4 months ago (2014-08-22 02:09:51 UTC) #23
commit-bot: I haz the power
Try jobs failed on following builders: android_chromium_gn_compile_rel on tryserver.chromium.linux (http://build.chromium.org/p/tryserver.chromium.linux/builders/android_chromium_gn_compile_rel/builds/8335)
6 years, 4 months ago (2014-08-22 02:09:52 UTC) #24
ericzeng
The CQ bit was checked by ericzeng@chromium.org
6 years, 4 months ago (2014-08-22 19:28:09 UTC) #25
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/ericzeng@chromium.org/490783002/140001
6 years, 4 months ago (2014-08-22 19:29:02 UTC) #26
ericzeng
The CQ bit was unchecked by ericzeng@chromium.org
6 years, 4 months ago (2014-08-22 19:41:22 UTC) #27
ericzeng
The CQ bit was checked by ericzeng@chromium.org
6 years, 4 months ago (2014-08-22 19:52:28 UTC) #28
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/ericzeng@chromium.org/490783002/160001
6 years, 4 months ago (2014-08-22 19:53:27 UTC) #29
commit-bot: I haz the power
FYI, CQ is re-trying this CL (attempt #1). The failing builders are: android_chromium_gn_compile_rel on tryserver.chromium.linux ...
6 years, 4 months ago (2014-08-22 21:10:03 UTC) #30
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 4 months ago (2014-08-22 21:11:59 UTC) #31
commit-bot: I haz the power
Try jobs failed on following builders: android_chromium_gn_compile_rel on tryserver.chromium.linux (http://build.chromium.org/p/tryserver.chromium.linux/builders/android_chromium_gn_compile_rel/builds/8759)
6 years, 4 months ago (2014-08-22 21:12:00 UTC) #32
ericzeng
The CQ bit was checked by ericzeng@chromium.org
6 years, 4 months ago (2014-08-22 21:56:53 UTC) #33
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/ericzeng@chromium.org/490783002/180001
6 years, 4 months ago (2014-08-22 21:57:57 UTC) #34
commit-bot: I haz the power
6 years, 4 months ago (2014-08-22 23:32:42 UTC) #35
Message was sent while issue was closed.
Committed patchset #10 (180001) as 291554

Powered by Google App Engine
This is Rietveld 408576698