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

Issue 9703026: Makes the maximize/restore button handling (Closed)

Created:
8 years, 9 months ago by sky
Modified:
8 years, 9 months ago
CC:
chromium-reviews, dhollowa+watch_chromium.org, sadrul, tfarina, ben+watch_chromium.org
Visibility:
Public.

Description

Makes the maximize/restore button handling snapping/minimizing. FrameMaximizeButton handles all the logic for this. If you move the mouse the drag threshold we'll trigger to snapping behavior. moving to the left snaps to the left half, moving to the right the right half, and below minimizes. Uses PhantomWindowController to render the snap position. Minimizing highlights the launcher button. To support this I had to plumb through getting the bounds of the launcher button. BUG=116213 TEST=none R=ben@chromium.org Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=126729

Patch Set 1 #

Patch Set 2 : Cleanup #

Total comments: 2

Patch Set 3 : Incorporate review feedback #

Unified diffs Side-by-side diffs Delta from patch set Stats (+424 lines, -19 lines) Patch
M ash/ash.gyp View 1 chunk +2 lines, -0 lines 0 comments Download
M ash/launcher/launcher.h View 5 chunks +11 lines, -4 lines 0 comments Download
M ash/launcher/launcher.cc View 3 chunks +24 lines, -6 lines 0 comments Download
M ash/launcher/launcher_button.h View 1 1 chunk +3 lines, -0 lines 0 comments Download
M ash/launcher/launcher_button.cc View 1 1 chunk +4 lines, -0 lines 0 comments Download
M ash/launcher/launcher_delegate.h View 3 chunks +5 lines, -2 lines 0 comments Download
M ash/launcher/launcher_view.h View 1 chunk +4 lines, -0 lines 0 comments Download
M ash/launcher/launcher_view.cc View 1 chunk +14 lines, -0 lines 0 comments Download
M ash/shell.h View 1 chunk +3 lines, -0 lines 0 comments Download
M ash/shell.cc View 1 chunk +4 lines, -0 lines 0 comments Download
M ash/shell/shell_main.cc View 3 chunks +17 lines, -0 lines 0 comments Download
M ash/shell/window_type_launcher.h View 1 chunk +1 line, -0 lines 0 comments Download
M ash/shell/window_type_launcher.cc View 1 chunk +4 lines, -0 lines 0 comments Download
M ash/wm/custom_frame_view_ash.cc View 2 chunks +2 lines, -1 line 0 comments Download
A ash/wm/workspace/frame_maximize_button.h View 1 2 1 chunk +81 lines, -0 lines 0 comments Download
A ash/wm/workspace/frame_maximize_button.cc View 1 chunk +217 lines, -0 lines 0 comments Download
M ash/wm/workspace/phantom_window_controller.cc View 1 2 chunks +11 lines, -1 line 0 comments Download
M ash/wm/workspace_controller.h View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/views/ash/launcher/chrome_launcher_delegate.h View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/ui/views/ash/launcher/chrome_launcher_delegate.cc View 1 chunk +10 lines, -0 lines 0 comments Download
M chrome/browser/ui/views/frame/browser_non_client_frame_view_aura.cc View 2 chunks +2 lines, -1 line 0 comments Download
M ui/views/controls/button/image_button.h View 1 2 1 chunk +1 line, -1 line 0 comments Download
M ui/views/controls/button/image_button.cc View 1 2 1 chunk +2 lines, -2 lines 0 comments Download

Messages

Total messages: 5 (0 generated)
sky
8 years, 9 months ago (2012-03-14 16:34:03 UTC) #1
tfarina
http://codereview.chromium.org/9703026/diff/25/ui/views/controls/button/image_button.h File ui/views/controls/button/image_button.h (left): http://codereview.chromium.org/9703026/diff/25/ui/views/controls/button/image_button.h#oldcode26 ui/views/controls/button/image_button.h:26: virtual void SetImage(ButtonState aState, const SkBitmap* anImage); nit: anImage ...
8 years, 9 months ago (2012-03-14 16:36:03 UTC) #2
tfarina
http://codereview.chromium.org/9703026/diff/25/ash/wm/workspace/frame_maximize_button.h File ash/wm/workspace/frame_maximize_button.h (right): http://codereview.chromium.org/9703026/diff/25/ash/wm/workspace/frame_maximize_button.h#newcode13 ash/wm/workspace/frame_maximize_button.h:13: class MouseEvent; nit: no need to forward declare this, ...
8 years, 9 months ago (2012-03-14 16:38:42 UTC) #3
Ben Goodger (Google)
LGTM
8 years, 9 months ago (2012-03-14 16:46:22 UTC) #4
sky
8 years, 9 months ago (2012-03-14 16:47:52 UTC) #5
I incorporated your review feedback Thiago.

  -Scott

On Wed, Mar 14, 2012 at 9:38 AM,  <tfarina@chromium.org> wrote:
>
>
http://codereview.chromium.org/9703026/diff/25/ash/wm/workspace/frame_maximiz...
> File ash/wm/workspace/frame_maximize_button.h (right):
>
>
http://codereview.chromium.org/9703026/diff/25/ash/wm/workspace/frame_maximiz...
> ash/wm/workspace/frame_maximize_button.h:13: class MouseEvent;
> nit: no need to forward declare this, it comes from ui/views/view.h
>
> http://codereview.chromium.org/9703026/

Powered by Google App Engine
This is Rietveld 408576698