Missing space

Missing space

Not the space space but an empty thing before 'Has'.

--- EDDiscovery/UserControls/Overlays/UserControlSurveyor.cs
+++ EDDiscovery/UserControls/Overlays/UserControlSurveyor.cs
@@ -430,7 +430,7 @@
             information.Append((js.Terraformable && !js.WaterWorld && js.PlanetTypeID != EDPlanet.High_metal_content_body && js.PlanetTypeID != EDPlanet.Metal_rich_body) ? @" is a terraformable planet.".T(EDTx.UserControlSurveyor_isaterraformableplanet) : null);
             information.Append((js.HasRings) ? @" Has ring.".T(EDTx.UserControlSurveyor_Hasring) : null);
             information.Append((js.HasMeaningfulVolcanism) ? @" Has ".T(EDTx.UserControlSurveyor_Has) + js.Volcanism + "." : null);
-            information.Append((js.nEccentricity >= eccentricityLimit) ? @"Has an high eccentricity of ".T(EDTx.UserControlSurveyor_eccentricity) + js.nEccentricity + "." : null);
+            information.Append((js.nEccentricity >= eccentricityLimit) ? @" Has an high eccentricity of ".T(EDTx.UserControlSurveyor_eccentricity) + js.nEccentricity + "." : null);
             information.Append((js.nRadius < lowRadiusLimit) ? @" is tiny.".T(EDTx.UserControlSurveyor_LowRadius) : null);
             information.Append((sn.Signals != null) ? " Has Signals.".T(EDTx.UserControlSurveyor_Signals) : null);
             information.Append((js.IsLandable && !js.HasAtmosphericComposition && js.nRadius<= largeRadiusLimit) ? @" Is landable.".T(EDTx.UserControlSurveyor_islandable) : null);


Change FileSystemInfo to FileInfo for methods that operate on FileInfo only.

--- Easy.Common/Extensions/FileAndDirectoryInfoExtensions.cs
+++ Easy.Common/Extensions/FileAndDirectoryInfoExtensions.cs
@@ -75,7 +75,7 @@
         /// thrown if the file does not exist.
         /// </remarks>
         /// </summary>
-        public static FileStream OpenSequentialRead(this FileSystemInfo file)
+        public static FileStream OpenSequentialRead(this FileInfo file)
             => new FileStream(
                 file.FullName,
                 FileMode.Open,
@@ -88,7 +88,7 @@
         /// Opens or creates a stream for reading with sequential optimization and providing
         /// <see cref="FileShare.ReadWrite"/> for others.
         /// </summary>
-        public static FileStream OpenOrCreateSequentialRead(this FileSystemInfo file)
+        public static FileStream OpenOrCreateSequentialRead(this FileInfo file)
             => new FileStream(
                 file.FullName,
                 FileMode.OpenOrCreate,
@@ -101,7 +101,7 @@
         /// Opens or creates a stream for writing with sequential optimization and providing
         /// <see cref="FileShare.Read"/> for others.
         /// </summary>
-        public static FileStream OpenOrCreateSequentialWrite(this FileSystemInfo file)
+        public static FileStream OpenOrCreateSequentialWrite(this FileInfo file)
             => new FileStream(
                 file.FullName,
                 FileMode.OpenOrCreate,
@@ -114,7 +114,7 @@
         /// Opens or creates a stream for reading and writing with sequential optimization and providing
         /// <see cref="FileShare.ReadWrite"/> for others.
         /// </summary>
-        public static FileStream OpenOrCreateSequentialReadWrite(this FileSystemInfo file)
+        public static FileStream OpenOrCreateSequentialReadWrite(this FileInfo file)
             => new FileStream(
                 file.FullName,
                 FileMode.OpenOrCreate,
@@ -219,7 +219,7 @@
         /// Determines whether the given <paramref name="file"/> is binary or a text file.
         /// </summary>
         [DebuggerStepThrough]
-        public static bool IsBinary(this FileSystemInfo file)
+        public static bool IsBinary(this FileInfo file)
         {
             var buffer = new char[256];


Improved performance of EnumerateDirectoriesSafe and EnumerateFilesSafe by parallelization.

--- Easy.Common/Extensions/FileAndDirectoryInfoExtensions.cs
+++ Easy.Common/Extensions/FileAndDirectoryInfoExtensions.cs
@@ -177,8 +177,8 @@
                 if (option == SearchOption.AllDirectories)
                 {
                     directories = directory.EnumerateDirectories()
-                        .SelectMany(d =>
-                            d.EnumerateDirectoriesSafe(searchPattern, option, throwOnPathTooLong));
+                        .AsParallel()
+                        .SelectMany(d => d.EnumerateDirectoriesSafe(searchPattern, option, throwOnPathTooLong));
                 }

                 return directories.Concat(directory.EnumerateDirectories(searchPattern));
@@ -206,6 +206,7 @@
                 if (option == SearchOption.AllDirectories)
                 {
                     files = directory.EnumerateDirectories()
+                        .AsParallel()
                         .SelectMany(d => d.EnumerateFilesSafe(searchPattern, option, throwOnPathTooLong));
                 }


时间格式区分问题。

时间格式区分问题。

--- ElectronicObserver/Utility/Mathematics/DateTimeHelper.cs
+++ ElectronicObserver/Utility/Mathematics/DateTimeHelper.cs
@@ -203,7 +203,7 @@
 		}

 		public static DateTime CSVStringToTime( string str ) {
-			string[] elem = str.Split( "/ :".ToCharArray() );
+			string[] elem = str.Split( "-/ :".ToCharArray() );
 			return new DateTime( int.Parse( elem[0] ), int.Parse( elem[1] ), int.Parse( elem[2] ), int.Parse( elem[3] ), int.Parse( elem[4] ), int.Parse( elem[5] ) );
 		}


Adding support for array content settings properties, used e.g. by ListPart

--- Extensions/CodeGeneration/CodeGenerationDisplayDriver.cs
+++ Extensions/CodeGeneration/CodeGenerationDisplayDriver.cs
@@ -18,6 +18,29 @@
                 {
                     var codeBuilder = new StringBuilder();

+                    static string ConvertJToken(JToken jToken)
+                    {
+                        if (jToken is JValue jValue)
+                        {
+                            var value = jValue.Value;
+                            return value switch
+                            {
+                                bool _ => value.ToString().ToLowerInvariant(),
+                                string _ => $"\"{value}\"",
+                                _ => value.ToString().Replace(',', '.') // Replace decimal commas.
+                            };
+
+                        }
+                        else if (jToken is JArray jArray)
+                        {
+                            return "new[] { " + string.Join(", ", jArray.Select(item => ConvertJToken(item))) + " }";
+                        }
+                        else
+                        {
+                            throw new NotSupportedException($"Settings values of type {jToken.GetType()} are not supported.");
+                        }
+                    }
+
                     void AddSettingsWithout<T>(JObject settings, int indentationDepth)
                     {
                         var indentation = string.Join("", Enumerable.Repeat(" ", indentationDepth));
@@ -35,16 +58,7 @@
                             for (int i = 0; i < properties.Length; i++)
                             {
                                 var property = properties[i];
-                                var value = ((JValue)property.Value).Value;
-                                var valueString = value switch
-                                {
-                                    bool _ => value.ToString().ToLowerInvariant(),
-                                    string _ => $"\"{value}\"",
-                                    _ => value.ToString().Replace(',', '.') // Replace decimal commas.
-                                };
-
-                                codeBuilder.AppendLine($"{indentation}    {property.Name} = {valueString}{(i != properties.Length - 1 ? "," : string.Empty)}");
-                                if (i == properties.Length) codeBuilder.Length--; // Removing the trailing comma.
+                                codeBuilder.AppendLine($"{indentation}    {property.Name} = {ConvertJToken(property.Value)}{(i != properties.Length - 1 ? "," : string.Empty)}");
                             }

                             codeBuilder.AppendLine(indentation + "})");


Remove 1px border on top of the notification (fixes empty space between scrollbar and the top)

--- Core/Notification/TweetNotification.cs
+++ Core/Notification/TweetNotification.cs
@@ -101,7 +101,7 @@
                 build.Append(' ').Append(bodyClasses);
             }

-            build.Append('\'').Append(isExample ? " td-example-notification" : "").Append(">

");
+            build.Append('\'').Append(isExample ? " td-example-notification" : "").Append(">

");
             build.Append(html);
             build.Append("

");
             build.Append("");


Local changes for the paths of dwjson files

--- Python/Product/Profiling/Profiling/ProfiledProcess.cs
+++ Python/Product/Profiling/Profiling/ProfiledProcess.cs
@@ -219,20 +219,20 @@
                 // Contains the data to analyze
                 package.CreateResourceFromPath(
                     "DiagnosticsHub.Resource.DWJsonFile",
-                    @"c:\users\rgesteve\downloads\Sample1.dwjson",
+                    @"c:\users\perf\downloads\Sample1.dwjson",
                     null,
                     CompressionOption.CompressionOption_Normal);

                 // Counter data to show in swimlane
                 package.CreateResourceFromPath(
                     "DiagnosticsHub.Resource.CountersFile",
-                    @"c:\users\rgesteve\downloads\Session.counters",
+                    @"c:\users\perf\downloads\Session.counters",
                     null,
                     CompressionOption.CompressionOption_Normal);

                 // You can add the commit option (CommitOption.CommitOption_CleanUpResources) and it will delete
                 // the resources added from disk after they have been committed to the DiagSession
-                package.CommitToPath(@"c:\users\rgesteve\downloads\demo", CommitOption.CommitOption_Archive);
+                package.CommitToPath(@"c:\users\perf\downloads\demo", CommitOption.CommitOption_Archive);
             }
         }


Fixed action to launch fan page in native browser

--- AppStudio.Shared/ViewModels/ConcertsViewModel.cs
+++ AppStudio.Shared/ViewModels/ConcertsViewModel.cs
@@ -8,6 +8,7 @@
 using AppStudio.Services;
 using AppStudio.Data;
 using AppStudio.Data.DataSchemas;
+using Windows.System;

 namespace AppStudio.ViewModels
 {
@@ -25,13 +26,18 @@
                         {
                             if (item.ticket_status.ToLower().Equals("available"))
                             {
-                                NavigationServices.NavigateToPage("BrowserPage", item.url);
-                            }
+                                LaunchArtistFanPage(new Uri(item.url));
+                            }
                         });
                 }

                 return itemClickCommand;
             }
+        }
+
+        private async void LaunchArtistFanPage(Uri fanPageUri)
+        {
+            await Launcher.LaunchUriAsync(fanPageUri);
         }

         override protected DataSourceBase<ConcertSchema> CreateDataSource()


add reference to github in lobby

add reference to github in lobby

--- src/Lobby.cs
+++ src/Lobby.cs
@@ -155,6 +155,7 @@
                 player.vt.WriteText(" aixterm colors");
 				player.vt.WriteText("");
 				player.vt.WriteText("Should work on any VT100 compatibile terminal, but works best on PuTTY");
+				player.vt.WriteText("Source: https://github.com/Milek7/telnet-games");
             }
             else
             {


Fix ProtocolType types and add some new ones

git-svn-id: 8d82213adbbc6b1538a984bace977d31fcb31691@143 2f5d681c-ba19-11dd-a503-ed2d4bea8bb5

--- trunk/src/demos/ProtocolType.cs
+++ trunk/src/demos/ProtocolType.cs
@@ -16,11 +16,16 @@
 namespace TAP {
 	/* http://www.iana.org/assignments/protocol-numbers/ */
 	public enum ProtocolType : byte {
-		HOPOPT  = 1,
-		ICMP    = 2,
-		IGMP    = 3,
-		GGP     = 4,
-		IP      = 5,
+		HOPOPT  = 0,
+		ICMP    = 1,
+		IGMP    = 2,
+		GGP     = 3,
+		IP      = 4,
+		ST      = 5,
+		TCP     = 6,
+		CBT     = 7,
+		EGP     = 8,
+		IGP     = 9,
 		IPv6    = 41,
 		ICMPv6  = 58
 	}


revise OrderedCsvHttpHeader to use IndexedDictionary (#38)

Also now allows CSV items to be removed if the q-value indicates that
they are unacceptable.

--- Net/OrderedCsvHttpHeader.cs
+++ Net/OrderedCsvHttpHeader.cs
@@ -9,6 +9,8 @@
 using System.Collections.Generic;
 using System.Linq;
 using System.Text;
+
+using McSherry.Zener.Core;

 namespace McSherry.Zener.Net
 {
@@ -43,10 +45,40 @@
             ;

         /// <summary>
+        /// Converts an indexed dictionary to a string that would be accepted
+        /// by the Networking.ParseUnquotedKeyValues method called in
+        /// OrderedCsvHttpHeader's constructor.
+        /// </summary>
+        /// <param name="dict">The dictionary to convert.</param>
+        /// <returns>A key-value string representation of the dictionary.</returns>
+        private string GetIxDictString(IndexedDictionary<string, string> dict)
+        {
+            StringBuilder sb = new StringBuilder();
+
+            foreach (var kvp in dict)
+            {
+                if (kvp.Value == null)
+                {
+                    sb.AppendFormat("{0}; ", kvp.Key);
+                }
+                else
+                {
+                    sb.AppendFormat("{0}={1}; ", kvp.Key, kvp.Value);
+                }
+            }
+
+            return sb.ToString().Trim(' ', ';');
+        }
+
+        /// <summary>
         /// Creates a new OrderedCsvHttpHeader from an HttpHeader class.
         /// </summary>
         /// <param name="header">
         /// The HttpHeader class to create this OrderedCsvHttpHeader from.
+        /// </param>
+        /// <param name="removeUnacceptable">
+        /// Whether to remove any comma-separated values which have a q-value
+        /// indicating that they are not acceptable.
         /// </param>
         /// <exception cref="System.ArgumentException">
         ///     Thrown when:
@@ -55,8 +87,11 @@
         ///         3. The field name contains a carriage return or line feed character.
         ///         4. The value contains a carriage return or line feed character.
         /// </exception>
-        public OrderedCsvHttpHeader(HttpHeader header)
-            : this(header.Field, header.Value)
+        public OrderedCsvHttpHeader(
+            HttpHeader header,
+            bool removeUnacceptable = false
+            )
+            : this(header.Field, header.Value, removeUnacceptable)
         {

         }
@@ -69,26 +104,34 @@
         /// <param name="fieldValue">
         /// The value of the header.
         /// </param>
+        /// <param name="removeUnacceptable">
+        /// Whether to remove any comma-separated values which have a q-value
+        /// indicating that they are not acceptable.
+        /// </param>
         /// <exception cref="System.ArgumentException">
-        ///     Thrown when:
-        ///         1. The provided field name is null, zero-length, or whitespace.
-        ///         2. The provided value is null, zero-length, or whitespace.
-        ///         3. The field name contains a carriage return or line feed character.
-        ///         4. The value contains a carriage return or line feed character.
-        ///         5. One or more of the comma-separated items cannot be parsed as a
-        ///            set of key-value pairs.
-        ///         6. One or more of the q-values is invalid.
+        /// Thrown when:
+        ///     1. The provided field name is null, zero-length, or whitespace.
+        ///     2. The provided value is null, zero-length, or whitespace.
+        ///     3. The field name contains a carriage return or line feed character.
+        ///     4. The value contains a carriage return or line feed character.
+        ///     5. One or more of the comma-separated items cannot be parsed as a
+        ///        set of key-value pairs.
+        ///     6. One or more of the q-values is invalid.
         /// </exception>
-        public OrderedCsvHttpHeader(string fieldName, string fieldValue)
+        public OrderedCsvHttpHeader(
+            string fieldName, string fieldValue,
+            bool removeUnacceptable = false
+            )
             : base(fieldName, fieldValue)
         {
+            IndexedDictionary<string, string>[] ixDicts =
+                new IndexedDictionary<string,string>[base.Items.Count];
             decimal[] weightings = new decimal[base.Items.Count];
             for (int i = 0; i < base.Items.Count; i++)
             {
-                IDictionary<string, string> kvp;
                 try
                 {
-                    kvp = Networking
+                    ixDicts[i] = Networking
                         .ParseUnquotedKeyValues(base.Items.ElementAt(i));
                 }
                 catch (ArgumentException aex)
@@ -99,6 +142,8 @@
                         aex
                         );
                 }
+
+                var kvp = ixDicts[i];

                 // Attempt to retrieve the item's weighting.
                 string wStr;
@@ -147,20 +192,54 @@
                 }
             }

-            base.Items = base.Items
-                // Associate the weightings with the appropriate
-                // comma-separated values.
-                .Zip(weightings, (i, w) => new { i, w })
-                // Order them, ensuring that the largest weighting
-                // is placed first.
-                .OrderByDescending(o => o.w)
-                // Retrieve the now-ordered items. We'll leave the
-                // item strings unmodified (this means that the
-                // q-values are still present).
-                .Select(o => o.i)
-                // base.Items is an ICollection, so we need to
-                // set it as something that implements that interface.
-                .ToList();
+            // Remove any q-values from the indexed dictionaries.
+            foreach (var ix in ixDicts) ix.Remove("q");
+
+            // Just having two separate code paths is probably going to
+            // be faster and more readable than having some weird combinatorial
+            // logic in LINQ calls.
+            if (removeUnacceptable)
+            {
+                base.Items = ixDicts
+                    // Associate the weightings with the appropriate
+                    // comma-separated values.
+                    .Zip(weightings, (d, w) => new { d, w })
+                    // Remove any items which have the minimum weighting.
+                    .Where(o => o.w != MinimumWeighting)
+                    // Order them, ensuring that the largest weighting
+                    // is placed first.
+                    .OrderByDescending(o => o.w)
+                    // We then convert the IndexedDictionary instances
+                    // to a string. We previously removed any q-values,
+                    // so this should now just be the comma-separated
+                    // value.
+                    .Select(o => this.GetIxDictString(o.d))
+                    // base.Items needs to be an ICollection, so we
+                    // use the appropriate method. We also make it
+                    // read-only.
+                    .ToList()
+                    .AsReadOnly();
+            }
+            else
+            {
+                base.Items = ixDicts
+                    // Associate the weightings with the appropriate
+                    // comma-separated values.
+                    .Zip(weightings, (d, w) => new { d, w })
+                    // Order them, ensuring that the largest weighting
+                    // is placed first.
+                    .OrderByDescending(o => o.w)
+                    // We then convert the IndexedDictionary instances
+                    // to a string. We previously removed any q-values,
+                    // so this should now just be the comma-separated
+                    // value.
+                    .Select(o => this.GetIxDictString(o.d))
+                    // base.Items needs to be an ICollection, so we
+                    // use the appropriate method. We also make it
+                    // read-only.
+                    .ToList()
+                    .AsReadOnly();
+            }
         }
     }
 }


