tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

nsIShellService.idl (2494B)


      1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
      2 /* This Source Code Form is subject to the terms of the Mozilla Public
      3 * License, v. 2.0. If a copy of the MPL was not distributed with this
      4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
      5 
      6 #include "nsISupports.idl"
      7 
      8 interface nsIFile;
      9 
     10 webidl Element;
     11 
     12 [scriptable, uuid(2d1a95e4-5bd8-4eeb-b0a8-c1455fd2a357)]
     13 interface nsIShellService : nsISupports
     14 {
     15  /**
     16   * Determines whether or not Firefox is the "Default Browser."
     17   * This is simply whether or not Firefox is registered to handle
     18   * http links.
     19   *
     20   * @param aForAllTypes  true if the check should be made for HTTP and HTML.
     21   *                      false if the check should be made for HTTP only.
     22   *                      This parameter may be ignored on some platforms.
     23   */
     24  boolean isDefaultBrowser([optional] in boolean aForAllTypes);
     25 
     26  /**
     27   * Registers Firefox as the "Default Browser."
     28   *
     29   * @param aForAllUsers   Whether or not Firefox should attempt
     30   *                       to become the default browser for all
     31   *                       users on a multi-user system.
     32   */
     33  void setDefaultBrowser(in boolean aForAllUsers);
     34 
     35  /**
     36   * Flags for positioning/sizing of the Desktop Background image.
     37   */
     38  const long BACKGROUND_TILE      = 1;
     39  const long BACKGROUND_STRETCH   = 2;
     40  const long BACKGROUND_CENTER    = 3;
     41  const long BACKGROUND_FILL      = 4;
     42  const long BACKGROUND_FIT       = 5;
     43  const long BACKGROUND_SPAN      = 6;
     44 
     45    /**
     46     * Sets the desktop background image using either the HTML <IMG>
     47     * element supplied or the background image of the element supplied.
     48     *
     49     * @param aImageElement Either a HTML <IMG> element or an element with
     50     *                      a background image from which to source the
     51     *                      background image.
     52     * @param aPosition     How to place the image on the desktop
     53     * @param aImageName    The image name. Equivalent to the leaf name of the
     54     *                      location.href.
     55     */
     56  void setDesktopBackground(in Element aElement,
     57                            in long aPosition,
     58                            in ACString aImageName);
     59 
     60  /**
     61   * The desktop background color, visible when no background image is
     62   * used, or if the background image is centered and does not fill the
     63   * entire screen. A rgb value, where (r << 16 | g << 8 | b)
     64   */
     65  attribute unsigned long desktopBackgroundColor;
     66 };