nsIWinAppHelper 编辑

toolkit/xre/nsIWinAppHelper.idlScriptable Used on Windows only to do some work from a special process that gets created with elevated privileges. 1.0 66 Introduced Gecko 1.8 Inherits from: nsISupports Last changed in Gecko 1.9.2 (Firefox 3.6 / Thunderbird 3.1 / Fennec 1.0)

Implemented by: @mozilla.org/xre/app-info;1. To create an instance, use:

var xulAppInfo = Components.classes["@mozilla.org/xre/app-info;1"]
                 .getService(Components.interfaces.nsIWinAppHelper);

The nsIXULAppInfo and nsIXULRuntime interfaces are also implemented by "xre/app-info".

Method overview

void fixReg(); Obsolete since Gecko 1.9
void postUpdate(in nsILocalFile logFile); Obsolete since Gecko 1.9.2

Attributes

AttributeTypeDescription
userCanElevateboolean

Read only. Returns true only if all the following conditions are all true at once:

  • The operating system is at least Windows Vista
  • User Account Control is enabled
  • The user is an Administrator
  • The application is not already running with elevated permissions

Otherwise it returns false.

Methods

fixReg()

Obsolete since Gecko 1.9 (Firefox 3)

Invokes helper.exe with the /fixreg parameter. Note that this parameter was never actually supported.

void fixReg();
Parameters

None.

postUpdate()

Obsolete since Gecko 1.9.2 (Firefox 3.6 / Thunderbird 3.1 / Fennec 1.0)

Invokes helper.exe with the /postupdate parameter. This updates the uninstallation log so that the application can be uninstalled correctly after an update.

void postUpdate(
  in nsILocalFile logFile
);
Parameters
logFile

The file to use for the uninstallation log. The path is passed to helper.exe as the /uninstalllog parameter.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据

词条统计

浏览:84 次

字数:3444

最后编辑:7年前

编辑次数:0 次

    我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
    原文