Updated version number to 0.9.1.

Updated version number to 0.9.1.

--- Nini/Source/AssemblyInfo.cs
+++ Nini/Source/AssemblyInfo.cs
@@ -49,7 +49,7 @@
 // You can specify all the values or you can default the Revision and Build Numbers
 // by using the '*' as shown below:

-[assembly: System.Reflection.AssemblyVersion("0.9.0.0")]
+[assembly: System.Reflection.AssemblyVersion("0.9.1.0")]

 [assembly:CLSCompliant(true)] // Required for CLS compliance


productinfomessage: fix renew prices

productinfomessage: fix renew prices

--- Community/ProductInfoMessage.cs
+++ Community/ProductInfoMessage.cs
@@ -50,6 +50,12 @@
 		/// </summary>
 		[EnumMember]
 		IsRefundRequested = IsRefundAllow << 1,
+
+		/// <summary>
+		/// Was purchased before.
+		/// </summary>
+		[EnumMember]
+		WasPurchased = IsRefundRequested << 1,
 	}

 	/// <summary>
@@ -147,17 +153,13 @@
 		/// Price for monthly renew.
 		/// </summary>
 		[DataMember]
-		[Obsolete]
-		// ReSharper disable once ValueParameterNotUsed
-		public Currency RenewMonthlyPrice { get => RenewPrice; set { } }
+		public Currency RenewMonthlyPrice { get; set; }

 		/// <summary>
 		/// Price for annual renew.
 		/// </summary>
 		[DataMember]
-		[Obsolete]
-		// ReSharper disable once ValueParameterNotUsed
-		public Currency RenewAnnualPrice { get => RenewPrice; set { } }
+		public Currency RenewAnnualPrice { get; set; }

 		/// <summary>
 		/// Download count.
@@ -329,6 +331,8 @@
 			destination.AnnualPrice = AnnualPrice?.Clone();
 			destination.LifetimePrice = LifetimePrice?.Clone();
 			destination.RenewPrice = RenewPrice?.Clone();
+			destination.RenewMonthlyPrice = RenewMonthlyPrice?.Clone();
+			destination.RenewAnnualPrice = RenewAnnualPrice?.Clone();
 			destination.DownloadCount = DownloadCount;
 			destination.Rating = Rating;
 			destination.DocUrl = DocUrl;
@@ -371,11 +375,11 @@
 			if (Author != 0)
 				str += $",Author={Author}";

-			if (MonthlyPrice != null || DiscountMonthlyPrice != null)
-				str += $",Monthly={MonthlyPrice} (disc={DiscountMonthlyPrice})";
-
-			if (AnnualPrice != null || DiscountAnnualPrice != null)
-				str += $",Annual={AnnualPrice} (disc={DiscountAnnualPrice})";
+			if (MonthlyPrice != null || DiscountMonthlyPrice != null || RenewMonthlyPrice != null)
+				str += $",Monthly={MonthlyPrice},renew={RenewMonthlyPrice},disc={DiscountMonthlyPrice}";
+
+			if (AnnualPrice != null || DiscountAnnualPrice != null || RenewAnnualPrice != null)
+				str += $",Annual={AnnualPrice},renew={RenewAnnualPrice},disc={DiscountAnnualPrice}";

 			if (LifetimePrice != null || DiscountLifetimePrice != null)
 				str += $",Life={LifetimePrice} (disc={DiscountLifetimePrice})";


Tweak to unit test

Tweak to unit test

--- test/Test.Integration/NuGetCommandLine/NuGetPushCommandTest.cs
+++ test/Test.Integration/NuGetCommandLine/NuGetPushCommandTest.cs
@@ -302,7 +302,7 @@
                 // Assert
                 var output = Encoding.Default.GetString(memoryStream.ToArray());
                 Assert.NotEqual(0, ret);
-                Assert.Contains("The remote server returned an error: (302) Redirect.", output);
+                Assert.Contains("The remote server returned an error: (302)", output);
             }
             finally
             {


Add test for when only TrackedSha changes

--- test/UnitTests/GitHub.App/Services/TeamExplorerContextTests.cs
+++ test/UnitTests/GitHub.App/Services/TeamExplorerContextTests.cs
@@ -187,6 +187,26 @@
                 Assert.That(eventWasRaised, Is.EqualTo(expectWasRaised));
             }

+            [TestCase("trackedSha", "trackedSha", false)]
+            [TestCase("trackedSha1", "trackedSha2", true)]
+            public void TrackedShaChanges_CheckWasRaised(string trackedSha1, string trackedSha2, bool expectWasRaised)
+            {
+                var gitExt = new FakeGitExt();
+                var repositoryPaths = new[] { Directory.GetCurrentDirectory(), Path.GetTempPath() };
+                var repoPath = Directory.GetCurrentDirectory();
+                var repoInfo = new GitRepositoryInfo(repoPath, new GitBranchInfo("name", "sha"));
+                var service = Substitute.For<TeamExplorerContext.IService>();
+                service.FindTrackedSha(Arg.Any<string>()).Returns(trackedSha1, trackedSha2);
+                var target = CreateTeamExplorerContext(gitExt, service: service);
+                gitExt.SetActiveRepository(repoInfo);
+                var eventWasRaised = false;
+                target.StatusChanged += (s, e) => eventWasRaised = true;
+
+                gitExt.SetActiveRepository(repoInfo);
+
+                Assert.That(eventWasRaised, Is.EqualTo(expectWasRaised));
+            }
+
             [Test]
             public void SolutionUnloadedAndReloaded_DontFireStatusChanged()
             {


On Windows the resolver is not used

On Windows the resolver is not used

git-svn-id: 648254992e62896316d6a1d4b75c778d65bd21a1@419 458802cb-8328-0410-b1d9-a76001e3bb52

--- xmlunit/src/main/net-core/validation/Validator.cs
+++ xmlunit/src/main/net-core/validation/Validator.cs
@@ -109,12 +109,24 @@
             }
             List<ValidationProblem> problems = new List<ValidationProblem>();
             settings.ValidationEventHandler += CollectProblems(problems);
