def getWindowPID(self, hwnd):
        """ Gets the process ID that the specified window belongs to """
        for w in self._get_window_list():
            if "kCGWindowNumber" in w and w["kCGWindowNumber"] == hwnd:
                return w["kCGWindowOwnerPID"]
Gets the process ID that the specified window belongs to