1
0
Fork 1
mirror of https://github.com/zen-browser/desktop.git synced 2025-07-10 18:15:30 +02:00

Fixed PGO builds not fully working

This commit is contained in:
mr. M 2024-12-21 13:32:03 +01:00
parent e0b125d762
commit c489a0b7cc
No known key found for this signature in database
GPG key ID: CBD57A2AEDBDA1FB
8 changed files with 19 additions and 32 deletions

View file

@ -2,7 +2,6 @@
const lazy = {};
var ZenStartup = {
init() {
this.logHeader();
this.openWatermark();
window.SessionStore.promiseInitialized.then(() => {
this._changeSidebarLocation();
@ -27,9 +26,12 @@
}
// Fix notification deck
const deckTemplate = document.getElementById('tab-notification-deck-template');
if (deckTemplate) {
document
.getElementById('zen-appcontent-navbar-container')
.appendChild(document.getElementById('tab-notification-deck-template'));
.appendChild(deckTemplate);
}
// Disable smooth scroll
gBrowser.tabContainer.arrowScrollbox.smoothScroll = false;
@ -104,21 +106,6 @@
gURLBar._initPasteAndGo();
gURLBar._initStripOnShare();
},
logHeader() {
console.info(`
Welcome to Zen Browser!
If you are seeing this message, it means that you have successfully opened Zen's developer console.
Here you can see all the logs and errors that Zen is generating.
If you have any questions or need help, please contact us in any media in https://zen-browser.app/
Note: This developer console is not the same as the browser console, it has access to Zen's internal functions and variables, including your passwords and other sensitive information. Please do not paste any code here unless you know what you are doing.
`);
},
};
ZenStartup.init();

View file

@ -538,7 +538,7 @@ class ZenKeyboardShortcutsLoader {
} catch (e) {
// Recreate shortcuts file
Services.prefs.clearUserPref('zen.keyboard.shortcuts.version');
console.error('Error loading shortcuts file', e);
console.warn('Error loading shortcuts file', e);
return null;
}
}
@ -557,7 +557,6 @@ function zenGetDefaultShortcuts() {
// For adding new default shortcuts, add them to inside the migration function
// and increment the version number.
console.info('Zen CKS: Loading default shortcuts...');
let keySet = document.getElementById(ZEN_MAIN_KEYSET_ID);
let newShortcutList = [];

View file

@ -1,12 +1,10 @@
var ZenPinnedTabsStorage = {
async init() {
console.log('ZenPinnedTabsStorage: Initializing...');
await this._ensureTable();
},
async _ensureTable() {
await PlacesUtils.withConnectionWrapper('ZenPinnedTabsStorage._ensureTable', async (db) => {
console.log('ZenPinnedTabsStorage: Ensuring tables...');
// Create the pins table if it doesn't exist
await db.execute(`
CREATE TABLE IF NOT EXISTS zen_pins (

View file

@ -53,8 +53,6 @@ var gZenStylesheetManager = {
var gZenThemesImporter = new (class {
constructor() {
console.info('[ZenThemesImporter]: Initializing Zen Themes Importer');
try {
window.SessionStore.promiseInitialized.then(async () => {
if (Services.prefs.getBoolPref('zen.themes.disable-all', false) || Services.appinfo.inSafeMode) {

View file

@ -77,6 +77,9 @@ var ZenWorkspaces = new (class extends ZenMultiWindowFeature {
}
async _delayedStartup() {
if (!this.workspaceEnabled) {
return;
}
await this.initializeWorkspaces();
console.info('ZenWorkspaces: ZenWorkspaces initialized');

View file

@ -6,7 +6,6 @@ var ZenWorkspacesStorage = {
PlacesUtils: "resource://gre/modules/PlacesUtils.sys.mjs",
});
console.log('ZenWorkspacesStorage: Initializing...');
await this._ensureTable();
await ZenWorkspaceBookmarksStorage.init();
},

View file

@ -1,13 +1,16 @@
diff --git a/testing/profiles/profileserver/user.js b/testing/profiles/profileserver/user.js
index 19ff7d474f6d22d2d386764e2e6942ce6a324470..3cec3a25acc6f8780d56d273995974a905b6c031 100644
index 19ff7d474f6d22d2d386764e2e6942ce6a324470..40d1906bdebd08510014fd6124be17052248e748 100644
--- a/testing/profiles/profileserver/user.js
+++ b/testing/profiles/profileserver/user.js
@@ -8,3 +8,7 @@
@@ -8,3 +8,11 @@
user_pref("dom.timeout.enable_budget_timer_throttling", false);
// Turn off update
user_pref("app.update.disabledForTesting", true);
+
+// zen:
+// Disable workspaces in order to prevent SQL calls
+// Disable some of zen's features to better match the default Firefox experience
+user_pref("zen.workspaces.enabled", false);
\ No newline at end of file
+user_pref("zen.welcome-screen.enabled", false);
+user_pref("zen.tab-unloader.enabled", false);
+user_pref("zen.watermark.enabled", false);
+user_pref("zen.glance.enabled", false);