+            settings.XmlResolver = new ThrowingResolver();
             using (XmlReader r = XmlReader.Create(instance.Reader,
                                                   settings)) {
                 while (r.Read()) ;
             }
             return new ValidationResult(problems.Count == 0, problems);
         }
+
+        private class ThrowingResolver : XmlResolver {
+            public override object GetEntity(Uri uri, string role, Type type) {
+                throw new Exception(string.Format("GetEntity invoked with ({0}, {1}, {2}",
+                                                  uri, role, type));
+            }
+
+            public override System.Net.ICredentials Credentials {
+                set {}
+            }
+        }

         private static readonly IDictionary<string, ValidationType> types;


修改代码瑕疵

修改代码瑕疵

--- ConvertLibrary/ExcelAnalysis.cs
+++ ConvertLibrary/ExcelAnalysis.cs
@@ -80,7 +80,7 @@

                 Range currentCell1 = (Range)eWorksheet.Cells[i, 1];
                 int icount = currentCell1.MergeArea.Count;
-                tc.ExternalId = currentCell1.Text.ToString().ToString();
+                tc.ExternalId = currentCell1.Text.ToString();

                 Range currentCell2 = (Range) eWorksheet.Cells[i, 2];
                 tc.Name = currentCell2.Text.ToString();


Remove Console.WriteLine statements in Management.Client.

--- Source/EasyNetQ.Management.Client/ManagementClient.cs
+++ Source/EasyNetQ.Management.Client/ManagementClient.cs
@@ -619,7 +619,6 @@
         private HttpWebRequest CreateRequestForPath(string path)
         {
 			var endpointAddress = BuildEndpointAddress (path);
-			Console.WriteLine (endpointAddress);

 			var uri = new Uri (endpointAddress);

@@ -638,7 +637,6 @@

 			var request = (HttpWebRequest)WebRequest.Create(uri);
             request.Credentials = new NetworkCredential(username, password);
-			Console.WriteLine (request.RequestUri.PathAndQuery);
             return request;
         }


Only one thread can access the files event store

--- Source/EventFlow/EventStores/Files/FilesEventStore.cs
+++ Source/EventFlow/EventStores/Files/FilesEventStore.cs
@@ -37,6 +37,7 @@
     {
         private readonly IJsonSerializer _jsonSerializer;
         private readonly IFilesEventStoreConfiguration _configuration;
+        private readonly AsyncLock _asyncLock = new AsyncLock();

         public class FileEventData : ICommittedDomainEvent
         {
@@ -68,73 +69,79 @@
             IReadOnlyCollection<SerializedEvent> serializedEvents,
             CancellationToken cancellationToken)
         {
-            var aggregateType = typeof (TAggregate);
-            var batchId = Guid.NewGuid();
-            var committedDomainEvents = new List<ICommittedDomainEvent>();
+            using (await _asyncLock.WaitAsync(cancellationToken).ConfigureAwait(false))
+            {
+                var aggregateType = typeof (TAggregate);
+                var batchId = Guid.NewGuid();
+                var committedDomainEvents = new List<ICommittedDomainEvent>();

-            var aggregatePath = GetAggregatePath(aggregateType, id);
-            if (!Directory.Exists(aggregatePath))
-            {
-                Directory.CreateDirectory(aggregatePath);
-            }
-
-            foreach (var serializedEvent in serializedEvents)
-            {
-                var fileEventData = new FileEventData
-                    {
-                        AggregateId = id,
-                        AggregateName = aggregateType.Name,
-                        AggregateSequenceNumber = serializedEvent.AggregateSequenceNumber,
-                        BatchId = batchId,
-                        Data = serializedEvent.Data,
-                        GlobalSequenceNumber = serializedEvent.AggregateSequenceNumber, // TODO: Find a better number
-                        Metadata = serializedEvent.Meta,
-                    };
-
-                var json = _jsonSerializer.Serialize(fileEventData);
-                var eventPath = GetEventPath(aggregateType, id, serializedEvent.AggregateSequenceNumber);
-
-                if (File.Exists(eventPath))
+                var aggregatePath = GetAggregatePath(aggregateType, id);
+                if (!Directory.Exists(aggregatePath))
                 {
-                    // TODO: This needs to be on file creation
-                    throw new OptimisticConcurrencyException(string.Format(
-                        "Event {0} already exists for aggregate '{1}' with ID '{2}'",
-                        fileEventData.AggregateSequenceNumber,
-                        aggregateType.Name,
-                        id));
+                    Directory.CreateDirectory(aggregatePath);
                 }

-                using (var streamWriter = File.CreateText(eventPath))
+                foreach (var serializedEvent in serializedEvents)
                 {
-                    Log.Verbose("Writing file '{0}'", eventPath);
-                    await streamWriter.WriteAsync(json).ConfigureAwait(false);
+                    var fileEventData = new FileEventData
+                        {
+                            AggregateId = id,
+                            AggregateName = aggregateType.Name,
+                            AggregateSequenceNumber = serializedEvent.AggregateSequenceNumber,
+                            BatchId = batchId,
+                            Data = serializedEvent.Data,
+                            GlobalSequenceNumber = serializedEvent.AggregateSequenceNumber, // TODO: Find a better number
+                            Metadata = serializedEvent.Meta,
+                        };
+
+                    var json = _jsonSerializer.Serialize(fileEventData);
+                    var eventPath = GetEventPath(aggregateType, id, serializedEvent.AggregateSequenceNumber);
+
+                    if (File.Exists(eventPath))
+                    {
+                        // TODO: This needs to be on file creation
+                        throw new OptimisticConcurrencyException(string.Format(
+                            "Event {0} already exists for aggregate '{1}' with ID '{2}'",
+                            fileEventData.AggregateSequenceNumber,
+                            aggregateType.Name,
+                            id));
+                    }
+
+                    using (var streamWriter = File.CreateText(eventPath))
+                    {
+                        Log.Verbose("Writing file '{0}'", eventPath);
+                        await streamWriter.WriteAsync(json).ConfigureAwait(false);
+                    }
+
+                    committedDomainEvents.Add(fileEventData);
                 }
-
-                committedDomainEvents.Add(fileEventData);
+
+                return committedDomainEvents;
             }
-
-            return committedDomainEvents;
         }

         protected override async Task<IReadOnlyCollection<ICommittedDomainEvent>> LoadCommittedEventsAsync<TAggregate>(
             string id,
             CancellationToken cancellationToken)
         {
-            var aggregateType = typeof (TAggregate);
-            var committedDomainEvents = new List<ICommittedDomainEvent>();
-            for (var i = 1;; i++)
+            using (await _asyncLock.WaitAsync(cancellationToken).ConfigureAwait(false))
             {
-                var eventPath = GetEventPath(aggregateType, id, i);
-                if (!File.Exists(eventPath))
+                var aggregateType = typeof(TAggregate);
+                var committedDomainEvents = new List<ICommittedDomainEvent>();
+                for (var i = 1; ; i++)
                 {
-                    return committedDomainEvents;
-                }
+                    var eventPath = GetEventPath(aggregateType, id, i);
+                    if (!File.Exists(eventPath))
+                    {
+                        return committedDomainEvents;
+                    }

-                using (var streamReader = File.OpenText(eventPath))
-                {
-                    var json = await streamReader.ReadToEndAsync().ConfigureAwait(false);
-                    var committedDomainEvent = _jsonSerializer.Deserialize<FileEventData>(json);
-                    committedDomainEvents.Add(committedDomainEvent);
+                    using (var streamReader = File.OpenText(eventPath))
+                    {
+                        var json = await streamReader.ReadToEndAsync().ConfigureAwait(false);
+                        var committedDomainEvent = _jsonSerializer.Deserialize<FileEventData>(json);
+                        committedDomainEvents.Add(committedDomainEvent);
+                    }
                 }
             }
         }


Added example for issue 10056

Added example for issue 10056

--- Source/Examples/ExampleLibrary/Examples/OpenIssues.cs
+++ Source/Examples/ExampleLibrary/Examples/OpenIssues.cs
@@ -76,5 +76,62 @@
             plotModel1.Series.Add(lineSeries1);
             return plotModel1;
         }
+
+        [Example("10056: Tracker wrong for logarithmic y-axis")]
+        public static PlotModel ValueTime()
+        {
+            var plotModel1 = new PlotModel
+                                 {
+                                     LegendBackground = OxyColor.FromArgb(200, 255, 255, 255),
+                                     LegendBorder = OxyColors.Black,
+                                     LegendPlacement = LegendPlacement.Outside,
+                                     PlotAreaBackground = OxyColors.Gray,
+                                     PlotAreaBorderColor = OxyColors.Gainsboro,
+                                     PlotAreaBorderThickness = 2,
+                                     Title = "Value / Time"
+                                 };
+            var linearAxis1 = new LinearAxis
+                                  {
+                                      AbsoluteMaximum = 45,
+                                      AbsoluteMinimum = 0,
+                                      Key = "X-Axis",
+                                      Maximum = 46,
+                                      Minimum = -1,
+                                      Position = AxisPosition.Bottom,
+                                      Title = "Years",
+                                      Unit = "yr"
+                                  };
+            plotModel1.Axes.Add(linearAxis1);
+            var logarithmicAxis1 = new LogarithmicAxis { Key = "Y-Axis", Title = "Value for section" };
+            plotModel1.Axes.Add(logarithmicAxis1);
+            var lineSeries1 = new LineSeries
+                                  {
+                                      Color = OxyColors.Red,
+                                      LineStyle = LineStyle.Solid,
+                                      MarkerFill = OxyColors.Black,
+                                      MarkerSize = 2,
+                                      MarkerStroke = OxyColors.Black,
+                                      MarkerType = MarkerType.Circle,
+                                      DataFieldX = "X",
+                                      DataFieldY = "Y",
+                                      XAxisKey = "X-Axis",
+                                      YAxisKey = "Y-Axis",
+                                      Background = OxyColors.White,
+                                      Title = "Section Value",
+                                      TrackerKey = "ValueVersusTimeTracker"
+                                  };
+            lineSeries1.Points.Add(new DataPoint(0, 0));
+            lineSeries1.Points.Add(new DataPoint(5, 0));
+            lineSeries1.Points.Add(new DataPoint(10, 0));
+            lineSeries1.Points.Add(new DataPoint(15, 0));
+            lineSeries1.Points.Add(new DataPoint(20, 1));
+            lineSeries1.Points.Add(new DataPoint(25, 1));
+            lineSeries1.Points.Add(new DataPoint(30, 1));
+            lineSeries1.Points.Add(new DataPoint(35, 1));
+            lineSeries1.Points.Add(new DataPoint(40, 1));
+            lineSeries1.Points.Add(new DataPoint(45, 1));
+            plotModel1.Series.Add(lineSeries1);
+            return plotModel1;
+        }
     }
 }


Workitem 10045 solved.

Workitem 10045 solved.

--- Source/HelixToolkit.Wpf.SharpDX/Controls/DPFCanvas.cs
+++ Source/HelixToolkit.Wpf.SharpDX/Controls/DPFCanvas.cs
@@ -332,7 +332,7 @@
             this.device.ImmediateContext.ResolveSubresource(this.colorBuffer, 0, this.renderTargetNMS, 0, Format.B8G8R8A8_UNorm);
             this.surfaceD3D.SetRenderTargetDX11(this.renderTargetNMS);
 #else
-            this.surfaceD3D.SetRenderTargetDX11(this.renderTarget);
+            this.surfaceD3D.SetRenderTargetDX11(this.colorBuffer);
 #endif
         }

@@ -412,7 +412,6 @@
                         }
                         this.renderContext = new RenderContext(this, EffectsManager.Instance.GetEffect(this.RenderTechnique));
                         this.renderRenderable.Attach(this);
-                        this.SetDefaultRenderTargets();

                         if(this.RenderTechnique == Techniques.RenderDeferred)
                         {
@@ -430,6 +429,8 @@
                     }
                 }

