1 | /* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
---|
2 | /* ***** BEGIN LICENSE BLOCK *****
|
---|
3 | * Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
---|
4 | *
|
---|
5 | * The contents of this file are subject to the Mozilla Public License Version
|
---|
6 | * 1.1 (the "License"); you may not use this file except in compliance with
|
---|
7 | * the License. You may obtain a copy of the License at
|
---|
8 | * http://www.mozilla.org/MPL/
|
---|
9 | *
|
---|
10 | * Software distributed under the License is distributed on an "AS IS" basis,
|
---|
11 | * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
---|
12 | * for the specific language governing rights and limitations under the
|
---|
13 | * License.
|
---|
14 | *
|
---|
15 | * The Original Code is Mozilla Communicator client code, released
|
---|
16 | * March 31, 1998.
|
---|
17 | *
|
---|
18 | * The Initial Developer of the Original Code is
|
---|
19 | * Netscape Communications Corporation.
|
---|
20 | * Portions created by the Initial Developer are Copyright (C) 1998
|
---|
21 | * the Initial Developer. All Rights Reserved.
|
---|
22 | *
|
---|
23 | * Contributor(s):
|
---|
24 | * Doug Turner <[email protected]>
|
---|
25 | * IBM Corp.
|
---|
26 | *
|
---|
27 | * Alternatively, the contents of this file may be used under the terms of
|
---|
28 | * either of the GNU General Public License Version 2 or later (the "GPL"),
|
---|
29 | * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
---|
30 | * in which case the provisions of the GPL or the LGPL are applicable instead
|
---|
31 | * of those above. If you wish to allow use of your version of this file only
|
---|
32 | * under the terms of either the GPL or the LGPL, and not to allow others to
|
---|
33 | * use your version of this file under the terms of the MPL, indicate your
|
---|
34 | * decision by deleting the provisions above and replace them with the notice
|
---|
35 | * and other provisions required by the GPL or the LGPL. If you do not delete
|
---|
36 | * the provisions above, a recipient may use your version of this file under
|
---|
37 | * the terms of any one of the MPL, the GPL or the LGPL.
|
---|
38 | *
|
---|
39 | * ***** END LICENSE BLOCK ***** */
|
---|
40 |
|
---|
41 | #ifndef _SPECIALSYSTEMDIRECTORY_H_
|
---|
42 | #define _SPECIALSYSTEMDIRECTORY_H_
|
---|
43 |
|
---|
44 | #include "nscore.h"
|
---|
45 | #include "nsILocalFile.h"
|
---|
46 |
|
---|
47 | #if defined(XP_MAC) || defined(XP_MACOSX)
|
---|
48 | #include <Types.h>
|
---|
49 | #include "nsILocalFileMac.h"
|
---|
50 | #include "prenv.h"
|
---|
51 | #endif
|
---|
52 |
|
---|
53 |
|
---|
54 | extern NS_COM void StartupSpecialSystemDirectory();
|
---|
55 | extern NS_COM void ShutdownSpecialSystemDirectory();
|
---|
56 |
|
---|
57 |
|
---|
58 | enum SystemDirectories {
|
---|
59 | OS_DriveDirectory = 1,
|
---|
60 | OS_TemporaryDirectory = 2,
|
---|
61 | OS_CurrentProcessDirectory= 3,
|
---|
62 | OS_CurrentWorkingDirectory= 4,
|
---|
63 | XPCOM_CurrentProcessComponentDirectory= 5,
|
---|
64 | XPCOM_CurrentProcessComponentRegistry= 6,
|
---|
65 |
|
---|
66 | Moz_BinDirectory = 100 ,
|
---|
67 | Mac_SystemDirectory = 101,
|
---|
68 | Mac_DesktopDirectory = 102,
|
---|
69 | Mac_TrashDirectory = 103,
|
---|
70 | Mac_StartupDirectory = 104,
|
---|
71 | Mac_ShutdownDirectory = 105,
|
---|
72 | Mac_AppleMenuDirectory = 106,
|
---|
73 | Mac_ControlPanelDirectory = 107,
|
---|
74 | Mac_ExtensionDirectory = 108,
|
---|
75 | Mac_FontsDirectory = 109,
|
---|
76 | Mac_ClassicPreferencesDirectory = 110,
|
---|
77 | Mac_DocumentsDirectory = 111,
|
---|
78 | Mac_InternetSearchDirectory = 112,
|
---|
79 | Mac_DefaultDownloadDirectory = 113,
|
---|
80 | Mac_UserLibDirectory = 114,
|
---|
81 | Mac_PreferencesDirectory = 115,
|
---|
82 |
|
---|
83 | Win_SystemDirectory = 201,
|
---|
84 | Win_WindowsDirectory = 202,
|
---|
85 | Win_HomeDirectory = 203,
|
---|
86 | Win_Desktop = 204,
|
---|
87 | Win_Programs = 205,
|
---|
88 | Win_Controls = 206,
|
---|
89 | Win_Printers = 207,
|
---|
90 | Win_Personal = 208,
|
---|
91 | Win_Favorites = 209,
|
---|
92 | Win_Startup = 210,
|
---|
93 | Win_Recent = 211,
|
---|
94 | Win_Sendto = 212,
|
---|
95 | Win_Bitbucket = 213,
|
---|
96 | Win_Startmenu = 214,
|
---|
97 | Win_Desktopdirectory = 215,
|
---|
98 | Win_Drives = 216,
|
---|
99 | Win_Network = 217,
|
---|
100 | Win_Nethood = 218,
|
---|
101 | Win_Fonts = 219,
|
---|
102 | Win_Templates = 220,
|
---|
103 | Win_Common_Startmenu = 221,
|
---|
104 | Win_Common_Programs = 222,
|
---|
105 | Win_Common_Startup = 223,
|
---|
106 | Win_Common_Desktopdirectory = 224,
|
---|
107 | Win_Appdata = 225,
|
---|
108 | Win_Printhood = 226,
|
---|
109 | Win_Cookies = 227,
|
---|
110 |
|
---|
111 | Unix_LocalDirectory = 301,
|
---|
112 | Unix_LibDirectory = 302,
|
---|
113 | Unix_HomeDirectory = 303,
|
---|
114 |
|
---|
115 | BeOS_SettingsDirectory = 401,
|
---|
116 | BeOS_HomeDirectory = 402,
|
---|
117 | BeOS_DesktopDirectory = 403,
|
---|
118 | BeOS_SystemDirectory = 404,
|
---|
119 |
|
---|
120 | OS2_SystemDirectory = 501,
|
---|
121 | OS2_OS2Directory = 502,
|
---|
122 | OS2_DesktopDirectory = 503,
|
---|
123 | OS2_HomeDirectory = 504
|
---|
124 | };
|
---|
125 |
|
---|
126 | nsresult
|
---|
127 | GetSpecialSystemDirectory(SystemDirectories aSystemSystemDirectory,
|
---|
128 | nsILocalFile** aFile);
|
---|
129 | #if defined(XP_MACOSX)
|
---|
130 | nsresult
|
---|
131 | GetOSXFolderType(short aDomain, OSType aFolderType, nsILocalFile **localFile);
|
---|
132 | #endif
|
---|
133 |
|
---|
134 | #endif
|
---|