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

Issue 316006: GTK: Try to position info bubbles onscreen. (Closed)

Created:
11 years, 2 months ago by Daniel Erat
Modified:
9 years, 7 months ago
Reviewers:
Evan Stade
CC:
chromium-reviews_googlegroups.com
Visibility:
Public.

Description

GTK: Try to position info bubbles onscreen. I didn't go so far as to add support for arrows-on-the-bottom in this change; I'm just making the bubble extend left or right as needed. I'll add a parameter to specify the default arrow location (needed for browser action popups) in another CL. Tested by: - dragging a window to the right edge of the screen and confirming that bookmark bubbles open extended to the left - opening a bookmark bubble, using a little X program to move the Chrome window to the right side of the screen (can't drag it there since the pointer is grabbed), and confirming that the bubble gets updated to extend to the left - running in Arabic and confirming that bubbles extend to the left by default but get switched to extend to the right as needed BUG=23373 TEST=see above Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=29992

Patch Set 1 #

Patch Set 2 : fix redraws and merge #

Total comments: 1

Patch Set 3 : update a comment #

Total comments: 1

Patch Set 4 : merge #

Unified diffs Side-by-side diffs Delta from patch set Stats (+193 lines, -103 lines) Patch
M chrome/browser/gtk/info_bubble_gtk.h View 1 2 4 chunks +45 lines, -0 lines 0 comments Download
M chrome/browser/gtk/info_bubble_gtk.cc View 1 8 chunks +148 lines, -101 lines 0 comments Download
M chrome/browser/gtk/location_bar_view_gtk.cc View 2 3 1 chunk +0 lines, -2 lines 0 comments Download

Messages

Total messages: 3 (0 generated)
Daniel Erat
http://codereview.chromium.org/316006/diff/1001/2001 File chrome/browser/gtk/info_bubble_gtk.cc (left): http://codereview.chromium.org/316006/diff/1001/2001#oldcode172 Line 172: gtk_widget_set_double_buffered(window_, TRUE); Removing this 'cause it's the default.
11 years, 2 months ago (2009-10-23 18:45:16 UTC) #1
Evan Stade
hmm, so this doesn't support a dynamic arrow position? i.e. if you had a bubble ...
11 years, 2 months ago (2009-10-23 22:47:13 UTC) #2
use derat at chromium.org
11 years, 2 months ago (2009-10-24 03:12:01 UTC) #3
On Fri, Oct 23, 2009 at 3:47 PM,  <estade@chromium.org> wrote:
> hmm, so this doesn't support a dynamic arrow position? i.e. if you had a
> bubble
> the same width as the screen it wouldn't magically fit it all. Oh well, I
> guess
> that use case will probably never come up. LGTM, just one question

Nope, but Views doesn't support this either -- see
browser/views/bubble_border.h:

  // Possible locations for the (optional) arrow.
  enum ArrowLocation {
    NONE,
    TOP_LEFT,
    TOP_RIGHT,
    BOTTOM_LEFT,
    BOTTOM_RIGHT
  };

> http://codereview.chromium.org/316006/diff/3001/4001
> File chrome/browser/gtk/info_bubble_gtk.cc (right):
>
> http://codereview.chromium.org/316006/diff/3001/4001#newcode181
> Line 181: bool ltr = (arrow_location == ARROW_LOCATION_TOP_LEFT);
> I thought we were going to make the arrow location top right for browser
> actions in LTR?

Yeah, I'm planning to do this in the next CL.

> http://codereview.chromium.org/316006
>

Powered by Google App Engine
This is Rietveld 408576698