environ.py 文件源码

python
阅读 21 收藏 0 点赞 0 评论 0

项目:jaraco.windows 作者: jaraco 项目源码 文件源码
def notify(class_):
        """
        Notify other windows that the environment has changed (following
        http://support.microsoft.com/kb/104011).
        """
        # TODO: Implement Microsoft UIPI (User Interface Privilege Isolation) to
        #  elevate privilege to system level so the system gets this notification
        # for now, this must be run as admin to work as expected
        return_val = ctypes.wintypes.DWORD()
        res = message.SendMessageTimeout(
            message.HWND_BROADCAST,
            message.WM_SETTINGCHANGE,
            0, # wparam must be null
            'Environment',
            message.SMTO_ABORTIFHUNG,
            5000, # timeout in ms
            return_val,
        )
        error.handle_nonzero_success(res)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号