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

Issue 8183005: Choose the right window to switch to when a panel is deactivated on Windows. (Closed)

Created:
9 years, 2 months ago by jianli
Modified:
9 years, 2 months ago
Reviewers:
jennb, Dmitry Titov
CC:
chromium-reviews, Dmitry Titov, prasadt, dcheng, Paweł Hajdan Jr.
Visibility:
Public.

Description

Choose the right window to switch to when a panel is deactivated on Windows. We choose the last active browser window that is not minimized. BUG=none TEST=browser tests Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=104584

Patch Set 1 #

Total comments: 17

Patch Set 2 : '' #

Total comments: 4

Patch Set 3 : '' #

Patch Set 4 : '' #

Unified diffs Side-by-side diffs Delta from patch set Stats (+192 lines, -22 lines) Patch
M chrome/browser/ui/panels/base_panel_browser_test.cc View 1 chunk +0 lines, -2 lines 0 comments Download
M chrome/browser/ui/panels/native_panel.h View 1 2 3 1 chunk +3 lines, -0 lines 0 comments Download
M chrome/browser/ui/panels/panel.cc View 1 1 chunk +1 line, -2 lines 0 comments Download
M chrome/browser/ui/panels/panel_browser_view.h View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/ui/panels/panel_browser_view.cc View 1 2 3 3 chunks +36 lines, -1 line 0 comments Download
M chrome/browser/ui/panels/panel_browser_view_browsertest.cc View 1 chunk +0 lines, -17 lines 0 comments Download
M chrome/browser/ui/panels/panel_browser_window_cocoa.mm View 1 2 3 2 chunks +5 lines, -0 lines 0 comments Download
M chrome/browser/ui/panels/panel_browser_window_gtk.cc View 1 2 3 2 chunks +5 lines, -0 lines 0 comments Download
M chrome/browser/ui/panels/panel_browsertest.cc View 1 2 3 3 chunks +121 lines, -0 lines 0 comments Download
M chrome/browser/ui/panels/panel_manager.h View 1 1 chunk +5 lines, -0 lines 0 comments Download
M chrome/browser/ui/panels/panel_manager.cc View 1 2 2 chunks +15 lines, -0 lines 0 comments Download

Messages

Total messages: 8 (0 generated)
jianli
9 years, 2 months ago (2011-10-06 23:27:41 UTC) #1
Dmitry Titov
http://codereview.chromium.org/8183005/diff/1/chrome/browser/ui/panels/native_panel.h File chrome/browser/ui/panels/native_panel.h (right): http://codereview.chromium.org/8183005/diff/1/chrome/browser/ui/panels/native_panel.h#newcode92 chrome/browser/ui/panels/native_panel.h:92: virtual bool VerifyTitlebarPaintedAsActive(bool as_active) = 0; Does it verify ...
9 years, 2 months ago (2011-10-07 20:29:15 UTC) #2
jennb
http://codereview.chromium.org/8183005/diff/1/chrome/browser/ui/panels/panel_browsertest.cc File chrome/browser/ui/panels/panel_browsertest.cc (right): http://codereview.chromium.org/8183005/diff/1/chrome/browser/ui/panels/panel_browsertest.cc#newcode1055 chrome/browser/ui/panels/panel_browsertest.cc:1055: // When a panel is created, it should be ...
9 years, 2 months ago (2011-10-07 20:34:16 UTC) #3
jianli
http://codereview.chromium.org/8183005/diff/1/chrome/browser/ui/panels/native_panel.h File chrome/browser/ui/panels/native_panel.h (right): http://codereview.chromium.org/8183005/diff/1/chrome/browser/ui/panels/native_panel.h#newcode92 chrome/browser/ui/panels/native_panel.h:92: virtual bool VerifyTitlebarPaintedAsActive(bool as_active) = 0; On 2011/10/07 20:29:15, ...
9 years, 2 months ago (2011-10-07 22:01:54 UTC) #4
jennb
LGTM but wait for dimich http://codereview.chromium.org/8183005/diff/10001/chrome/browser/ui/panels/panel_browsertest.cc File chrome/browser/ui/panels/panel_browsertest.cc (right): http://codereview.chromium.org/8183005/diff/10001/chrome/browser/ui/panels/panel_browsertest.cc#newcode1088 chrome/browser/ui/panels/panel_browsertest.cc:1088: std::string panel_name_base("PanelTets"); typo http://codereview.chromium.org/8183005/diff/10001/chrome/browser/ui/panels/panel_browsertest.cc#newcode1090 ...
9 years, 2 months ago (2011-10-07 22:08:30 UTC) #5
jianli
http://codereview.chromium.org/8183005/diff/10001/chrome/browser/ui/panels/panel_browsertest.cc File chrome/browser/ui/panels/panel_browsertest.cc (right): http://codereview.chromium.org/8183005/diff/10001/chrome/browser/ui/panels/panel_browsertest.cc#newcode1090 chrome/browser/ui/panels/panel_browsertest.cc:1090: CreatePanelWithBounds(panel_name_base + base::IntToString(i), On 2011/10/07 22:08:30, jennb wrote: > ...
9 years, 2 months ago (2011-10-07 22:11:37 UTC) #6
Dmitry Titov
LGTM Please consider the following, but I do not insist on it: http://codereview.chromium.org/8183005/diff/1/chrome/browser/ui/panels/native_panel.h File chrome/browser/ui/panels/native_panel.h ...
9 years, 2 months ago (2011-10-07 22:26:41 UTC) #7
jianli
9 years, 2 months ago (2011-10-07 22:32:01 UTC) #8
On 2011/10/07 22:26:41, Dmitry Titov wrote:
> LGTM
> 
> Please consider the following, but I do not insist on it:
> 
>
http://codereview.chromium.org/8183005/diff/1/chrome/browser/ui/panels/native...
> File chrome/browser/ui/panels/native_panel.h (right):
> 
>
http://codereview.chromium.org/8183005/diff/1/chrome/browser/ui/panels/native...
> chrome/browser/ui/panels/native_panel.h:92: virtual bool
> VerifyTitlebarPaintedAsActive(bool as_active) = 0;
> On 2011/10/07 22:01:54, jianli wrote:
> > On 2011/10/07 20:29:15, Dmitry Titov wrote:
> > > Does it verify that the panel is actually active or that the color of the
> > > titlebar is correct? It's not clear from the description. If it is
verifying
> > > that the panel is really active, we could name the method VarifyIsActive()
> and
> > > implement it by checking the color of titlebar. It could be a different
> check
> > on
> > > another platform.
> > 
> > We want to verify that the titlebar is painted correctly per its active
state.
> > This is the reason I name it as ***PaintedAsActive. Checking whether the
panel
> > is active can be done by calling Panel::IsActive.
> 
> Same logic here as VerifyDrawingAttention() - the method is actually
implemented
> differently on various platforms. On Views, it checks for colors, on OSX, it
> checks for internal flag. It makes sense to name the method by 'what' it does
> rather then 'how exactly does it do that'. In this particular case, you verify
> that the native panel actually, really and for sure is drawing 'active'
> decorations. The 'how' is 'by changing the color of the titlebar'. On OSX, we
> might again check for internal flag because the colors are not pulled until we
> actually draw real pixels.

Renamed to VerifyActiveState.

Powered by Google App Engine
This is Rietveld 408576698