Fix for KeyUp triggers us hitting the disk duing PIE and killing performance. Stop updating menu when PIE viewport has focus. Tested without this in place where things like CMD+N don't function anyway with PIE viewport focused, so it keeps that functionality. Tested PIE selecgtedviewport and new editor window.

Also use the CachedSolutionPath in XcodeCodeAccessor as an actual cache rather then computing each time.

#jira UE-60257
#rb michael.trepka

#ROBOMERGE-SOURCE: CL 4127174 in //UE4/Release-4.20/...
#ROBOMERGE-BOT: RELEASE (Release-4.20 -> Release-Staging-4.20)

[CL 4127178 by richard wallis in Staging-4.20 branch]
This commit is contained in:
richard wallis
2018-06-13 10:31:29 -04:00
parent 2e5bbcc9cc
commit 7be4314df2
2 changed files with 27 additions and 10 deletions

View File

@@ -82,22 +82,26 @@ void FXCodeSourceCodeAccessor::Startup()
void FXCodeSourceCodeAccessor::Shutdown()
{
CachedSolutionPath.Empty();
}
FString FXCodeSourceCodeAccessor::GetSolutionPath() const
{
if(IsInGameThread())
{
CachedSolutionPath = FPaths::ProjectDir();
if (!FUProjectDictionary(FPaths::RootDir()).IsForeignProject(CachedSolutionPath))
if(CachedSolutionPath.Len() <= 0)
{
CachedSolutionPath = FPaths::Combine(FPaths::RootDir(), + TEXT("UE4.xcworkspace/contents.xcworkspacedata"));
}
else
{
FString BaseName = FApp::HasProjectName() ? FApp::GetProjectName() : FPaths::GetBaseFilename(CachedSolutionPath);
CachedSolutionPath = FPaths::Combine(CachedSolutionPath, BaseName + TEXT(".xcworkspace/contents.xcworkspacedata"));
CachedSolutionPath = FPaths::ProjectDir();
if (!FUProjectDictionary(FPaths::RootDir()).IsForeignProject(CachedSolutionPath))
{
CachedSolutionPath = FPaths::Combine(FPaths::RootDir(), + TEXT("UE4.xcworkspace/contents.xcworkspacedata"));
}
else
{
FString BaseName = FApp::HasProjectName() ? FApp::GetProjectName() : FPaths::GetBaseFilename(CachedSolutionPath);
CachedSolutionPath = FPaths::Combine(CachedSolutionPath, BaseName + TEXT(".xcworkspace/contents.xcworkspacedata"));
}
}
}
return CachedSolutionPath;