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

Issue 9195003: Move IN_OVERFLOW from Panel::ExpansionState to new enum. (Closed)

Created:
8 years, 11 months ago by jianli
Modified:
8 years, 9 months ago
Reviewers:
jennb
CC:
chromium-reviews, jennb, jianli, Dmitry Titov, dcheng, prasadt
Visibility:
Public.

Description

Move IN_OVERFLOW from Panel::ExpansionState to new enum. BUG=NONE TEST=existing tests

Patch Set 1 #

Total comments: 14

Patch Set 2 : Fix per feedback #

Total comments: 15

Patch Set 3 : Fix trybot plus sync #

Patch Set 4 : Fix per feedback #

Total comments: 3

Patch Set 5 : Fix trybot #

Total comments: 11

Patch Set 6 : Fix per feedback #

Unified diffs Side-by-side diffs Delta from patch set Stats (+724 lines, -463 lines) Patch
M chrome/browser/ui/panels/base_panel_browser_test.h View 1 2 chunks +4 lines, -0 lines 0 comments Download
M chrome/browser/ui/panels/base_panel_browser_test.cc View 1 2 chunks +19 lines, -0 lines 0 comments Download
M chrome/browser/ui/panels/panel.h View 1 4 chunks +19 lines, -11 lines 0 comments Download
M chrome/browser/ui/panels/panel.cc View 1 2 3 4 5 6 chunks +24 lines, -7 lines 0 comments Download
M chrome/browser/ui/panels/panel_browser_frame_view.cc View 1 2 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/browser/ui/panels/panel_browser_view.cc View 1 2 3 4 5 3 chunks +14 lines, -6 lines 0 comments Download
M chrome/browser/ui/panels/panel_manager.h View 1 1 chunk +5 lines, -1 line 0 comments Download
M chrome/browser/ui/panels/panel_manager.cc View 1 2 3 4 5 1 chunk +11 lines, -4 lines 0 comments Download
M chrome/browser/ui/panels/panel_overflow_browsertest.cc View 1 2 3 4 5 48 chunks +525 lines, -379 lines 0 comments Download
M chrome/browser/ui/panels/panel_overflow_strip.h View 1 1 chunk +2 lines, -2 lines 0 comments Download
M chrome/browser/ui/panels/panel_overflow_strip.cc View 1 3 chunks +5 lines, -4 lines 0 comments Download
M chrome/browser/ui/panels/panel_strip.h View 1 2 chunks +7 lines, -1 line 0 comments Download
M chrome/browser/ui/panels/panel_strip.cc View 1 2 3 4 5 9 chunks +82 lines, -46 lines 0 comments Download
M chrome/common/chrome_notification_types.h View 1 1 chunk +5 lines, -0 lines 0 comments Download

Messages

Total messages: 13 (0 generated)
jianli
8 years, 11 months ago (2012-01-19 02:42:28 UTC) #1
jennb
http://codereview.chromium.org/9195003/diff/1/chrome/browser/ui/panels/panel.h File chrome/browser/ui/panels/panel.h (right): http://codereview.chromium.org/9195003/diff/1/chrome/browser/ui/panels/panel.h#newcode35 chrome/browser/ui/panels/panel.h:35: enum StripOwner { PanelLayout? More informative than StripOwner. http://codereview.chromium.org/9195003/diff/1/chrome/browser/ui/panels/panel.h#newcode36 ...
8 years, 11 months ago (2012-01-19 18:14:26 UTC) #2
jennb
A couple more minor things. http://codereview.chromium.org/9195003/diff/1/chrome/browser/ui/panels/panel_overflow_browsertest.cc File chrome/browser/ui/panels/panel_overflow_browsertest.cc (right): http://codereview.chromium.org/9195003/diff/1/chrome/browser/ui/panels/panel_overflow_browsertest.cc#newcode82 chrome/browser/ui/panels/panel_overflow_browsertest.cc:82: bool visible, bool active) ...
8 years, 11 months ago (2012-01-19 18:41:17 UTC) #3
jianli
Also fixed the problem that clicking an overflow panel does not bring it out of ...
8 years, 11 months ago (2012-01-19 22:24:40 UTC) #4
jennb
http://codereview.chromium.org/9195003/diff/1/chrome/browser/ui/panels/panel_overflow_browsertest.cc File chrome/browser/ui/panels/panel_overflow_browsertest.cc (right): http://codereview.chromium.org/9195003/diff/1/chrome/browser/ui/panels/panel_overflow_browsertest.cc#newcode82 chrome/browser/ui/panels/panel_overflow_browsertest.cc:82: bool visible, bool active) { On 2012/01/19 22:24:41, jianli ...
8 years, 11 months ago (2012-01-19 23:44:06 UTC) #5
jianli
http://codereview.chromium.org/9195003/diff/4003/chrome/browser/ui/panels/panel.cc File chrome/browser/ui/panels/panel.cc (right): http://codereview.chromium.org/9195003/diff/4003/chrome/browser/ui/panels/panel.cc#newcode82 chrome/browser/ui/panels/panel.cc:82: if (layout_state_ == DOCKED && expansion_state_ == EXPANDED) On ...
8 years, 11 months ago (2012-01-20 01:16:07 UTC) #6
jennb
Also, I forgot to ask if you checked every place that looks at expansion state ...
8 years, 11 months ago (2012-01-20 02:01:53 UTC) #7
jianli
On Thu, Jan 19, 2012 at 6:01 PM, <jennb@chromium.org> wrote: > Also, I forgot to ...
8 years, 11 months ago (2012-01-20 02:15:19 UTC) #8
jennb
I like the idea of combining a layout plus expansion state change into a single ...
8 years, 11 months ago (2012-01-20 02:21:20 UTC) #9
jianli
On Thu, Jan 19, 2012 at 6:21 PM, Jenn Braithwaite (胡慧鋒) <jennb@chromium.org>wrote: > I like ...
8 years, 11 months ago (2012-01-20 02:32:56 UTC) #10
prasadt
drive-by http://codereview.chromium.org/9195003/diff/23/chrome/browser/ui/panels/panel_manager.cc File chrome/browser/ui/panels/panel_manager.cc (right): http://codereview.chromium.org/9195003/diff/23/chrome/browser/ui/panels/panel_manager.cc#newcode182 chrome/browser/ui/panels/panel_manager.cc:182: Panel::LayoutState old_state) { Indentation off by a space. ...
8 years, 11 months ago (2012-01-20 04:43:08 UTC) #11
jennb
http://codereview.chromium.org/9195003/diff/23/chrome/browser/ui/panels/panel_manager.cc File chrome/browser/ui/panels/panel_manager.cc (right): http://codereview.chromium.org/9195003/diff/23/chrome/browser/ui/panels/panel_manager.cc#newcode184 chrome/browser/ui/panels/panel_manager.cc:184: panel_overflow_strip_->OnPanelLayoutStateChanged(panel, old_state); On 2012/01/20 04:43:08, prasadt wrote: > This ...
8 years, 11 months ago (2012-01-20 23:28:59 UTC) #12
jianli
8 years, 11 months ago (2012-01-20 23:33:08 UTC) #13
Also checked and fixed all the usages of expansion_state() and fixed visible
parameter in PanelData.

