Skip to content

Commit

Permalink
Added configurations for (Release/Debug With(out) Progress).
Browse files Browse the repository at this point in the history
Updated # Getting Started section in README.md.
  • Loading branch information
timcassell committed Oct 30, 2020
1 parent ba80ef6 commit b9879ab
Show file tree
Hide file tree
Showing 4 changed files with 50 additions and 20 deletions.
30 changes: 20 additions & 10 deletions ProtoPromise.sln
Original file line number Diff line number Diff line change
Expand Up @@ -9,18 +9,28 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ProtoPromise", "Runtime\Pro
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
Debug With Progress|Any CPU = Debug With Progress|Any CPU
Debug Without Progress|Any CPU = Debug Without Progress|Any CPU
Release With Progress|Any CPU = Release With Progress|Any CPU
Release Without Progress|Any CPU = Release Without Progress|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{27C1B5AC-2E73-4B91-8258-C67B4B064569}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{27C1B5AC-2E73-4B91-8258-C67B4B064569}.Debug|Any CPU.Build.0 = Debug|Any CPU
{27C1B5AC-2E73-4B91-8258-C67B4B064569}.Release|Any CPU.ActiveCfg = Release|Any CPU
{27C1B5AC-2E73-4B91-8258-C67B4B064569}.Release|Any CPU.Build.0 = Release|Any CPU
{2A0BBD14-FA01-467C-8A42-55C5C287F66D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{2A0BBD14-FA01-467C-8A42-55C5C287F66D}.Debug|Any CPU.Build.0 = Debug|Any CPU
{2A0BBD14-FA01-467C-8A42-55C5C287F66D}.Release|Any CPU.ActiveCfg = Release|Any CPU
{2A0BBD14-FA01-467C-8A42-55C5C287F66D}.Release|Any CPU.Build.0 = Release|Any CPU
{27C1B5AC-2E73-4B91-8258-C67B4B064569}.Debug With Progress|Any CPU.ActiveCfg = Debug With Progress|Any CPU
{27C1B5AC-2E73-4B91-8258-C67B4B064569}.Debug With Progress|Any CPU.Build.0 = Debug With Progress|Any CPU
{27C1B5AC-2E73-4B91-8258-C67B4B064569}.Debug Without Progress|Any CPU.ActiveCfg = Release Without Progress|Any CPU
{27C1B5AC-2E73-4B91-8258-C67B4B064569}.Debug Without Progress|Any CPU.Build.0 = Release Without Progress|Any CPU
{27C1B5AC-2E73-4B91-8258-C67B4B064569}.Release With Progress|Any CPU.ActiveCfg = Release With Progress|Any CPU
{27C1B5AC-2E73-4B91-8258-C67B4B064569}.Release With Progress|Any CPU.Build.0 = Release With Progress|Any CPU
{27C1B5AC-2E73-4B91-8258-C67B4B064569}.Release Without Progress|Any CPU.ActiveCfg = Release Without Progress|Any CPU
{27C1B5AC-2E73-4B91-8258-C67B4B064569}.Release Without Progress|Any CPU.Build.0 = Release Without Progress|Any CPU
{2A0BBD14-FA01-467C-8A42-55C5C287F66D}.Debug With Progress|Any CPU.ActiveCfg = Debug With Progress|Any CPU
{2A0BBD14-FA01-467C-8A42-55C5C287F66D}.Debug With Progress|Any CPU.Build.0 = Debug With Progress|Any CPU
{2A0BBD14-FA01-467C-8A42-55C5C287F66D}.Debug Without Progress|Any CPU.ActiveCfg = Release Without Progress|Any CPU
{2A0BBD14-FA01-467C-8A42-55C5C287F66D}.Debug Without Progress|Any CPU.Build.0 = Release Without Progress|Any CPU
{2A0BBD14-FA01-467C-8A42-55C5C287F66D}.Release With Progress|Any CPU.ActiveCfg = Release With Progress|Any CPU
{2A0BBD14-FA01-467C-8A42-55C5C287F66D}.Release With Progress|Any CPU.Build.0 = Release With Progress|Any CPU
{2A0BBD14-FA01-467C-8A42-55C5C287F66D}.Release Without Progress|Any CPU.ActiveCfg = Release Without Progress|Any CPU
{2A0BBD14-FA01-467C-8A42-55C5C287F66D}.Release Without Progress|Any CPU.Build.0 = Release Without Progress|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down
9 changes: 5 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,13 +82,14 @@ Also check out the [C# Asynchronous Benchmarks](https://github.com/timcassell/CS
2. Extract the source code from the zip.
3. Now you have 2 options:
A. Use dll
1. Open the ProtoPromise.sln in Visual Studio 2019.
2. Set the compiler symbol `PROTO_PROMISE_PROGRESS_DISABLE` if you want to disable progress.
1. Open the ProtoPromise.sln in Visual Studio 2019 or later.
2. Select the configuration you want (Release/Debug With(out) Progress).
3. Build the solution.
4. Select the dll you want to use under `Runtime/bin` and use that in your own project.
B. Use source code
1. Place the entire `Runtime` folder in your project directory and add the `ProtoPromise.csproj` project reference to your solution.
2. Set the compiler symbol `PROTO_PROMISE_PROGRESS_DISABLE` if you want to disable progress.
1. (optional) Place the entire `Runtime` folder in your project directory.
2. Add the `ProtoPromise.csproj` project reference to your solution (Visual Studio).
3. Set the compiler symbol `PROTO_PROMISE_PROGRESS_DISABLE` if you want to disable progress.
4. When you have the ProtoPromise assembly referenced in your project, once per frame (or application update loop), call `Proto.Promises.Promise.Manager.HandleCompletesAndProgress()`, ideally as the last thing before the frame is rendered (or the update loop starts over). This should only be done on the UI/main thread.
5. Continue to [Creating a Promise for an Async Operation](#creating-a-promise-for-an-async-operation).

Expand Down
15 changes: 12 additions & 3 deletions Runtime/ProtoPromise.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,23 @@
<PropertyGroup>
<TargetFrameworks>netcoreapp3.1;netstandard2.1;netstandard2.0</TargetFrameworks>
<RootNamespace>ProtoPromise</RootNamespace>
<Configurations>Debug With Progress;Release Without Progress;Release With Progress;Debug Without Progress</Configurations>
</PropertyGroup>

<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release With Progress|AnyCPU'">
<DefineConstants>CSHARP_7_3_OR_NEWER;CSHARP_7_OR_LATER</DefineConstants>
</PropertyGroup>

<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<DefineConstants>CSHARP_7_3_OR_NEWER;CSHARP_7_OR_LATER</DefineConstants>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Without Progress|AnyCPU'">
<DefineConstants>CSHARP_7_3_OR_NEWER;CSHARP_7_OR_LATER;PROTO_PROMISE_PROGRESS_DISABLE</DefineConstants>
</PropertyGroup>

<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug With Progress|AnyCPU'">
<DefineConstants>DEBUG;CSHARP_7_3_OR_NEWER;CSHARP_7_OR_LATER</DefineConstants>
</PropertyGroup>

<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Without Progress|AnyCPU'">
<DefineConstants>DEBUG;CSHARP_7_3_OR_NEWER;CSHARP_7_OR_LATER;PROTO_PROMISE_PROGRESS_DISABLE</DefineConstants>
</PropertyGroup>

<ItemGroup>
Expand Down
16 changes: 13 additions & 3 deletions Tests/ProtoPromiseTests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,24 @@
<TargetFramework>netcoreapp3.1</TargetFramework>

<IsPackable>false</IsPackable>

<Configurations>Debug With Progress;Release Without Progress;Release With Progress;Debug Without Progress</Configurations>
</PropertyGroup>

<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release With Progress|AnyCPU'">
<DefineConstants>CSHARP_7_3_OR_NEWER;CSHARP_7_OR_LATER</DefineConstants>
</PropertyGroup>

<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<DefineConstants>CSHARP_7_3_OR_NEWER;CSHARP_7_OR_LATER</DefineConstants>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Without Progress|AnyCPU'">
<DefineConstants>CSHARP_7_3_OR_NEWER;CSHARP_7_OR_LATER;PROTO_PROMISE_PROGRESS_DISABLE</DefineConstants>
</PropertyGroup>

<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug With Progress|AnyCPU'">
<DefineConstants>DEBUG;CSHARP_7_3_OR_NEWER;CSHARP_7_OR_LATER</DefineConstants>
</PropertyGroup>

<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Without Progress|AnyCPU'">
<DefineConstants>DEBUG;CSHARP_7_3_OR_NEWER;CSHARP_7_OR_LATER;PROTO_PROMISE_PROGRESS_DISABLE</DefineConstants>
</PropertyGroup>

<ItemGroup>
Expand Down

0 comments on commit b9879ab

Please sign in to comment.