Browse Source

new ChildProcess::getPID()

pull/8/head
falkTX 7 years ago
parent
commit
b6b2fef0d0
4 changed files with 17 additions and 0 deletions
  1. +5
    -0
      modules/juce_core/native/juce_posix_SharedCode.h
  2. +5
    -0
      modules/juce_core/native/juce_win32_Threads.cpp
  3. +5
    -0
      modules/juce_core/threads/juce_ChildProcess.cpp
  4. +2
    -0
      modules/juce_core/threads/juce_ChildProcess.h

+ 5
- 0
modules/juce_core/native/juce_posix_SharedCode.h View File

@@ -1234,6 +1234,11 @@ public:
return 0;
}
int getPID() const noexcept
{
return childPID;
}
int childPID;
private:


+ 5
- 0
modules/juce_core/native/juce_win32_Threads.cpp View File

@@ -488,6 +488,11 @@ public:
return (uint32) exitCode;
}
int getPID() const noexcept
{
return 0;
}
bool ok;
private:


+ 5
- 0
modules/juce_core/threads/juce_ChildProcess.cpp View File

@@ -75,6 +75,11 @@ String ChildProcess::readAllProcessOutput()
return result.toString();
}
uint32 ChildProcess::getPID() const noexcept
{
return activeProcess != nullptr ? activeProcess->getPID() : 0;
}
//==============================================================================
#if JUCE_UNIT_TESTS


+ 2
- 0
modules/juce_core/threads/juce_ChildProcess.h View File

@@ -99,6 +99,8 @@ public:
*/
bool kill();
uint32 getPID() const noexcept;
private:
//==============================================================================
class ActiveProcess;


Loading…
Cancel
Save