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

Issue 11399002: Implemented GetWindowSnapshot on RenderViewImpl (Closed)

Created:
8 years, 1 month ago by bajones
Modified:
8 years ago
CC:
chromium-reviews, joi+watch-content_chromium.org, darin-cc_chromium.org, piman
Base URL:
http://git.chromium.org/chromium/src.git@master
Visibility:
Public.

Description

Implemented GetWindowSnapshot on RenderViewImpl This necessitated the relocation of the previous chrome::GrabWindowSnapshot code to ui/snapshot, which has been turned into it's own component to avoid circular dependencies with aura. A new variant of GrabWindowSnapshot, GrabViewSnapshot, has been added as well to facilitate easier usage by views. chrome::GrabWindowSnapshotForUser was left in place to accomodate existing calls to the API, but now calls up to the ui/snapshot code. This is a subset of the prior CL 11362023, which has been broken apart to facilitate easier reviews BUG=157479 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=173329

Patch Set 1 #

Total comments: 10

Patch Set 2 : Addressing nits #

Total comments: 1

Patch Set 3 : Moved snapshot files to ui/base #

Total comments: 2

Patch Set 4 : Addressing feedback #

Patch Set 5 : Added comment about security concerns to OnGetWindowSnapshot #

Patch Set 6 : Fixed namespace issue in tests #

Patch Set 7 : Trying to fix clobber issues #

Patch Set 8 : Added stub snapshot function for Android #

Patch Set 9 : Trying to appease the angry trybot Gods #

Patch Set 10 : Android Window/View are note the same type #

Patch Set 11 : Fixed aura snapshot circular dependency #

Total comments: 4

Patch Set 12 : Addressing nits #

Total comments: 1

Patch Set 13 : Resolved dependency issues #

Total comments: 5

Patch Set 14 : fixed gyp typos #

Patch Set 15 : Addressing nit, fixed unit test #

Total comments: 1

Patch Set 16 : Added snapshot DEPS file #

Patch Set 17 : Added stub methods for iOS #

Unified diffs Side-by-side diffs Delta from patch set Stats (+330 lines, -423 lines) Patch
M chrome/browser/ui/window_snapshot/window_snapshot.h View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +1 line, -13 lines 0 comments Download
M chrome/browser/ui/window_snapshot/window_snapshot.cc View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +4 lines, -3 lines 0 comments Download
D chrome/browser/ui/window_snapshot/window_snapshot_aura.cc View 1 2 3 11 12 1 chunk +0 lines, -54 lines 0 comments Download
D chrome/browser/ui/window_snapshot/window_snapshot_gtk.cc View 1 chunk +0 lines, -80 lines 0 comments Download
D chrome/browser/ui/window_snapshot/window_snapshot_mac.mm View 1 chunk +0 lines, -62 lines 0 comments Download
D chrome/browser/ui/window_snapshot/window_snapshot_mac_unittest.mm View 1 chunk +0 lines, -62 lines 0 comments Download
D chrome/browser/ui/window_snapshot/window_snapshot_win.cc View 1 chunk +0 lines, -102 lines 0 comments Download
M chrome/chrome_browser_ui.gypi View 1 2 3 4 5 6 7 8 9 10 11 12 13 3 chunks +1 line, -5 lines 0 comments Download
M chrome/chrome_tests_unit.gypi View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +0 lines, -1 line 0 comments Download
M chrome/test/base/ui_test_utils.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 3 chunks +2 lines, -2 lines 0 comments Download
M content/DEPS View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +1 line, -0 lines 0 comments Download
M content/browser/renderer_host/render_view_host_impl.h View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +1 line, -0 lines 0 comments Download
M content/browser/renderer_host/render_view_host_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 3 chunks +25 lines, -0 lines 0 comments Download
M content/common/view_messages.h View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +10 lines, -0 lines 0 comments Download
M content/content_browser.gypi View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +1 line, -0 lines 0 comments Download
M content/renderer/render_view_impl.h View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +16 lines, -0 lines 0 comments Download
M content/renderer/render_view_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 3 chunks +17 lines, -0 lines 0 comments Download
A ui/snapshot/DEPS View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1 chunk +7 lines, -0 lines 0 comments Download
A ui/snapshot/snapshot.h View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +34 lines, -0 lines 0 comments Download
A ui/snapshot/snapshot.gyp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 1 chunk +65 lines, -0 lines 0 comments Download
A ui/snapshot/snapshot_android.cc View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +25 lines, -0 lines 0 comments Download
A + ui/snapshot/snapshot_aura.cc View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +9 lines, -5 lines 0 comments Download
A ui/snapshot/snapshot_export.h View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +32 lines, -0 lines 0 comments Download
A + ui/snapshot/snapshot_gtk.cc View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +12 lines, -7 lines 0 comments Download
A ui/snapshot/snapshot_ios.mm View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 1 chunk +25 lines, -0 lines 0 comments Download
A + ui/snapshot/snapshot_mac.mm View 1 2 3 4 5 6 7 8 9 10 11 12 13 3 chunks +29 lines, -18 lines 0 comments Download
A + ui/snapshot/snapshot_mac_unittest.mm View 1 2 3 4 5 6 7 8 9 10 11 12 4 chunks +4 lines, -4 lines 0 comments Download
A + ui/snapshot/snapshot_win.cc View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +9 lines, -5 lines 0 comments Download

