Integrating latest from github/staging
Integrating up through commit 5e1bdae
This commit is contained in:
+3
-3
@@ -22,7 +22,7 @@
|
||||
|
||||
#include <AzFramework/StringFunc/StringFunc.h>
|
||||
|
||||
#include <AzToolsFramework/Process/ProcessWatcher.h>
|
||||
#include <AzFramework/Process/ProcessWatcher.h>
|
||||
#include <AzToolsFramework/SourceControl/PerforceConnection.h>
|
||||
|
||||
namespace AzToolsFramework
|
||||
@@ -1251,14 +1251,14 @@ namespace AzToolsFramework
|
||||
return changelistNum;
|
||||
}
|
||||
|
||||
ProcessWatcher* pWatcher = s_perforceConn->m_command.ExecuteNewChangelistInput();
|
||||
AzFramework::ProcessWatcher* pWatcher = s_perforceConn->m_command.ExecuteNewChangelistInput();
|
||||
AZ_Assert(pWatcher, "No process found for p4!");
|
||||
if (!pWatcher)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
ProcessCommunicator* pCommunicator = pWatcher->GetCommunicator();
|
||||
AzFramework::ProcessCommunicator* pCommunicator = pWatcher->GetCommunicator();
|
||||
AZ_Assert(pCommunicator, "No communicator found for p4!");
|
||||
if (!pCommunicator)
|
||||
{
|
||||
|
||||
+12
-12
@@ -13,7 +13,7 @@
|
||||
#include "AzToolsFramework_precompiled.h"
|
||||
|
||||
#include <AzToolsFramework/SourceControl/PerforceConnection.h>
|
||||
#include <AzToolsFramework/Process/ProcessWatcher.h>
|
||||
#include <AzFramework/Process/ProcessWatcher.h>
|
||||
|
||||
#define SCC_WINDOW "Source Control"
|
||||
|
||||
@@ -331,7 +331,7 @@ namespace AzToolsFramework
|
||||
ExecuteCommand();
|
||||
}
|
||||
|
||||
ProcessWatcher* PerforceCommand::ExecuteNewChangelistInput()
|
||||
AzFramework::ProcessWatcher* PerforceCommand::ExecuteNewChangelistInput()
|
||||
{
|
||||
m_commandArgs = "change -i";
|
||||
return ExecuteIOCommand();
|
||||
@@ -370,31 +370,31 @@ namespace AzToolsFramework
|
||||
void PerforceCommand::ExecuteCommand()
|
||||
{
|
||||
m_rawOutput.Clear();
|
||||
ProcessLauncher::ProcessLaunchInfo processLaunchInfo;
|
||||
AzFramework::ProcessLauncher::ProcessLaunchInfo processLaunchInfo;
|
||||
processLaunchInfo.m_commandlineParameters = "p4 -ztag " + m_commandArgs;
|
||||
processLaunchInfo.m_showWindow = false;
|
||||
ProcessWatcher::LaunchProcessAndRetrieveOutput(processLaunchInfo, ProcessCommunicationType::COMMUNICATOR_TYPE_STDINOUT, m_rawOutput);
|
||||
m_applicationFound = processLaunchInfo.m_launchResult == ProcessLauncher::PLR_MissingFile ? false : true;
|
||||
AzFramework::ProcessWatcher::LaunchProcessAndRetrieveOutput(processLaunchInfo, AzFramework::ProcessCommunicationType::COMMUNICATOR_TYPE_STDINOUT, m_rawOutput);
|
||||
m_applicationFound = processLaunchInfo.m_launchResult == AzFramework::ProcessLauncher::PLR_MissingFile ? false : true;
|
||||
}
|
||||
|
||||
ProcessWatcher* PerforceCommand::ExecuteIOCommand()
|
||||
AzFramework::ProcessWatcher* PerforceCommand::ExecuteIOCommand()
|
||||
{
|
||||
ProcessLauncher::ProcessLaunchInfo processLaunchInfo;
|
||||
AzFramework::ProcessLauncher::ProcessLaunchInfo processLaunchInfo;
|
||||
processLaunchInfo.m_commandlineParameters = "p4 " + m_commandArgs;
|
||||
processLaunchInfo.m_showWindow = false;
|
||||
ProcessWatcher* processWatcher = ProcessWatcher::LaunchProcess(processLaunchInfo, ProcessCommunicationType::COMMUNICATOR_TYPE_STDINOUT);
|
||||
m_applicationFound = processLaunchInfo.m_launchResult == ProcessLauncher::PLR_MissingFile ? false : true;
|
||||
AzFramework::ProcessWatcher* processWatcher = AzFramework::ProcessWatcher::LaunchProcess(processLaunchInfo, AzFramework::ProcessCommunicationType::COMMUNICATOR_TYPE_STDINOUT);
|
||||
m_applicationFound = processLaunchInfo.m_launchResult == AzFramework::ProcessLauncher::PLR_MissingFile ? false : true;
|
||||
return processWatcher;
|
||||
}
|
||||
|
||||
void PerforceCommand::ExecuteRawCommand()
|
||||
{
|
||||
m_rawOutput.Clear();
|
||||
ProcessLauncher::ProcessLaunchInfo processLaunchInfo;
|
||||
AzFramework::ProcessLauncher::ProcessLaunchInfo processLaunchInfo;
|
||||
processLaunchInfo.m_commandlineParameters = "p4 " + m_commandArgs;
|
||||
processLaunchInfo.m_showWindow = false;
|
||||
ProcessWatcher::LaunchProcessAndRetrieveOutput(processLaunchInfo, ProcessCommunicationType::COMMUNICATOR_TYPE_STDINOUT, m_rawOutput);
|
||||
m_applicationFound = processLaunchInfo.m_launchResult == ProcessLauncher::PLR_MissingFile ? false : true;
|
||||
AzFramework::ProcessWatcher::LaunchProcessAndRetrieveOutput(processLaunchInfo, AzFramework::ProcessCommunicationType::COMMUNICATOR_TYPE_STDINOUT, m_rawOutput);
|
||||
m_applicationFound = processLaunchInfo.m_launchResult == AzFramework::ProcessLauncher::PLR_MissingFile ? false : true;
|
||||
}
|
||||
|
||||
AZStd::string PerforceConnection::GetUser() const
|
||||
|
||||
@@ -13,16 +13,19 @@
|
||||
#pragma once
|
||||
|
||||
#include <AzToolsFramework/SourceControl/PerforceComponent.h>
|
||||
#include <AzToolsFramework/Process/ProcessCommunicator.h>
|
||||
#include <AzFramework/Process/ProcessCommunicator.h>
|
||||
|
||||
namespace AzFramework
|
||||
{
|
||||
class ProcessWatcher;
|
||||
}
|
||||
|
||||
namespace AzToolsFramework
|
||||
{
|
||||
class ProcessWatcher;
|
||||
|
||||
class PerforceCommand
|
||||
{
|
||||
public:
|
||||
ProcessOutput m_rawOutput;
|
||||
AzFramework::ProcessOutput m_rawOutput;
|
||||
PerforceMap m_commandOutputMap; // doesn't allow duplicate kvp's
|
||||
AZStd::vector<PerforceMap> m_commandOutputMapList; // allows duplicate kvp's
|
||||
|
||||
@@ -79,7 +82,7 @@ namespace AzToolsFramework
|
||||
void ExecuteTicketStatus();
|
||||
void ExecuteTrust(bool enable, const AZStd::string& fingerprint);
|
||||
|
||||
ProcessWatcher* ExecuteNewChangelistInput();
|
||||
AzFramework::ProcessWatcher* ExecuteNewChangelistInput();
|
||||
void ExecuteNewChangelistOutput();
|
||||
void ExecuteRevert(const AZStd::string& filePath);
|
||||
void ExecuteShowChangelists(const AZStd::string& currentUser, const AZStd::string& currentClient);
|
||||
@@ -91,7 +94,7 @@ namespace AzToolsFramework
|
||||
bool m_applicationFound = false;
|
||||
|
||||
virtual void ExecuteCommand();
|
||||
virtual ProcessWatcher* ExecuteIOCommand();
|
||||
virtual AzFramework::ProcessWatcher* ExecuteIOCommand();
|
||||
virtual void ExecuteRawCommand();
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user