+                this.SetDefaultRenderTargets();
+
                 /// ---------------------------------------------------------------------------
                 /// this part is per frame
                 if (this.RenderTechnique == Techniques.RenderDeferred)
@@ -458,7 +459,7 @@
 #if MSAA
                     this.deferredRenderer.RenderGBufferOutput(ref this.renderTargetNMS);
 #else
-                    this.deferredRenderer.RenderGBufferOutput(ref this.renderTarget);
+                    this.deferredRenderer.RenderGBufferOutput(ref this.colorBuffer);
 #endif
                 }
                 else


openPDC Manager: Added a confirm dialog if user want to update output stream device when an input device acronym is changed.

git-tfs-id: [https://tfs.codeplex.com/tfs/TFS07]$/openpdc/Synchrophasor/Current Version;C72691

--- Source/Libraries/openPDC.UI.WPF/ViewModels/Devices.cs
+++ Source/Libraries/openPDC.UI.WPF/ViewModels/Devices.cs
@@ -498,7 +498,7 @@

                 try
                 {
-                    if (originalDevice != null && CurrentItem.Acronym != originalDevice.Acronym) // if acronym was modified then make changes to output stream devices.
+                    if (originalDevice != null && CurrentItem.Acronym != originalDevice.Acronym && Confirm("Do you want to update corresponding output stream device?", "Update Output Stream Device")) // if acronym was modified then make changes to output stream devices.
                     {
                         ObservableCollection<OutputStreamDevice> outputStreamDevices = OutputStreamDevice.GetOutputStreamDevices(null, "WHERE Acronym = '" + originalDevice.Acronym + "'");
                         foreach (OutputStreamDevice device in outputStreamDevices)


Clean up usings in AllBreakersReport.cs

Clean up usings in AllBreakersReport.cs

--- Source/Libraries/openXDA.Reports/AllBreakersReport.cs
+++ Source/Libraries/openXDA.Reports/AllBreakersReport.cs
@@ -21,27 +21,19 @@
 //
 //******************************************************************************************************

-using GSF.Web.Model;
-using openHistorian.XDALink;
-using openXDA.Model;
-using Root.Reports;
 using System;
 using System.Collections.Generic;
 using System.Data;
 using System.Drawing;
 using System.IO;
 using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using System.Windows.Forms.DataVisualization.Charting;
-using ChartSeries = System.Windows.Forms.DataVisualization.Charting.Series;
+using GSF.Data;
 using log4net;
-using GSF;
-using GSF.Data;
+using Root.Reports;

 namespace openXDA.Reports
 {
-    public class AllBreakersReport : Root.Reports.Report
+    public class AllBreakersReport : Report
     {
         #region [ Members ]
         public class Point {


make HFTLog correctly filter

make HFTLog correctly filter

--- Assets/HappyFunTimes/HappyFunTimesCore/HFTLog.cs
+++ Assets/HappyFunTimes/HappyFunTimesCore/HFTLog.cs
@@ -2,6 +2,7 @@
 using System.Collections.Generic;
 using System.Text.RegularExpressions;
 using System.IO;
+using System.Linq;

 namespace HappyFunTimes
 {
@@ -75,7 +76,7 @@
             set
             {
                 s_debug = value;
-                string[] patterns = s_debug.Split(',');
+                string[] patterns = s_debug.Replace("\n", ",").Split(',').Where(s => !String.IsNullOrEmpty(s)).ToArray();
                 for (int i = 0; i < patterns.Length; ++i)
                 {
                     patterns[i] = patterns[i].Replace("*", ".*?");


remove unused annotations and namepsaces

--- Assets/Scripts/HarryPotterUnity/UI/HudManager.cs
+++ Assets/Scripts/HarryPotterUnity/UI/HudManager.cs
@@ -1,5 +1,4 @@
-using System;
-using System.Collections.Generic;
+using System.Collections.Generic;
 using System.Linq;
 using ExitGames.Client.Photon;
 using HarryPotterUnity.Enums;
@@ -100,14 +99,12 @@

         private List<LessonTypes> _selectedLessons;

-        [UsedImplicitly]
         public void Start()
         {
             _networkManager = FindObjectsOfType<NetworkManager>().First();
             _selectedLessons = new List<LessonTypes>();
         }
-
-        [UsedImplicitly]
+
         public void Update()
         {
             _playersOnlineText.text = string.Format("Players Online: {0}", PhotonNetwork.countOfPlayers);


Changed a test from relying on TestEventX

to instead relying on DataContractTestEventX, because the test isn't
concerned with the exact type of event anyway. This is done in order to
clean up the test library by ultimately removing the TestEventX class.

--- AtomEventStore.UnitTests/AtomEventStreamTests.cs
+++ AtomEventStore.UnitTests/AtomEventStreamTests.cs
@@ -22,8 +22,8 @@
         public void VerifyGuardClauses(GuardClauseAssertion assertion)
         {
             assertion.Verify(
-                typeof(AtomEventStream<TestEventX>).GetMembers()
-                    .Where(m => new Methods<AtomEventStream<TestEventX>>().Select(x => x.OnError(null)) != m));
+                typeof(AtomEventStream<DataContractTestEventX>).GetMembers()
+                    .Where(m => new Methods<AtomEventStream<DataContractTestEventX>>().Select(x => x.OnError(null)) != m));
         }

         [Theory, AutoAtomData]


Add BTCPayServerEnvironment.Altcoins

Add BTCPayServerEnvironment.Altcoins

--- BTCPayServer/Services/BTCPayServerEnvironment.cs
+++ BTCPayServer/Services/BTCPayServerEnvironment.cs
@@ -22,6 +22,12 @@
 #else
 			Build = "Release";
 #endif
+#if ALTCOINS
+            AltcoinsVersion = true;
+#else
+            AltcoinsVersion = false;
+#endif
+
             Environment = env;
             NetworkType = provider.NetworkType;
             this.torServices = torServices;
@@ -46,6 +52,7 @@
         {
             get; set;
         }
+        public bool AltcoinsVersion { get; set; }

         public bool IsDevelopping
         {
@@ -72,9 +79,8 @@
         {
             StringBuilder txt = new StringBuilder();
             txt.Append($"@Copyright BTCPayServer v{Version}");
-#if ALTCOINS
-            txt.Append($" (altcoins)");
-#endif
+            if (AltcoinsVersion)
+                txt.Append($" (altcoins)");
             if (!Environment.IsProduction() || !Build.Equals("Release", StringComparison.OrdinalIgnoreCase))
             {
                 txt.Append($" Environment: {Environment.EnvironmentName} Build: {Build}");


added a handling of timeoutException into the service call.


KN-8222 If scope is empty all translation are exported

--- Core/Web/LocalizationHandler.cs
+++ Core/Web/LocalizationHandler.cs
@@ -170,6 +170,8 @@
 						foreach (var s in scopes)
 							res.AddRange(objects.Where(obj => obj.Scope.ToLowerInvariant().Contains(s.ToLowerInvariant())));
 					}
+					else
+						res.AddRange(objects);

 					var data = res.Select(x =>
 						new


Spelling error in assembly info

Spelling error in assembly info


Modified JsonBodyHandler.cs to fix how headers are handled

--- src/main/csharp/JsonBodyHandler.cs
+++ src/main/csharp/JsonBodyHandler.cs
@@ -39,7 +39,7 @@
         {
             if (body != null && stream != null)
             {
-                stream.Write(body, 0, body.Length);
+                stream.Write(body, 0, body.Length);
             }
         }

@@ -47,14 +47,14 @@
         {
             if (request != null)
             {
-                req.Headers.Add("Content-Type", "application/json");
+                req.ContentType = "application/json";

                 try
                 {
                     string jsonBody = JsonConvert.SerializeObject(request);
                     body = Encoding.UTF8.GetBytes(jsonBody);

-                    req.Headers.Add("Content-Length", body.Length.ToString());
+                    req.ContentLength = body.Length;
                 }
                 catch (IOException e)
                 {


Implementing most of the content type export process

--- Chauffeur/Deliverables/ContentTypeDeliverable.cs
+++ Chauffeur/Deliverables/ContentTypeDeliverable.cs
@@ -3,8 +3,10 @@
 using System.Configuration;
 using System.IO;
 using System.Linq;
+using System.Reflection;
 using System.Text;
 using System.Threading.Tasks;
+using System.Xml.Linq;
 using Umbraco.Core;
 using Umbraco.Core.Models;
 using Umbraco.Core.Persistence;
@@ -38,6 +40,10 @@
                     await Get(args.Skip(1).ToArray());
                     break;

+                case "export":
+                    await Export(args.Skip(1).ToArray());
+                    break;
+
                 default:
                     await Out.WriteLineAsync(string.Format("The operation `{0}` is not supported", operation));
                     break;
@@ -46,12 +52,84 @@
             return await base.Run(args);
         }

-        private async Task Get(string[] args)
+        private async Task Export(string[] args)
+        {
+            var contentType = await Get(args, false);
+
+            if (contentType == null)
+                return;
+
+            var exportDirectory = Path.Combine(new FileInfo(Assembly.GetExecutingAssembly().Location).Directory.FullName, "..", "App_Data", "Chauffeur");
+
+            if (!Directory.Exists(exportDirectory))
+            {
+                try
+                {
+                    Directory.CreateDirectory(exportDirectory);
+                }
+                catch (UnauthorizedAccessException)
+                {
+                    Out.WriteLine("Chauffer directory 'App_Data\\Chauffeur' cannot be created, check directory permissions");
+                    return;
+                }
+            }
+
+            var xml = new XDocument();
+            xml.Add(new XElement("DocumentType",
+                    new XElement("Info",
+                        new XElement("Name", contentType.Name),
+                        new XElement("Alias", contentType.Alias),
+                        new XElement("Icon", contentType.Icon),
+                        new XElement("Thumbnail", contentType.Thumbnail),
+                        new XElement("Description", contentType.Description),
+                        new XElement("AllowAtRoot", contentType.AllowedAsRoot),
+                        //todo - Master support
+                        new XElement("AllowedTemplates",
+                            contentType.AllowedTemplates.Select(t => new XElement("Template", t.Alias))
+                        ),
+                        new XElement("DefaultTemplate", contentType.DefaultTemplate == null ? string.Empty : contentType.DefaultTemplate.Alias)
+                    ),
+                    new XElement("Structure",
+                        contentType.AllowedContentTypes.Select(c => new XElement("DocumentType", c.Alias))
+                    ),
+                    new XElement("GenericProperties",
+                        contentType.PropertyTypes
+                            .Select(pt => new XElement(
+                                    "GenericProperty",
+                                    new XElement("Name", pt.Name),
+                                    new XElement("Alias", pt.Alias),
+                                    new XElement("Type", pt.PropertyEditorAlias),
+                                    //new XElement("Definition"),
+                                    //new XElement("Tab"),
+                                    new XElement("Mandatory", pt.Mandatory),
+                                    new XElement("Validation", pt.ValidationRegExp),
+                                    new XElement("Description", pt.Description)
+                                )
+                            )
+                    ),
+                    new XElement("Tabs",
+                        contentType.PropertyGroups.Select(pg =>
+                            new XElement("Tab",
+                                new XElement("Id", pg.Id),
+                                new XElement("Caption", pg.Name),
+                                new XElement("SortOrder", pg.SortOrder)
+                            )
+                        )
+                    )
+                )
+            );
+
+            var fileName = DateTime.UtcNow.ToString("yyyyMMdd") + "-" + contentType.Alias + ".xml";
+            xml.Save(Path.Combine(exportDirectory, fileName));
+            await Out.WriteLineAsync(string.Format("Content Type has been exported with file name '{0}'", fileName));
+        }
+
+        private async Task<IContentType> Get(string[] args, bool dump = true)
         {
             if (!args.Any())
             {
                 await Out.WriteLineAsync("Please provide the numerical id or alias if the doc type to get");
-                return;
+                return null;
             }

             var cts = CreateContentTypeService();
@@ -64,7 +142,7 @@
             {
                 //Sigh, can't use the GetByAlias because at the moment there are internal dependencies I can't load
                 //contentType = cts.GetContentType(args[0]);
-
+
                 //instead we'll find the ID ourselves from the DB
                 var sql = new Sql()
                     .Select("NodeId")
@@ -81,11 +159,12 @@

             if (contentType == null)
                 await Out.WriteLineAsync(string.Format("No content type found with {0} of '{1}'", foundWith, args[0]));
-            else
+            else if (dump)
                 await PrintContentType(contentType);
-        }
-
-        private async Task PrintContentType(Umbraco.Core.Models.IContentType contentType)
+            return contentType;
+        }
+
+        private async Task PrintContentType(IContentType contentType)
         {
             await Out.WriteLineAsync("\tId\tAlias\tName\tParent Id");
             await Out.WriteLineAsync(


Added stub for future calculator - needs major grid fixes

--- Demos/SampleApp/SampleWindow.cs
+++ Demos/SampleApp/SampleWindow.cs
@@ -227,6 +227,95 @@
             Child = b;
         }

+        public void CalculatorampleWindow()
+        {
+            Background = Brushes.Black;
+            Grid mainGrid = new Grid
+            {
+                HorizontalAlignment = HorizontalAlignment.Stretch,
+                VerticalAlignment = VerticalAlignment.Stretch,
+            };
+            Child = mainGrid;
+            mainGrid.RowDefinitions.Add(new RowDefinition(new GridLength()));
+            mainGrid.RowDefinitions.Add(new RowDefinition(new GridLength()));
+            mainGrid.RowDefinitions.Add(new RowDefinition(new GridLength(1, GridLengthType.Star)));
+            mainGrid.ColumnDefinitions.Add(new ColumnDefinition());
+
+            TextBlock trackerText = new TextBlock
+            {
+                Text = "1 + ",
+                Foreground = Brushes.LightGray,
+                FontSize = 8,
+                HorizontalAlignment = HorizontalAlignment.Right,
+                Margin = new FourSidedNumber(5)
+            };
+            mainGrid.Children.Add(trackerText);
+            mainGrid.SetChildColumn(trackerText, 0);
+            mainGrid.SetChildRow(trackerText, 0);
+
+
+            TextBlock inputText = new TextBlock
+            {
+                Text = "123",
+                Foreground = Brushes.White,
+                FontSize = 32,
+                FontWeight = FontWeight.Bold,
+                HorizontalAlignment = HorizontalAlignment.Right,
+                Margin = new FourSidedNumber(5)
+            };
+            mainGrid.Children.Add(inputText);
+            mainGrid.SetChildColumn(inputText, 0);
+            mainGrid.SetChildRow(inputText, 1);
+
+            Grid buttonsGrid = new Grid
+            {
+                HorizontalAlignment = HorizontalAlignment.Stretch,
+                VerticalAlignment = VerticalAlignment.Stretch,
+            };
+            buttonsGrid.RowDefinitions.Add(new RowDefinition(new GridLength(1, GridLengthType.Star)));
+            buttonsGrid.RowDefinitions.Add(new RowDefinition(new GridLength(1, GridLengthType.Star)));
+            buttonsGrid.RowDefinitions.Add(new RowDefinition(new GridLength(1, GridLengthType.Star)));
+            buttonsGrid.RowDefinitions.Add(new RowDefinition(new GridLength(1, GridLengthType.Star)));
+            buttonsGrid.RowDefinitions.Add(new RowDefinition(new GridLength(1, GridLengthType.Star)));
+            buttonsGrid.ColumnDefinitions.Add(new ColumnDefinition(new GridLength(1, GridLengthType.Star)));
+            buttonsGrid.ColumnDefinitions.Add(new ColumnDefinition(new GridLength(1, GridLengthType.Star)));
+            buttonsGrid.ColumnDefinitions.Add(new ColumnDefinition(new GridLength(1, GridLengthType.Star)));
+            buttonsGrid.ColumnDefinitions.Add(new ColumnDefinition(new GridLength(1, GridLengthType.Star)));
+            mainGrid.Children.Add(buttonsGrid);
+            mainGrid.SetChildColumn(buttonsGrid, 0);
+            mainGrid.SetChildRow(buttonsGrid, 2);
+
+            string[] buttons = new[] { "CE", "^2", "sqrt", "/", "7", "8", "9", "X", "4", "5", "6", "-", "1", "2", "3", "+", "+-", "0", ".", "=" };
+            int row = 0;
+            int column = 0;
+            for (int i = 0; i < buttons.Length; i++)
+            {
+                if (column == 4)
+                {
+                    row++;
+                    column = 0;
+                }
+
+                Button b = new Button
+                {
+                    Content = buttons[i],
+                    HorizontalAlignment = HorizontalAlignment.Stretch,
+                    VerticalAlignment = VerticalAlignment.Stretch
+                };
+                buttonsGrid.Children.Add(b);
+                buttonsGrid.SetChildColumn(b, column);
+                buttonsGrid.SetChildRow(b, row);
+                b.Click += CalculatorButtonOnClick;
+
+                column++;
+            }
+
+        }
+
+        private void CalculatorButtonOnClick(object sender, EventArgs e)
+        {
+            Console.WriteLine(((Button)sender).Content + " clicked");
+        }

         private void OnMouseLeftButtonDown(object sender, EventArgs e)
         {


stateから初期化できるようにした。

stateから初期化できるようにした。

--- DiceStg-OnlineCore/GameState.cs
+++ DiceStg-OnlineCore/GameState.cs
@@ -44,6 +44,8 @@
             Turn = turn;
         }

+        public GameState(GameState state) : this(state.Field, state.Players, state.Turn) { }
+
         public GameState(Field field, List<Player> players) : this(field, players, 0) { }
     }
 }


Fix potential leak/null reference when switching projects

**Bug**
We can end up hitting a null dereference when switching projects for a project with a symlink watcher. This happens because we null out the `ItemNode` before destroying the symlink watcher.

**Fix**
Reorder the operations. We should destory the symlink watcher and then null out the nodes.

--- Common/Product/SharedProject/CommonFolderNode.cs
+++ Common/Product/SharedProject/CommonFolderNode.cs
@@ -239,10 +239,10 @@
         }

         public override void Close() {
-            base.Close();
-
             // make sure this thing isn't hanging around...
             ProjectMgr.TryDeactivateSymLinkWatcher(this);
+
+            base.Close();
         }

         /// <summary>


added stereotypes in NavigatorControl.cs

--- EANavigator/NavigatorControl.cs
+++ EANavigator/NavigatorControl.cs
@@ -397,6 +397,34 @@
 			return element.fqn;
 		}
 		/// <summary>
+		/// returns a string represenation of the stereotypes
+		/// </summary>
+		/// <param name="element">the element containing the stereotype</param>
+		/// <returns>a string containing the stereotype «stereo1,ste..»</returns>
+		private string getStereotypeString(UML.UMLItem element)
+		{
+			string stereotypeString = string.Empty;
+			int maxLength = 20;
+			if (element.stereotypes.Count > 0)
+			{
+				stereotypeString = "«";
+				foreach (UML.Profiles.Stereotype stereotype in element.stereotypes)
+				{
+					if (stereotypeString.Length > 1)
+					{
+						stereotypeString += ", ";
+					}
+					stereotypeString += stereotype.name;
+					if (stereotypeString.Length > maxLength)
+					{
+						stereotypeString = stereotypeString.Substring(0,maxLength- 2) + "..";
+					}
+				}
+				stereotypeString += "» ";
+			}
+			return stereotypeString;
+		}
+		/// <summary>
 		/// returns the name to show as node name for this element
 		/// </summary>
 		/// <param name="element"></param>
@@ -406,7 +434,8 @@
 			string name = string.Empty;
 			if (element != null)
 			{
-				name = element.name;
+				name = this.getStereotypeString(element);
+				name += element.name;
 			}
 			if (element is UML.Classes.Kernel.Parameter)
 			{
@@ -419,7 +448,7 @@
 			else if (element is UML.Classes.Kernel.Feature)
 			{
 				UML.Classes.Kernel.Feature feature = (UML.Classes.Kernel.Feature)element;
-				name = feature.owner.name + "." + feature.name;
+				name = feature.owner.name + "." + this.getStereotypeString(element)+ feature.name;
 			}
 			else if (element is UML.Profiles.TaggedValue)
 			{


Ajout de l'image par défaut du clou

Ajout de l'image par défaut du clou

--- Enigmas/Components/Clou/Nail.cs
+++ Enigmas/Components/Clou/Nail.cs
@@ -1,5 +1,6 @@
 using System;
 using System.Collections.Generic;
+using System.Drawing;
 using System.Linq;
 using System.Text;
 using System.Threading.Tasks;
@@ -12,9 +13,18 @@
     /// </summary>
     class Nail : PictureBox
     {
+        /// <summary>
+        /// Constructeur : Définition/instanciation des valeurs par défaut.
+        /// </summary>
         public Nail()
         {
+            #region Pbx propriétés
+            //Définition de l'image source
+            BackgroundImage = Properties.Resources.nailResized;

+            //Définition de la taille de l'image
+            Size = new Size(101, 356);
+            #endregion
         }
     }
 }


Update UniversalHashingFamily.cs

Update UniversalHashingFamily.cs

Added an extra check when choosing the second prime multiplier.

--- DataStructures/Hashing/UniversalHashingFamily.cs
+++ DataStructures/Hashing/UniversalHashingFamily.cs
@@ -54,8 +54,8 @@
             Array.Clear(_firstMultipliersVector, 0, _firstMultipliersVector.Length);
             Array.Clear(_secondMultipliersVector, 0, _secondMultipliersVector.Length);

-			int randomMin = 0;
-			int randomMax = _primes.Count - 1;
+	    int randomMin = 0;
+	    int randomMax = _primes.Count - 1;

             for (int i = 0; i < _numberOfHashFunctions; i++)
             {
@@ -66,10 +66,11 @@
                     randomIndex = _randomizer.Next(randomMin, randomMax);

                 _firstMultipliersVector[i] = _primes[randomIndex];
-
+
+		// make sure the next prime we choose is different than the first one and less than the biggest-prime.
                 randomIndex = _randomizer.Next(randomMin, randomMax);

-                while (_primes[randomIndex] >= BIG_PRIME)
+                while (_primes[randomIndex] >= BIG_PRIME || _primes[randomIndex] == _firstMultipliersVector[i])
                     randomIndex = _randomizer.Next(randomMin, randomMax);

                 _secondMultipliersVector[i] = _primes[randomIndex];
@@ -105,16 +106,13 @@

             int prehash = 0;
             var characters = key.ToCharArray();
-			int n = characters.Length;
-
-			for (int i = 0; i < n; ++i)
-            {
-				prehash = prehash + (characters[i] ^ (n - 1));
+	    int n = characters.Length;
+
+	    for (int i = 0; i < n; ++i) {
+	        prehash = prehash + (characters[i] ^ (n - 1));
             }

             return UniversalHash(prehash, whichHashFunction);
         }
-
     }
-
 }


update

update

--- Demos/NormalMapping/NormalMappingNode.shaders.cs
+++ Demos/NormalMapping/NormalMappingNode.shaders.cs
@@ -186,14 +186,6 @@
     vec3 Normal = CalcBumpedNormal();
     vec4 TotalLight = CalcDirectionalLight(Normal);

-    for (int i = 0 ; i < gNumPointLights ; i++) {
-        TotalLight += CalcPointLight(gPointLights[i], Normal, LightSpacePos);
-    }
-
-    for (int i = 0 ; i < gNumSpotLights ; i++) {
-        TotalLight += CalcSpotLight(gSpotLights[i], Normal, LightSpacePos);
-    }
-
     vec4 SampledColor = texture2D(gColorMap, TexCoord0.xy);
     FragColor = SampledColor * TotalLight;
 }


found a bug, insert comment!

found a bug, insert comment!

--- Inscribe/Filter/Filters/Particular/FilterConversation.cs
+++ Inscribe/Filter/Filters/Particular/FilterConversation.cs
@@ -56,6 +56,8 @@
                     !status.User.ScreenName.Equals(user2, StringComparison.CurrentCultureIgnoreCase))
                     return false;

+                // ここおかしい, @が入る
+                // あとユーザー名マッチングを使えるように
                 if (RegularExpressions.AtRegex.Matches(status.Text).Cast<Match>()
                     .Any(m => m.Value.Equals(user1, StringComparison.CurrentCultureIgnoreCase) ||
                         m.Value.Equals(user2, StringComparison.CurrentCultureIgnoreCase)))


remove no effect throw.

remove no effect throw.

--- Jasily.Frameworks.Cli.Standard/Commands/CommandRouter.cs
+++ Jasily.Frameworks.Cli.Standard/Commands/CommandRouter.cs
@@ -72,8 +72,8 @@
                     return session.UnknownCommand<ICommand>();
                 }
             }
+
             session.DrawUsage();
-            session.Termination();
             return null;
         }
     }


Added ToString in order to make the debugger a little easier to use

--- LINQToTTree/LINQToTTreeLib/Statements/StatementAssign.cs
+++ LINQToTTree/LINQToTTreeLib/Statements/StatementAssign.cs
@@ -36,5 +36,10 @@
             if (result != setTo)
                 yield return result + "=" + setTo + ";";
         }
+
+        public override string ToString()
+        {
+            return ResultVariable.RawValue + "=" + Expression.RawValue;
+        }
     }
 }


Support custom properties in custom placement attributes

--- Source/Orleankka.Runtime/Core/ActorTypeDeclaration.cs
+++ Source/Orleankka.Runtime/Core/ActorTypeDeclaration.cs
@@ -214,8 +214,50 @@
                 case PreferLocalPlacementAttribute local: return typeof(PreferLocalPlacementAttribute).Name;
                 case ActivationCountBasedPlacementAttribute count: return typeof(ActivationCountBasedPlacementAttribute).Name;
                 case HashBasedPlacementAttribute hash: return typeof(HashBasedPlacementAttribute).Name;
-                default: return placement.GetType().FullName;
-            }
+                default: return GenerateCustomPlacement(placement);
+            }
+        }
+
+        static string GenerateCustomPlacement(PlacementAttribute placement)
+        {
+            var properties = placement.GetType()
+                .GetProperties(BindingFlags.Instance | BindingFlags.Public | BindingFlags.DeclaredOnly)
+                .Where(x => x.CanRead);
+
+            var setters = properties.Select(x => new {Property = x, Setter = GenerateAttributePropertySetter(x, placement)})
+                .Where(x => x.Setter != null)
+                .Select(x => $"{char.ToLowerInvariant(x.Property.Name[0]) + x.Property.Name.Substring(1)}:{x.Setter}")
+                .ToList();
+
+            return "global:" + placement.GetType().FullName + $"({string.Join(",", setters)})";
+        }
+
+        static string GenerateAttributePropertySetter(PropertyInfo p, object obj)
+        {
+            if (p.PropertyType == typeof(Type))
+                return $"typeof(global::{p.GetValue(obj)})";
+
+            if (p.PropertyType.IsEnum)
+                return $"global::{p.PropertyType.FullName}.{p.GetValue(obj)}";
+
+            if (p.PropertyType == typeof(string))
+                return $"\"{p.GetValue(obj)}\"";
+
+            if (p.PropertyType == typeof(bool))
+                return $"{p.GetValue(obj).ToString().ToLower()}";
+
+            if (p.PropertyType == typeof(short) ||
+                p.PropertyType == typeof(int) ||
+                p.PropertyType == typeof(long))
+                return $"{p.GetValue(obj)}";
+
+            if (p.PropertyType == typeof(double))
+                return $"{p.GetValue(obj)}d";
+
+            if (p.PropertyType == typeof(float))
+                return $"{p.GetValue(obj)}f";
+
+            return null;
         }

         bool IsStateful() => typeof(IStatefulActor).IsAssignableFrom(actor);


