зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1026561 - The New Tab Page should be smarter about showing more tiles when on large screens [r=adw]
Bump up default columns to fit most Firefox users including 2560px wide resolutions.
This commit is contained in:
Родитель
370ea668f5
Коммит
29226f48ab
|
@ -1471,7 +1471,7 @@ pref("browser.newtabpage.enabled", true);
|
|||
pref("browser.newtabpage.rows", 3);
|
||||
|
||||
// number of columns of newtab grid
|
||||
pref("browser.newtabpage.columns", 3);
|
||||
pref("browser.newtabpage.columns", 8);
|
||||
|
||||
// directory tiles download URL
|
||||
pref("browser.newtabpage.directory.source", "chrome://global/content/directoryLinks.json");
|
||||
|
|
|
@ -17,8 +17,8 @@ function runTests() {
|
|||
// Expected length of grid
|
||||
let expectedValues = [1, 1, 1, 1, 8, 10];
|
||||
|
||||
// Values before setting new pref values (9 is the default value -> 3 x 3)
|
||||
let previousValues = [9, 1, 1, 1, 1, 8];
|
||||
// Values before setting new pref values (24 is the default value -> 8 x 3)
|
||||
let previousValues = [24, 1, 1, 1, 1, 8];
|
||||
|
||||
let existingTab, existingTabGridLength, newTab, newTabGridLength;
|
||||
yield addNewTabPageTab();
|
||||
|
|
|
@ -1,6 +1,8 @@
|
|||
/* Any copyright is dedicated to the Public Domain.
|
||||
http://creativecommons.org/publicdomain/zero/1.0/ */
|
||||
|
||||
const PREF_NEWTAB_COLUMNS = "browser.newtabpage.columns";
|
||||
|
||||
/*
|
||||
* These tests make sure that dragging and dropping sites works as expected.
|
||||
* Sites contained in the grid need to shift around to indicate the result
|
||||
|
@ -28,8 +30,11 @@ function runTests() {
|
|||
yield addNewTabPageTab();
|
||||
checkGrid("0,1,2,3,4,5,6,7p,8p");
|
||||
|
||||
// force the grid to be small enough that a pinned cell could be pushed out
|
||||
Services.prefs.setIntPref(PREF_NEWTAB_COLUMNS, 3);
|
||||
yield simulateExternalDrop(7);
|
||||
checkGrid("0,1,2,3,4,5,7p,99p,8p");
|
||||
Services.prefs.clearUserPref(PREF_NEWTAB_COLUMNS);
|
||||
|
||||
// drag a new site beneath a pinned cell and make sure the pinned cell is
|
||||
// not moved
|
||||
|
@ -52,4 +57,4 @@ function runTests() {
|
|||
|
||||
yield simulateExternalDrop(1);
|
||||
checkGrid("0p,99p,1p,2p,3,4,5,6,7");
|
||||
}
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче