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

Issue 11238055: Re-open DevTools windows for PackagedApps if they are reloaded with DevTools open. (Closed)

Created:
8 years, 2 months ago by tapted
Modified:
8 years, 2 months ago
Reviewers:
benwells
CC:
chromium-reviews, Aaron Boodman, chromium-apps-reviews_chromium.org, koz (OOO until 15th September), jeremya
Base URL:
http://git.chromium.org/chromium/src.git@master
Visibility:
Public.

Description

Re-open DevTools windows for PackagedApps if they are reloaded with DevTools open. This augments the ShellWindowRegistry with a set of <extension_id, window_id> keys that were observed to have devtools attached to them, and delays returning to the chrome.app.window.create(..) callback until a new devtools window is open and ready to intercept any breakpoints that were specified in the client code. BUG=153235 TEST=Run packaged App that uses |id| in create(..), Inspect, set breakpoint, reload app. Result: inspector reloads with app. Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=163779

Patch Set 1 : before unit test #

Total comments: 21

Patch Set 2 : reviewer comments #

Patch Set 3 : picky visual stdio #

Patch Set 4 : adds unit test but hits http://crbug.com/157097 on debug builds #

Total comments: 3

Patch Set 5 : more encapsulation, self-nit unit test code, add expected FAILS_ for debug builds #

Total comments: 13

Patch Set 6 : reviewer comments, use MAYBE_ #

Unified diffs Side-by-side diffs Delta from patch set Stats (+211 lines, -12 lines) Patch
M chrome/browser/extensions/api/app_window/app_window_api.h View 1 2 3 4 1 chunk +3 lines, -1 line 0 comments Download
M chrome/browser/extensions/api/app_window/app_window_api.cc View 1 2 3 4 5 3 chunks +57 lines, -1 line 0 comments Download
M chrome/browser/extensions/platform_app_browsertest.cc View 1 2 3 4 5 3 chunks +57 lines, -1 line 0 comments Download
M chrome/browser/extensions/shell_window_registry.h View 5 chunks +19 lines, -2 lines 0 comments Download
M chrome/browser/extensions/shell_window_registry.cc View 1 2 3 chunks +61 lines, -2 lines 0 comments Download
A chrome/test/data/extensions/platform_apps/minimal_id/main.html View 1 2 3 4 1 chunk +10 lines, -0 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/minimal_id/main.js View 1 2 3 4 1 chunk +2 lines, -0 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/minimal_id/manifest.json View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
A + chrome/test/data/extensions/platform_apps/minimal_id/test.js View 1 2 3 4 5 1 chunk +1 line, -4 lines 0 comments Download

Messages

Total messages: 10 (0 generated)
tapted
still investigating a possible/feasible unit test https://codereview.chromium.org/11238055/diff/2001/chrome/browser/extensions/shell_window_registry.h File chrome/browser/extensions/shell_window_registry.h (right): https://codereview.chromium.org/11238055/diff/2001/chrome/browser/extensions/shell_window_registry.h#newcode51 chrome/browser/extensions/shell_window_registry.h:51: typedef std::set<std::string> InspectedWindowSet; ...
8 years, 2 months ago (2012-10-23 06:04:14 UTC) #1
benwells
https://codereview.chromium.org/11238055/diff/2001/chrome/browser/extensions/api/app_window/app_window_api.cc File chrome/browser/extensions/api/app_window/app_window_api.cc (right): https://codereview.chromium.org/11238055/diff/2001/chrome/browser/extensions/api/app_window/app_window_api.cc#newcode42 chrome/browser/extensions/api/app_window/app_window_api.cc:42: class AppWindowCreateFunction::DelayedResponseForDevTools Hmmm, naming is always hard, but I ...
8 years, 2 months ago (2012-10-23 06:18:48 UTC) #2
tapted
Amalgamate review. Might try adapting my unit test from https://codereview.chromium.org/11190016 ... https://codereview.chromium.org/11238055/diff/2001/chrome/browser/extensions/api/app_window/app_window_api.cc File chrome/browser/extensions/api/app_window/app_window_api.cc (right): ...
8 years, 2 months ago (2012-10-23 07:04:23 UTC) #3
tapted
Unit test for the try-bots, and general feedback, but let me self-nit the additions first, ...
8 years, 2 months ago (2012-10-23 10:16:45 UTC) #4
benwells
https://codereview.chromium.org/11238055/diff/5006/chrome/browser/extensions/platform_app_browsertest.cc File chrome/browser/extensions/platform_app_browsertest.cc (right): https://codereview.chromium.org/11238055/diff/5006/chrome/browser/extensions/platform_app_browsertest.cc#newcode732 chrome/browser/extensions/platform_app_browsertest.cc:732: CloseShellWindow(window); On 2012/10/23 10:16:45, tapted wrote: > This line ...
8 years, 2 months ago (2012-10-23 10:27:13 UTC) #5
tapted
I think this is ready for final review. https://codereview.chromium.org/11238055/diff/5006/chrome/browser/extensions/platform_app_browsertest.cc File chrome/browser/extensions/platform_app_browsertest.cc (right): https://codereview.chromium.org/11238055/diff/5006/chrome/browser/extensions/platform_app_browsertest.cc#newcode732 chrome/browser/extensions/platform_app_browsertest.cc:732: CloseShellWindow(window); ...
8 years, 2 months ago (2012-10-23 23:41:15 UTC) #6
benwells
lgtm with nits and assuming tryjobs are happy http://codereview.chromium.org/11238055/diff/8003/chrome/browser/extensions/api/app_window/app_window_api.cc File chrome/browser/extensions/api/app_window/app_window_api.cc (right): http://codereview.chromium.org/11238055/diff/8003/chrome/browser/extensions/api/app_window/app_window_api.cc#newcode50 chrome/browser/extensions/api/app_window/app_window_api.cc:50: DevToolsWindow::ToggleDevToolsWindow(created_view, ...
8 years, 2 months ago (2012-10-24 03:24:08 UTC) #7
tapted
scraping logs, stdio on {linux,mac,win}{,rel} suggest that PlatformAppBrowserTest.{FAILS_,}DevToolsOpenedWithReload is content with this approach, even though ...
8 years, 2 months ago (2012-10-24 04:03:57 UTC) #8
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/tapted@chromium.org/11238055/19002
8 years, 2 months ago (2012-10-24 04:06:02 UTC) #9
commit-bot: I haz the power
8 years, 2 months ago (2012-10-24 06:14:25 UTC) #10
Change committed as 163779

Powered by Google App Engine
This is Rietveld 408576698