PropertyDefinitions need to be cleared (when not, adding a new dataTable as ItemsSource will not create new columns)

--- Source/PropertyTools.Wpf/DataGrid/DataGrid.Content.cs
+++ Source/PropertyTools.Wpf/DataGrid/DataGrid.Content.cs
@@ -36,6 +36,8 @@
             this.columnGrid.ColumnDefinitions.Clear();
             this.columnGrid.Children.Clear();
             this.columnHeaderMap.Clear();
+
+            this.propertyDefinitions.Clear();

             this.sheetGrid.RowDefinitions.Clear();
             this.sheetGrid.ColumnDefinitions.Clear();


[Toolkit.Graphics] Fix issue #335. Using StructLayout.Explicit with fixed size and field offset was generating a wrong code (seems a bug in JIT), leading to a crash in EffectPass.Apply(). Change Explicit layout to sequential and remove field offset fixed this.

--- Source/Toolkit/SharpDX.Toolkit.Graphics/EffectPass.cs
+++ Source/Toolkit/SharpDX.Toolkit.Graphics/EffectPass.cs
@@ -863,24 +863,31 @@

         #region Nested type: SlotLink

-        [StructLayout(LayoutKind.Explicit, Size = 16)]
+        // The CLR seems to have a bug when using an explicit layout and adding this object
+        // to a list. The object is not correctly copied!
+        [StructLayout(LayoutKind.Sequential)]
         private struct SlotLink
         {
             public SlotLink(int globalIndex, int slotIndex, int slotCount)
             {
-                Pointer = IntPtr.Zero;
-                GlobalIndex = globalIndex;
+                Pointer = new IntPtr(globalIndex);
                 SlotIndex = slotIndex;
                 SlotCount = slotCount;
             }

-            [FieldOffset(0)] public IntPtr Pointer;
-
-            [FieldOffset(0)] public int GlobalIndex;
-
-            [FieldOffset(8)] public int SlotIndex;
-
-            [FieldOffset(12)] public int SlotCount;
+            public IntPtr Pointer;
+
+            public int SlotIndex;
+
+            public int SlotCount;
+
+            public int GlobalIndex
+            {
+                get
+                {
+                    return Pointer.ToInt32();
+                }
+            }
         }

         #endregion