http://codereview.chromium.org/9195003/diff/2007/chrome/browser/ui/panels/pan...
File chrome/browser/ui/panels/panel_strip.cc (right):

http://codereview.chromium.org/9195003/diff/2007/chrome/browser/ui/panels/pan...
chrome/browser/ui/panels/panel_strip.cc:488: // If the panel is in overflow,
rearrange if panel's width is smaller becuase
On 2012/01/20 02:01:54, jennb wrote:
> typo: becuase

Done.

http://codereview.chromium.org/9195003/diff/23/chrome/browser/ui/panels/panel...
File chrome/browser/ui/panels/panel_manager.cc (right):

http://codereview.chromium.org/9195003/diff/23/chrome/browser/ui/panels/panel...
chrome/browser/ui/panels/panel_manager.cc:182: Panel::LayoutState old_state) {
On 2012/01/20 04:43:08, prasadt wrote:
> Indentation off by a space.

Done.

http://codereview.chromium.org/9195003/diff/23/chrome/browser/ui/panels/panel...
chrome/browser/ui/panels/panel_manager.cc:184:
panel_overflow_strip_->OnPanelLayoutStateChanged(panel, old_state);
On 2012/01/20 04:43:08, prasadt wrote:
> This may be cleaner if the strips just listened to the notification fired by
> Panel.

Yes, it might be. But for our usage, I think it would be simpler to notify the
strip directly, instead of incurring overhead with the notification scheme.

http://codereview.chromium.org/9195003/diff/23/chrome/browser/ui/panels/panel...
chrome/browser/ui/panels/panel_manager.cc:190:
panel_strip_->OnPanelExpansionStateChanged(panel, old_state);
On 2012/01/20 04:43:08, prasadt wrote:
> Same comment as above. PanelStrip could just listen to the notification. The
> logic would seem like it belongs in PanelStrip.

ExpansonState now solely belongs to PanelStrip. I removed this method since we
now call directly into PanelStrip for any expansion state changes.

http://codereview.chromium.org/9195003/diff/23/chrome/browser/ui/panels/panel...
File chrome/browser/ui/panels/panel_strip.cc (right):

http://codereview.chromium.org/9195003/diff/23/chrome/browser/ui/panels/panel...
chrome/browser/ui/panels/panel_strip.cc:359: Panel::LayoutState old_state) {
On 2012/01/20 04:43:08, prasadt wrote:
> Indentation off by a space.

Done.

http://codereview.chromium.org/9195003/diff/23/chrome/common/chrome_notificat...
File chrome/common/chrome_notification_types.h (right):

http://codereview.chromium.org/9195003/diff/23/chrome/common/chrome_notificat...
chrome/common/chrome_notification_types.h:972:
NOTIFICATION_PANEL_CHANGED_LAYOUT_STATE,
On 2012/01/20 04:43:08, prasadt wrote:
> Not in alphabetical order.

I do not think there is a requirement for this. I rather put notification for
layout state change before expansion state change since the former one takes
higher priority.

Powered by Google App Engine
This is Rietveld 408576698