Bug 962314 - Create nsIXULAppinfo.processID for obtaining Firefox PID; r=bsmedberg

--HG--
extra : rebase_source : 36536f7ed561dda55bc067a4d0d9ddef790bed17
This commit is contained in:
Kathleen Brade 2014-03-26 11:55:22 -04:00
Родитель 061be48b00
Коммит 2dcb20430e
2 изменённых файлов: 17 добавлений и 1 удалений

Просмотреть файл

@ -790,6 +790,17 @@ nsXULAppInfo::GetProcessType(uint32_t* aResult)
return NS_OK;
}
NS_IMETHODIMP
nsXULAppInfo::GetProcessID(uint32_t* aResult)
{
#ifdef XP_WIN
*aResult = GetCurrentProcessId();
#else
*aResult = getpid();
#endif
return NS_OK;
}
static bool gBrowserTabsRemote = false;
static bool gBrowserTabsRemoteInitialized = false;

Просмотреть файл

@ -20,7 +20,7 @@ bool BrowserTabsRemote();
* stable/frozen, please contact Benjamin Smedberg.
*/
[scriptable, uuid(ef6df588-f0bf-4e38-949e-9de838c228ea)]
[scriptable, uuid(e080b1f6-8452-4bde-9368-c795808b86d1)]
interface nsIXULRuntime : nsISupports
{
/**
@ -76,6 +76,11 @@ interface nsIXULRuntime : nsISupports
*/
readonly attribute unsigned long processType;
/**
* The system process ID of the caller's process.
*/
readonly attribute unsigned long processID;
/**
* If true, browser tabs may be opened in a different process from the main
* browser UI.