Tune colors

Tune colors

--- MatterControlLib/ApplicationView/Themes/AffinityTheme.cs
+++ MatterControlLib/ApplicationView/Themes/AffinityTheme.cs
@@ -90,7 +90,7 @@
 					{
 						Focused = new ThemeConfig.StateColor()
 						{
-							BackgroundColor = new Color("#999"),
+							BackgroundColor = new Color("#ccc"),
 							TextColor = new Color("#222"),
 							BorderColor = new Color("#FF7F00")
 						},
@@ -120,7 +120,7 @@

 					InactiveTabColor = new Color("#404040"),
 					InteractionLayerOverlayColor = new Color(new Color("#373737"), 240),
-					SplitterBackground = new Color("#282828"),
+					SplitterBackground = new Color("#2C2C2C"),
 					TabBodyBackground = new Color("#00000000"),
 					ToolbarButtonBackground = new Color("#00000000"),
 					ThumbnailBackground = new Color("#00000000"),


single test

single test

--- Spa/NakedObjects.Spa.Selenium.Test/tests/HomeTests.cs
+++ Spa/NakedObjects.Spa.Selenium.Test/tests/HomeTests.cs
@@ -285,7 +285,7 @@
     public class MegaHomeTestBase : HomeTestsRoot {
         [TestMethod] //Mega
         public virtual void MegaHomeTest() {
-            WaitForSingleHome();
+            //WaitForSingleHome();
             //ClickOnVariousMenus();
             //OpenAndCloseSubMenus();
             //SelectSuccessiveDialogActionsThenCancel();


Modificación momentanea

Modificación momentanea

--- MuseoCliente/modInvestigaciones/modInvestigacion.xaml.cs
+++ MuseoCliente/modInvestigaciones/modInvestigacion.xaml.cs
@@ -18,7 +18,7 @@
 	/// </summary>
 	public partial class modInvestigacion : UserControl
 	{
-        //Pendiente Editor: Porque es el usuario que ingresa
+        //Pendiente Editor: Porque es el usuario que ingresa -
         Connection.Objects.Pieza piezas = new Connection.Objects.Pieza();
         Connection.Objects.Autor autores = new Connection.Objects.Autor();
         Connection.Objects.Investigacion investigacion = new Connection.Objects.Investigacion();


Refine HtmlViewModel test codes.

Refine HtmlViewModel test codes.

--- Nancy.AttributeRouting.Tests/ViewModels/HtmlViewModel.cs
+++ Nancy.AttributeRouting.Tests/ViewModels/HtmlViewModel.cs
@@ -2,62 +2,42 @@
 {
     public class HtmlViewModel
     {
-        public string Message
-        {
-            get { return "Hello world!"; }
-        }
-
         [Get("/html")]
         [View("view")]
-        public HtmlViewModel GetView()
+        public object GetView()
         {
-            return this;
+            return new { Message = "Hello world!" };
         }

         [ViewPrefix("Inner")]
         public class InnerViewModel
         {
-            public virtual string Message
-            {
-                get { return "Get inner message."; }
-            }
-
             [Get("/html/inner")]
             [View("inner")]
-            public InnerViewModel GetInnerView()
+            public object GetInnerView()
             {
-                return this;
+                return new { Message = "Get inner message." };
             }
         }

         [ViewPrefix("Deeper")]
         public class DeeperViewModel : InnerViewModel
         {
-            public override string Message
-            {
-                get { return "Get deeper message."; }
-            }
-
             [Get("/html/deeper")]
             [View("deeper")]
-            public DeeperViewModel GetDeeperView()
+            public object GetDeeperView()
             {
-                return this;
+                return new { Message = "Get deeper message." };
             }
         }

         public class InheritPrefixViewModel : InnerViewModel
         {
-            public override string Message
-            {
-                get { return "Inherit prefix message."; }
-            }
-
             [Get("/html/inner/inherit")]
             [View("inherit")]
-            public InheritPrefixViewModel GetView()
+            public object GetView()
             {
-                return this;
+                return new { Message = "Inherit prefix message." };
             }
         }
     }


JustMock fails to raise internal events

JustMock fails to raise internal events

o fixed issue

--- Telerik.JustMock/Core/Behaviors/EventStubsBehavior.cs
+++ Telerik.JustMock/Core/Behaviors/EventStubsBehavior.cs
@@ -52,9 +52,9 @@
 				return;

 			invocation.UserProvidedImplementation = true;
+			var delg = (Delegate)invocation.Args[0];

-			var delg = (Delegate)invocation.Args[0];
-			if (candidateEvent.GetAddMethod() == invocation.Method)
+			if (candidateEvent.GetAddMethod(true) == invocation.Method)
 				this.AddEventHandler(candidateEvent, delg);
 			else
 				this.RemoveEventHandler(candidateEvent, delg);


Commented some backend request method in the ExampleBackend.cs

--- Unity/Assets/Scripts/BackendManager/ExampleBackend.cs
+++ Unity/Assets/Scripts/BackendManager/ExampleBackend.cs
@@ -129,6 +129,10 @@
         }
     }

+    /// <summary>
+    /// Does a GET request at the server, getting you all the savegames of the giving samegame type. On success, the OnGamesLoaded delegate will be called. On fail, the OnGamesLoadedFailed will be called.
+    /// </summary>
+    /// <param name="savegameTypeName">The name of the savegame type you wish to get. Example: JeuDeBouleData</param>
     public void LoadGames(string savegameTypeName) {
         WWWForm form = new WWWForm();
         form.AddField("SavegameType", savegameTypeName);
@@ -148,6 +152,9 @@
         }
     }

+    /// <summary>
+    /// Does a GET request at the backend, getting you all scores. When succesfull, the OnScoresLoaded delegate will be called. When failing, the OnScoresLoadedFailed delegate will be called.
+    /// </summary>
     public void GetAllScores() {
         Send(RequestType.Get, "score", null, OnGetAllScoresResponse, authenticationToken);
     }
@@ -164,6 +171,10 @@
         }
     }

+    /// <summary>
+    /// Does a POST request to the backend, containing the score of the player.
+    /// </summary>
+    /// <param name="score"></param>
     public void PostScore(int score) {
         WWWForm form = new WWWForm();
         form.AddField("score", score);


Support mouse wheel zooming

Support mouse wheel zooming

--- R3/R3.Core/Control/Mouse.cs
+++ R3/R3.Core/Control/Mouse.cs
@@ -73,6 +73,7 @@
 			m_drawSurface.MouseDown += new MouseEventHandler( this.MouseDown );
 			m_drawSurface.MouseMove += new MouseEventHandler( this.MouseMove );
 			m_drawSurface.MouseUp += new MouseEventHandler( this.MouseUp );
+			m_drawSurface.MouseWheel += new MouseEventHandler( MouseWheel );
 		}

 		public void SetClickHandler( Action<ClickData> clickHandler )
