mirror of
https://github.com/moparisthebest/FireTray
synced 2025-01-08 12:08:05 -05:00
Cleaning.
This commit is contained in:
parent
738c412c23
commit
7da4cc30c0
@ -171,10 +171,15 @@ firetray.Handler.registerWindow = function(win) {
|
|||||||
|
|
||||||
let baseWin = firetray.Handler.getWindowInterface(win, "nsIBaseWindow");
|
let baseWin = firetray.Handler.getWindowInterface(win, "nsIBaseWindow");
|
||||||
let nativeHandle = baseWin.nativeHandle;
|
let nativeHandle = baseWin.nativeHandle;
|
||||||
let hwnd = nativeHandle ?
|
let hwnd, wid;
|
||||||
firetray.Win32.hexStrToHwnd(nativeHandle) :
|
if (nativeHandle) {
|
||||||
user32.FindWindowW("MozillaWindowClass", win.document.title);
|
hwnd = firetray.Win32.hexStrToHwnd(nativeHandle);
|
||||||
let wid = firetray.Win32.hwndToHexStr(hwnd);
|
wid = nativeHandle;
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
hwnd = user32.FindWindowW("MozillaWindowClass", win.document.title);
|
||||||
|
wid = firetray.Win32.hwndToHexStr(hwnd);
|
||||||
|
}
|
||||||
log.debug("=== hwnd="+hwnd+" wid="+wid+" win.document.title: "+win.document.title);
|
log.debug("=== hwnd="+hwnd+" wid="+wid+" win.document.title: "+win.document.title);
|
||||||
|
|
||||||
if (this.windows.hasOwnProperty(wid)) {
|
if (this.windows.hasOwnProperty(wid)) {
|
||||||
|
Loading…
Reference in New Issue
Block a user