From d82ade59b2b937a8cd4d7f3c1fecde0333c0ff0c Mon Sep 17 00:00:00 2001 From: Guy Date: Sun, 13 May 2018 04:12:15 +0300 Subject: [PATCH] Upgraded to netstandard. --- .../Properties/AssemblyInfo.cs | 0 TLSharp.Core.old/TLSharp.Core.csproj | 89 ++ TLSharp.Core/Requests/AuthSendCodeRequest.cs | 2 +- TLSharp.Core/TLSharp.Core.csproj | 96 +- TLSharp.Core/packages.config | 5 - .../TLSharp.Tests.NUnit.csproj | 54 + .../TLSharp.Tests.NUnit.csproj | 58 +- TLSharp.Tests.NUnit/Test.cs | 2 +- .../Properties/AssemblyInfo.cs | 0 TLSharp.Tests.VS.old/TLSharp.Tests.VS.csproj | 103 ++ TLSharp.Tests.VS/TLSharp.Tests.VS.csproj | 108 +- .../Properties/AssemblyInfo.cs | 0 TLSharp.Tests.old/TLSharp.Tests.csproj | 67 ++ TLSharp.Tests/TLSharp.Tests.csproj | 71 +- TLSharp.Tests/TLSharpTests.cs | 29 +- TLSharp.Tests/packages.config | 3 - TLSharp.sln | 73 +- .../Properties/AssemblyInfo.cs | 0 .../TeleSharp.Generator.csproj | 80 ++ .../TeleSharp.Generator.csproj | 83 +- TeleSharp.Generator/packages.config | 4 - .../Properties/AssemblyInfo.cs | 0 TeleSharp.TL.old/TeleSharp.TL.csproj | 938 +++++++++++++++++ TeleSharp.TL/TLContext.cs | 5 +- TeleSharp.TL/TeleSharp.TL.csproj | 941 +----------------- TeleSharp.TL/packages.config | 4 - 26 files changed, 1456 insertions(+), 1359 deletions(-) rename {TLSharp.Core => TLSharp.Core.old}/Properties/AssemblyInfo.cs (100%) create mode 100644 TLSharp.Core.old/TLSharp.Core.csproj delete mode 100644 TLSharp.Core/packages.config create mode 100644 TLSharp.Tests.NUnit.old/TLSharp.Tests.NUnit.csproj rename {TLSharp.Tests.VS => TLSharp.Tests.VS.old}/Properties/AssemblyInfo.cs (100%) create mode 100644 TLSharp.Tests.VS.old/TLSharp.Tests.VS.csproj rename {TLSharp.Tests => TLSharp.Tests.old}/Properties/AssemblyInfo.cs (100%) create mode 100644 TLSharp.Tests.old/TLSharp.Tests.csproj delete mode 100644 TLSharp.Tests/packages.config rename {TeleSharp.Generator => TeleSharp.Generator.old}/Properties/AssemblyInfo.cs (100%) create mode 100644 TeleSharp.Generator.old/TeleSharp.Generator.csproj delete mode 100644 TeleSharp.Generator/packages.config rename {TeleSharp.TL => TeleSharp.TL.old}/Properties/AssemblyInfo.cs (100%) create mode 100644 TeleSharp.TL.old/TeleSharp.TL.csproj delete mode 100644 TeleSharp.TL/packages.config diff --git a/TLSharp.Core/Properties/AssemblyInfo.cs b/TLSharp.Core.old/Properties/AssemblyInfo.cs similarity index 100% rename from TLSharp.Core/Properties/AssemblyInfo.cs rename to TLSharp.Core.old/Properties/AssemblyInfo.cs diff --git a/TLSharp.Core.old/TLSharp.Core.csproj b/TLSharp.Core.old/TLSharp.Core.csproj new file mode 100644 index 00000000..09dbb81f --- /dev/null +++ b/TLSharp.Core.old/TLSharp.Core.csproj @@ -0,0 +1,89 @@ + + + + + Debug + AnyCPU + {400D2544-1CC6-4D8A-A62C-2292D9947A16} + Library + Properties + TLSharp.Core + TLSharp.Core + v4.5 + 512 + + + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + ..\packages\MarkerMetro.Unity.Ionic.Zlib.2.0.0.14\lib\net35\Ionic.ZLib.dll + True + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + {d6144517-91d2-4880-86df-e9ff5d7f383a} + TeleSharp.TL + + + + + \ No newline at end of file diff --git a/TLSharp.Core/Requests/AuthSendCodeRequest.cs b/TLSharp.Core/Requests/AuthSendCodeRequest.cs index 06852a85..f06e2a0d 100644 --- a/TLSharp.Core/Requests/AuthSendCodeRequest.cs +++ b/TLSharp.Core/Requests/AuthSendCodeRequest.cs @@ -6,7 +6,7 @@ namespace TLSharp.Core.Requests { public class AuthSendCodeRequest : MTProtoRequest { - + public bool _phoneRegistered; public string _phoneCodeHash; public SendCodeArgs args=new SendCodeArgs(); diff --git a/TLSharp.Core/TLSharp.Core.csproj b/TLSharp.Core/TLSharp.Core.csproj index fbef9425..ed6dcace 100644 --- a/TLSharp.Core/TLSharp.Core.csproj +++ b/TLSharp.Core/TLSharp.Core.csproj @@ -1,89 +1,23 @@ - - - + + - Debug - AnyCPU - {400D2544-1CC6-4D8A-A62C-2292D9947A16} - Library - Properties - TLSharp.Core - TLSharp.Core - v4.5 - 512 + netstandard2.0 - - true - full - false - bin\Debug\ - DEBUG;TRACE - prompt - 4 - - - pdbonly - true - bin\Release\ - TRACE - prompt - 4 - - - - ..\packages\MarkerMetro.Unity.Ionic.Zlib.2.0.0.14\lib\net35\Ionic.ZLib.dll - True - - - - - - - - - - + - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + - + + - - {d6144517-91d2-4880-86df-e9ff5d7f383a} - TeleSharp.TL - + - - - \ No newline at end of file + + diff --git a/TLSharp.Core/packages.config b/TLSharp.Core/packages.config deleted file mode 100644 index 00518560..00000000 --- a/TLSharp.Core/packages.config +++ /dev/null @@ -1,5 +0,0 @@ - - - - - \ No newline at end of file diff --git a/TLSharp.Tests.NUnit.old/TLSharp.Tests.NUnit.csproj b/TLSharp.Tests.NUnit.old/TLSharp.Tests.NUnit.csproj new file mode 100644 index 00000000..e947f4e9 --- /dev/null +++ b/TLSharp.Tests.NUnit.old/TLSharp.Tests.NUnit.csproj @@ -0,0 +1,54 @@ + + + + Debug + AnyCPU + {E90B705B-19FA-43BA-B952-69957976D12C} + Library + TLSharp.Tests.NUnit + TLSharp.Tests.NUnit + v4.5 + + + true + full + false + bin\Debug + DEBUG; + prompt + 4 + false + + + full + true + bin\Release + prompt + 4 + false + + + + + ..\packages\NUnit.2.6.4\lib\nunit.framework.dll + + + + + + + + app.config + + + + + + + + + {DE5C0467-EE99-4734-95F2-EFF7A0B99924} + TLSharp.Tests + + + diff --git a/TLSharp.Tests.NUnit/TLSharp.Tests.NUnit.csproj b/TLSharp.Tests.NUnit/TLSharp.Tests.NUnit.csproj index e947f4e9..5bde4cab 100644 --- a/TLSharp.Tests.NUnit/TLSharp.Tests.NUnit.csproj +++ b/TLSharp.Tests.NUnit/TLSharp.Tests.NUnit.csproj @@ -1,54 +1,18 @@ - - + + - Debug - AnyCPU - {E90B705B-19FA-43BA-B952-69957976D12C} - Library - TLSharp.Tests.NUnit - TLSharp.Tests.NUnit - v4.5 + netcoreapp2.1 - - true - full - false - bin\Debug - DEBUG; - prompt - 4 - false - - - full - true - bin\Release - prompt - 4 - false - - - - - ..\packages\NUnit.2.6.4\lib\nunit.framework.dll - - - - - - - - app.config - - - + - + + + + + - - {DE5C0467-EE99-4734-95F2-EFF7A0B99924} - TLSharp.Tests - + + diff --git a/TLSharp.Tests.NUnit/Test.cs b/TLSharp.Tests.NUnit/Test.cs index 40e54ac6..31644b8b 100644 --- a/TLSharp.Tests.NUnit/Test.cs +++ b/TLSharp.Tests.NUnit/Test.cs @@ -9,7 +9,7 @@ namespace TLSharp.Tests [TestFixture] public class TLSharpTestsNUnit : TLSharpTests { - [TestFixtureSetUp] + [OneTimeSetUp] public void Init() { base.Init(o => Assert.IsNotNull(o), b => Assert.IsTrue(b)); diff --git a/TLSharp.Tests.VS/Properties/AssemblyInfo.cs b/TLSharp.Tests.VS.old/Properties/AssemblyInfo.cs similarity index 100% rename from TLSharp.Tests.VS/Properties/AssemblyInfo.cs rename to TLSharp.Tests.VS.old/Properties/AssemblyInfo.cs diff --git a/TLSharp.Tests.VS.old/TLSharp.Tests.VS.csproj b/TLSharp.Tests.VS.old/TLSharp.Tests.VS.csproj new file mode 100644 index 00000000..a44fff4b --- /dev/null +++ b/TLSharp.Tests.VS.old/TLSharp.Tests.VS.csproj @@ -0,0 +1,103 @@ + + + + Debug + AnyCPU + {AFFC3B00-3E4D-4327-8F7A-08EE41E0C8B7} + Library + Properties + TLSharp.Tests.VS + TLSharp.Tests.VS + v4.5 + 512 + {3AC096D0-A1C2-E12C-1390-A8335801FDAB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} + 10.0 + $(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion) + $(ProgramFiles)\Common Files\microsoft shared\VSTT\$(VisualStudioVersion)\UITestExtensionPackages + False + UnitTest + + + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + + + + + + + + + + + + + + + + + + + + {d6144517-91d2-4880-86df-e9ff5d7f383a} + TeleSharp.TL + + + {400d2544-1cc6-4d8a-a62c-2292d9947a16} + TLSharp.Core + + + {de5c0467-ee99-4734-95f2-eff7a0b99924} + TLSharp.Tests + + + + + app.config + + + + + + + + False + + + False + + + False + + + False + + + + + + + + \ No newline at end of file diff --git a/TLSharp.Tests.VS/TLSharp.Tests.VS.csproj b/TLSharp.Tests.VS/TLSharp.Tests.VS.csproj index a44fff4b..3f0962cf 100644 --- a/TLSharp.Tests.VS/TLSharp.Tests.VS.csproj +++ b/TLSharp.Tests.VS/TLSharp.Tests.VS.csproj @@ -1,103 +1,17 @@ - - + + - Debug - AnyCPU - {AFFC3B00-3E4D-4327-8F7A-08EE41E0C8B7} - Library - Properties - TLSharp.Tests.VS - TLSharp.Tests.VS - v4.5 - 512 - {3AC096D0-A1C2-E12C-1390-A8335801FDAB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} - 10.0 - $(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion) - $(ProgramFiles)\Common Files\microsoft shared\VSTT\$(VisualStudioVersion)\UITestExtensionPackages - False - UnitTest + netcoreapp2.1 - - true - full - false - bin\Debug\ - DEBUG;TRACE - prompt - 4 - - - pdbonly - true - bin\Release\ - TRACE - prompt - 4 - - - - - - - - - - - - - - - - - - - - + - - {d6144517-91d2-4880-86df-e9ff5d7f383a} - TeleSharp.TL - - - {400d2544-1cc6-4d8a-a62c-2292d9947a16} - TLSharp.Core - - - {de5c0467-ee99-4734-95f2-eff7a0b99924} - TLSharp.Tests - + + + + - - app.config - + - - - - - - False - - - False - - - False - - - False - - - - - - - - \ No newline at end of file + + diff --git a/TLSharp.Tests/Properties/AssemblyInfo.cs b/TLSharp.Tests.old/Properties/AssemblyInfo.cs similarity index 100% rename from TLSharp.Tests/Properties/AssemblyInfo.cs rename to TLSharp.Tests.old/Properties/AssemblyInfo.cs diff --git a/TLSharp.Tests.old/TLSharp.Tests.csproj b/TLSharp.Tests.old/TLSharp.Tests.csproj new file mode 100644 index 00000000..e2277f1c --- /dev/null +++ b/TLSharp.Tests.old/TLSharp.Tests.csproj @@ -0,0 +1,67 @@ + + + + + Debug + AnyCPU + {DE5C0467-EE99-4734-95F2-EFF7A0B99924} + Library + Properties + TLSharp.Tests + TLSharp.Tests + v4.5 + 512 + + + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + + + + + + + + + + + + + {d6144517-91d2-4880-86df-e9ff5d7f383a} + TeleSharp.TL + + + {400d2544-1cc6-4d8a-a62c-2292d9947a16} + TLSharp.Core + + + + + Always + + + + + \ No newline at end of file diff --git a/TLSharp.Tests/TLSharp.Tests.csproj b/TLSharp.Tests/TLSharp.Tests.csproj index e2277f1c..00857854 100644 --- a/TLSharp.Tests/TLSharp.Tests.csproj +++ b/TLSharp.Tests/TLSharp.Tests.csproj @@ -1,67 +1,22 @@ - - - + + - Debug - AnyCPU - {DE5C0467-EE99-4734-95F2-EFF7A0B99924} - Library - Properties - TLSharp.Tests - TLSharp.Tests - v4.5 - 512 + netstandard2.0 - - true - full - false - bin\Debug\ - DEBUG;TRACE - prompt - 4 - - - pdbonly - true - bin\Release\ - TRACE - prompt - 4 - - - - - - - - - + - - + + - - {d6144517-91d2-4880-86df-e9ff5d7f383a} - TeleSharp.TL - - - {400d2544-1cc6-4d8a-a62c-2292d9947a16} - TLSharp.Core - + + + - + Always - + - - - \ No newline at end of file + + diff --git a/TLSharp.Tests/TLSharpTests.cs b/TLSharp.Tests/TLSharpTests.cs index 34bca76b..6f8e70ae 100644 --- a/TLSharp.Tests/TLSharpTests.cs +++ b/TLSharp.Tests/TLSharpTests.cs @@ -79,42 +79,47 @@ private TelegramClient NewClient() private void GatherTestConfiguration() { string appConfigMsgWarning = "{0} not configured in app.config! Some tests may fail."; + // https://github.com/dotnet/corefx/issues/22101#issuecomment-374415132 + Configuration config = ConfigurationManager.OpenMappedExeConfiguration(new ExeConfigurationFileMap + { + ExeConfigFilename = Path.Combine(AppContext.BaseDirectory, "app.config") + }, ConfigurationUserLevel.None); - ApiHash = ConfigurationManager.AppSettings[nameof(ApiHash)]; + ApiHash = config.AppSettings.Settings[nameof(ApiHash)].Value; if (string.IsNullOrEmpty(ApiHash)) Debug.WriteLine(appConfigMsgWarning, nameof(ApiHash)); - var apiId = ConfigurationManager.AppSettings[nameof(ApiId)]; + var apiId = config.AppSettings.Settings[nameof(ApiId)].Value; if (string.IsNullOrEmpty(apiId)) Debug.WriteLine(appConfigMsgWarning, nameof(ApiId)); else ApiId = int.Parse(apiId); - NumberToAuthenticate = ConfigurationManager.AppSettings[nameof(NumberToAuthenticate)]; + NumberToAuthenticate = config.AppSettings.Settings[nameof(NumberToAuthenticate)].Value; if (string.IsNullOrEmpty(NumberToAuthenticate)) Debug.WriteLine(appConfigMsgWarning, nameof(NumberToAuthenticate)); - CodeToAuthenticate = ConfigurationManager.AppSettings[nameof(CodeToAuthenticate)]; + CodeToAuthenticate = config.AppSettings.Settings[nameof(CodeToAuthenticate)].Value; if (string.IsNullOrEmpty(CodeToAuthenticate)) Debug.WriteLine(appConfigMsgWarning, nameof(CodeToAuthenticate)); - PasswordToAuthenticate = ConfigurationManager.AppSettings[nameof(PasswordToAuthenticate)]; + PasswordToAuthenticate = config.AppSettings.Settings[nameof(PasswordToAuthenticate)].Value; if (string.IsNullOrEmpty(PasswordToAuthenticate)) Debug.WriteLine(appConfigMsgWarning, nameof(PasswordToAuthenticate)); - NotRegisteredNumberToSignUp = ConfigurationManager.AppSettings[nameof(NotRegisteredNumberToSignUp)]; + NotRegisteredNumberToSignUp = config.AppSettings.Settings[nameof(NotRegisteredNumberToSignUp)].Value; if (string.IsNullOrEmpty(NotRegisteredNumberToSignUp)) Debug.WriteLine(appConfigMsgWarning, nameof(NotRegisteredNumberToSignUp)); - UserNameToSendMessage = ConfigurationManager.AppSettings[nameof(UserNameToSendMessage)]; + UserNameToSendMessage = config.AppSettings.Settings[nameof(UserNameToSendMessage)].Value; if (string.IsNullOrEmpty(UserNameToSendMessage)) Debug.WriteLine(appConfigMsgWarning, nameof(UserNameToSendMessage)); - NumberToGetUserFull = ConfigurationManager.AppSettings[nameof(NumberToGetUserFull)]; + NumberToGetUserFull = config.AppSettings.Settings[nameof(NumberToGetUserFull)].Value; if (string.IsNullOrEmpty(NumberToGetUserFull)) Debug.WriteLine(appConfigMsgWarning, nameof(NumberToGetUserFull)); - NumberToAddToChat = ConfigurationManager.AppSettings[nameof(NumberToAddToChat)]; + NumberToAddToChat = config.AppSettings.Settings[nameof(NumberToAddToChat)].Value; if (string.IsNullOrEmpty(NumberToAddToChat)) Debug.WriteLine(appConfigMsgWarning, nameof(NumberToAddToChat)); } @@ -268,7 +273,7 @@ public virtual async Task DownloadFileFromContactTest() Version = document.Version }, document.Size); - + Assert.IsTrue(resFile.Bytes.Length > 0); } @@ -283,7 +288,7 @@ public virtual async Task DownloadFileFromWrongLocationTest() var user = result.Users .OfType() .FirstOrDefault(x => x.Id == 5880094); - + var photo = ((TLUserProfilePhoto)user.Photo); var photoLocation = (TLFileLocation) photo.PhotoBig; @@ -294,7 +299,7 @@ public virtual async Task DownloadFileFromWrongLocationTest() VolumeId = photoLocation.VolumeId }, 1024); - var res = await client.GetUserDialogsAsync(); + var res = await client.GetUserDialogsAsync(); Assert.IsTrue(resFile.Bytes.Length > 0); } diff --git a/TLSharp.Tests/packages.config b/TLSharp.Tests/packages.config deleted file mode 100644 index 6b8deb9c..00000000 --- a/TLSharp.Tests/packages.config +++ /dev/null @@ -1,3 +0,0 @@ - - - \ No newline at end of file diff --git a/TLSharp.sln b/TLSharp.sln index 4f55f1bd..7d9437cc 100644 --- a/TLSharp.sln +++ b/TLSharp.sln @@ -1,19 +1,19 @@  Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio 14 -VisualStudioVersion = 14.0.24720.0 +# Visual Studio 15 +VisualStudioVersion = 15.0.27130.2027 MinimumVisualStudioVersion = 10.0.40219.1 -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TLSharp.Core", "TLSharp.Core\TLSharp.Core.csproj", "{400D2544-1CC6-4D8A-A62C-2292D9947A16}" +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TeleSharp.Generator", "TeleSharp.Generator\TeleSharp.Generator.csproj", "{E447A49F-8C71-4024-A191-864533EF91EF}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TeleSharp.TL", "TeleSharp.TL\TeleSharp.TL.csproj", "{D6144517-91D2-4880-86DF-E9FF5D7F383A}" +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TeleSharp.TL", "TeleSharp.TL\TeleSharp.TL.csproj", "{68AFF5CD-8D91-48B0-9841-2EB95C66B940}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TeleSharp.Generator", "TeleSharp.Generator\TeleSharp.Generator.csproj", "{9BE3B9D4-9FF6-4DC8-B9CC-EB2E3F390129}" +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TLSharp.Core", "TLSharp.Core\TLSharp.Core.csproj", "{2B5062F5-81D9-4559-8B47-FA6FAFB5D617}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TLSharp.Tests", "TLSharp.Tests\TLSharp.Tests.csproj", "{DE5C0467-EE99-4734-95F2-EFF7A0B99924}" +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TLSharp.Tests.NUnit", "TLSharp.Tests.NUnit\TLSharp.Tests.NUnit.csproj", "{CDF11B31-A455-4496-B771-CBEF4E1F4A25}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TLSharp.Tests.VS", "TLSharp.Tests.VS\TLSharp.Tests.VS.csproj", "{AFFC3B00-3E4D-4327-8F7A-08EE41E0C8B7}" +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TLSharp.Tests", "TLSharp.Tests\TLSharp.Tests.csproj", "{E91B06D3-9C9C-41DF-B7A9-51394735FCC3}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TLSharp.Tests.NUnit", "TLSharp.Tests.NUnit\TLSharp.Tests.NUnit.csproj", "{E90B705B-19FA-43BA-B952-69957976D12C}" +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TLSharp.Tests.VS", "TLSharp.Tests.VS\TLSharp.Tests.VS.csproj", "{A8AB6168-CE14-45AE-8213-656D3983DCCD}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution @@ -21,30 +21,36 @@ Global Release|Any CPU = Release|Any CPU EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution - {400D2544-1CC6-4D8A-A62C-2292D9947A16}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {400D2544-1CC6-4D8A-A62C-2292D9947A16}.Debug|Any CPU.Build.0 = Debug|Any CPU - {400D2544-1CC6-4D8A-A62C-2292D9947A16}.Release|Any CPU.ActiveCfg = Release|Any CPU - {400D2544-1CC6-4D8A-A62C-2292D9947A16}.Release|Any CPU.Build.0 = Release|Any CPU - {D6144517-91D2-4880-86DF-E9FF5D7F383A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {D6144517-91D2-4880-86DF-E9FF5D7F383A}.Debug|Any CPU.Build.0 = Debug|Any CPU - {D6144517-91D2-4880-86DF-E9FF5D7F383A}.Release|Any CPU.ActiveCfg = Release|Any CPU - {D6144517-91D2-4880-86DF-E9FF5D7F383A}.Release|Any CPU.Build.0 = Release|Any CPU - {9BE3B9D4-9FF6-4DC8-B9CC-EB2E3F390129}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {9BE3B9D4-9FF6-4DC8-B9CC-EB2E3F390129}.Debug|Any CPU.Build.0 = Debug|Any CPU - {9BE3B9D4-9FF6-4DC8-B9CC-EB2E3F390129}.Release|Any CPU.ActiveCfg = Release|Any CPU - {9BE3B9D4-9FF6-4DC8-B9CC-EB2E3F390129}.Release|Any CPU.Build.0 = Release|Any CPU - {DE5C0467-EE99-4734-95F2-EFF7A0B99924}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {DE5C0467-EE99-4734-95F2-EFF7A0B99924}.Debug|Any CPU.Build.0 = Debug|Any CPU - {DE5C0467-EE99-4734-95F2-EFF7A0B99924}.Release|Any CPU.ActiveCfg = Release|Any CPU - {DE5C0467-EE99-4734-95F2-EFF7A0B99924}.Release|Any CPU.Build.0 = Release|Any CPU - {AFFC3B00-3E4D-4327-8F7A-08EE41E0C8B7}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {AFFC3B00-3E4D-4327-8F7A-08EE41E0C8B7}.Debug|Any CPU.Build.0 = Debug|Any CPU - {AFFC3B00-3E4D-4327-8F7A-08EE41E0C8B7}.Release|Any CPU.ActiveCfg = Release|Any CPU - {AFFC3B00-3E4D-4327-8F7A-08EE41E0C8B7}.Release|Any CPU.Build.0 = Release|Any CPU - {E90B705B-19FA-43BA-B952-69957976D12C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {E90B705B-19FA-43BA-B952-69957976D12C}.Debug|Any CPU.Build.0 = Debug|Any CPU - {E90B705B-19FA-43BA-B952-69957976D12C}.Release|Any CPU.ActiveCfg = Release|Any CPU - {E90B705B-19FA-43BA-B952-69957976D12C}.Release|Any CPU.Build.0 = Release|Any CPU + {E447A49F-8C71-4024-A191-864533EF91EF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {E447A49F-8C71-4024-A191-864533EF91EF}.Debug|Any CPU.Build.0 = Debug|Any CPU + {E447A49F-8C71-4024-A191-864533EF91EF}.Release|Any CPU.ActiveCfg = Release|Any CPU + {E447A49F-8C71-4024-A191-864533EF91EF}.Release|Any CPU.Build.0 = Release|Any CPU + {68AFF5CD-8D91-48B0-9841-2EB95C66B940}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {68AFF5CD-8D91-48B0-9841-2EB95C66B940}.Debug|Any CPU.Build.0 = Debug|Any CPU + {68AFF5CD-8D91-48B0-9841-2EB95C66B940}.Release|Any CPU.ActiveCfg = Release|Any CPU + {68AFF5CD-8D91-48B0-9841-2EB95C66B940}.Release|Any CPU.Build.0 = Release|Any CPU + {2B5062F5-81D9-4559-8B47-FA6FAFB5D617}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {2B5062F5-81D9-4559-8B47-FA6FAFB5D617}.Debug|Any CPU.Build.0 = Debug|Any CPU + {2B5062F5-81D9-4559-8B47-FA6FAFB5D617}.Release|Any CPU.ActiveCfg = Release|Any CPU + {2B5062F5-81D9-4559-8B47-FA6FAFB5D617}.Release|Any CPU.Build.0 = Release|Any CPU + {CDF11B31-A455-4496-B771-CBEF4E1F4A25}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {CDF11B31-A455-4496-B771-CBEF4E1F4A25}.Debug|Any CPU.Build.0 = Debug|Any CPU + {CDF11B31-A455-4496-B771-CBEF4E1F4A25}.Release|Any CPU.ActiveCfg = Release|Any CPU + {CDF11B31-A455-4496-B771-CBEF4E1F4A25}.Release|Any CPU.Build.0 = Release|Any CPU + {E91B06D3-9C9C-41DF-B7A9-51394735FCC3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {E91B06D3-9C9C-41DF-B7A9-51394735FCC3}.Debug|Any CPU.Build.0 = Debug|Any CPU + {E91B06D3-9C9C-41DF-B7A9-51394735FCC3}.Release|Any CPU.ActiveCfg = Release|Any CPU + {E91B06D3-9C9C-41DF-B7A9-51394735FCC3}.Release|Any CPU.Build.0 = Release|Any CPU + {A8AB6168-CE14-45AE-8213-656D3983DCCD}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {A8AB6168-CE14-45AE-8213-656D3983DCCD}.Debug|Any CPU.Build.0 = Debug|Any CPU + {A8AB6168-CE14-45AE-8213-656D3983DCCD}.Release|Any CPU.ActiveCfg = Release|Any CPU + {A8AB6168-CE14-45AE-8213-656D3983DCCD}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {B516F53E-BB4D-42E3-9F03-A2F6BE909AD8} EndGlobalSection GlobalSection(MonoDevelopProperties) = preSolution Policies = $0 @@ -81,7 +87,4 @@ Global $2.inheritsScope = text/x-csharp $2.scope = text/x-csharp EndGlobalSection - GlobalSection(SolutionProperties) = preSolution - HideSolutionNode = FALSE - EndGlobalSection EndGlobal diff --git a/TeleSharp.Generator/Properties/AssemblyInfo.cs b/TeleSharp.Generator.old/Properties/AssemblyInfo.cs similarity index 100% rename from TeleSharp.Generator/Properties/AssemblyInfo.cs rename to TeleSharp.Generator.old/Properties/AssemblyInfo.cs diff --git a/TeleSharp.Generator.old/TeleSharp.Generator.csproj b/TeleSharp.Generator.old/TeleSharp.Generator.csproj new file mode 100644 index 00000000..94f3e9b3 --- /dev/null +++ b/TeleSharp.Generator.old/TeleSharp.Generator.csproj @@ -0,0 +1,80 @@ + + + + + Debug + AnyCPU + {9BE3B9D4-9FF6-4DC8-B9CC-EB2E3F390129} + Exe + Properties + TeleSharp.Generator + TeleSharp.Generator + v4.5 + 512 + true + + + AnyCPU + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + AnyCPU + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + ..\packages\Newtonsoft.Json.9.0.1\lib\net45\Newtonsoft.Json.dll + True + + + + + + + + + + + + + + + + + + + Always + + + + + + + + + Always + + + Always + + + + + \ No newline at end of file diff --git a/TeleSharp.Generator/TeleSharp.Generator.csproj b/TeleSharp.Generator/TeleSharp.Generator.csproj index 94f3e9b3..afada826 100644 --- a/TeleSharp.Generator/TeleSharp.Generator.csproj +++ b/TeleSharp.Generator/TeleSharp.Generator.csproj @@ -1,80 +1,11 @@ - - - + + - Debug - AnyCPU - {9BE3B9D4-9FF6-4DC8-B9CC-EB2E3F390129} - Exe - Properties - TeleSharp.Generator - TeleSharp.Generator - v4.5 - 512 - true + netstandard2.0 - - AnyCPU - true - full - false - bin\Debug\ - DEBUG;TRACE - prompt - 4 - - - AnyCPU - pdbonly - true - bin\Release\ - TRACE - prompt - 4 - - - - ..\packages\Newtonsoft.Json.9.0.1\lib\net45\Newtonsoft.Json.dll - True - - - - - - - - - - - - - - - - - - - Always - - - - - - + - - Always - - - Always - + - - - \ No newline at end of file + + diff --git a/TeleSharp.Generator/packages.config b/TeleSharp.Generator/packages.config deleted file mode 100644 index 9d64bf36..00000000 --- a/TeleSharp.Generator/packages.config +++ /dev/null @@ -1,4 +0,0 @@ - - - - \ No newline at end of file diff --git a/TeleSharp.TL/Properties/AssemblyInfo.cs b/TeleSharp.TL.old/Properties/AssemblyInfo.cs similarity index 100% rename from TeleSharp.TL/Properties/AssemblyInfo.cs rename to TeleSharp.TL.old/Properties/AssemblyInfo.cs diff --git a/TeleSharp.TL.old/TeleSharp.TL.csproj b/TeleSharp.TL.old/TeleSharp.TL.csproj new file mode 100644 index 00000000..7c6b30c8 --- /dev/null +++ b/TeleSharp.TL.old/TeleSharp.TL.csproj @@ -0,0 +1,938 @@ + + + + + Debug + AnyCPU + {D6144517-91D2-4880-86DF-E9FF5D7F383A} + Library + Properties + TeleSharp.TL + TeleSharp.TL + v4.5 + 512 + + + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + ..\packages\BigMath.0.5.0\lib\portable-net45+netcore45+wpa81+wp8+MonoAndroid1+MonoTouch1\BigMath.dll + True + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/TeleSharp.TL/TLContext.cs b/TeleSharp.TL/TLContext.cs index db686aa8..26b7a249 100644 --- a/TeleSharp.TL/TLContext.cs +++ b/TeleSharp.TL/TLContext.cs @@ -20,7 +20,10 @@ public static void Init() where t.IsSubclassOf(typeof(TLObject)) where t.GetCustomAttribute(typeof(TLObjectAttribute)) != null select t).ToDictionary(x => ((TLObjectAttribute)x.GetCustomAttribute(typeof(TLObjectAttribute))).Constructor, x => x); - Types.Add(481674261, typeof(TLVector<>)); + if (!Types.ContainsKey(481674261)) + { + Types.Add(481674261, typeof(TLVector<>)); + } } public static Type getType(int Constructor) { diff --git a/TeleSharp.TL/TeleSharp.TL.csproj b/TeleSharp.TL/TeleSharp.TL.csproj index 7c6b30c8..b56b6f19 100644 --- a/TeleSharp.TL/TeleSharp.TL.csproj +++ b/TeleSharp.TL/TeleSharp.TL.csproj @@ -1,938 +1,11 @@ - - - + + - Debug - AnyCPU - {D6144517-91D2-4880-86DF-E9FF5D7F383A} - Library - Properties - TeleSharp.TL - TeleSharp.TL - v4.5 - 512 + netstandard2.0 - - true - full - false - bin\Debug\ - DEBUG;TRACE - prompt - 4 - - - pdbonly - true - bin\Release\ - TRACE - prompt - 4 - - - - ..\packages\BigMath.0.5.0\lib\portable-net45+netcore45+wpa81+wp8+MonoAndroid1+MonoTouch1\BigMath.dll - True - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + - + - - - - \ No newline at end of file + + diff --git a/TeleSharp.TL/packages.config b/TeleSharp.TL/packages.config deleted file mode 100644 index cde6ccbe..00000000 --- a/TeleSharp.TL/packages.config +++ /dev/null @@ -1,4 +0,0 @@ - - - - \ No newline at end of file