@@ -140,6 +141,22 @@
 		}

 		private readonly Stopwatch m_stopWatch = new Stopwatch();
+
+		private void MouseWheel( object sender, MouseEventArgs e )
+		{
+			int amount = e.Delta * SystemInformation.MouseWheelScrollLines / 120;
+			int numberOfPixelsToMove = amount;
+			if( numberOfPixelsToMove == 0 )
+				return;
+
+			if( m_dragHandler == null )
+				return;
+
+			DragData dragData = new DragData();
+			dragData.YPercent = (float)(numberOfPixelsToMove) / (float)m_drawSurface.Height;
+			dragData.Button = MouseButtons.Right;
+			m_dragHandler( dragData );
+		}

 		private void MouseUp( Object sender, MouseEventArgs e )
 		{


escape brackets

escape brackets

--- OBeautifulCode.AutoFakeItEasy/Properties/AssemblyInfo.cs
+++ OBeautifulCode.AutoFakeItEasy/Properties/AssemblyInfo.cs
@@ -12,7 +12,7 @@
 // set of attributes. Change these attribute values to modify the information
 // associated with an assembly.
 [assembly: AssemblyTitle("OBeautifulCode.AutoFakeItEasy")]
-[assembly: AssemblyDescription("Use AutoFixture to fulfill calls to FakeItEasy's A.Dummy<T>().  Makes FakeItEasy dummies actually useable.  Leverages the power of AutoFixture to create anonymous variables.  Fixes some of AutoFixture's poor default behaviors.  Makes unit tests more expressive with less lines of code.")]
+[assembly: AssemblyDescription("Use AutoFixture to fulfill calls to FakeItEasy's A.Dummy<T>().  Makes FakeItEasy dummies actually useable.  Leverages the power of AutoFixture to create anonymous variables.  Fixes some of AutoFixture's poor default behaviors.  Makes unit tests more expressive with less lines of code.")]
 [assembly: AssemblyConfiguration("")]
 [assembly: AssemblyCompany("OBeautifulCode")]
 [assembly: AssemblyProduct("OBeautifulCode.AutoFakeItEasy")]


update

update

--- OpenGLviaCSharp/c02d04_CubeMapTexture/shaders.4.final.cs
+++ OpenGLviaCSharp/c02d04_CubeMapTexture/shaders.4.final.cs
@@ -35,7 +35,7 @@
     //by multiplying the colour alpha with the background colour and adding the
     //product to the given colour uniform
     if (useBackground) {
-        outColor = color + backgroundColor*color.a;
+        outColor = color + backgroundColor * color.a;
     }
     else {
         outColor = color;


艦隊：デッキビルダーへのコピー時に索敵式がずれるのを修正

艦隊：デッキビルダーへのコピー時に索敵式がずれるのを修正

--- ElectronicObserver/Window/FormFleet.cs
+++ ElectronicObserver/Window/FormFleet.cs
@@ -169,7 +169,7 @@
 					double probStart = fleet.GetContactProbability();
 					var probSelect = fleet.GetContactSelectionProbability();

-					sb.AppendFormat("(旧)2-5式: {0}\r\n2-5式(秋): {1}\r\n2-5新秋簡易式: {2}\r\n判定式(33): {3}\r\n\r\n触接開始率: \r\n　確保 {4:p1} / 優勢 {5:p1}\r\n",
+					sb.AppendFormat( "(旧)2-5式: {0}\r\n2-5式(秋): {1}\r\n2-5新秋簡易式: {2}\r\n判定式(33): {3}\r\n\r\n触接開始率: \r\n　確保 {4:p1} / 優勢 {5:p1}\r\n",
 						fleet.GetSearchingAbilityString( 0 ),
 						fleet.GetSearchingAbilityString( 1 ),
 						fleet.GetSearchingAbilityString( 2 ),
@@ -844,7 +844,9 @@
 					int eqcount = 1;
 					foreach ( var eq in ship.SlotInstance ) {
 						if ( eq == null ) break;
-						sb.AppendFormat( @"""i{0}"":{{""id"":{1},""rf"":{2}}},", eqcount, eq.EquipmentID, Math.Max( eq.Level, eq.AircraftLevel ) );
+
+						// 水偵は改修レベル優先(熟練度にすると改修レベルに誤解されて 33式 の結果がずれるため)
+						sb.AppendFormat( @"""i{0}"":{{""id"":{1},""rf"":{2}}},", eqcount, eq.EquipmentID, eq.MasterEquipment.CategoryType == 10 ? eq.Level : Math.Max( eq.Level, eq.AircraftLevel ) );

 						eqcount++;
 					}


Remove TODO comment.

Remove TODO comment.

--- PaletteInsightAgent/Configuration/ConfigurationLoader.cs
+++ PaletteInsightAgent/Configuration/ConfigurationLoader.cs
@@ -349,7 +349,6 @@
                     && workgroup.Connection.Host != null;
             }

-            // TODO: If we can't get everything from ymls, fallback to our config
             private static Workgroup GetRepoFromWorkgroupYaml(string tableauRoot)
             {
                 // Get basic info from workgroup yml. Everything else from connections.yml


Fix error handling in FileSystemDataFeed

Exceptions thrown in the data feed were not reported as Runtime errors

--- Engine/DataFeeds/FileSystemDataFeed.cs
+++ Engine/DataFeeds/FileSystemDataFeed.cs
@@ -471,7 +471,12 @@
                 catch (Exception err)
                 {
                     Log.Error(err);
-                    continue;
+
+                    // notify the algorithm about the error, so it can be reported to the user
+                    _algorithm.RunTimeError = err;
+                    _algorithm.Status = AlgorithmStatus.RuntimeError;
+
+                    break;
                 }

                 // syncer returns MaxValue on failure/end of data


Disconnect only if connected (actions)

Disconnect only if connected (actions)

--- EOLib/Net/Connection/NetworkConnectionActions.cs
+++ EOLib/Net/Connection/NetworkConnectionActions.cs
@@ -65,7 +65,8 @@

 		public void DisconnectFromServer()
 		{
-			Client.Disconnect();
+			if (Client.Connected)
+				Client.Disconnect();
 		}

 		public async Task<IInitializationData> BeginHandshake()


Connect the artwork property immediately to its source

--- Espera/Espera.View/ViewModels/ArtistViewModel.cs
+++ Espera/Espera.View/ViewModels/ArtistViewModel.cs
@@ -41,6 +41,7 @@
                 .Concat()
                 .FirstOrDefaultAsync(pic => pic != null)
                 .ToProperty(this, x => x.Cover);
+            var connect = this.Cover; // Connect the property to the source observable immediately

             this.UpdateArtwork(artworkKeys);


explicate class statements

explicate class statements

--- FG5eXmlToPdf.Console/Program.cs
+++ FG5eXmlToPdf.Console/Program.cs
@@ -6,9 +6,9 @@

 namespace FG5eXmlToPdf.Console
 {
-    class Program
+    internal class Program
     {
-        static void Main(string[] args)
+        private static void Main(string[] args)
         {
         }
     }


minor property identifier bugfix

minor property identifier bugfix

--- Fallen-8/Model/AGraphElement.cs
+++ Fallen-8/Model/AGraphElement.cs
@@ -141,7 +141,7 @@
         /// <param name="result">Result.</param>
         /// <param name="propertyId">Property identifier.</param>
         /// <returns><c>true</c> if something was found; otherwise, <c>false</c>.</returns>
-        public Boolean TryGetProperty<TProperty>(out TProperty result, Int32 propertyId)
+        public Boolean TryGetProperty<TProperty>(out TProperty result, UInt16 propertyId)
         {
             if (ReadResource())
             {


Updated order repository tests

Updated order repository tests

--- Purchasing.Tests/RepositoryTests/OrderRepositoryTests.cs
+++ Purchasing.Tests/RepositoryTests/OrderRepositoryTests.cs
@@ -7790,6 +7790,322 @@
         }
         #endregion ApUser Tests

+        #region PostStatus Tests
+        #region Invalid Tests
+
+        /// <summary>
+        /// Tests the PostStatus with too long value does not save.
+        /// </summary>
+        [TestMethod]
+        [ExpectedException(typeof(ApplicationException))]
+        public void TestPostStatusWithTooLongValueDoesNotSave()
+        {
+            Order order = null;
+            try
+            {
+                #region Arrange
+                order = GetValid(9);
+                order.PostStatus = "x".RepeatTimes((50 + 1));
+                #endregion Arrange
+
+                #region Act
+                OrderRepository.DbContext.BeginTransaction();
+                OrderRepository.EnsurePersistent(order);
+                OrderRepository.DbContext.CommitTransaction();
+                #endregion Act
+            }
+            catch (Exception)
+            {
+                Assert.IsNotNull(order);
+                Assert.AreEqual(50 + 1, order.PostStatus.Length);
+                var results = order.ValidationResults().AsMessageList();
+                results.AssertErrorsAre(string.Format("The field {0} must be a string with a maximum length of {1}.", "PostStatus", "50"));
+                Assert.IsTrue(order.IsTransient());
+                Assert.IsFalse(order.IsValid());
+                throw;
+            }
+        }
+        #endregion Invalid Tests
+
+        #region Valid Tests
+
+        /// <summary>
+        /// Tests the PostStatus with null value saves.
+        /// </summary>
+        [TestMethod]
+        public void TestPostStatusWithNullValueSaves()
+        {
+            #region Arrange
+            var order = GetValid(9);
+            order.PostStatus = null;
+            #endregion Arrange
+
+            #region Act
+            OrderRepository.DbContext.BeginTransaction();
+            OrderRepository.EnsurePersistent(order);
+            OrderRepository.DbContext.CommitTransaction();
+            #endregion Act
+
+            #region Assert
+            Assert.IsFalse(order.IsTransient());
+            Assert.IsTrue(order.IsValid());
+            #endregion Assert
+        }
+
+        /// <summary>
+        /// Tests the PostStatus with empty string saves.
+        /// </summary>
+        [TestMethod]
+        public void TestPostStatusWithEmptyStringSaves()
+        {
+            #region Arrange
+            var order = GetValid(9);
+            order.PostStatus = string.Empty;
+            #endregion Arrange
+
+            #region Act
+            OrderRepository.DbContext.BeginTransaction();
+            OrderRepository.EnsurePersistent(order);
+            OrderRepository.DbContext.CommitTransaction();
+            #endregion Act
+
+            #region Assert
+            Assert.IsFalse(order.IsTransient());
+            Assert.IsTrue(order.IsValid());
+            #endregion Assert
+        }
+
+        /// <summary>
+        /// Tests the PostStatus with one space saves.
+        /// </summary>
+        [TestMethod]
+        public void TestPostStatusWithOneSpaceSaves()
+        {
+            #region Arrange
+            var order = GetValid(9);
+            order.PostStatus = " ";
+            #endregion Arrange
+
+            #region Act
+            OrderRepository.DbContext.BeginTransaction();
+            OrderRepository.EnsurePersistent(order);
+            OrderRepository.DbContext.CommitTransaction();
+            #endregion Act
+
+            #region Assert
+            Assert.IsFalse(order.IsTransient());
+            Assert.IsTrue(order.IsValid());
+            #endregion Assert
+        }
+
+        /// <summary>
+        /// Tests the PostStatus with one character saves.
+        /// </summary>
+        [TestMethod]
+        public void TestPostStatusWithOneCharacterSaves()
+        {
+            #region Arrange
+            var order = GetValid(9);
+            order.PostStatus = "x";
+            #endregion Arrange
+
+            #region Act
+            OrderRepository.DbContext.BeginTransaction();
+            OrderRepository.EnsurePersistent(order);
+            OrderRepository.DbContext.CommitTransaction();
+            #endregion Act
+
+            #region Assert
+            Assert.IsFalse(order.IsTransient());
+            Assert.IsTrue(order.IsValid());
+            #endregion Assert
+        }
+
+        /// <summary>
+        /// Tests the PostStatus with long value saves.
+        /// </summary>
+        [TestMethod]
+        public void TestPostStatusWithLongValueSaves()
+        {
+            #region Arrange
+            var order = GetValid(9);
+            order.PostStatus = "x".RepeatTimes(50);
+            #endregion Arrange
+
+            #region Act
+            OrderRepository.DbContext.BeginTransaction();
+            OrderRepository.EnsurePersistent(order);
+            OrderRepository.DbContext.CommitTransaction();
+            #endregion Act
+
+            #region Assert
+            Assert.AreEqual(50, order.PostStatus.Length);
+            Assert.IsFalse(order.IsTransient());
+            Assert.IsTrue(order.IsValid());
+            #endregion Assert
+        }
+
+        #endregion Valid Tests
+        #endregion PostStatus Tests
+
+        #region OrderNote Tests
+        #region Invalid Tests
+
+        /// <summary>
+        /// Tests the OrderNote with too long value does not save.
+        /// </summary>
+        [TestMethod]
+        [ExpectedException(typeof(ApplicationException))]
+        public void TestOrderNoteWithTooLongValueDoesNotSave()
+        {
+            Order order = null;
+            try
+            {
+                #region Arrange
+                order = GetValid(9);
+                order.OrderNote = "x".RepeatTimes((140 + 1));
+                #endregion Arrange
+
+                #region Act
+                OrderRepository.DbContext.BeginTransaction();
+                OrderRepository.EnsurePersistent(order);
+                OrderRepository.DbContext.CommitTransaction();
+                #endregion Act
+            }
+            catch (Exception)
+            {
+                Assert.IsNotNull(order);
+                Assert.AreEqual(140 + 1, order.OrderNote.Length);
+                var results = order.ValidationResults().AsMessageList();
+                results.AssertErrorsAre(string.Format("The field {0} must be a string with a maximum length of {1}.", "OrderNote", "140"));
+                Assert.IsTrue(order.IsTransient());
+                Assert.IsFalse(order.IsValid());
+                throw;
+            }
+        }
+        #endregion Invalid Tests
+
+        #region Valid Tests
+
+        /// <summary>
+        /// Tests the OrderNote with null value saves.
+        /// </summary>
+        [TestMethod]
+        public void TestOrderNoteWithNullValueSaves()
+        {
+            #region Arrange
+            var order = GetValid(9);
+            order.OrderNote = null;
+            #endregion Arrange
+
+            #region Act
+            OrderRepository.DbContext.BeginTransaction();
+            OrderRepository.EnsurePersistent(order);
+            OrderRepository.DbContext.CommitTransaction();
+            #endregion Act
+
+            #region Assert
+            Assert.IsFalse(order.IsTransient());
+            Assert.IsTrue(order.IsValid());
+            #endregion Assert
+        }
+
+        /// <summary>
+        /// Tests the OrderNote with empty string saves.
+        /// </summary>
+        [TestMethod]
+        public void TestOrderNoteWithEmptyStringSaves()
+        {
+            #region Arrange
+            var order = GetValid(9);
+            order.OrderNote = string.Empty;
+            #endregion Arrange
+
+            #region Act
+            OrderRepository.DbContext.BeginTransaction();
+            OrderRepository.EnsurePersistent(order);
+            OrderRepository.DbContext.CommitTransaction();
+            #endregion Act
+
+            #region Assert
+            Assert.IsFalse(order.IsTransient());
+            Assert.IsTrue(order.IsValid());
+            #endregion Assert
+        }
+
+        /// <summary>
+        /// Tests the OrderNote with one space saves.
+        /// </summary>
+        [TestMethod]
+        public void TestOrderNoteWithOneSpaceSaves()
+        {
+            #region Arrange
+            var order = GetValid(9);
+            order.OrderNote = " ";
+            #endregion Arrange
+
+            #region Act
+            OrderRepository.DbContext.BeginTransaction();
+            OrderRepository.EnsurePersistent(order);
+            OrderRepository.DbContext.CommitTransaction();
+            #endregion Act
+
+            #region Assert
+            Assert.IsFalse(order.IsTransient());
+            Assert.IsTrue(order.IsValid());
+            #endregion Assert
+        }
+
+        /// <summary>
+        /// Tests the OrderNote with one character saves.
+        /// </summary>
+        [TestMethod]
+        public void TestOrderNoteWithOneCharacterSaves()
+        {
+            #region Arrange
+            var order = GetValid(9);
+            order.OrderNote = "x";
+            #endregion Arrange
+
+            #region Act
+            OrderRepository.DbContext.BeginTransaction();
+            OrderRepository.EnsurePersistent(order);
+            OrderRepository.DbContext.CommitTransaction();
+            #endregion Act
+
+            #region Assert
+            Assert.IsFalse(order.IsTransient());
+            Assert.IsTrue(order.IsValid());
+            #endregion Assert
+        }
+
+        /// <summary>
+        /// Tests the OrderNote with long value saves.
+        /// </summary>
+        [TestMethod]
+        public void TestOrderNoteWithLongValueSaves()
+        {
+            #region Arrange
+            var order = GetValid(9);
+            order.OrderNote = "x".RepeatTimes(140);
+            #endregion Arrange
+
+            #region Act
+            OrderRepository.DbContext.BeginTransaction();
+            OrderRepository.EnsurePersistent(order);
+            OrderRepository.DbContext.CommitTransaction();
+            #endregion Act
+
+            #region Assert
+            Assert.AreEqual(140, order.OrderNote.Length);
+            Assert.IsFalse(order.IsTransient());
+            Assert.IsTrue(order.IsValid());
+            #endregion Assert
+        }
+
+        #endregion Valid Tests
+        #endregion OrderNote Tests
+

         #region Constructor Tests

@@ -7910,6 +8226,10 @@
             expectedFields.Add(new NameAndType("LineItems", "System.Collections.Generic.IList`1[Purchasing.Core.Domain.LineItem]", new List<string>()));
             expectedFields.Add(new NameAndType("LineItemSummary", "System.String", new List<string>()));
             expectedFields.Add(new NameAndType("OrderComments", "System.Collections.Generic.IList`1[Purchasing.Core.Domain.OrderComment]", new List<string>()));
+            expectedFields.Add(new NameAndType("OrderNote", "System.String", new List<string>
+            {
+                 "[System.ComponentModel.DataAnnotations.StringLengthAttribute((Int32)140)]"
+            }));
             expectedFields.Add(new NameAndType("OrderReceived", "System.Boolean", new List<string>()));
             expectedFields.Add(new NameAndType("OrderTrackings", "System.Collections.Generic.IList`1[Purchasing.Core.Domain.OrderTracking]", new List<string>()));
             expectedFields.Add(new NameAndType("OrderType", "Purchasing.Core.Domain.OrderType", new List<string>
@@ -7922,6 +8242,10 @@
             }));
             expectedFields.Add(new NameAndType("PeoplePendingAction", "System.String", new List<string>()));
             expectedFields.Add(new NameAndType("PoNumber", "System.String", new List<string>
+            {
+                 "[System.ComponentModel.DataAnnotations.StringLengthAttribute((Int32)50)]"
+            }));
+            expectedFields.Add(new NameAndType("PostStatus", "System.String", new List<string>
             {
                  "[System.ComponentModel.DataAnnotations.StringLengthAttribute((Int32)50)]"
             }));


fixes output cache with multi-tenancy

fixes output cache with multi-tenancy

--- Articulate/Controllers/ArticulateTagsController.cs
+++ Articulate/Controllers/ArticulateTagsController.cs
@@ -21,7 +21,7 @@
     /// <remarks>
     /// Cached for one minute
     /// </remarks>
-    [OutputCache(Duration = 60)]
+    [OutputCache(Duration = 60, VaryByHeader = "host")]
     public class ArticulateTagsController : RenderMvcController
     {
         /// <summary>


GestureManager.cs: Fixed class summary to reflect PR change request.

--- Assets/HoloToolkit/Input/Scripts/GestureManager.cs
+++ Assets/HoloToolkit/Input/Scripts/GestureManager.cs
@@ -18,7 +18,8 @@
     /// information about the manipulation gesture via ManipulationOffset and ManipulationHandPosition.
     ///
     /// Editor and Companion App Input can also be used by assigning a keyboard select key and
-    /// using both left and right mouse buttons to select the currently focused object.
+    /// using the right mouse button to select the currently focused object.  Using Gestures with
+    /// mouse is currently not supported.
     /// </remarks>
     [RequireComponent(typeof(GazeManager))]
     public partial class GestureManager : Singleton<GestureManager>


easing function on progress bar fill changed

--- Assets/Scripts/_ChrsUtils/TaskManager/TaskTypes.cs
+++ Assets/Scripts/_ChrsUtils/TaskManager/TaskTypes.cs
@@ -181,7 +181,7 @@

     protected override void OnTick(float t)
     {
-        progressBar.fillAmount = Mathf.Lerp(progressBar.fillAmount, endAmount, EasingEquations.Easing.ExpoEaseIn(t));
+        progressBar.fillAmount = Mathf.Lerp(progressBar.fillAmount, endAmount, EasingEquations.Easing.BackEaseIn(t));
     }
 }


Added Friend.GetAchievementUnlockTime

Added Friend.GetAchievementUnlockTime

--- Facepunch.Steamworks/Structs/Friend.cs
+++ Facepunch.Steamworks/Structs/Friend.cs
@@ -243,5 +243,21 @@
 			return val;
 		}

+		/// <summary>
+		/// Gets a the time this achievement was unlocked.
+		/// </summary>
+		/// <param name="statName">The name of the achievement you want to get</param>
+		/// <returns>The time unlocked. If it wasn't unlocked, or you haven't downloaded the stats yet - will return DateTime.MinValue</returns>
+		public DateTime GetAchievementUnlockTime( string statName )
+		{
+			bool val = false;
+			uint time = 0;
+
+			if ( !SteamUserStats.Internal.GetUserAchievementAndUnlockTime( Id, statName, ref val, ref time ) || !val )
+				return DateTime.MinValue;
+
+			return Epoch.ToDateTime( time );
+		}
+
 	}
 }


convert web.config to lower case

convert web.config to lower case

--- Azure/WebSite/ConnectTheDotsWebSite/Global.asax.cs
+++ Azure/WebSite/ConnectTheDotsWebSite/Global.asax.cs
@@ -126,13 +126,13 @@
         {
             // Read settings for Devices Event Hub
             eventHubDevicesSettings.connectionString = CloudConfigurationManager.GetSetting("Microsoft.ServiceBus.ConnectionStringDevices");
-            eventHubDevicesSettings.name = CloudConfigurationManager.GetSetting("Microsoft.ServiceBus.EventHubDevices");
+            eventHubDevicesSettings.name = CloudConfigurationManager.GetSetting("Microsoft.ServiceBus.EventHubDevices").ToLowerInvariant();
             eventHubDevicesSettings.storageConnectionString = CloudConfigurationManager.GetSetting("Microsoft.Storage.ConnectionString");
             eventHubDevicesSettings.namespaceManager = NamespaceManager.CreateFromConnectionString(CloudConfigurationManager.GetSetting("Microsoft.ServiceBus.ConnectionString"));

             // Read settings for Alerts Event Hub
             eventHubAlertsSettings.connectionString = CloudConfigurationManager.GetSetting("Microsoft.ServiceBus.ConnectionStringAlerts");
-            eventHubAlertsSettings.name = CloudConfigurationManager.GetSetting("Microsoft.ServiceBus.EventHubAlerts");
+				eventHubAlertsSettings.name = CloudConfigurationManager.GetSetting("Microsoft.ServiceBus.EventHubAlerts").ToLowerInvariant();
             eventHubAlertsSettings.storageConnectionString = CloudConfigurationManager.GetSetting("Microsoft.Storage.ConnectionString");
             eventHubAlertsSettings.namespaceManager = NamespaceManager.CreateFromConnectionString(CloudConfigurationManager.GetSetting("Microsoft.ServiceBus.ConnectionString"));


Remove cryptopia from CoinAverage

Remove cryptopia from CoinAverage

--- BTCPayServer/Services/Rates/CoinAverageSettings.cs
+++ BTCPayServer/Services/Rates/CoinAverageSettings.cs
@@ -120,7 +120,6 @@
                 (DisplayName: "Quoine", Name: "quoine"),
                 (DisplayName: "BTC Markets", Name: "btcmarkets"),
                 (DisplayName: "Bitso", Name: "bitso"),
-                (DisplayName: "Cryptopia", Name: "cryptopia"),
                 })
             {
                 AvailableExchanges.TryAdd(item.Name, new CoinAverageExchange(item.Name, item.DisplayName));