From 3201e27b626a11777531fc93215dafa1a07ffe1e Mon Sep 17 00:00:00 2001 From: Kangho Hur Date: Thu, 7 Dec 2017 13:41:51 +0900 Subject: [PATCH 1/4] Add Tizen backend --- .../Platforms/tizen/EcoreMainloopScheduler.cs | 52 +++++++++++++++++++ .../Platforms/tizen/PlatformOperations.cs | 17 ++++++ .../Platforms/tizen/PlatformRegistrations.cs | 20 +++++++ src/ReactiveUI/ReactiveUI.csproj | 8 ++- 4 files changed, 96 insertions(+), 1 deletion(-) create mode 100644 src/ReactiveUI/Platforms/tizen/EcoreMainloopScheduler.cs create mode 100644 src/ReactiveUI/Platforms/tizen/PlatformOperations.cs create mode 100644 src/ReactiveUI/Platforms/tizen/PlatformRegistrations.cs diff --git a/src/ReactiveUI/Platforms/tizen/EcoreMainloopScheduler.cs b/src/ReactiveUI/Platforms/tizen/EcoreMainloopScheduler.cs new file mode 100644 index 0000000000..1dda65f04c --- /dev/null +++ b/src/ReactiveUI/Platforms/tizen/EcoreMainloopScheduler.cs @@ -0,0 +1,52 @@ +// Licensed to the .NET Foundation under one or more agreements. +// The .NET Foundation licenses this file to you under the MS-PL license. +// See the LICENSE file in the project root for more information. + +using System; +using System.Reactive.Concurrency; +using System.Reactive.Disposables; +using ElmSharp; + +namespace ReactiveUI +{ + class EcoreMainloopScheduler : IScheduler + { + public static IScheduler MainThreadScheduler = new EcoreMainloopScheduler(); + + public DateTimeOffset Now => DateTimeOffset.Now; + + public IDisposable Schedule(TState state, Func action) + { + var innerDisp = new SingleAssignmentDisposable(); + EcoreMainloop.PostAndWakeUp(() => { + if (!innerDisp.IsDisposed) innerDisp.Disposable = action(this, state); + }); + return innerDisp; + } + + public IDisposable Schedule(TState state, TimeSpan dueTime, Func action) + { + var innerDisp = Disposable.Empty; + bool isCancelled = false; + + IntPtr timer = EcoreMainloop.AddTimer(dueTime.TotalSeconds, () => { + if (!isCancelled) innerDisp = action(this, state); + return false; + }); + + return Disposable.Create(() => { + isCancelled = true; + EcoreMainloop.RemoveTimer(timer); + innerDisp.Dispose(); + }); + } + + public IDisposable Schedule(TState state, DateTimeOffset dueTime, Func action) + { + if (dueTime <= Now) { + return Schedule(state, action); + } + return Schedule(state, dueTime - Now, action); + } + } +} diff --git a/src/ReactiveUI/Platforms/tizen/PlatformOperations.cs b/src/ReactiveUI/Platforms/tizen/PlatformOperations.cs new file mode 100644 index 0000000000..3ec1738cd7 --- /dev/null +++ b/src/ReactiveUI/Platforms/tizen/PlatformOperations.cs @@ -0,0 +1,17 @@ +// Licensed to the .NET Foundation under one or more agreements. +// The .NET Foundation licenses this file to you under the MS-PL license. +// See the LICENSE file in the project root for more information. + +namespace ReactiveUI +{ + /// + /// Returns the current orientation of the device on iOS. + /// + public class PlatformOperations : IPlatformOperations + { + public string GetOrientation() + { + return null; + } + } +} diff --git a/src/ReactiveUI/Platforms/tizen/PlatformRegistrations.cs b/src/ReactiveUI/Platforms/tizen/PlatformRegistrations.cs new file mode 100644 index 0000000000..88ae4cf2dd --- /dev/null +++ b/src/ReactiveUI/Platforms/tizen/PlatformRegistrations.cs @@ -0,0 +1,20 @@ +// Licensed to the .NET Foundation under one or more agreements. +// The .NET Foundation licenses this file to you under the MS-PL license. +// See the LICENSE file in the project root for more information. + +using System; +using System.Reactive.Concurrency; + +namespace ReactiveUI +{ + public class PlatformRegistrations : IWantsToRegisterStuff + { + public void Register(Action, Type> registerFunction) + { + registerFunction(() => new PlatformOperations(), typeof(IPlatformOperations)); + registerFunction(() => new ComponentModelTypeConverter(), typeof(IBindingTypeConverter)); + RxApp.TaskpoolScheduler = TaskPoolScheduler.Default; + RxApp.MainThreadScheduler = EcoreMainloopScheduler.MainThreadScheduler; + } + } +} diff --git a/src/ReactiveUI/ReactiveUI.csproj b/src/ReactiveUI/ReactiveUI.csproj index 7740e4a4b0..103253af7c 100644 --- a/src/ReactiveUI/ReactiveUI.csproj +++ b/src/ReactiveUI/ReactiveUI.csproj @@ -1,6 +1,6 @@  - netstandard1.1;net45;uap10.0;Xamarin.iOS10;Xamarin.Mac20;MonoAndroid80;netcoreapp1.0 + netstandard1.1;net45;uap10.0;Xamarin.iOS10;Xamarin.Mac20;MonoAndroid80;netcoreapp1.0;tizen40 ReactiveUI ReactiveUI A MVVM framework that integrates with the Reactive Extensions for .NET to create elegant, testable User Interfaces that run on any mobile or desktop platform. Supports Xamarin.iOS, Xamarin.Android, Xamarin.Mac, Xamarin Forms, WPF, Windows Forms, Windows Phone 8.1, Windows Store and Universal Windows Platform (UWP). @@ -62,6 +62,12 @@ + + + + + + From 98d7aa38e04db6d5d2b9001a0f91867469fa119f Mon Sep 17 00:00:00 2001 From: Geoffrey Huntley Date: Thu, 17 May 2018 22:37:17 +1000 Subject: [PATCH 2/4] red build: added events - require help finishing this --- build.cake | 1 + .../Cecil/EventTemplateInformation.cs | 46 ++++++++++--- src/EventBuilder/CommandLineOptions.cs | 3 +- src/EventBuilder/EventBuilder.sln | 13 ++-- src/EventBuilder/Platforms/Tizen.cs | 66 +++++++++++++++++++ src/EventBuilder/Program.cs | 10 ++- .../ReactiveUI.Events.csproj | 8 ++- 7 files changed, 131 insertions(+), 16 deletions(-) create mode 100644 src/EventBuilder/Platforms/Tizen.cs diff --git a/build.cake b/build.cake index 205494430b..bd2a182596 100644 --- a/build.cake +++ b/build.cake @@ -166,6 +166,7 @@ Task("GenerateEvents") generate("ios", "src/ReactiveUI.Events/"); generate("mac", "src/ReactiveUI.Events/"); generate("uwp", "src/ReactiveUI.Events/"); + generate("tizen", "src/ReactiveUI.Events/"); generate("wpf", "src/ReactiveUI.Events.WPF/"); generate("xamforms", "src/ReactiveUI.Events.XamForms/"); generate("winforms", "src/ReactiveUI.Events.Winforms/"); diff --git a/src/EventBuilder/Cecil/EventTemplateInformation.cs b/src/EventBuilder/Cecil/EventTemplateInformation.cs index d2226c8099..af7ae16abc 100644 --- a/src/EventBuilder/Cecil/EventTemplateInformation.cs +++ b/src/EventBuilder/Cecil/EventTemplateInformation.cs @@ -17,12 +17,34 @@ public static class EventTemplateInformation {"Windows.UI.Xaml.Data.PropertyChangedEventHandler", "global::System.ComponentModel.PropertyChangedEventHandler"}, {"Windows.Foundation.EventHandler", "EventHandler"}, {"Windows.Foundation.EventHandler`1", "EventHandler"}, - {"Windows.Foundation.EventHandler`2", "EventHandler"} + {"Windows.Foundation.EventHandler`2", "EventHandler"}, + + // tizen40 + {"System.Boolean", "Boolean"}, + {"System.Boolean`1", "Boolean"}, + + + {"System.EventHandler", "EventHandler"}, + {"System.EventHandler`1", "EventHandler"}, + {"System.EventHandler`2", "EventHandler"}, + + {"System.EventArgs", "EventArgs"}, + {"System.EventArgs`1", "EventArgs"}, + {"System.EventArgs`2", "EventArgs"}, + + {"Tizen.NUI.EventHandlerWithReturnType", "Tizen.NUI.EventHandlerWithReturnType"}, + {"Tizen.NUI.EventHandlerWithReturnType`1", "Tizen.NUI.EventHandlerWithReturnType"}, + {"Tizen.NUI.EventHandlerWithReturnType`2", "Tizen.NUI.EventHandlerWithReturnType"}, + {"Tizen.NUI.EventHandlerWithReturnType`3", "Tizen.NUI.EventHandlerWithReturnType"}, + + }; - private static string RenameBogusWinRTTypes(string typeName) + private static string RenameBogusTypes(string typeName) { - if (SubstitutionList.ContainsKey(typeName)) return SubstitutionList[typeName]; + if (SubstitutionList.ContainsKey(typeName)) { + return SubstitutionList[typeName]; + } return typeName; } @@ -34,7 +56,7 @@ private static string GetEventArgsTypeForEvent(EventDefinition ei) if (invoke.Parameters.Count < 2) return null; var param = invoke.Parameters[1]; - var ret = RenameBogusWinRTTypes(param.ParameterType.FullName); + var ret = RenameBogusTypes(param.ParameterType.FullName); var generic = ei.EventType as GenericInstanceType; if (generic != null) { @@ -53,10 +75,10 @@ var kvp in private static string GetRealTypeName(TypeDefinition t) { - if (t.GenericParameters.Count == 0) return RenameBogusWinRTTypes(t.FullName); + if (t.GenericParameters.Count == 0) return RenameBogusTypes(t.FullName); var ret = string.Format("{0}<{1}>", - RenameBogusWinRTTypes(t.Namespace + "." + t.Name), + RenameBogusTypes(t.Namespace + "." + t.Name), string.Join(",", t.GenericParameters.Select(x => GetRealTypeName(x.Resolve())))); // NB: Inner types in Mono.Cecil get reported as 'Foo/Bar' @@ -66,12 +88,20 @@ private static string GetRealTypeName(TypeDefinition t) private static string GetRealTypeName(TypeReference t) { var generic = t as GenericInstanceType; - if (generic == null) return RenameBogusWinRTTypes(t.FullName); + if (generic == null) return RenameBogusTypes(t.FullName); var ret = string.Format("{0}<{1}>", - RenameBogusWinRTTypes(generic.Namespace + "." + generic.Name), + RenameBogusTypes(generic.Namespace + "." + generic.Name), string.Join(",", generic.GenericArguments.Select(x => GetRealTypeName(x)))); + // NB: Handy place to hook to troubleshoot if something needs to be added to SubstitutionList + //if (generic.FullName.Contains("MarkReachedEventArgs")) { + // // Tizen.NUI.EventHandlerWithReturnType`3 + // // + //} + // NB: Inner types in Mono.Cecil get reported as 'Foo/Bar' return ret.Replace('/', '.'); } diff --git a/src/EventBuilder/CommandLineOptions.cs b/src/EventBuilder/CommandLineOptions.cs index a35346ef3c..bc66951580 100644 --- a/src/EventBuilder/CommandLineOptions.cs +++ b/src/EventBuilder/CommandLineOptions.cs @@ -14,6 +14,7 @@ public enum AutoPlatform Android, iOS, Mac, + Tizen, WPF, XamForms, UWP, @@ -27,7 +28,7 @@ public class CommandLineOptions [Option('p', "platform", Required = true, HelpText = - "Platform to automatically generate. Possible options include: NONE, ANDROID, IOS, WPF, MAC, UWP, XAMFORMS, WINFORMS" + "Platform to automatically generate. Possible options include: NONE, ANDROID, IOS, WPF, MAC, TIZEN, UWP, XAMFORMS, WINFORMS" )] public AutoPlatform Platform { get; set; } diff --git a/src/EventBuilder/EventBuilder.sln b/src/EventBuilder/EventBuilder.sln index 153b5d6041..2438ddbb8f 100644 --- a/src/EventBuilder/EventBuilder.sln +++ b/src/EventBuilder/EventBuilder.sln @@ -3,7 +3,7 @@ Microsoft Visual Studio Solution File, Format Version 12.00 # Visual Studio 15 VisualStudioVersion = 15.0.26228.9 MinimumVisualStudioVersion = 10.0.40219.1 -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EventBuilder", "EventBuilder.csproj", "{A6B86E12-057F-4591-98A3-FD50E9CEAE69}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "EventBuilder", "EventBuilder.csproj", "{A6B86E12-057F-4591-98A3-FD50E9CEAE69}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution @@ -15,14 +15,17 @@ Global GlobalSection(ProjectConfigurationPlatforms) = postSolution {A6B86E12-057F-4591-98A3-FD50E9CEAE69}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {A6B86E12-057F-4591-98A3-FD50E9CEAE69}.Debug|Any CPU.Build.0 = Debug|Any CPU - {A6B86E12-057F-4591-98A3-FD50E9CEAE69}.Debug|x86.ActiveCfg = Debug|x86 - {A6B86E12-057F-4591-98A3-FD50E9CEAE69}.Debug|x86.Build.0 = Debug|x86 + {A6B86E12-057F-4591-98A3-FD50E9CEAE69}.Debug|x86.ActiveCfg = Debug|Any CPU + {A6B86E12-057F-4591-98A3-FD50E9CEAE69}.Debug|x86.Build.0 = Debug|Any CPU {A6B86E12-057F-4591-98A3-FD50E9CEAE69}.Release|Any CPU.ActiveCfg = Release|Any CPU {A6B86E12-057F-4591-98A3-FD50E9CEAE69}.Release|Any CPU.Build.0 = Release|Any CPU - {A6B86E12-057F-4591-98A3-FD50E9CEAE69}.Release|x86.ActiveCfg = Release|x86 - {A6B86E12-057F-4591-98A3-FD50E9CEAE69}.Release|x86.Build.0 = Release|x86 + {A6B86E12-057F-4591-98A3-FD50E9CEAE69}.Release|x86.ActiveCfg = Release|Any CPU + {A6B86E12-057F-4591-98A3-FD50E9CEAE69}.Release|x86.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {8AD09057-1163-45D2-A260-CB034E6DFD07} + EndGlobalSection EndGlobal diff --git a/src/EventBuilder/Platforms/Tizen.cs b/src/EventBuilder/Platforms/Tizen.cs new file mode 100644 index 0000000000..e200a82e67 --- /dev/null +++ b/src/EventBuilder/Platforms/Tizen.cs @@ -0,0 +1,66 @@ +// Licensed to the .NET Foundation under one or more agreements. +// The .NET Foundation licenses this file to you under the MS-PL license. +// See the LICENSE file in the project root for more information. + +using NuGet; +using Polly; +using Serilog; +using System; +using System.IO; +using System.Linq; + +namespace EventBuilder.Platforms +{ + public class Tizen : BasePlatform + { + private const string _packageName = "Tizen.NET"; + + public Tizen() + { + var packageUnzipPath = Environment.CurrentDirectory; + + Log.Debug("Package unzip path is {PackageUnzipPath}", packageUnzipPath); + + var retryPolicy = Policy + .Handle() + .WaitAndRetry( + 5, + retryAttempt => TimeSpan.FromSeconds(Math.Pow(2, retryAttempt)), + (exception, timeSpan, context) => { + Log.Warning( + "An exception was thrown whilst retrieving or installing {packageName}: {exception}", + _packageName, exception); + }); + + retryPolicy.Execute(() => { + var repo = PackageRepositoryFactory.Default.CreateRepository("https://packages.nuget.org/api/v2"); + + var packageManager = new PackageManager(repo, packageUnzipPath); + + var package = repo.FindPackagesById(_packageName).Single(x => x.Version.ToString() == "4.0.0"); + + Log.Debug("Using Tizen.NET {Version} released on {Published}", package.Version, package.Published); + Log.Debug("{ReleaseNotes}", package.ReleaseNotes); + + packageManager.InstallPackage(package, ignoreDependencies: true, allowPrereleaseVersions: false); + }); + + var elmSharp = Directory.GetFiles(packageUnzipPath, "ElmSharp*.dll", SearchOption.AllDirectories); + + foreach (var assembly in elmSharp) { + Assemblies.Add(assembly); + } + + var tizenNet = Directory.GetFiles(packageUnzipPath, "Tizen*.dll", SearchOption.AllDirectories); + + foreach (var assembly in tizenNet) { + Assemblies.Add(assembly); + } + + CecilSearchDirectories.Add($"{packageUnzipPath}\\Tizen.NET.4.0.0\\build\\tizen40\\ref"); + CecilSearchDirectories.Add($"{packageUnzipPath}\\Tizen.NET.4.0.0\\lib\\netstandard2.0"); + + + } + } +} diff --git a/src/EventBuilder/Program.cs b/src/EventBuilder/Program.cs index cd0ec6e572..25c0756b2a 100644 --- a/src/EventBuilder/Program.cs +++ b/src/EventBuilder/Program.cs @@ -41,7 +41,7 @@ private static void Main(string[] args) // allow app to be debugged in visual studio. if (Debugger.IsAttached) { //args = "--help ".Split(' '); - args = "--platform=ios".Split(' '); + args = "--platform=tizen".Split(' '); //args = new[] //{ // "--platform=none", @@ -101,6 +101,10 @@ private static void Main(string[] args) platform = new XamForms(); break; + case AutoPlatform.Tizen: + platform = new Tizen(); + break; + case AutoPlatform.UWP: platform = new UWP(); break; @@ -118,6 +122,10 @@ private static void Main(string[] args) Environment.Exit((int)ExitCode.Success); } catch (Exception ex) { Log.Fatal(ex.ToString()); + + if (Debugger.IsAttached) { + Debugger.Break(); + } } } diff --git a/src/ReactiveUI.Events/ReactiveUI.Events.csproj b/src/ReactiveUI.Events/ReactiveUI.Events.csproj index 9280784675..b11fbb5137 100644 --- a/src/ReactiveUI.Events/ReactiveUI.Events.csproj +++ b/src/ReactiveUI.Events/ReactiveUI.Events.csproj @@ -1,6 +1,6 @@  - uap10.0.16299;Xamarin.iOS10;Xamarin.Mac20;MonoAndroid80 + uap10.0.16299;Xamarin.iOS10;Xamarin.Mac20;MonoAndroid80;tizen40 ReactiveUI.Events ReactiveUI.Events Provides Observable-based events API for common UI controls/eventhandlers. The contents of this package is automatically generated, please target pull-requests to the code generator. @@ -36,5 +36,11 @@ + + + + + + From 9d0a22f7151134ce5a7fb6cdbfa97ac1704c88e8 Mon Sep 17 00:00:00 2001 From: Kangho Hur Date: Mon, 28 May 2018 20:22:47 +0900 Subject: [PATCH 3/4] Fix unexpedted string replacement for generic intstance type --- src/EventBuilder/Cecil/EventTemplateInformation.cs | 7 ++++++- src/ReactiveUI/Platforms/tizen/PlatformOperations.cs | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/EventBuilder/Cecil/EventTemplateInformation.cs b/src/EventBuilder/Cecil/EventTemplateInformation.cs index af7ae16abc..79ab142249 100644 --- a/src/EventBuilder/Cecil/EventTemplateInformation.cs +++ b/src/EventBuilder/Cecil/EventTemplateInformation.cs @@ -65,7 +65,12 @@ var kvp in type.GenericParameters.Zip(generic.GenericArguments, (name, actual) => new { name, actual })) { var realType = GetRealTypeName(kvp.actual); - ret = ret.Replace(kvp.name.FullName, realType); + var temp = ret.Replace(kvp.name.FullName, realType); + if (temp != ret) + { + ret = temp; + break; + } } } diff --git a/src/ReactiveUI/Platforms/tizen/PlatformOperations.cs b/src/ReactiveUI/Platforms/tizen/PlatformOperations.cs index 3ec1738cd7..613dfcdd92 100644 --- a/src/ReactiveUI/Platforms/tizen/PlatformOperations.cs +++ b/src/ReactiveUI/Platforms/tizen/PlatformOperations.cs @@ -5,7 +5,7 @@ namespace ReactiveUI { /// - /// Returns the current orientation of the device on iOS. + /// Returns the current orientation of the device on tizen. /// public class PlatformOperations : IPlatformOperations { From b15c737614a22e664e793838b2234eee418c91eb Mon Sep 17 00:00:00 2001 From: Kangho Hur Date: Wed, 11 Jul 2018 17:24:37 +0900 Subject: [PATCH 4/4] Fix string interpolations and code clean up --- src/Directory.build.targets | 5 ++++- .../Cecil/EventTemplateInformation.cs | 8 ------- src/EventBuilder/Platforms/Tizen.cs | 22 +++++-------------- 3 files changed, 10 insertions(+), 25 deletions(-) diff --git a/src/Directory.build.targets b/src/Directory.build.targets index 459f4576c7..f334b3170d 100644 --- a/src/Directory.build.targets +++ b/src/Directory.build.targets @@ -19,8 +19,11 @@ + + $(DefineConstants);Tizen + - \ No newline at end of file + diff --git a/src/EventBuilder/Cecil/EventTemplateInformation.cs b/src/EventBuilder/Cecil/EventTemplateInformation.cs index 79ab142249..138ed4d38d 100644 --- a/src/EventBuilder/Cecil/EventTemplateInformation.cs +++ b/src/EventBuilder/Cecil/EventTemplateInformation.cs @@ -18,26 +18,18 @@ public static class EventTemplateInformation {"Windows.Foundation.EventHandler", "EventHandler"}, {"Windows.Foundation.EventHandler`1", "EventHandler"}, {"Windows.Foundation.EventHandler`2", "EventHandler"}, - - // tizen40 {"System.Boolean", "Boolean"}, {"System.Boolean`1", "Boolean"}, - - {"System.EventHandler", "EventHandler"}, {"System.EventHandler`1", "EventHandler"}, {"System.EventHandler`2", "EventHandler"}, - {"System.EventArgs", "EventArgs"}, {"System.EventArgs`1", "EventArgs"}, {"System.EventArgs`2", "EventArgs"}, - {"Tizen.NUI.EventHandlerWithReturnType", "Tizen.NUI.EventHandlerWithReturnType"}, {"Tizen.NUI.EventHandlerWithReturnType`1", "Tizen.NUI.EventHandlerWithReturnType"}, {"Tizen.NUI.EventHandlerWithReturnType`2", "Tizen.NUI.EventHandlerWithReturnType"}, {"Tizen.NUI.EventHandlerWithReturnType`3", "Tizen.NUI.EventHandlerWithReturnType"}, - - }; private static string RenameBogusTypes(string typeName) diff --git a/src/EventBuilder/Platforms/Tizen.cs b/src/EventBuilder/Platforms/Tizen.cs index e200a82e67..a543ebec71 100644 --- a/src/EventBuilder/Platforms/Tizen.cs +++ b/src/EventBuilder/Platforms/Tizen.cs @@ -19,7 +19,7 @@ public Tizen() { var packageUnzipPath = Environment.CurrentDirectory; - Log.Debug("Package unzip path is {PackageUnzipPath}", packageUnzipPath); + Log.Debug($"Package unzip path is {packageUnzipPath}"); var retryPolicy = Policy .Handle() @@ -28,39 +28,29 @@ public Tizen() retryAttempt => TimeSpan.FromSeconds(Math.Pow(2, retryAttempt)), (exception, timeSpan, context) => { Log.Warning( - "An exception was thrown whilst retrieving or installing {packageName}: {exception}", + "An exception was thrown whilst retrieving or installing {0}: {1}", _packageName, exception); }); retryPolicy.Execute(() => { var repo = PackageRepositoryFactory.Default.CreateRepository("https://packages.nuget.org/api/v2"); - var packageManager = new PackageManager(repo, packageUnzipPath); - var package = repo.FindPackagesById(_packageName).Single(x => x.Version.ToString() == "4.0.0"); - Log.Debug("Using Tizen.NET {Version} released on {Published}", package.Version, package.Published); - Log.Debug("{ReleaseNotes}", package.ReleaseNotes); + Log.Debug("Using Tizen.NET {0} released on {1}", package.Version, package.Published); + Log.Debug("{0}", package.ReleaseNotes); packageManager.InstallPackage(package, ignoreDependencies: true, allowPrereleaseVersions: false); }); var elmSharp = Directory.GetFiles(packageUnzipPath, "ElmSharp*.dll", SearchOption.AllDirectories); - - foreach (var assembly in elmSharp) { - Assemblies.Add(assembly); - } + Assemblies.AddRange(elmSharp); var tizenNet = Directory.GetFiles(packageUnzipPath, "Tizen*.dll", SearchOption.AllDirectories); - - foreach (var assembly in tizenNet) { - Assemblies.Add(assembly); - } + Assemblies.AddRange(tizenNet); CecilSearchDirectories.Add($"{packageUnzipPath}\\Tizen.NET.4.0.0\\build\\tizen40\\ref"); CecilSearchDirectories.Add($"{packageUnzipPath}\\Tizen.NET.4.0.0\\lib\\netstandard2.0"); - - } } }