Messages

Total messages: 59 (0 generated)
bajones
8 years, 1 month ago (2012-11-08 21:03:22 UTC) #1
Ken Russell (switch to Gerrit)
Basically LGTM but there is one bug you need to fix. https://codereview.chromium.org/11399002/diff/1/content/common/view_messages.h File content/common/view_messages.h (right): ...
8 years, 1 month ago (2012-11-08 22:27:44 UTC) #2
jam
just nits and one question: it looks like the the moved code doesn't have any ...
8 years, 1 month ago (2012-11-09 02:21:29 UTC) #3
bajones
Nits addressed. Sorry, still getting acclimated to the code style!
8 years, 1 month ago (2012-11-09 18:02:51 UTC) #4
Ben Goodger (Google)
the location seems fine to me.
8 years, 1 month ago (2012-11-12 18:23:16 UTC) #5
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/bajones@chromium.org/11399002/10001
8 years, 1 month ago (2012-11-12 18:26:53 UTC) #6
commit-bot: I haz the power
Presubmit check for 11399002-10001 failed and returned exit status 1. Running presubmit commit checks ...
8 years, 1 month ago (2012-11-12 18:27:01 UTC) #7
bajones
Could I get a thumbs up and/or further comments from the directory owners?
8 years, 1 month ago (2012-11-12 18:37:18 UTC) #8
jamesr
lgtm http://codereview.chromium.org/11399002/diff/10001/content/renderer/render_view_impl.cc File content/renderer/render_view_impl.cc (right): http://codereview.chromium.org/11399002/diff/10001/content/renderer/render_view_impl.cc#newcode1720 content/renderer/render_view_impl.cc:1720: void RenderViewImpl::OnWindowSnapshotCompleted(const int snapshot_id, we don't typically use ...
8 years, 1 month ago (2012-11-12 18:41:15 UTC) #9
jamesr
On 2012/11/12 18:41:15, jamesr wrote: > lgtm for content/renderer/, that is. I have no powers ...
8 years, 1 month ago (2012-11-12 18:41:39 UTC) #10
Ben Goodger (Google)
jam and I agreed ui/base would be a good place for this.
8 years, 1 month ago (2012-11-12 21:07:34 UTC) #11
jam
On 2012/11/12 21:07:34, Ben Goodger (Google) wrote: > jam and I agreed ui/base would be ...
8 years, 1 month ago (2012-11-12 21:09:26 UTC) #12
bajones
The snapshot files have been relocated to ui/base as requested.
8 years, 1 month ago (2012-11-14 21:52:49 UTC) #13
jam
content lgtm https://codereview.chromium.org/11399002/diff/14003/content/common/view_messages.h File content/common/view_messages.h (right): https://codereview.chromium.org/11399002/diff/14003/content/common/view_messages.h#newcode1937 content/common/view_messages.h:1937: IPC_MESSAGE_ROUTED3(ViewMsg_WindowSnapshotCompleted, nit: this should go with the ...
8 years, 1 month ago (2012-11-15 01:05:58 UTC) #14
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/bajones@chromium.org/11399002/16001
8 years ago (2012-11-26 21:10:23 UTC) #15
commit-bot: I haz the power
Presubmit check for 11399002-16001 failed and returned exit status 1. Running presubmit commit checks ...
8 years ago (2012-11-26 21:10:45 UTC) #16
bajones
Looks like I still need a security review on view_messages.h and an LGTM from ben@ ...
8 years ago (2012-11-26 21:18:19 UTC) #17
Tom Sepez
Won't this become a security issue once we move to a world with proper process ...
8 years ago (2012-11-26 21:25:47 UTC) #18
jschuh
On 2012/11/26 21:25:47, Tom Sepez wrote: > Won't this become a security issue once we ...
8 years ago (2012-11-26 21:31:00 UTC) #19
bajones
On 2012/11/26 21:31:00, Justin Schuh wrote: > On 2012/11/26 21:25:47, Tom Sepez wrote: > > ...
8 years ago (2012-11-26 21:36:12 UTC) #20
Tom Sepez
Ah. It's behind kEnableGPUBenchmarking. Two things: RenderViewHostImpl::OnGetWindowSnapshot() probably should have a comment saying that this ...
8 years ago (2012-11-26 21:37:35 UTC) #21
Tom Sepez
Otherwise, messages LGTM apart from those comments.
8 years ago (2012-11-26 21:38:30 UTC) #22
Ben Goodger (Google)
Nice move. LGTM.
8 years ago (2012-11-27 17:36:38 UTC) #23
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/bajones@chromium.org/11399002/24001
8 years ago (2012-11-27 18:06:49 UTC) #24
commit-bot: I haz the power
Sorry for I got bad news for ya. Compile failed with a clobber build on ...
8 years ago (2012-11-27 18:27:51 UTC) #25
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/bajones@chromium.org/11399002/22002
8 years ago (2012-11-28 01:25:35 UTC) #26
commit-bot: I haz the power
Sorry for I got bad news for ya. Compile failed with a clobber build on ...
8 years ago (2012-11-28 02:09:12 UTC) #27
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/bajones@chromium.org/11399002/24006
8 years ago (2012-11-28 18:25:30 UTC) #28
commit-bot: I haz the power
Sorry for I got bad news for ya. Compile failed with a clobber build on ...
8 years ago (2012-11-28 19:02:45 UTC) #29
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/bajones@chromium.org/11399002/22074
8 years ago (2012-11-29 05:52:13 UTC) #30
commit-bot: I haz the power
Retried try job too often on win_aura for step(s) aura_unittests, content_browsertests, content_unittests, views_unittests
8 years ago (2012-11-29 06:19:25 UTC) #31
bajones
Previous patch set had circular dependency issues in the Aura implementation that weren't seen until ...
8 years ago (2012-11-30 22:15:31 UTC) #32
Ken Russell (switch to Gerrit)
LGTM again. Nice work pushing this through. Couple of minor comments. https://chromiumcodereview.appspot.com/11399002/diff/18087/content/browser/renderer_host/render_view_host_impl.cc File content/browser/renderer_host/render_view_host_impl.cc (right): ...
8 years ago (2012-11-30 22:32:54 UTC) #33
jam
On 2012/11/30 22:15:31, bajones wrote: > Previous patch set had circular dependency issues in the ...
8 years ago (2012-11-30 23:07:18 UTC) #34
Ken Russell (switch to Gerrit)
On 2012/11/30 23:07:18, John Abd-El-Malek wrote: > On 2012/11/30 22:15:31, bajones wrote: > > Previous ...
8 years ago (2012-11-30 23:10:51 UTC) #35
jam
On 2012/11/30 23:10:51, kbr wrote: > On 2012/11/30 23:07:18, John Abd-El-Malek wrote: > > On ...
8 years ago (2012-12-01 00:16:07 UTC) #36
Ken Russell (switch to Gerrit)
On 2012/12/01 00:16:07, John Abd-El-Malek wrote: > On 2012/11/30 23:10:51, kbr wrote: > > On ...
8 years ago (2012-12-01 00:26:57 UTC) #37
jam
On 2012/12/01 00:26:57, kbr wrote: > On 2012/12/01 00:16:07, John Abd-El-Malek wrote: > > On ...
8 years ago (2012-12-01 00:33:40 UTC) #38
Ken Russell (switch to Gerrit)
On 2012/12/01 00:33:40, John Abd-El-Malek wrote: > On 2012/12/01 00:26:57, kbr wrote: > > On ...
8 years ago (2012-12-01 03:22:03 UTC) #39
piman
https://chromiumcodereview.appspot.com/11399002/diff/20008/content/browser/renderer_host/render_view_host_impl.cc File content/browser/renderer_host/render_view_host_impl.cc (right): https://chromiumcodereview.appspot.com/11399002/diff/20008/content/browser/renderer_host/render_view_host_impl.cc#newcode2052 content/browser/renderer_host/render_view_host_impl.cc:2052: if (ui::GrabViewSnapshot(GetView()->GetNativeView(), Why not delegating to the view here, ...
8 years ago (2012-12-04 00:05:47 UTC) #40
bajones
Okay, let's try and get this one pushed through once and for all! The dependency ...
8 years ago (2012-12-12 23:31:10 UTC) #41
Ken Russell (switch to Gerrit)
On 2012/12/12 23:31:10, bajones wrote: > Okay, let's try and get this one pushed through ...
8 years ago (2012-12-12 23:32:37 UTC) #42
Nico
On 2012/12/12 23:31:10, bajones wrote: > Okay, let's try and get this one pushed through ...
8 years ago (2012-12-12 23:35:29 UTC) #43
bajones
On 2012/12/12 23:35:29, Nico wrote: > On 2012/12/12 23:31:10, bajones wrote: > > Okay, let's ...
8 years ago (2012-12-12 23:39:13 UTC) #44
Ken Russell (switch to Gerrit)
LGTM https://chromiumcodereview.appspot.com/11399002/diff/33001/ui/snapshot/snapshot_mac.mm File ui/snapshot/snapshot_mac.mm (right): https://chromiumcodereview.appspot.com/11399002/diff/33001/ui/snapshot/snapshot_mac.mm#newcode9 ui/snapshot/snapshot_mac.mm:9: #include <iostream> Unnecessary; please remove.
8 years ago (2012-12-12 23:43:13 UTC) #45
Nico
The ui and chrome bits in this change lgtm. The component bits look good too ...
8 years ago (2012-12-12 23:46:20 UTC) #46
piman
LGTM+nits for content/ https://chromiumcodereview.appspot.com/11399002/diff/33001/content/browser/renderer_host/render_view_host_impl.cc File content/browser/renderer_host/render_view_host_impl.cc (right): https://chromiumcodereview.appspot.com/11399002/diff/33001/content/browser/renderer_host/render_view_host_impl.cc#newcode2053 content/browser/renderer_host/render_view_host_impl.cc:2053: gfx::Rect snapshot_bounds( nit: this should work: ...
8 years ago (2012-12-12 23:59:50 UTC) #47
jam
content lgtm
8 years ago (2012-12-13 08:36:21 UTC) #48
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/bajones@chromium.org/11399002/46001
8 years ago (2012-12-13 21:09:46 UTC) #49
commit-bot: I haz the power
Sorry for I got bad news for ya. Compile failed with a clobber build on ...
8 years ago (2012-12-13 21:30:57 UTC) #50
Ben Goodger (Google)
Looks like there's a DEPS file in src/ui, but that's a poor place for one. ...
8 years ago (2012-12-13 21:41:34 UTC) #51
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/bajones@chromium.org/11399002/45006
8 years ago (2012-12-14 18:35:19 UTC) #52
commit-bot: I haz the power
Sorry for I got bad news for ya. Compile failed with a clobber build on ...
8 years ago (2012-12-14 18:52:53 UTC) #53
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/bajones@chromium.org/11399002/51005
8 years ago (2012-12-14 19:12:37 UTC) #54
commit-bot: I haz the power
Retried try job too often on win_rel for step(s) browser_tests
8 years ago (2012-12-14 22:10:40 UTC) #55
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/bajones@chromium.org/11399002/51005
8 years ago (2012-12-14 22:59:03 UTC) #56
commit-bot: I haz the power
Retried try job too often on win_rel for step(s) browser_tests
8 years ago (2012-12-15 04:52:29 UTC) #57
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/bajones@chromium.org/11399002/51005
8 years ago (2012-12-15 18:51:42 UTC) #58
commit-bot: I haz the power
8 years ago (2012-12-15 22:20:11 UTC) #59
Message was sent while issue was closed.
Change committed as 173329

Powered by Google App Engine
This is Rietveld 408576698