get rid of debug mode

This commit is contained in:
oneflux 2025-04-21 11:14:35 -07:00
parent 95cc4489d0
commit 52a82add9b

View file

@ -28,29 +28,6 @@ index 1cfa4b8497..bdf8d7202e 100644
// When the fingerprinting resistance is enabled, making sure that we don't // When the fingerprinting resistance is enabled, making sure that we don't
// have a maximum window to interfere with generating rounded window dimensions. // have a maximum window to interfere with generating rounded window dimensions.
document.documentElement.setAttribute("sizemode", "normal"); document.documentElement.setAttribute("sizemode", "normal");
@@ -310,6 +320,22 @@ var gBrowserInit = {
// Update UI if browser is under remote control.
gRemoteControl.updateVisualCue();
+ // Camoufox: print URL changes to console
+ if (ChromeUtils.isCamouDebug()) {
+ ChromeUtils.camouDebug("Debug mode ON.");
+ gBrowser.addTabsProgressListener({
+ onLocationChange(aBrowser, aWebProgress, aRequest, aLocation, aFlags) {
+ if (aBrowser === gBrowser.selectedBrowser) {
+ ChromeUtils.camouDebug("URL changed to: " + aLocation.spec);
+ }
+ }
+ });
+
+ gURLBar.addEventListener("change", () => {
+ ChromeUtils.camouDebug("URL bar value changed to: " + gURLBar.value);
+ });
+ }
+
// If we are given a tab to swap in, take care of it before first paint to
// avoid an about:blank flash.
let tabToAdopt = this.getTabToAdopt();
@@ -345,6 +371,31 @@ var gBrowserInit = { @@ -345,6 +371,31 @@ var gBrowserInit = {
} }
} }