mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-11 20:35:50 +00:00
Bug 690739 (1/2) - [TabletUI] Make the swipable sidebar margin smaller when the sidebar is closed [r=mfinkle]
This commit is contained in:
parent
72ba68a736
commit
51d1a1a523
@ -1356,11 +1356,14 @@ Browser.MainDragger.prototype = {
|
||||
let isTablet = Util.isTablet();
|
||||
this._panToolbars = !isTablet;
|
||||
|
||||
this._grabSidebar = false;
|
||||
// In landscape portrait mode, swiping from the left margin drags the tab sidebar.
|
||||
this._grabSidebar = isTablet && !Util.isPortrait() &&
|
||||
((Util.localeDir == Util.LOCALE_DIR_LTR) ?
|
||||
(clientX - bcr.left < 30) :
|
||||
(bcr.right - clientX < 30));
|
||||
if (isTablet && !Util.isPortrait()) {
|
||||
let grabSidebarMargin = TabsPopup.visible ? 30 : 5;
|
||||
this._grabSidebar = ((Util.localeDir == Util.LOCALE_DIR_LTR)
|
||||
? (clientX - bcr.left < 30)
|
||||
: (bcr.right - clientX < 30));
|
||||
}
|
||||
|
||||
if (this._grabSidebar)
|
||||
Browser.grabSidebar();
|
||||
|
Loading…
Reference in New Issue
Block a user