uriloader/exthandler/nsIInternetConfigService.idl
author Simon Montagu <smontagu@smontagu.org>
Mon, 11 Aug 2008 18:11:41 +0300
changeset 16555 ea563fdea8225b59c5c617ccd1d4d76c7691a969
parent 1 9b2a99adc05e53cd4010de512f50118594756650
child 26366 b8dde9bd27382ea4c41c52bb303ba96eab1591be
permissions -rw-r--r--
Bug 447853. Remove obsolete intl/ctl module. r=ted, sr=roc

/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
 * Version: MPL 1.1/GPL 2.0/LGPL 2.1
 *
 * The contents of this file are subject to the Mozilla Public License Version
 * 1.1 (the "License"); you may not use this file except in compliance with
 * the License. You may obtain a copy of the License at
 * http://www.mozilla.org/MPL/
 *
 * Software distributed under the License is distributed on an "AS IS" basis,
 * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
 * for the specific language governing rights and limitations under the
 * License.
 *
 * The Original Code is Mozilla Communicator client code.
 *
 * The Initial Developer of the Original Code is
 * Netscape Communications Corporation.
 * Portions created by the Initial Developer are Copyright (C) 2000
 * the Initial Developer. All Rights Reserved.
 *
 * Contributor(s):
 *
 * Alternatively, the contents of this file may be used under the terms of
 * either of the GNU General Public License Version 2 or later (the "GPL"),
 * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
 * in which case the provisions of the GPL or the LGPL are applicable instead
 * of those above. If you wish to allow use of your version of this file only
 * under the terms of either the GPL or the LGPL, and not to allow others to
 * use your version of this file under the terms of the MPL, indicate your
 * decision by deleting the provisions above and replace them with the notice
 * and other provisions required by the GPL or the LGPL. If you do not delete
 * the provisions above, a recipient may use your version of this file under
 * the terms of any one of the MPL, the GPL or the LGPL.
 *
 * ***** END LICENSE BLOCK ***** */

#include "nsISupports.idl"

interface nsIMIMEInfo;
interface nsIURL;

%{C++

#include <Files.h>

#define NS_INTERNETCONFIGSERVICE_CONTRACTID \
"@mozilla.org/mac/internet-config-service;1"

%}

native FSSpec(FSSpec);
[ptr] native FSSpecPtr(FSSpec);

[scriptable, uuid(9B8B9D80-5F4F-11D4-9696-0060083A0BCF)]
interface nsIInternetConfigService : nsISupports
{
  const unsigned long eICColor_WebBackgroundColour = 1;
  const unsigned long eICColor_WebReadColor = 2;
  const unsigned long eICColor_WebTextColor = 3;
  const unsigned long eICColor_WebUnreadColor = 4;
  const unsigned long eICBoolean_WebUnderlineLinks = 11;
  const unsigned long eICString_WWWHomePage = 101;
  const unsigned long eICString_WebSearchPagePrefs = 102;
  const unsigned long eICString_MacSearchHost = 103;
  const unsigned long eICString_FTPHost = 121;
  const unsigned long eICBoolean_UsePassiveFTP = 122;
  const unsigned long eICBoolean_UseFTPProxy = 123;      const unsigned long eICString_FTPProxyUser = 124; 
  const unsigned long eICString_FTPProxyAccount = 125;   const unsigned long eICString_FTPProxyHost = 126;
  const unsigned long eICString_FTPProxyPassword = 127;
  const unsigned long eICBoolean_UseHTTPProxy = 130;     const unsigned long eICString_HTTPProxyHost = 131;
  const unsigned long eICString_LDAPSearchbase = 201;    const unsigned long eICString_LDAPServer = 202;
  const unsigned long eICString_SMTPHost = 221;
  const unsigned long eICString_Email = 222;
  const unsigned long eICString_MailAccount = 223;       const unsigned long eICString_MailPassword = 224;
  const unsigned long eICText_MailHeaders = 225;         const unsigned long eICText_Signature = 226;
  const unsigned long eICBoolean_NewMailDialog = 231;
  const unsigned long eICBoolean_NewMailFlashIcon = 232;
  const unsigned long eICBoolean_NewMailPlaySound = 233; const unsigned long eICString_NewMailSoundName = 234;
  const unsigned long eICString_NNTPHost = 241;
  const unsigned long eICString_NewsAuthUsername = 242;  const unsigned long eICString_NewsAuthPassword = 243;
  const unsigned long eICText_NewsHeaders = 244;
  const unsigned long eICString_InfoMacPreferred = 245;
  const unsigned long eICString_Organization = 251;      const unsigned long eICString_RealName = 252;
  const unsigned long eICText_SnailMailAddress = 253;
  const unsigned long eICString_QuotingString = 254;
  const unsigned long eICString_GopherHost = 301;
  const unsigned long eICBoolean_UseGopherProxy = 302;   const unsigned long eICString_GopherProxy = 303;
  const unsigned long eICBoolean_UseSocks = 321;         const unsigned long eICString_SocksHost = 322;
  const unsigned long eICString_TelnetHost = 331;
  const unsigned long eICString_IRCHost = 341;
  const unsigned long eICString_NTPHost = 351;
  const unsigned long eICString_WAISGateway = 381;
  const unsigned long eICString_FingerHost = 382;        const unsigned long eICText_Plan = 383;
  const unsigned long eICString_WhoisHost = 384;
  const unsigned long eICString_PhHost = 385;
  const unsigned long eICString_ArchiePreferred = 386;
  const unsigned long eICString_UMichPreferred = 391;

  const unsigned long eIICMapFlag_BinaryMask            = 1;  /* file should be transfered in binary as opposed to text mode*/
  const unsigned long eIICMapFlag_ResourceForkMask      = 2;  /* the resource fork of the file is significant*/
  const unsigned long eIICMapFlag_DataForkMask          = 4;  /* the data fork of the file is significant*/
  const unsigned long eIICMapFlag_PostMask              = 8;  /* post process using post fields*/
  const unsigned long eIICMapFlag_NotIncomingMask       = 16; /* ignore this mapping for incoming files*/
  const unsigned long eIICMapFlag_NotOutgoingMask       = 32; /* ignore this mapping for outgoing files*/


  void launchURL(in string url);
  
  boolean hasMappingForMIMEType(in string mimetype);
  
  boolean hasProtocolHandler(in string protocol);
  
  // pass in a mime type or a file extension.....
  void fillInMIMEInfo(in string mimetype, in string aFileExtension, out nsIMIMEInfo mimeinfo);
  
  void getMIMEInfoFromExtension(in string aFileExt, out nsIMIMEInfo mimeinfo);
  
  void getMIMEInfoFromTypeCreator(in PRUint32 aType, in PRUint32 aCreator, in string aFileExt, out nsIMIMEInfo mimeInfo);
  
  //Return a File Mapping for the specified file. If no mapping found, return -1.
  [noscript] long getFileMappingFlags(in FSSpecPtr fsspec, in boolean lookupByExtensionFirst);
  
  [noscript] void getDownloadFolder(out FSSpec fsspec);
  
  ACString getString(in unsigned long keyenum);

  unsigned long getColor(in unsigned long keyenum);

  boolean getBoolean(in unsigned long keyenum);
};