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

Issue 242139: Mac: Fix crash while dragging a tab alone in a window. (Closed)

Created:
11 years, 2 months ago by viettrungluu
Modified:
9 years, 6 months ago
CC:
chromium-reviews_googlegroups.com
Visibility:
Public.

Description

Mac: Fix crash while dragging a tab alone in a window. Specifically, the crash could be repro'ed as follows (it also occurred under other circumstances as well): Have a window with one or more tabs in it. Create a new window with a single tab. Drag the tab in the new window, and while dragging right-click (and release). This patch also prevents right-clicks while dragging from stopping the drag. BUG=23591 TEST=See above. Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=28075

Patch Set 1 #

Total comments: 10

Patch Set 2 : Updated as per reviews. #

Total comments: 2

Patch Set 3 : Unconditionally clear tab controller's target. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+13 lines, -1 line) Patch
M chrome/browser/cocoa/tab_strip_controller.mm View 1 2 1 chunk +6 lines, -0 lines 0 comments Download
M chrome/browser/cocoa/tab_view.mm View 1 2 chunks +7 lines, -1 line 0 comments Download

Messages

Total messages: 6 (0 generated)
viettrungluu
11 years, 2 months ago (2009-10-03 02:33:33 UTC) #1
John Grabowski
This seems a little hacky. I realize this fixes a crash, so LGTM if you ...
11 years, 2 months ago (2009-10-05 01:49:29 UTC) #2
pink (ping after 24hrs)
http://codereview.chromium.org/242139/diff/1/2 File chrome/browser/cocoa/tab_strip_controller.mm (right): http://codereview.chromium.org/242139/diff/1/2#newcode635 Line 635: // TODO(viettrungluu): Find a better way to handle ...
11 years, 2 months ago (2009-10-05 16:19:23 UTC) #3
viettrungluu
Thanks. Please re-review. http://codereview.chromium.org/242139/diff/1/2 File chrome/browser/cocoa/tab_strip_controller.mm (right): http://codereview.chromium.org/242139/diff/1/2#newcode635 Line 635: // TODO(viettrungluu): Find a better ...
11 years, 2 months ago (2009-10-05 17:31:14 UTC) #4
pink (ping after 24hrs)
lgtm either way, but see comment. http://codereview.chromium.org/242139/diff/9/10 File chrome/browser/cocoa/tab_strip_controller.mm (right): http://codereview.chromium.org/242139/diff/9/10#newcode635 Line 635: // TODO(viettrungluu): ...
11 years, 2 months ago (2009-10-05 18:32:06 UTC) #5
viettrungluu
11 years, 2 months ago (2009-10-05 18:49:09 UTC) #6
http://codereview.chromium.org/242139/diff/9/10
File chrome/browser/cocoa/tab_strip_controller.mm (right):

http://codereview.chromium.org/242139/diff/9/10#newcode635
Line 635: // TODO(viettrungluu): [crbug.com/23829] Find a better way to handle
the tab
On 2009/10/05 18:32:08, pink wrote:
> if you say so. I don't really see why we need to find a better way to deal
with
> this. Cocoa has this issue throughout. It's probably even ok to unilaterally
> clear the target even if it's not us, since if someone changed the target, it
> will have broken assumptions about how this class expects to operate with the
> tab (recall we set it in the first place and expect it to stay put).

I'd feel warmer and fuzzier (or something like that) if this were cleaner (at
the very least, I don't like the fact that we manually fiddle with the tab
controller's target), but it's pretty low-priority. I do agree that it's okay to
unilaterally clear the target though, so I've made that change.

Powered by Google App Engine
This is Rietveld 408576698