1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2026-01-04 17:34:12 +01:00

Fix strange content compartment leak. I don't understand why this change should be necessary.

This commit is contained in:
Kris Maglione
2012-03-13 14:41:28 -04:00
parent 3730ddc5e3
commit cab8f93eef
2 changed files with 8 additions and 19 deletions

View File

@@ -50,9 +50,6 @@ XPI_NAME = $(NAME)-$(VERSION)
XPI = ../downloads/$(XPI_NAME).xpi XPI = ../downloads/$(XPI_NAME).xpi
XPI_PATH = $(TOP)/$(XPI:%.xpi=%) XPI_PATH = $(TOP)/$(XPI:%.xpi=%)
RDF = ../downloads/update.rdf
RDF_IN = $(RDF).in
BUILD_DIR = build.$(VERSION).$(OS) BUILD_DIR = build.$(VERSION).$(OS)
.SILENT: .SILENT:
@@ -78,7 +75,6 @@ help:
@echo " make install - installs this source tree directly to your $(HOSTAPP) profile" @echo " make install - installs this source tree directly to your $(HOSTAPP) profile"
@echo ' set $$PROFILE to select a profile by name and $$PROFILEPATHS' @echo ' set $$PROFILE to select a profile by name and $$PROFILEPATHS'
@echo ' to change the directory where profiles are searched' @echo ' to change the directory where profiles are searched'
@echo " make release - updates update.rdf (this is not for you)"
@echo " make dist - uploads to Google Code (this is not for you)" @echo " make dist - uploads to Google Code (this is not for you)"
@echo " make clean - clean up" @echo " make clean - clean up"
@echo " make distclean - clean up more" @echo " make distclean - clean up more"
@@ -94,8 +90,6 @@ info:
jar: $(JAR) jar: $(JAR)
release: $(XPI) $(RDF)
# This is not for you! # This is not for you!
dist: $(XPI) dist: $(XPI)
@echo DIST $(XPI) $(GOOGLE) @echo DIST $(XPI) $(GOOGLE)
@@ -160,13 +154,6 @@ install:
installxpi: xpi installxpi: xpi
$(HOSTAPP) $(XPI) $(HOSTAPP) $(XPI)
$(RDF): $(RDF_IN) Makefile
@echo "Preparing release..."
$(SED) -e "s,@VERSION@,$(VERSION),g" \
-e "s,@DATE@,$(BUILD_DATE),g" \
< $< > $@
@echo "SUCCESS: $@"
clean: clean:
@echo "General $(NAME) cleanup..." @echo "General $(NAME) cleanup..."
rm -f $(JAR) $(XPI) rm -f $(JAR) $(XPI)

View File

@@ -116,7 +116,7 @@ var Events = Module("events", {
}); });
this._fullscreen = window.fullScreen; this._fullscreen = window.fullScreen;
this._lastFocus = null; this._lastFocus = { get: function () null };
this._macroKeys = []; this._macroKeys = [];
this._lastMacro = ""; this._lastMacro = "";
@@ -901,20 +901,22 @@ var Events = Module("events", {
} }
let urlbar = document.getElementById("urlbar"); let urlbar = document.getElementById("urlbar");
if (elem == null && urlbar && urlbar.inputField == this._lastFocus) if (elem == null && urlbar && urlbar.inputField == this._lastFocus.get())
util.threadYield(true); // Why? --Kris util.threadYield(true); // Why? --Kris
while (modes.main.ownsFocus while (modes.main.ownsFocus
&& modes.topOfStack.params.ownsFocus != elem && let ({ ownsFocus } = modes.topOfStack.params)
&& modes.topOfStack.params.ownsFocus != win (!ownsFocus ||
ownsFocus.get() != elem &&
ownsFocus.get() != win)
&& !modes.topOfStack.params.holdFocus) && !modes.topOfStack.params.holdFocus)
modes.pop(null, { fromFocus: true }); modes.pop(null, { fromFocus: true });
} }
finally { finally {
this._lastFocus = elem; this._lastFocus = util.weakReference(elem);
if (modes.main.ownsFocus) if (modes.main.ownsFocus)
modes.topOfStack.params.ownsFocus = elem; modes.topOfStack.params.ownsFocus = util.weakReference(elem);
} }
}), }),