Skip to content

Commit

Permalink
Merge pull request #32 from xTheEc0/patch-1
Browse files Browse the repository at this point in the history
Patch 1
  • Loading branch information
meslubi2021 authored Aug 15, 2024
2 parents aed1696 + 830e09c commit b1f6c1f
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 21 deletions.
1 change: 0 additions & 1 deletion Facebook.Unity.Editor/FacebookPostprocess.cs
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,6 @@ public static void OnPostProcessBuild(BuildTarget target, string path)
if (target.ToString() == "iOS" || target.ToString() == "iPhone")
{
UpdatePlist(path);
FixupFiles.FixColdStart(path);
FixupFiles.AddBuildFlag(path);
}

Expand Down
20 changes: 0 additions & 20 deletions Facebook.Unity.Editor/iOS/FixupFiles.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,26 +28,6 @@ namespace Facebook.Unity.Editor

public class FixupFiles
{
private static string didFinishLaunchingWithOptions =
@"(?x) # Verbose mode
(didFinishLaunchingWithOptions.+ # Find this function...
(?:.*\n)+? # Match as few lines as possible until...
\s*return\ )NO(\;\n # return NO;
\}) # }";

public static void FixColdStart(string path)
{
string fullPath = Path.Combine(path, Path.Combine("Classes", "UnityAppController.mm"));
string data = Load(fullPath);

data = Regex.Replace(
data,
didFinishLaunchingWithOptions,
"$1YES$2");

Save(fullPath, data);
}

public static void AddBuildFlag(string path)
{
string projPath = Path.Combine(path, Path.Combine("Unity-iPhone.xcodeproj", "project.pbxproj"));
Expand Down

0 comments on commit b1f6c1f

Please sign in to comment.