diff --git a/pyfpdb/Hud.py b/pyfpdb/Hud.py index 80ec9a82..aaa9b42d 100644 --- a/pyfpdb/Hud.py +++ b/pyfpdb/Hud.py @@ -307,6 +307,7 @@ class Stat_Window: pass if event.button == 1: # left button event + # TODO: make position saving save sizes as well? if event.state & gtk.gdk.SHIFT_MASK: self.window.begin_resize_drag(gtk.gdk.WINDOW_EDGE_SOUTH_EAST, event.button, int(event.x_root), int(event.y_root), event.time) else: diff --git a/pyfpdb/Tables.py b/pyfpdb/Tables.py index 9f5360e2..d2cb2a24 100755 --- a/pyfpdb/Tables.py +++ b/pyfpdb/Tables.py @@ -248,7 +248,9 @@ def get_nt_exe(hwnd): """Finds the name of the executable that the given window handle belongs to.""" processid = win32process.GetWindowThreadProcessId(hwnd) pshandle = win32api.OpenProcess(win32con.PROCESS_QUERY_INFORMATION | win32con.PROCESS_VM_READ, False, processid[1]) - return win32process.GetModuleFileNameEx(pshandle, 0) + exename = win32process.GetModuleFileNameEx(pshandle, 0) + win32api.CloseHandle(pshandle) + return exename def decode_windows(c, title, hwnd): """Gets window parameters from the window title and handle--Windows."""