• Leonard Grey's avatar
    Mac: Don't trigger mouse down events on bookmark buttons if command key is down · 4a7db45d
    Leonard Grey authored
    Currently, all clicks on a bookmark folder button trigger their action on
    mouse down, so that the folder menu can open on mouse down as expected.
    
    This also includes command click, which, rather than opening the folder menu,
    opens all the bookmarks in the folder as new tabs. This isn't desirable since:
    - The expected behavior is that button clicks trigger on mouse up.
    - Triggering this on mouse down interacts poorly with the nested run loop
    created by the confirmation dialog we display when the folder has many links.
    
    This change causes the action to no longer fire on mouse down if the user
    is command-clicking the folder button.
    
    Bug: 840387
    Change-Id: Ic1364160cf26f2f3ea6e67d7dd0d6cf5079082eb
    Reviewed-on: https://chromium-review.googlesource.com/1053947Reviewed-by: default avatarRobert Sesek <rsesek@chromium.org>
    Commit-Queue: Leonard Grey <lgrey@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#557676}
    4a7db45d
draggable_button_unittest.mm 6.9 KB