quick and dirt bypass of old caching and prioritizer of updates. They now go directly to output queues. This needs cleanup and possible some of old priority rules check (?)

--- OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs
+++ OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs
@@ -3555,24 +3555,263 @@
         /// <summary>
         /// Generate one of the object update packets based on PrimUpdateFlags
         /// and broadcast the packet to clients
-        /// </summary>
-        public void SendPrimUpdate(ISceneEntity entity, PrimUpdateFlags updateFlags)
-        {
+        /// </summary>
+        public void SendPrimUpdate(ISceneEntity entity, PrimUpdateFlags updateFlags)
+            {
+
+            // this needs to be very optimized
+
+            OpenSim.Framework.Lazy<List<ObjectUpdatePacket.ObjectDataBlock>> objectUpdateBlocks = new OpenSim.Framework.Lazy<List<ObjectUpdatePacket.ObjectDataBlock>>();
+            OpenSim.Framework.Lazy<List<ObjectUpdateCompressedPacket.ObjectDataBlock>> compressedUpdateBlocks = new OpenSim.Framework.Lazy<List<ObjectUpdateCompressedPacket.ObjectDataBlock>>();
+            OpenSim.Framework.Lazy<List<ImprovedTerseObjectUpdatePacket.ObjectDataBlock>> terseUpdateBlocks = new OpenSim.Framework.Lazy<List<ImprovedTerseObjectUpdatePacket.ObjectDataBlock>>();
+            OpenSim.Framework.Lazy<List<ObjectUpdateCachedPacket.ObjectDataBlock>> cachedUpdateBlocks = new OpenSim.Framework.Lazy<List<ObjectUpdateCachedPacket.ObjectDataBlock>>();
+
+            if (entity is SceneObjectPart)
+                {
+                SceneObjectPart part = (SceneObjectPart)entity;
+
+                if (part.ParentGroup.IsAttachment && m_disableFacelights)
+                    {
+                    if (part.ParentGroup.RootPart.Shape.State != (byte)AttachmentPoint.LeftHand &&
+                        part.ParentGroup.RootPart.Shape.State != (byte)AttachmentPoint.RightHand)
+                        {
+                        part.Shape.LightEntry = false;
+                        }
+                    }
+                }
+
+            bool canUseCompressed = true;
+            bool canUseImproved = true;
+            bool canUseCached = true;
+
+            // Compressed and cached object updates only make sense for LL primitives
+            if (!(entity is SceneObjectPart))
+                {
+                canUseCompressed = false;
+                canUseCached = false;
+                }
+            if (entity is SceneObjectPart)
+                {
+                // Please do not remove this unless you can demonstrate on the OpenSim mailing list that a client
+                // will never receive an update after a prim kill.  Even then, keeping the kill record may be a good
+                // safety measure.
+                //
+                // If a Linden Lab 1.23.5 client (and possibly later and earlier) receives an object update
+                // after a kill, it will keep displaying the deleted object until relog.  OpenSim currently performs
+                // updates and kills on different threads with different scheduling strategies, hence this protection.
+                //
+                // This doesn't appear to apply to child prims - a client will happily ignore these updates
+                // after the root prim has been deleted.
+                if (m_killRecord.Contains(entity.LocalId))
+                    {
+                    m_log.ErrorFormat(
+                        "[CLIENT]: Preventing update for prim with local id {0} after client for user {1} told it was deleted. Mantis this at http://mantis.aurora-sim.org/bug_report_page.php !",
+                        entity.LocalId, Name);
+                    return;
+                    }
+
+                IObjectCache module = Scene.RequestModuleInterface<IObjectCache>();
+                if (module != null)
+                    {
+                    canUseCached = module.UseCachedObject(AgentId, entity.LocalId, ((SceneObjectPart)entity).CRC);
+                    }
+                else
+                    {
+                    //No cache module? Don't use cached then, or it won't stop sending ObjectUpdateCached even when the client requests prims
+                    canUseCached = false;
+                    }
+                }
+
+            if (updateFlags.HasFlag(PrimUpdateFlags.FullUpdate))
+                {
+                canUseCompressed = false;
+                canUseImproved = false;
+                //If a full update has been requested, DO THE FULL UPDATE.
+                // Don't try to get out of this.... the monster called RepeatObjectUpdateCachedFromTheServer will occur and eat all your prims!
+                canUseCached = false;
+                }
+            else
+                {
+                if (updateFlags.HasFlag(PrimUpdateFlags.Velocity) ||
+                    updateFlags.HasFlag(PrimUpdateFlags.Acceleration) ||
+                    updateFlags.HasFlag(PrimUpdateFlags.CollisionPlane) ||
+                    updateFlags.HasFlag(PrimUpdateFlags.Joint))
+                    {
+                    canUseCompressed = false;
+                    }
+
+                if (updateFlags.HasFlag(PrimUpdateFlags.PrimFlags) ||
+                    updateFlags.HasFlag(PrimUpdateFlags.ParentID) ||
+                    updateFlags.HasFlag(PrimUpdateFlags.AttachmentPoint) ||
+                    updateFlags.HasFlag(PrimUpdateFlags.Shape) ||
+                    updateFlags.HasFlag(PrimUpdateFlags.PrimData) ||
+                    updateFlags.HasFlag(PrimUpdateFlags.Text) ||
+                    updateFlags.HasFlag(PrimUpdateFlags.NameValue) ||
+                    updateFlags.HasFlag(PrimUpdateFlags.ExtraData) ||
+                    updateFlags.HasFlag(PrimUpdateFlags.TextureAnim) ||
+                    updateFlags.HasFlag(PrimUpdateFlags.Sound) ||
+                    updateFlags.HasFlag(PrimUpdateFlags.Particles) ||
+                    updateFlags.HasFlag(PrimUpdateFlags.Material) ||
+                    updateFlags.HasFlag(PrimUpdateFlags.ClickAction) ||
+                    updateFlags.HasFlag(PrimUpdateFlags.MediaURL) ||
+                    updateFlags.HasFlag(PrimUpdateFlags.Joint))
+                    {
+                    canUseImproved = false;
+                    }
+                }
+
+            // UNTODO: Remove this once we can build compressed updates
+            // UPDATE: WE CAN!
+            //canUseCompressed = false;
+
+            // UNTODO: Remove this once we can build cached updates
+            // UPDATE: WE CAN!
+            //canUseCached = false;
+
+            try
+                {
+                //Do NOT send cached updates for terse updates
+                bool isTerse = updateFlags.HasFlag((PrimUpdateFlags.Position | PrimUpdateFlags.Rotation | PrimUpdateFlags.Velocity | PrimUpdateFlags.Acceleration | PrimUpdateFlags.AngularVelocity));
+                //ONLY send full updates for attachments unless you want to figure out all the little screwy things with sending compressed updates and attachments
+                if (entity is SceneObjectPart &&
+                    ((SceneObjectPart)entity).IsAttachment)
+                    {
+                    canUseCached = false;
+                    canUseImproved = false;
+                    canUseCompressed = false;
+                    }
+                if (canUseCached && !isTerse)
+                    {
+                    cachedUpdateBlocks.Value.Add(CreatePrimCachedUpdateBlock((SceneObjectPart)entity, this.m_agentId));
+                    }
+                else if (!canUseImproved && !canUseCompressed)
+                    {
+                    if (entity is ScenePresence)
+                        {
+                        objectUpdateBlocks.Value.Add(CreateAvatarUpdateBlock((ScenePresence)entity));
+                        }
+                    else
+                        {
+                        objectUpdateBlocks.Value.Add(CreatePrimUpdateBlock((SceneObjectPart)entity, this.m_agentId));
+                        }
+                    }
+                else if (!canUseImproved)
+                    {
+                    CompressedFlags Flags = CompressedFlags.None;
+                    if (updateFlags.HasFlag(PrimUpdateFlags.AngularVelocity))
+                        Flags |= CompressedFlags.HasAngularVelocity;
+                    if (updateFlags.HasFlag(PrimUpdateFlags.MediaURL))
+                        Flags |= CompressedFlags.MediaURL;
+                    if (updateFlags.HasFlag(PrimUpdateFlags.ParentID))
+                        Flags |= CompressedFlags.HasParent;
+                    if (updateFlags.HasFlag(PrimUpdateFlags.Particles))
+                        Flags |= CompressedFlags.HasParticles;
+                    if (updateFlags.HasFlag(PrimUpdateFlags.Sound))
+                        Flags |= CompressedFlags.HasSound;
+                    if (updateFlags.HasFlag(PrimUpdateFlags.Text))
+                        Flags |= CompressedFlags.HasText;
+                    if (updateFlags.HasFlag(PrimUpdateFlags.TextureAnim))
+                        Flags |= CompressedFlags.TextureAnimation;
+                    if (updateFlags.HasFlag(PrimUpdateFlags.NameValue) || ((SceneObjectPart)entity).IsAttachment)
+                        Flags |= CompressedFlags.HasNameValues;
+
+                    compressedUpdateBlocks.Value.Add(CreateCompressedUpdateBlock((SceneObjectPart)entity, Flags, updateFlags));
+                    }
+                else
+                    {
+                    terseUpdateBlocks.Value.Add(CreateImprovedTerseBlock(entity, updateFlags.HasFlag(PrimUpdateFlags.Textures)));
+                    }
+                }
+            catch (Exception ex)
+                {
+                m_log.Warn("[LLCLIENTVIEW]: Issue creating an update block " + ex.ToString());
+                return;
+                }
+
+            float TIME_DILATION = m_scene.TimeDilation;
+            ushort timeDilation = Utils.FloatToUInt16(TIME_DILATION, 0.0f, 1.0f);
+
+            if (objectUpdateBlocks.IsValueCreated)
+                {
+                List<ObjectUpdatePacket.ObjectDataBlock> blocks = objectUpdateBlocks.Value;
+
+                ObjectUpdatePacket packet = (ObjectUpdatePacket)PacketPool.Instance.GetPacket(PacketType.ObjectUpdate);
+                packet.RegionData.RegionHandle = m_scene.RegionInfo.RegionHandle;
+                packet.RegionData.TimeDilation = timeDilation;
+                packet.ObjectData = new ObjectUpdatePacket.ObjectDataBlock[blocks.Count];
+
+                for (int i = 0; i < blocks.Count; i++)
+                    packet.ObjectData[i] = blocks[i];
+
+                OutPacket(packet, ThrottleOutPacketType.Task, true);
+                }
+
+            if (compressedUpdateBlocks.IsValueCreated)
+                {
+                List<ObjectUpdateCompressedPacket.ObjectDataBlock> blocks = compressedUpdateBlocks.Value;
+
+                ObjectUpdateCompressedPacket packet = (ObjectUpdateCompressedPacket)PacketPool.Instance.GetPacket(PacketType.ObjectUpdateCompressed);
+                packet.RegionData.RegionHandle = m_scene.RegionInfo.RegionHandle;
+                packet.RegionData.TimeDilation = timeDilation;
+                packet.ObjectData = new ObjectUpdateCompressedPacket.ObjectDataBlock[blocks.Count];
+
+                for (int i = 0; i < blocks.Count; i++)
+                    packet.ObjectData[i] = blocks[i];
+
+                OutPacket(packet, ThrottleOutPacketType.Task, true);
+                }
+
+            if (cachedUpdateBlocks.IsValueCreated)
+                {
+                List<ObjectUpdateCachedPacket.ObjectDataBlock> blocks = cachedUpdateBlocks.Value;
+
+                ObjectUpdateCachedPacket packet = (ObjectUpdateCachedPacket)PacketPool.Instance.GetPacket(PacketType.ObjectUpdateCached);
+                packet.RegionData.RegionHandle = m_scene.RegionInfo.RegionHandle;
+                packet.RegionData.TimeDilation = timeDilation;
+                packet.ObjectData = new ObjectUpdateCachedPacket.ObjectDataBlock[blocks.Count];
+
+                for (int i = 0; i < blocks.Count; i++)
+                    packet.ObjectData[i] = blocks[i];
+
+                OutPacket(packet, ThrottleOutPacketType.Task, true);
+                }
+
+            if (terseUpdateBlocks.IsValueCreated)
+                {
+                List<ImprovedTerseObjectUpdatePacket.ObjectDataBlock> blocks = terseUpdateBlocks.Value;
+
+                ImprovedTerseObjectUpdatePacket packet = new ImprovedTerseObjectUpdatePacket();
+                packet.RegionData.RegionHandle = m_scene.RegionInfo.RegionHandle;
+                packet.RegionData.TimeDilation = timeDilation;
+                packet.ObjectData = new ImprovedTerseObjectUpdatePacket.ObjectDataBlock[blocks.Count];
+
+                for (int i = 0; i < blocks.Count; i++)
+                    packet.ObjectData[i] = blocks[i];
+
+                OutPacket(packet, ThrottleOutPacketType.Task, true);
+                }
+
+
+
+            /*
             double priority = m_prioritizer.GetUpdatePriority(this, entity);
             PriorityQueueItem<EntityUpdate, double> item = new PriorityQueueItem<EntityUpdate,double>();
             item.Priority = priority;
             item.Value = new EntityUpdate(entity, updateFlags);
             lock (m_entityUpdates.SyncRoot)
                 m_entityUpdates.Enqueue(item);
-        }
-
+             */
+            }
         public void SendPrimUpdate(ISceneEntity entity, PrimUpdateFlags updateFlags, double priority)
         {
+            SendPrimUpdate(entity, updateFlags);
+/*
             PriorityQueueItem<EntityUpdate, double> item = new PriorityQueueItem<EntityUpdate, double>();
             item.Priority = priority;
             item.Value = new EntityUpdate(entity, updateFlags);
             lock (m_entityUpdates.SyncRoot)
                 m_entityUpdates.Enqueue(item);
+ */
         }

         private void ProcessEntityUpdates(int maxUpdates)


Add WordListWord object

Add WordListWord object

--- src/Models/WordList.cs
+++ src/Models/WordList.cs
@@ -9,9 +9,7 @@
     {
         [DefaultValue(0)]
         public long Id { get; set; }
-
         public string Permalink { get; set; }
-
         public string Name { get; set; }

         [JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
@@ -25,15 +23,21 @@
         [JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
         [JsonConverter(typeof(IsoDateTimeConverter))]
         public DateTime? LastActivityAt { get; set; }
-
         public string UserName { get; set; }
-
         public long UserId { get; set; }
-
         public string Description { get; set; }
-
         public long NumberWordsInList { get; set; }
-
         public string Type { get; set; }
     }
+
+    public class WordListWord
+    {
+        public long Id { get; set; }
+        public string Word { get; set; }
+        public string Username { get; set; }
+        public long UserId { get; set; }
+        public DateTime CreatedAt { get; set; }
+        public long NumberCommentsOnWord { get; set; }
+        public long NumberLists { get; set; }
+    }
 }


Renamed ReflectionHelper.GetLocation to .GetLocationDirectory

--- src/Kephas.Core/Reflection/ReflectionHelper.cs
+++ src/Kephas.Core/Reflection/ReflectionHelper.cs
@@ -269,39 +269,21 @@
         }

         /// <summary>
-        /// Gets the location for the provided assembly.
+        /// Gets the location directory for the provided assembly.
         /// </summary>
         /// <param name="assembly">The assembly to be checked.</param>
         /// <returns>
-        /// The assembly location.
-        /// </returns>
-        public static string GetLocation(this Assembly assembly)
-        {
-            if (assembly == null)
+        /// The assembly location directory.
+        /// </returns>
+        public static string GetLocationDirectory(this Assembly assembly)
+        {
+            if (assembly == null || string.IsNullOrEmpty(assembly.Location))
             {
                 return null;
             }

-            var location = Path.GetDirectoryName(GetFilePath(assembly));
+            var location = Path.GetDirectoryName(assembly.Location);
             return location;
-        }
-
-        /// <summary>
-        /// Gets the file path to the loaded assembly.
-        /// </summary>
-        /// <param name="assembly">The assembly.</param>
-        /// <returns>
-        /// The file path of the loaded assembly.
-        /// </returns>
-        public static string GetFilePath(this Assembly assembly)
-        {
-            if (assembly == null)
-            {
-                return null;
-            }
-
-            var codebaseUri = new Uri(assembly.CodeBase);
-            return Uri.UnescapeDataString(codebaseUri.AbsolutePath);
         }

         /// <summary>


Bugfix

Bugfix

--- src/core-filesystem/PathHelpers.cs
+++ src/core-filesystem/PathHelpers.cs
@@ -41,11 +41,11 @@
     }

     public static bool HasDirectorySeparators(string path) {
-      return path.IndexOf(Path.DirectorySeparatorChar) < 0;
+      return path.IndexOf(Path.DirectorySeparatorChar) >= 0;
     }

     public static bool HasAltDirectorySeparators(string path) {
-      return path.IndexOf(Path.AltDirectorySeparatorChar) < 0;
+      return path.IndexOf(Path.AltDirectorySeparatorChar) >= 0;
     }

     /// <summary>


C# 7 magic! :sparkles:

C# 7 magic! :sparkles:

--- src/Nzb/NzbDocument.cs
+++ src/Nzb/NzbDocument.cs
@@ -105,8 +105,7 @@

             var metadata = ParseMetadata(nzbElement);

-            long bytes;
-            var files = ParseFiles(nzbElement, out bytes);
+            var files = ParseFiles(nzbElement, out long bytes);

             return new NzbDocument(metadata, files, bytes);
         }
@@ -177,8 +176,7 @@

             var groups = ParseGroups(element);

-            long bytes;
-            var segments = ParseSegments(element, out bytes);
+            var segments = ParseSegments(element, out long bytes);

             return new NzbFile(poster, date, subject, groups, segments, bytes);
         }


added usage of datetime converter on relevant models

--- src/LunoClient/Models/Session/CreateSession.cs
+++ src/LunoClient/Models/Session/CreateSession.cs
@@ -1,4 +1,5 @@
 using System;
+using Luno.Converters;
 using Newtonsoft.Json;

 namespace Luno.Models.Session
@@ -21,6 +22,7 @@
 		public string Key { get; set; }

 		[JsonProperty("expires")]
+		[JsonConverter(typeof(JsonDateTimeConverter))]
 		public DateTime? Expires { get; set; } = DateTime.UtcNow.AddDays(14);

 		[JsonProperty("user_agent")]


Updated CompositeOperator.

Updated CompositeOperator.

--- src/Magick.NET.Core/Enums/CompositeOperator.cs
+++ src/Magick.NET.Core/Enums/CompositeOperator.cs
@@ -376,5 +376,45 @@
         /// Stereo.
         /// </summary>
         Stereo,
+
+        /// <summary>
+        /// Freeze.
+        /// </summary>
+        Freeze,
+
+        /// <summary>
+        /// Interpolate.
+        /// </summary>
+        Interpolate,
+
+        /// <summary>
+        /// Negate.
+        /// </summary>
+        Negate,
+
+        /// <summary>
+        /// Reflect.
+        /// </summary>
+        Reflect,
+
+        /// <summary>
+        /// SoftBurn.
+        /// </summary>
+        SoftBurn,
+
+        /// <summary>
+        /// SoftDodge.
+        /// </summary>
+        SoftDodge,
+
+        /// <summary>
+        /// Stamp.
+        /// </summary>
+        Stamp,
+
+        /// <summary>
+        /// RMSE.
+        /// </summary>
+        RMSE,
     }
 }


Use var instead.

Use var instead.

--- src/Magick.NET/Shared/MagickImageCollection.cs
+++ src/Magick.NET/Shared/MagickImageCollection.cs
@@ -1391,18 +1391,18 @@
         {
             Throw.IfNullOrEmpty(nameof(stream), stream);

-            Bytes bytes = Bytes.FromStreamBuffer(stream);
+            var bytes = Bytes.FromStreamBuffer(stream);
             if (bytes != null)
             {
                 AddImages(bytes.Data, 0, bytes.Length, readSettings, ping);
                 return;
             }

-            MagickSettings settings = CreateSettings(readSettings);
+            var settings = CreateSettings(readSettings);
             settings.Ping = ping;
             settings.FileName = null;

-            using (StreamWrapper wrapper = StreamWrapper.CreateForReading(stream))
+            using (var wrapper = StreamWrapper.CreateForReading(stream))
             {
                 ReadWriteStreamDelegate reader = new ReadWriteStreamDelegate(wrapper.Read);
                 SeekStreamDelegate seeker = null;
@@ -1414,7 +1414,7 @@
                     teller = new TellStreamDelegate(wrapper.Tell);
                 }

-                IntPtr result = _nativeInstance.ReadStream(settings, reader, seeker, teller);
+                var result = _nativeInstance.ReadStream(settings, reader, seeker, teller);
                 AddImages(result, settings);
             }
         }


Fixed the bug reported in issue #505.

Fixed the bug reported in issue #505.

--- src/Magick.NET/Shared/Profiles/EndianReader.cs
+++ src/Magick.NET/Shared/Profiles/EndianReader.cs
@@ -28,7 +28,13 @@

         public uint Index { get; private set; }

-        public bool CanRead(uint length) => Index + length <= _data.Length;
+        public bool CanRead(uint length)
+        {
+            if (length > _data.Length)
+                return false;
+
+            return Index + length <= _data.Length;
+        }

         public bool Seek(uint index)
         {


Remove HTTP client timeout

Remove HTTP client timeout

--- src/MiningCore/DaemonInterface/DaemonClient.cs
+++ src/MiningCore/DaemonInterface/DaemonClient.cs
@@ -99,10 +99,7 @@
                     handler.ServerCertificateCustomValidationCallback = (httpRequestMessage, cert, cetChain, policyErrors) => true;
                 }

-                return new HttpClient(handler)
-                {
-                    Timeout = TimeSpan.FromSeconds(3)
-                };
+                return new HttpClient(handler);
             });
         }


Fix WhereSubqueryTests.CategoriesWithFirstProductIsNotDiscouned for configurations where linq database is generated.

--- src/NHibernate.Test/Linq/WhereSubqueryTests.cs
+++ src/NHibernate.Test/Linq/WhereSubqueryTests.cs
@@ -568,7 +568,7 @@
 		{
 			//NH-3190
 			var result = (from c in db.Categories
-						  where c.Products.Select(p => p.Discontinued).FirstOrDefault() == false
+						  where c.Products.OrderBy(p => p.ProductId).Select(p => p.Discontinued).FirstOrDefault() == false
 						  select c).ToList();

 			Assert.That(result.Count, Is.EqualTo(7));


Full path returned from finding in environment.

--- src/RakeRunner.Library/Services/RakeService.cs
+++ src/RakeRunner.Library/Services/RakeService.cs
@@ -194,8 +194,9 @@
         {
             foreach (string path in (Environment.GetEnvironmentVariable("PATH") ?? "").Split(';'))
             {
-                if (!String.IsNullOrEmpty(path) && File.Exists(Path.Combine(path, file)))
-                    return Path.GetFullPath(path);
+                var combinedPath = "";
+                if (!String.IsNullOrEmpty(path) && File.Exists(combinedPath = Path.Combine(path, file)))
+                    return Path.GetFullPath(combinedPath);
             }
             throw new FileNotFoundException(new FileNotFoundException().Message, file);
         }


Fixes #4

Fixes #4

--- src/RedDog.Search/Model/FunctionAggregation.cs
+++ src/RedDog.Search/Model/FunctionAggregation.cs
@@ -5,7 +5,7 @@
         Sum,
         Average,
         Minimum,
-        Maxium,
+        Maximum,
         FirstMatching
     }
 }


undo change

undo change

--- src/Serialize.Linq/Internals/ValueConverter.cs
+++ src/Serialize.Linq/Internals/ValueConverter.cs
@@ -146,7 +146,7 @@
                 // TODO: think about a better way; exception could may have an critical impact on performance
                 try
                 {
-                    return Convert(value, convertTo);
+                    return System.Convert.ChangeType(value, convertTo);
                 }
                 catch (Exception)
                 {


Address PR feedback

Address PR feedback

--- src/System.Drawing.Common/tests/RegionTests.cs
+++ src/System.Drawing.Common/tests/RegionTests.cs
@@ -32,7 +32,7 @@
 {
     public class RegionTests
     {
-        private static Graphics s_graphic = Graphics.FromImage(new Bitmap(1, 1));
+        private static readonly Graphics s_graphic = Graphics.FromImage(new Bitmap(1, 1));

         [ConditionalFact(nameof(PlatformDetection) + "." + nameof(PlatformDetection.IsNotWindowsNanoServer))]
         public void Ctor_Default()
@@ -111,7 +111,8 @@
         public void Ctor_EmptyGraphicsPath_ThrowsExternalException()
         {
             var region = new Region(new GraphicsPath());
-            Assert.Throws<ExternalException>(() => new Region(region.GetRegionData()));
+            RegionData regionData = region.GetRegionData();
+            Assert.Throws<ExternalException>(() => new Region(regionData));
         }

         [ConditionalFact(nameof(PlatformDetection) + "." + nameof(PlatformDetection.IsNotWindowsNanoServer))]
@@ -125,11 +126,11 @@
         [ConditionalFact(nameof(PlatformDetection) + "." + nameof(PlatformDetection.IsNotWindowsNanoServer))]
         public void Ctor_GraphicsPath()
         {
-            var graphics = new GraphicsPath();
-            graphics.AddRectangle(new Rectangle(1, 2, 3, 4));
-            graphics.AddRectangle(new Rectangle(4, 5, 6, 7));
-
-            var region = new Region(graphics);
+            var graphicsPath = new GraphicsPath();
+            graphicsPath.AddRectangle(new Rectangle(1, 2, 3, 4));
+            graphicsPath.AddRectangle(new Rectangle(4, 5, 6, 7));
+
+            var region = new Region(graphicsPath);
             Assert.Equal(new RectangleF[]
             {
                 new RectangleF(1, 2, 3, 3),


Add voice option to ui test

Add voice option to ui test

--- PalasoUIWindowsForms.Tests/WritingSystems/UITests.cs
+++ PalasoUIWindowsForms.Tests/WritingSystems/UITests.cs
@@ -8,6 +8,7 @@
 using NUnit.Framework;
 using Palaso.TestUtilities;
 using Palaso.UI.WindowsForms.WritingSystems;
+using Palaso.UI.WindowsForms.WritingSystems.WSTree;
 using Palaso.WritingSystems;

 namespace PalasoUIWindowsForms.Tests.WritingSystems
@@ -21,7 +22,9 @@
 		{
 			using (var folder = new TemporaryFolder("WS-Test"))
 			{
-				new WritingSystemSetupDialog(folder.Path).ShowDialog();
+				var dlg = new WritingSystemSetupDialog(folder.Path);
+				dlg.WritingSystemSuggestor.SuggestVoice = true;
+				dlg.ShowDialog();
 			}
 		}


Now anyone can spend 4+ hours running this

--- PixVoxelAssets/PixVoxelAssets/OrthoVoxelsAdjusted.cs
+++ PixVoxelAssets/PixVoxelAssets/OrthoVoxelsAdjusted.cs
@@ -8342,51 +8342,74 @@
             //processUnitOutlinedWDouble("Lord");
             //processUnitOutlinedWDouble("Guard");

+            processUnitOutlinedPartial("Infantry");
+            TallVoxels.processUnitOutlinedPartial("Infantry");
+            processEightWayAnimation("Infantry");
+            processUnitOutlinedPartial("Infantry_P");
+            TallVoxels.processUnitOutlinedPartial("Infantry_P");
+            processEightWayAnimation("Infantry_P");
+            processUnitOutlinedPartial("Infantry_S");
+            TallVoxels.processUnitOutlinedPartial("Infantry_S");
+            processEightWayAnimation("Infantry_S");
+            processUnitOutlinedPartial("Infantry_T");
+            TallVoxels.processUnitOutlinedPartial("Infantry_T");
+            processEightWayAnimation("Infantry_T");
+            processUnitOutlinedPartial("Tank");
+            TallVoxels.processUnitOutlinedPartial("Tank");
+            processEightWayAnimation("Tank");
+            processUnitOutlinedPartial("Tank_P");
+            TallVoxels.processUnitOutlinedPartial("Tank_P");
+            processEightWayAnimation("Tank_P");
+            processUnitOutlinedPartial("Tank_S");
+            TallVoxels.processUnitOutlinedPartial("Tank_S");
+            processEightWayAnimation("Tank_S");
+            processUnitOutlinedPartial("Tank_T");
+            TallVoxels.processUnitOutlinedPartial("Tank_T");
+            processEightWayAnimation("Tank_T");
+            processUnitOutlinedPartial("Artillery");
+            TallVoxels.processUnitOutlinedPartial("Artillery");
+            processEightWayAnimation("Artillery");
+            processUnitOutlinedPartial("Artillery_P");
+            TallVoxels.processUnitOutlinedPartial("Artillery_P");
+            processEightWayAnimation("Artillery_P");
+            processUnitOutlinedPartial("Artillery_S");
+            TallVoxels.processUnitOutlinedPartial("Artillery_S");
+            processEightWayAnimation("Artillery_S");
+            processUnitOutlinedPartial("Artillery_T");
+            TallVoxels.processUnitOutlinedPartial("Artillery_T");
+            processEightWayAnimation("Artillery_T");
+            processUnitOutlinedPartial("Supply");
+            TallVoxels.processUnitOutlinedPartial("Supply");
+            processEightWayAnimation("Supply");
+            processUnitOutlinedPartial("Supply_P");
+            TallVoxels.processUnitOutlinedPartial("Supply_P");
+            processEightWayAnimation("Supply_P");
+            processUnitOutlinedPartial("Supply_S");
+            TallVoxels.processUnitOutlinedPartial("Supply_S");
+            processEightWayAnimation("Supply_S");
+            processUnitOutlinedPartial("Supply_T");
+            TallVoxels.processUnitOutlinedPartial("Supply_T");
+            processEightWayAnimation("Supply_T");
+            processUnitOutlinedPartial("Copter");
+            TallVoxels.processUnitOutlinedPartial("Copter");
+            processEightWayAnimation("Copter");
             processUnitOutlinedPartial("Copter_P");
+            TallVoxels.processUnitOutlinedPartial("Copter_P");
             processEightWayAnimation("Copter_P");
             processUnitOutlinedPartial("Copter_S");
+            TallVoxels.processUnitOutlinedPartial("Copter_S");
             processEightWayAnimation("Copter_S");
             processUnitOutlinedPartial("Copter_T");
+            TallVoxels.processUnitOutlinedPartial("Copter_T");
             processEightWayAnimation("Copter_T");
-            processUnitOutlinedPartial("Copter");
-            processEightWayAnimation("Copter");
-            processUnitOutlinedPartial("Infantry");
-            processEightWayAnimation("Infantry");
-            processUnitOutlinedPartial("Infantry_P");
-            processEightWayAnimation("Infantry_P");
-            processUnitOutlinedPartial("Infantry_S");
-            processEightWayAnimation("Infantry_S");
-            processUnitOutlinedPartial("Infantry_T");
-            processEightWayAnimation("Infantry_T");
-            processUnitOutlinedPartial("Tank");
-            processEightWayAnimation("Tank");
-            processUnitOutlinedPartial("Tank_P");
-            processEightWayAnimation("Tank_P");
-            processUnitOutlinedPartial("Tank_S");
-            processEightWayAnimation("Tank_S");
-            processUnitOutlinedPartial("Tank_T");
-            processEightWayAnimation("Tank_T");
-            processUnitOutlinedPartial("Artillery");
-            processEightWayAnimation("Artillery");
-            processUnitOutlinedPartial("Artillery_P");
-            processEightWayAnimation("Artillery_P");
-            processUnitOutlinedPartial("Artillery_S");
-            processEightWayAnimation("Artillery_S");
-            processUnitOutlinedPartial("Artillery_T");
-            processEightWayAnimation("Artillery_T");
-            processUnitOutlinedPartial("Supply");
-            processEightWayAnimation("Supply");
-            processUnitOutlinedPartial("Supply_P");
-            processEightWayAnimation("Supply_P");
-            processUnitOutlinedPartial("Supply_S");
-            processEightWayAnimation("Supply_S");
-            processUnitOutlinedPartial("Supply_T");
-            processEightWayAnimation("Supply_T");
             processUnitOutlinedPartial("Plane");
+            TallVoxels.processUnitOutlinedPartial("Plane");
             processEightWayAnimation("Plane");
             processUnitOutlinedPartial("Plane_S");
+            TallVoxels.processUnitOutlinedPartial("Plane_S");
             processEightWayAnimation("Plane_S");
             processUnitOutlinedPartial("Plane_T");
+            TallVoxels.processUnitOutlinedPartial("Plane_T");
             processEightWayAnimation("Plane_T");


fix(debugging): IpfsClient was not debugging

Race condition between IpfsClient and Common.Logging.  Use IpfsClient in another class.

--- IpfsMount/Program.cs
+++ IpfsMount/Program.cs
@@ -19,9 +19,9 @@
             bool help = false;
             bool debugging = false;
             bool unmount = false;
-            string ipfsServer = "http://127.0.0.1:5001";
+            string apiUrl = "http://127.0.0.1:5001";
             var p = new OptionSet() {
-                { "s|server=", "IPFS API server address", v => ipfsServer = v},
+                { "s|server=", "IPFS API server address", v => apiUrl = v},
                 { "u|unmount", "Unmount the drive", v => unmount = v != null },
                 { "d|debug", "Display debugging information", v => debugging = v != null },
                 { "h|?|help", "Show this help", v => help = v != null },
@@ -48,62 +48,29 @@
             // Allow colon after drive letter
             if (extras.Count < 1)
                 return ShowError("Missing the drive letter.");
+            else if (extras.Count > 1)
+                return ShowError("Unknown option");
+
             var drive = extras[0];
             if (drive.EndsWith(":"))
                 drive = drive.Substring(0, drive.Length - 1);
             drive = drive + @":\";

-            // Unmount
-            if (unmount)
-            {
-                try
-                {
-                    Dokan.Unmount(drive[0]);
-                    return 0;
-                }
-                catch (Exception e)
-                {
-                    return ShowError(e.Message);
-                }
-            }
-
-            // Verify that the local IPFS service is up and running
+            // Do the command
+            var program = new Runner();
             try
             {
-                IpfsClient.DefaultApiUri = new Uri(ipfsServer);
-                new IpfsClient().Id();
+                if (unmount)
+                    program.Unmount(drive);
+                else
+                    program.Mount(drive, apiUrl, debugging);
             }
             catch (Exception e)
             {
                 if (debugging)
-                    log.Fatal("IPFS is not running", e);
-                else
-                    Console.WriteLine("IPFS is not running at {0}\nTry 'ipfs daemon'.", ipfsServer);
-                return 1;
-            }
-
-            // CTRL-C will dismount and then exit.
-            Console.CancelKeyPress += (s, e) =>
-            {
-                Console.WriteLine("shutting down...");
-                Dokan.Unmount(drive[0]);
-                e.Cancel = true;
-            };
-
-            // Mount IPFS, doesn't return until the drive is dismounted
-            var options = DokanOptions.WriteProtection;
-            if (debugging)
-                options |= DokanOptions.DebugMode;
-            try
-            {
-                Dokan.Mount(new IpfsDokan(),
-                    drive,
-                    options,
-                    new DokanLogger());
-            }
-            catch (Exception e)
-            {
-                return ShowError(e.Message);
+                    log.Fatal("Failed", e);
+
+                return ShowError(e);
             }

             return 0;
@@ -116,6 +83,16 @@
             return 1;
         }

+        static int ShowError(Exception ex)
+        {
+            for (var e = ex; e != null; e = e.InnerException)
+            {
+                Console.WriteLine(e.Message);
+            }
+
+            return 1;
+        }
+
         static int ShowHelp(OptionSet p)
         {
             Console.WriteLine("Mount the IPFS on the specified drive");
@@ -124,6 +101,35 @@
             Console.WriteLine("Options:");
             p.WriteOptionDescriptions(Console.Out);
             return 0;
+        }
+    }
+
+    class Runner
+    {
+        public void Mount(string drive, string apiUrl, bool debugging)
+        {
+            // Verify that the local IPFS service is up and running
+            IpfsClient.DefaultApiUri = new Uri(apiUrl);
+            var x = new IpfsClient().Id().Result;
+
+            // CTRL-C will dismount and then exit.
+            Console.CancelKeyPress += (s, e) =>
+            {
+                Console.WriteLine("shutting down...");
+                Unmount(drive);
+                e.Cancel = true;
+            };
+
+            // Mount IPFS, doesn't return until the drive is dismounted
+            var options = DokanOptions.WriteProtection;
+            if (debugging)
+                options |= DokanOptions.DebugMode;
+            Dokan.Mount(new IpfsDokan(), drive, options, new DokanLogger());
+        }
+
+        public void Unmount(string drive)
+        {
+            Dokan.Unmount(drive[0]);
         }
     }


Update Game.Utility.cs

Update Game.Utility.cs

--- PokemonUnity.Shared/Application/Game/Game.Utility.cs
+++ PokemonUnity.Shared/Application/Game/Game.Utility.cs
@@ -1718,5 +1718,136 @@
     public partial class GlobalMetadata
     {
         public IAudioObject trainerRecording { get; set; }
+  public bool bicycle				{ get; set; }
+  public bool surfing				{ get; set; }
+  public bool diving				{ get; set; }
+  public bool sliding				{ get; set; }
+  public bool fishing				{ get; set; }
+  public bool runtoggle				{ get; set; }
+        /// <summary>
+        /// </summary>
+        /// Should not stack (encourage users to deplete excessive money);
+        /// reset count based on repel used.
+		///ToDo: Missing Variables for RepelType, Swarm
+  public int repel				    { get; set; }
+  public bool flashUsed				{ get; set; }
+  public float bridge				{ get; set; }
+  public bool runningShoes			{ get; set; }
+  public bool snagMachine			{ get; set; }
+  public bool seenStorageCreator	{ get; set; }
+  public DateTime startTime			{ get; set; }
+        /// <summary>
+        /// Has player beaten the game already and viewed credits from start to end
+        /// </summary>
+        /// New Game Plus
+  public bool creditsPlayed			                { get; set; }
+  public int playerID				                { get; set; }
+  public int coins				                    { get; set; }
+  public int sootsack				                { get; set; }
+  public int? mailbox				                { get; set; }
+  //public Character.PCItemStorage pcItemStorage	{ get; set; }
+  public int stepcount				                { get; set; }
+  public int happinessSteps				            { get; set; }
+  public int? pokerusTime				            { get; set; }
+  public Character.DayCare daycare		            { get; set; }
+  public bool daycareEgg				            { get; set; } //ToDo: int?...
+  public int daycareEggSteps			            { get; set; }
+  public bool[] pokedexUnlocked			            { get; set; } // Array storing which Dexes are unlocked
+  public List<int> pokedexViable		            { get; set; } // All Dexes of non-zero length and unlocked
+  public int pokedexDex				                { get; set; } // Dex currently looking at (-1 is National Dex)
+  public int[] pokedexIndex				            { get; set; } // Last species viewed per Dex
+  public int pokedexMode				            { get; set; } // Search mode
+  public int? healingSpot				            { get; set; }
+  public float[] escapePoint			            { get; set; }
+  public int pokecenterMapId			            { get; set; }
+  public float pokecenterX				            { get; set; }
+  public float pokecenterY				            { get; set; }
+  public int pokecenterDirection		            { get; set; }
+  //public Overworld.TilePosition pokecenter			{ get; set; }
+  public List<int> visitedMaps				        { get; set; }
+  public List<int> mapTrail				            { get; set; }
+  public int? nextBattleBGM				            { get; set; }
+  public int? nextBattleME				            { get; set; }
+  public int? nextBattleBack			            { get; set; }
+  public int? safariState				            { get; set; }
+  //public BugContestState bugContestState			{ get; set; }
+  public Combat.Trainer partner			            { get; set; }
+  public int? challenge				                { get; set; }
+  public int? lastbattle				            { get; set; }
+  public List<int> phoneNumbers			            { get; set; }
+  public int phoneTime				                { get; set; }
+  public bool safesave				                { get; set; }
+  public Dictionary<KeyValuePair<int,int>,int> eventvars				{ get; set; }
+
+  public GlobalMetadata() {
+    @bicycle              = false;
+    @surfing              = false;
+    @diving               = false;
+    @sliding              = false;
+    @fishing              = false;
+    @runtoggle            = false;
+    @repel                = 0;
+    @flashUsed            = false;
+    @bridge               = 0;
+    @runningShoes         = false;
+    @snagMachine          = false;
+    @seenStorageCreator   = false;
+    @startTime            = Game.GetTimeNow;
+    @creditsPlayed        = false;
+    @playerID             = -1;
+    @coins                = 0;
+    @sootsack             = 0;
+    @mailbox              = null;
+    //@pcItemStorage        = null;
+    @stepcount            = 0;
+    @happinessSteps       = 0;
+    @pokerusTime          = null;
+    @daycare              = new Character.DayCare(2); //{ { null, 0 }, { null, 0 } };
+    @daycareEgg           = false;//0;
+    @daycareEggSteps      = 0;
+    int numRegions        = 0;
+    //pbRgssOpen("Data/regionals.dat","rb"){|f| numRegions = f.fgetw }
+    @pokedexUnlocked      = new bool[numRegions];
+    @pokedexViable        = new List<int>();
+    @pokedexDex           = (numRegions==0) ? -1 : 0;
+    @pokedexIndex         = new int[numRegions];
+    @pokedexMode          = 0;
+    for (int i = 0; i < numRegions+1; i++) {	// National Dex isn't a region, but is included
+      @pokedexIndex[i]    = 0;
+      @pokedexUnlocked[i] = (i==0);
+    }
+    @healingSpot          = null;
+    @escapePoint          = new float[0];
+    @pokecenterMapId      = -1;
+    @pokecenterX          = -1;
+    @pokecenterY          = -1;
+    @pokecenterDirection  = -1;
+    @visitedMaps          = new List<int>();
+    @mapTrail             = new List<int>();
+    @nextBattleBGM        = null;
+    @nextBattleME         = null;
+    @nextBattleBack       = null;
+    @safariState          = null;
+    //@bugContestState      = null;
+    @partner              = null;
+    @challenge            = null;
+    @lastbattle           = null;
+    @phoneNumbers         = new List<int>();
+    @phoneTime            = 0;
+    @eventvars            = new Dictionary<KeyValuePair<int, int>, int>();
+    @safesave             = false;
+  }
+
+  //public void bridge() {
+  //  if (!@bridge) @bridge=0;
+  //  return @bridge;
+  //}
+
+  //public void roamPokemonCaught() {
+  //  if (!@roamPokemonCaught) {
+  //    @roamPokemonCaught=[];
+  //  }
+  //  return @roamPokemonCaught;
+  //}
     }
 }


fix bindings in GetStorageToken function

--- Producer/Producer.Functions/StorageTokenGenerator.cs
+++ Producer/Producer.Functions/StorageTokenGenerator.cs
@@ -18,22 +18,19 @@

 	public static class StorageTokenGenerator
 	{
-
-		//const string containerName = "uploads-avcontent";
-
-		//const string connString = "MS_AzureStorageAccountConnectionString";
+		static readonly string _storageAccountConnection = Environment.GetEnvironmentVariable("AzureWebJobsStorage");

 		static CloudBlobClient _blobClient;

-		public static CloudBlobClient BlobClient => _blobClient ?? (_blobClient = CloudStorageAccount.Parse ("%AzureWebJobsStorage%").CreateCloudBlobClient ());
+		public static CloudBlobClient BlobClient => _blobClient ?? (_blobClient = CloudStorageAccount.Parse (_storageAccountConnection).CreateCloudBlobClient ());

 #if !DEBUG
 		[Authorize]
 #endif
 		[FunctionName ("GetStorageToken")]
 		public static async Task<HttpResponseMessage> Run (
-			[HttpTrigger (AuthorizationLevel.Anonymous, "get", Route = "tokens/{collectionId:alpha}/{contentId:alpha}")]HttpRequestMessage req,
-			[DocumentDB ("Content", "collectionId", Id = "contentId")] AvContent avContent,
+			[HttpTrigger (AuthorizationLevel.Anonymous, "get", Route = "tokens/{collectionId}/{contentId}")]HttpRequestMessage req,
+			[DocumentDB ("Content", "{collectionId}", Id = "{contentId}")] AvContent avContent,
 			string collectionId,
 			string contentId,
 			TraceWriter log)
@@ -49,14 +46,18 @@

 			if (avContent == null)
 			{
-				//throw new HttpResponseException (req.CreateBadRequestResponse ("No item in database matching the contentId paramater {0}", contentId));
+				log.Info ($"No item in database matching the contentId paramater {contentId}");
+
 				return req.CreateErrorResponse (HttpStatusCode.NotFound, $"No item in database matching the contentId paramater {contentId}");
+			}
+			else
+			{
+				log.Info ($"Successfully found document in database matching the contentId paramater {contentId}");
 			}

 			var containerName = $"uploads-{collectionId}";

-
-
+
 			// Errors creating the storage container result in a 500 Internal Server Error
 			var container = BlobClient.GetContainerReference (containerName);


Using case-insensitive version of String.IndexOf instead of String.StartsWith to filter categories list.

--- src/managed/OpenLiveWriter.PostEditor/PostPropertyEditing/CategoryControl/TreeCategorySelector.cs
+++ src/managed/OpenLiveWriter.PostEditor/PostPropertyEditing/CategoryControl/TreeCategorySelector.cs
@@ -252,7 +252,7 @@
             {
                 Predicate<TreeNode> prefixPredicate = delegate (TreeNode node)
                                           {
-                                              return node.Text.ToLower(CultureInfo.CurrentCulture).StartsWith(criteria);
+                                              return node.Text.ToLower(CultureInfo.CurrentCulture).IndexOf(criteria, StringComparison.CurrentCultureIgnoreCase) >= 0;
                                           };

                 if (criteria.Length > 0 && criteria.StartsWith(lastQuery))


Files can also be uploaded by anyone who can view order

--- Purchasing.Web/Views/Order/_ReviewAttachments.cshtml
+++ Purchasing.Web/Views/Order/_ReviewAttachments.cshtml
@@ -17,16 +17,13 @@

             }

-        @if (Model.CanEditOrder)
-        {
-

-

-
-
Please enable JavaScript to use file uploader.

-
-
-

+

+

+
+
Please enable JavaScript to use file uploader.

+
+

-        }
+


Fix deleting all  items on update

Fix deleting all  items on update

--- R7.University/components/UniversityControllerBase.cs
+++ R7.University/components/UniversityControllerBase.cs
@@ -466,7 +466,7 @@
                     if (!allNew)
                     {
                         // delete remaining items
-                        foreach (var eduForm in eduForms)
+                        foreach (var eduForm in originalEduForms)
                         {
                             Delete<EduProgramProfileFormInfo> (eduForm);
                         }


changing ConstruktionContext parameter name in ConstruktionPipeline.

under the current circumstances of this class, this is NOT a breaking
change for anyone

--- Construktion/ConstruktionPipeline.cs
+++ Construktion/ConstruktionPipeline.cs
@@ -15,9 +15,9 @@
         /// <summary>
         /// Send a request through the pipeline to be constructed.
         /// </summary>
-        /// <param name="requestContext"></param>
+        /// <param name="context"></param>
         /// <returns></returns>
-        object Send(ConstruktionContext requestContext);
+        object Send(ConstruktionContext context);
     }

     internal class DefaultConstruktionPipeline : ConstruktionPipeline
@@ -31,11 +31,11 @@
             Settings = settings;
         }

-        public object Send(ConstruktionContext requestContext)
+        public object Send(ConstruktionContext context)
         {
-            var blueprint = Settings.Blueprints.First(x => x.Matches(requestContext));
+            var blueprint = Settings.Blueprints.First(x => x.Matches(context));

-            var result = Construct(requestContext, blueprint);
+            var result = Construct(context, blueprint);

             return result;
         }


Added zoom menu handlers

Added zoom menu handlers

--- Core2D.UI.WinForms/Forms/MainForm.cs
+++ Core2D.UI.WinForms/Forms/MainForm.cs
@@ -300,8 +300,8 @@
             // TODO:

             // View
-
-            // TODO:
+            resetZoomToolStripMenuItem.Click += (sender, e) => ResetZoom();
+            zoomToExtentToolStripMenuItem.Click += (sender, e) => AutoFit();

             // Tool
             noneToolStripMenuItem.Click += (sender, e) => OnSetToolToNone();


Remove debug line

Remove debug line

--- CorePlugin/Python/ExecutionEngine.cs
+++ CorePlugin/Python/ExecutionEngine.cs
@@ -46,7 +46,6 @@
             builder.AppendLine();

             string script = source.Insert(0, builder.ToString());
-            Console.WriteLine(script);

             _engine = Python.CreateEngine();
             _engine = Python.CreateEngine();


Fixed Misc

Fixed Misc

--- Kayn/Kayn/Program.cs
+++ Kayn/Kayn/Program.cs
@@ -121,9 +121,9 @@
             var target = TargetSelector.GetTarget(W.Range, DamageType.Physical);
             var wPred = W.GetPrediction(target);

-            if (Misc["Inter"].Cast<CheckBox>().CurrentValue && W.IsReady() && Q.GetPrediction(target).HitChance >= HitChance.High)
-            {
-                if (_Player.Distance(_Player.ServerPosition, true) <= W.Range && Q.GetPrediction(target).HitChance >= HitChance.High)
+            if (Misc["Inter"].Cast<CheckBox>().CurrentValue && W.IsReady() && W.GetPrediction(target).HitChance >= HitChance.High)
+            {
+                if (_Player.Distance(_Player.ServerPosition, true) <= W.Range && W.GetPrediction(target).HitChance >= HitChance.High)
                 {
                     W.Cast(target);
                 }


Revise SaveAmf to take ILibraryContentStream

--- CustomWidgets/ExportPrintItemPage.cs
+++ CustomWidgets/ExportPrintItemPage.cs
@@ -366,7 +366,7 @@
 			}
 		}

-		private void SaveAmf(string filePathToSave)
+		private bool SaveAmf(ILibraryContentStream source, string filePathToSave)
 		{
 			try
 			{
@@ -382,22 +382,21 @@
 					if (Path.GetExtension(printItemWrapper.FileLocation).ToUpper() == Path.GetExtension(filePathToSave).ToUpper())
 					{
 						File.Copy(printItemWrapper.FileLocation, filePathToSave, true);
+						return true;
 					}
 					else
 					{
 						IObject3D item = Object3D.Load(printItemWrapper.FileLocation, CancellationToken.None);
-						MeshFileIo.Save(item, filePathToSave);
-					}
-
-					ShowFileIfRequested(filePathToSave);
-				}
-			}
-			catch (Exception e)
-			{
-				UiThread.RunOnIdle (() => {
-					StyledMessageBox.ShowMessageBox(null, e.Message, "Couldn't save file".Localize());
-				});
-			}
+						return MeshFileIo.Save(item, filePathToSave);
+					}
+				}
+			}
+			catch (Exception ex)
+			{
+				Trace.WriteLine("Error exporting file: " + ex.Message);
+			}
+
+			return false;
 		}

 		private bool SaveStl(ILibraryContentStream source, string filePathToSave)


Change EventType property type

Change EventType property type

Add new enum which represents lobby events and change EventType property type to this enum

--- RiotSharp/TournamentEndpoint/TournamentLobbyEvent.cs
+++ RiotSharp/TournamentEndpoint/TournamentLobbyEvent.cs
@@ -1,5 +1,6 @@
 using System;
 using Newtonsoft.Json;
+using Newtonsoft.Json.Converters;

 namespace RiotSharp.TournamentEndpoint
 {
@@ -16,7 +17,8 @@
         ///     The type of event that was triggered
         /// </summary>
         [JsonProperty("eventType")]
-        public string EventType { get; set; }
+        [JsonConverter(typeof(StringEnumConverter))]
+        public LobbyEvent EventType { get; set; }

         /// <summary>
         ///     The summoner that triggered the event
@@ -31,4 +33,15 @@
         [JsonConverter(typeof(DateTimeConverterFromStringTimestamp))]
         public DateTime Timestamp { get; set; }
     }
+
+    public enum LobbyEvent
+    {
+        PracticeGameCreatedEvent,
+        PlayerJoinedGameEvent,
+        PlayerSwitchedTeamEvent,
+        PlayerQuitGameEvent,
+        ChampSelectStartedEvent,
+        GameAllocationStartedEvent,
+        GameAllocatedToLsmEvent
+    }
 }


Add Milestone stuff

Add Milestone stuff

--- RosaroterPanterWPF/RosaroterPanterWPF/DataService.cs
+++ RosaroterPanterWPF/RosaroterPanterWPF/DataService.cs
@@ -1,5 +1,6 @@
 using System;
 using System.Collections.Generic;
+using System.Collections.ObjectModel;
 using System.ComponentModel;
 using System.Linq;
 using System.Text;
@@ -32,9 +33,22 @@

     public class Task : NotifyPropertyChanged
     {
+        private bool _completed;
+
         public Color Color { get; set; }
         public string Description { get; set; }
-        public bool Completed { get; private set; }
+        public bool Completed
+        {
+            get
+            {
+                return _completed;
+            }
+            private set
+            {
+                _completed = value;
+                OnPropertyChanged("Completed");
+            }
+        }
         public string Name { get; set; }
         public double TotalTime { get; private set; }

@@ -63,38 +77,50 @@

     public class Milestone
     {
-        List<Task> _tasks;
-        public List<Task> Tasks {
+        ObservableCollection<Task> _tasks;
+        public Task[] Tasks
+        {
             get
             {
-                return _tasks;
-            }
-            set
-            {
-                _tasks = value;
-                Completed = CheckForCompletion();
+                return _tasks.ToArray();
             }
         }
         public bool Completed { get; private set; }

-        public Milestone(int number_of_tasks)
+        public Milestone()
         {
             Completed = false;
-            Tasks = new List<Task>(number_of_tasks);
+            _tasks = new ObservableCollection<Task>();
         }

-        public Milestone() : this(0)
-        { }
+        public void AddTask(Task task)
+        {
+            _tasks.Add(task);
+            task.PropertyChanged += (object sender, PropertyChangedEventArgs e) =>
+            {
+                if (e.PropertyName.Equals("Completed"))
+                    Completed = CheckForCompletion();
+            };
+        }

-        void AddTask(Task task)
+        public int CountOfTasks()
         {
-            Tasks.Add(task);
+            return _tasks.Count;
+        }

+        public bool RemoveTaskAt(int index)
+        {
+            if (_tasks.Count > index)
+            {
+                _tasks.RemoveAt(index);
+                return true;
+            }
+            return false;
         }

         private bool CheckForCompletion()
         {
-            foreach(Task t in _tasks)
+            foreach (Task t in _tasks)
             {
                 if (!t.Completed) return false;
             }


PostgreSql Dialect is complete

PostgreSql Dialect is complete

--- Sharp.Data/Databases/PostgreSql/PostgreSqlDialect.cs
+++ Sharp.Data/Databases/PostgreSql/PostgreSqlDialect.cs
@@ -4,6 +4,7 @@
 using System.Globalization;
 using System.Text;
 using Sharp.Data.Schema;
+using Sharp.Util;

 namespace Sharp.Data.Databases.PostgreSql {
     public class PostgreSqlDialect : Dialect {
@@ -26,7 +27,7 @@

             //create table
             var sb = new StringBuilder();
-            sb.Append("create table ").Append(table.Name).AppendLine(" (");
+            sb.Append("CREATE TABLE ").Append(table.Name).AppendLine(" (");

             var size = table.Columns.Count;
             for (var i = 0; i < size; i++) {
@@ -64,28 +65,39 @@
                 return;
             }
             var sequenceName = SequencePrefix + tableName;
-            sqls.Add(String.Format("create sequence {0} increment 1 minvalue 1 maxvalue 9223372036854775807 start 1 cache 1", sequenceName));
-            sqls.Add(String.Format("alter table {0} alter column {1} set default nextval(\"{2}\"::regclass)", tableName, autoIncrementColumn.ColumnName, sequenceName));
+            sqls.Add(String.Format("CREATE SEQUENCE {0} INCREMENT 1 MINVALUE 1 MAXVALUE 9223372036854775807 START 1 CACHE 1", sequenceName));
+            sqls.Add(String.Format("ALTER TABLE {0} ALTER COLUMN {1} SET DEFAULT NEXTVAL(\"{2}\"::REGCLASS)", tableName, autoIncrementColumn.ColumnName, sequenceName));
         }

         public override string[] GetDropTableSqls(string tableName) {
-            return new[] { String.Format("drop table {0} cascade", tableName) };
+            return new[] { String.Format("DROP TABLE {0} CASCADE", tableName) };
         }

         public override string GetForeignKeySql(string fkName, string table, string column, string referencingTable, string referencingColumn, OnDelete onDelete) {
-            throw new NotImplementedException();
+            switch (onDelete) {
+                case OnDelete.Cascade:
+                    return "ON DELETE CASCADE";
+                case OnDelete.SetNull:
+                    return "ON DELETE SET NULL";
+                default:
+                    return String.Empty;
+            }
         }

         public override string GetUniqueKeySql(string ukName, string table, params string[] columnNames) {
-            throw new NotImplementedException();
+            return String.Format("CREATE UNIQUE INDEX {0} ON {1} ({2})", ukName, table, StringHelper.Implode(columnNames, ","));
         }

         public override string GetDropUniqueKeySql(string uniqueKeyName, string tableName) {
-            throw new NotImplementedException();
+            return "DROP INDEX " + uniqueKeyName;
         }

         public override string GetInsertReturningColumnSql(string table, string[] columns, object[] values, string returningColumnName, string returningParameterName) {
-            throw new NotImplementedException();
+            return String.Format("{0} RETURNING {1} INTO {2}{3}",
+                             GetInsertSql(table, columns, values),
+                             returningColumnName,
+                             ParameterPrefix,
+                             returningParameterName);
         }

         public override string WrapSelectSqlWithPagination(string sql, int skipRows, int numberOfRows) {
@@ -137,7 +149,7 @@
         public override string GetColumnToSqlWhenCreate(Column col) {
             var colType = GetDbTypeString(col.Type, col.Size);
             var colNullable = col.IsNullable ? WordNull : WordNotNull;
-            var colDefault = (col.DefaultValue != null) ? String.Format("default {0}", GetColumnValueToSql(col.DefaultValue)) : "";
+            var colDefault = (col.DefaultValue != null) ? String.Format("DEFAULT {0}", GetColumnValueToSql(col.DefaultValue)) : "";

             return String.Format("{0} {1} {2} {3}", col.ColumnName, colType, colDefault, colNullable);
         }
@@ -179,17 +191,16 @@
             return String.Format("COMMENT ON TABLE {0} IS ''", tableName);
         }

-
         public override string GetRenameTableSql(string tableName, string newTableName) {
-            throw new NotImplementedException();
+            return String.Format("ALTER TABLE {0} RENAME TO {1}", tableName, newTableName);
         }

         public override string GetRenameColumnSql(string tableName, string columnName, string newColumnName) {
-            throw new NotImplementedException();
+            return String.Format("ALTER TABLE {0} RENAME COLUMN {1} TO {2}", tableName, columnName, newColumnName);
         }

         public override string GetModifyColumnSql(string tableName, string columnName, Column columnDefinition) {
-            throw new NotImplementedException();
+            return String.Format("ALTER TABLE {0} RENAME COLUMN {1} TO {2}", tableName, GetColumnToSqlWhenCreate(columnDefinition));
         }
     }
 }


commented up ListSyntaxParser

commented up ListSyntaxParser

--- SharpSwift/SharpSwift/Converters/ListSyntaxParser.cs
+++ SharpSwift/SharpSwift/Converters/ListSyntaxParser.cs
@@ -1,114 +1,75 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
+using System.Linq;
 using Microsoft.CodeAnalysis.CSharp.Syntax;

 namespace SharpSwift.Converters
 {
     partial class ConvertToSwift
     {
-        //NOTE: you shouldn't use anything special in Argument or ArgumentList - check ObjectCreationExpression FMI
-        [ParsesType(typeof(ArgumentSyntax))]
-        public static string Argument(ArgumentSyntax node)
+        /// <summary>
+        /// Converts a type argument list to Swift
+        /// </summary>
+        /// <param name="list">The list to convert</param>
+        /// <returns>The converted Swift list</returns>
+        [ParsesType(typeof(TypeArgumentListSyntax))]
+        public static string TypeArgumentList(TypeArgumentListSyntax list)
         {
-            var output = SyntaxNode(node.Expression);
-            if (node.NameColon != null)
-            {
-                output = SyntaxNode(node.NameColon.Name) + ": " + output;
-            }
-            return output;
+            return "<" + string.Join(", ", list.Arguments.Select(SyntaxNode)) + ">";
         }

-        [ParsesType(typeof(AttributeArgumentSyntax))]
-        public static string AttributeArgument(AttributeArgumentSyntax node)
+        /// <summary>
+        /// Converts a type parameter list to Swift
+        /// </summary>
+        /// <param name="list">The list to convert</param>
+        /// <returns>The converted Swift list</returns>
+        [ParsesType(typeof(TypeParameterListSyntax))]
+        public static string TypeParameterList(TypeParameterListSyntax list)
         {
-            var output = SyntaxNode(node.Expression);
-            if (node.NameColon != null)
-            {
-                output = SyntaxNode(node.NameColon.Name) + ": " + output;
-            }
-            return output;
+            return string.Join(", ", list.Parameters.Select(SyntaxNode));
         }

-        [ParsesType(typeof (ArgumentListSyntax))]
-        public static string ArgumentList(ArgumentListSyntax node)
+        /// <summary>
+        /// Converts a parameter list to Swift
+        /// </summary>
+        /// <example>(ParameterListSyntax list)</example>
+        /// <param name="list">The parameter list to convert</param>
+        /// <returns>The converted Swift list</returns>
+        [ParsesType(typeof(ParameterListSyntax))]
+        public static string ParameterList(ParameterListSyntax list)
         {
-            return "(" + string.Join(", ", node.Arguments.Select(SyntaxNode)) + ")";
+            return "(" + string.Join(", ", list.Parameters.Select(SyntaxNode)) + ")";
         }

+        /// <summary>
+        /// Converts an attribute list to Swift
+        /// </summary>
+        /// <param name="list">The list to convert</param>
+        /// <returns>The converted Swift list</returns>
         [ParsesType(typeof(AttributeListSyntax))]
-        public static string AttributeList(AttributeListSyntax node)
+        public static string AttributeList(AttributeListSyntax list)
         {
-            return string.Join(" ", node.Attributes.Select(SyntaxNode));
+            return string.Join(" ", list.Attributes.Select(SyntaxNode));
         }

-        [ParsesType(typeof(AttributeArgumentListSyntax))]
-        public static string AttributeArgumentList(AttributeArgumentListSyntax node)
+        /// <summary>
+        /// Converts an argument list to Swift
+        /// </summary>
+        /// <param name="list">The list to convert</param>
+        /// <returns>The converted Swift list</returns>
+        [ParsesType(typeof(ArgumentListSyntax))]
+        public static string ArgumentList(ArgumentListSyntax list)
         {
-            return "(" + string.Join(", ", node.Arguments.Select(SyntaxNode)) + ")";
+            return "(" + string.Join(", ", list.Arguments.Select(SyntaxNode)) + ")";
         }

-        [ParsesType(typeof(TypeArgumentListSyntax))]
-        public static string TypeArgumentList(TypeArgumentListSyntax node)
+        /// <summary>
+        /// Converts an attribute argument list to Swift
+        /// </summary>
+        /// <param name="list">The list to convert</param>
+        /// <returns>The converted Swift list</returns>
+        [ParsesType(typeof(AttributeArgumentListSyntax))]
+        public static string AttributeArgumentList(AttributeArgumentListSyntax list)
         {
-            return "<" + string.Join(", ", node.Arguments.Select(SyntaxNode)) + ">";
-        }
-
-        [ParsesType(typeof(TypeParameterSyntax))]
-        public static string TypeParameter(TypeParameterSyntax node)
-        {
-            var constraint = "";
-            if (node.Parent.Parent is MethodDeclarationSyntax)
-            {
-                var typeConstraints = ((MethodDeclarationSyntax)node.Parent.Parent).ConstraintClauses;
-                var constraints = typeConstraints.FirstOrDefault(constr => SyntaxNode(constr.Name) == node.Identifier.Text).Constraints;
-                constraint = ": " + string.Join(", ", constraints); //TODO: check if this is the right syntax for multiple constraints
-            }
-            return node.Identifier.Text + constraint;
-        }
-
-        [ParsesType(typeof(TypeParameterListSyntax))]
-        public static string TypeParameterList(TypeParameterListSyntax node)
-        {
-            return string.Join(", ", node.Parameters.Select(SyntaxNode));
-        }
-
-        //string something
-        [ParsesType(typeof(ParameterSyntax))]
-        public static string Parameter(ParameterSyntax node)
-        {
-            var output = node.Identifier.Text;
-
-            if (node.Type != null)
-            {
-                if (node.Type is GenericNameSyntax)
-                {
-                    output += ": " + SyntaxNode(node.Type);
-                }
-                else if (node.Type is IdentifierNameSyntax)
-                {
-                    output += ": " + Type(((IdentifierNameSyntax)node.Type).Identifier.Text);
-                }
-                else
-                {
-                    output += ": " + SyntaxNode(node.Type);
-                }
-            }
-
-            //variadic parameters O:
-            //params string[] strs -> strs: string...
-            //kindof.
-            if (node.Modifiers.Any(mod => mod.ToString() == "params"))
-            {
-                output = output.TrimEnd().TrimEnd('[', ']') + "...";
-            }
-            return output;
-        }
-
-        [ParsesType(typeof (ParameterListSyntax))]
-        public static string ParameterList(ParameterListSyntax node)
-        {
-            return "(" + string.Join(", ", node.Parameters.Select(SyntaxNode)) + ")";
+            return "(" + string.Join(", ", list.Arguments.Select(SyntaxNode)) + ")";
         }
     }
 }


fix check for macos

fix check for macos

--- src/Tools/Source/RunTests/AssemblyScheduler.cs
+++ src/Tools/Source/RunTests/AssemblyScheduler.cs
@@ -172,13 +172,11 @@
             }
         }

-        private static ImmutableArray<WorkItemInfo> BuildWorkItems<T>(
+        private ImmutableArray<WorkItemInfo> BuildWorkItems<T>(
             ImmutableSortedDictionary<AssemblyInfo, ImmutableArray<TypeInfo>> typeInfos,
             Func<T, bool> isOverLimitFunc,
             Func<TestMethodInfo, T, T> addFunc) where T : struct
         {
-            var isMacOs = RuntimeInformation.IsOSPlatform(OSPlatform.OSX);
-
             var workItems = new List<WorkItemInfo>();

             // Keep track of which work item we are creating - used to identify work items in names.
@@ -252,7 +250,13 @@

             bool IsOverMacOsFilterCountLimit()
             {
-                if (isMacOs)
+                // Hack: On helix MacOS machines the test platform will currently crash with a stack overflow
+                // when the test filter count exceeds about 6350 tests.  We need to truncate the work item before we get there.
+                // See https://github.com/microsoft/vstest/issues/3905
+                //
+                // Note: Because the partitioning for both OSX and Linux helix work items runs on Linux we must look
+                // at the target queue name to determine where the tests will eventually be running.
+                if (_options.HelixQueueName?.StartsWith("OSX") == true)
                 {
                     var currentNumberOfTestsInWorkItem = currentFilters.Values.SelectMany(t => t).Count();
                     if (currentNumberOfTestsInWorkItem > 6300)


fix  SearchControl_GetContextMenuItems

fix  SearchControl_GetContextMenuItems

--- Signum.Windows.Extensions/Processes/ProcessClient.cs
+++ Signum.Windows.Extensions/Processes/ProcessClient.cs
@@ -80,8 +80,8 @@
                           where oi.IsEntityOperation && oi.Lite == true
                           group KVP.Create(t, oi) by oi.Key into g
                           let os = (EntityOperationSettingsBase)OperationClient.Manager.Settings.TryGetC(g.Key)
-                          where os == null ||
-                                os.ContextualFromMany == null && !os.ClickOverriden ||
+                          where os == null ? true:
+                                os.ContextualFromMany == null ? !os.ClickOverriden :
                                 os.ContextualFromMany.OnVisible(sc, g.First().Value)
                           select new PackageData
                           {


Use DataField's ColumnName when converting Expressions to columns.

--- Silk.Data.SQL.ORM/Expressions/ExpressionConverter.cs
+++ Silk.Data.SQL.ORM/Expressions/ExpressionConverter.cs
@@ -2,6 +2,7 @@
 using Silk.Data.SQL.ORM.Modelling;
 using System;
 using System.Collections.Generic;
+using System.Linq;
 using System.Linq.Expressions;

 namespace Silk.Data.SQL.ORM.Expressions
@@ -11,11 +12,12 @@
 		where TView : new()
 	{
 		public DataModel<TSource, TView> DataModel { get; }
-		private ConverterVisitor _converterVisitor = new ConverterVisitor();
+		private ConverterVisitor _converterVisitor;

 		public ExpressionConverter(DataModel<TSource, TView> dataModel)
 		{
 			DataModel = dataModel;
+			_converterVisitor = new ConverterVisitor(dataModel);
 		}

 		public QueryExpression ConvertToCondition(Expression<Func<TView, bool>> expression)
@@ -30,6 +32,12 @@
 		{
 			private string _parameterName;
 			private readonly Stack<QueryExpression> _expressionStack = new Stack<QueryExpression>();
+			private readonly DataModel<TSource, TView> _dataModel;
+
+			public ConverterVisitor(DataModel<TSource, TView> dataModel)
+			{
+				_dataModel = dataModel;
+			}

 			public void Setup(string parameterName)
 			{
@@ -68,7 +76,10 @@
 				if (expressionParameter != null)
 				{
 					//  member is based from a parameter to a lambda expression
-					PushOntoStack(QueryExpression.Column(node.Member.Name));
+					PushOntoStack(QueryExpression.Column(
+						_dataModel.Fields.First(q => q.Name == node.Member.Name)
+							.Storage.ColumnName
+						));
 				}
 				else
 				{


Fix tests

Fix tests

--- src/Umbraco.Tests/Runtimes/CoreRuntimeTests.cs
+++ src/Umbraco.Tests/Runtimes/CoreRuntimeTests.cs
@@ -13,7 +13,6 @@
 using Umbraco.Core.Runtime;
 using Umbraco.Tests.TestHelpers;
 using Umbraco.Tests.TestHelpers.Stubs;
-using Umbraco.Examine;
 using Umbraco.Web;

 namespace Umbraco.Tests.Runtimes
@@ -61,23 +60,13 @@
         {
             protected override IRuntime GetRuntime()
             {
-                return new TestRuntime(this);
+                return new TestRuntime();
             }
-
-            // don't register anything against AppDomain
-            protected override void ConfigureUnhandledException(ILogger logger)
-            { }
         }

         // test runtime
         public class TestRuntime : CoreRuntime
         {
-            public TestRuntime(UmbracoApplicationBase umbracoApplication)
-                : base()
-            {
-                _umbracoApplication = umbracoApplication;
-            }
-
             // the application's logger is created by the application
             // through GetLogger, that custom application can override
             protected override ILogger GetLogger()
@@ -118,7 +107,6 @@
             }

             private MainDom _mainDom;
-            private readonly UmbracoApplicationBase _umbracoApplication;

             public override void Boot(ServiceContainer container)
             {


Prevent Host.TypeConverter to serialize to string

--- source/Nuke.Common/Execution/Host.Activation.cs
+++ source/Nuke.Common/Execution/Host.Activation.cs
@@ -60,6 +60,11 @@

                 return base.ConvertFrom(context, culture, value);
             }
+
+            public override bool CanConvertTo(ITypeDescriptorContext context, Type destinationType)
+            {
+                return false;
+            }
         }
     }
 }


added reminder;

added reminder;

--- examples/TCP/TCB.cs
+++ examples/TCP/TCB.cs
@@ -97,6 +97,7 @@
     public static int find_free_TCB(TCB[] tcbs) {
       // FIXME linear search not efficient.
       for (int i = 0; i < tcbs.Length; i++) { // NOTE assuming that tcbs.Length == max_conn
+        // FIXME protect against race conditions
         if (tcbs[i].state == TCP_State.Free) {
           return i;
         }


Update Disasm6502.cs

Update Disasm6502.cs

--- 6502.Net/Disasm6502.cs
+++ 6502.Net/Disasm6502.cs
@@ -1,4 +1,4 @@
-//-----------------------------------------------------------------------------
+//-----------------------------------------------------------------------------
 // Copyright (c) 2017 informedcitizenry <informedcitizenry@gmail.com>
 //
 // Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -67,9 +67,12 @@
         private string DisassembleFileLine(SourceLine line)
         {
             string lineinfo = line.Filename;
-            if (lineinfo.Length > 14)
+            if (string.IsNullOrEmpty(lineinfo) == false)
+            {
+                if (lineinfo.Length > 14)
                 lineinfo = lineinfo.Substring(0, 11) + "...";
-            lineinfo += "(" + line.LineNumber.ToString() + ")";
+                lineinfo += "(" + line.LineNumber.ToString() + ")";
+            }
             return string.Format("{0,-20}:", lineinfo);
         }

@@ -89,7 +92,7 @@
             if (line.Instruction == "=" || line.Instruction.Equals(".equ", Controller.Options.StringComparison))
             {
                 Int64 value = 0;
-                if (line.Label == "*")
+                if (line.Label == "*" || Controller.Options.NoSource)
                     return string.Empty;
                 if (string.IsNullOrEmpty(line.Operand) || line.Operand == "*" || line.Label == "-" || line.Label == "+")
                 {
@@ -141,7 +144,7 @@
                     pc += 8;
                     if (i < subdisasms.Count - 1)
                     {
-                        string format = ">{0:x4}  ";
+                        string format = ">{0:x4}    ";
                         if (Controller.Options.VerboseList)
                             format = "                    :" + format;
                         sb.AppendFormat(format, pc);
@@ -171,7 +174,6 @@
                 return;// printing has been suppressed

             string sourcestr = line.SourceString;
-
             if (!Controller.Options.VerboseList)
             {
                 if (line.DoNotAssemble || Reserved.IsReserved(line.Instruction))
@@ -185,33 +187,54 @@
                 else if (Controller.Options.NoSource)
                 {
                     sourcestr = string.Empty;
-                }
+                }
                 else if (string.IsNullOrWhiteSpace(line.Label + line.Instruction))
+                {
                     return;
+                }
             }
             else
             {
                 if (string.IsNullOrEmpty(sourcestr))
-                    sourcestr = line.Instruction;
+                    return;
                 else if (Controller.Options.NoSource)
                     sourcestr = string.Empty;
                 sb.Append(DisassembleFileLine(line));
             }
-            sb.AppendFormat("{0,-7}", DisassembleAddress(line));
-
-            string asm = DisassembleAsm(line, sourcestr);
-            if (asm.Length > 24)
-            {
-                sb.Append(asm);
-            }
-            else
-            {
-                if (string.IsNullOrEmpty(line.Disassembly) || Controller.Options.NoDissasembly)
-                    sb.AppendFormat("{0,-29}{1,-10}", asm, sourcestr).AppendLine();
+            sb.AppendFormat("{0,-9}", DisassembleAddress(line));
+
+            if (Controller.Options.NoAssembly == false)
+            {
+                string asm = DisassembleAsm(line, sourcestr);
+                if (asm.Length > 24)
+                {
+                    sb.Append(asm);
+                    return;
+                }
+                else if (string.IsNullOrEmpty(line.Disassembly) || Controller.Options.NoDissasembly)
+                {
+                    sb.AppendFormat("{0,-29}", asm);
+                }
                 else
-                    sb.AppendFormat("{0,-13}{1,-16}{2,-10}", asm, line.Disassembly, sourcestr)
-                      .AppendLine();
-            }
+                {
+                    sb.AppendFormat("{0,-13}", asm);
+                }
+            }
+
+            if (Controller.Options.NoDissasembly == false)
+            {
+                if (string.IsNullOrEmpty(line.Disassembly) == false)
+                    sb.AppendFormat("{0,-16}", line.Disassembly);
+                else if (Controller.Options.NoAssembly)
+                    sb.AppendFormat("{0,-28}", line.Disassembly);
+            }
+
+            if (Controller.Options.NoSource == false)
+                sb.AppendFormat("{0,-10}", sourcestr);
+            else if (string.IsNullOrEmpty(line.Disassembly) && line.Assembly.Count == 0)
+                sb.TrimEnd();
+
+            sb.AppendLine();
         }

         /// <summary>


Update Disasm6502.cs

Update Disasm6502.cs


Make EnableAutomaticStepping into a property

--- AGXUnity/Simulation.cs
+++ AGXUnity/Simulation.cs
@@ -18,7 +18,13 @@
     /// </summary>
     private agxSDK.Simulation m_simulation = null;

-    public bool EnableAutomaticStepping = true;
+    [SerializeField]
+    private bool m_enableAutomaticStepping = true;
+    public bool EnableAutomaticStepping
+    {
+      get { return m_enableAutomaticStepping; }
+      set { m_enableAutomaticStepping = value; }
+    }

     public static float DefaultTimeStep { get { return Time.fixedDeltaTime; } }


Added logging

Added logging

--- Core.WebApi/Middlewares/ExceptionHandling/ExceptionHandlingMiddleware.cs
+++ Core.WebApi/Middlewares/ExceptionHandling/ExceptionHandlingMiddleware.cs
@@ -35,6 +35,7 @@
         private Task HandleExceptionAsync(HttpContext context, Exception exception)
         {
             logger.LogError(exception, exception.Message);
+            Console.WriteLine(exception.Message);

             var codeInfo = ExceptionToHttpStatusMapper.Map(exception);


Play charge animation on recharge

Play charge animation on recharge

--- Assets/Scripts/Shot.cs
+++ Assets/Scripts/Shot.cs
@@ -55,9 +55,15 @@

   // Recharge weapon
   private IEnumerator Recharge() {
+    Animation animation = GetComponent<Animation>();
+
     Cursor.visible = false;
+    animation.Play();
     GetComponent<AudioSource>().PlayOneShot(chargeSound);
+
     yield return new WaitForSeconds(chargeInterval);
+
+    animation.Stop();
     roundCount = cartridgeCount;
     Cursor.visible = true;
   }


Добавил отсутствующие поляв Page

Добавил отсутствующие поляв Page

--- VkNet/Model/Attachments/Page.cs
+++ VkNet/Model/Attachments/Page.cs
@@ -84,15 +84,26 @@
         /// </summary>
         public string Html { get; set; }

-        public string ViewUrl { get; set; }
+		/// <summary>
+		/// Gets or sets the view URL.
+		/// </summary>
+		public string ViewUrl { get; set; }

+		/// <summary>
+		/// Gets or sets the version created.
+		/// </summary>
 		public string VersionCreated { get; set; }
-
-        #endregion

-        #region Методы

-        internal static Page FromJson(VkResponse response)
+		/// <summary>
+		/// Количество просмотров вики-страницы.
+		/// </summary>
+		public long views;
+		#endregion
+
+		#region Методы
+
+		internal static Page FromJson(VkResponse response)
 		{
 			var page = new Page
 			{
@@ -114,7 +125,8 @@

 				Html = response["html"], // установлено экcпериментальным путем
 				ViewUrl = response["view_url"],
-				VersionCreated = response["version_created"]
+				VersionCreated = response["version_created"],
+				views = response["views"]
 			};
 			return page;
 		}


Added code to Start

Added code to Start

Added code to the Start method of the TomNewScript file

--- Assets/TomNewScript.cs
+++ Assets/TomNewScript.cs
@@ -5,7 +5,11 @@

 	// Use this for initialization
 	void Start () {
-
+
+
+	 // Tom added this in class on Nov 9
+	 // Sample code changes here only to Start.
+
 	}

 	// Update is called once per frame


Added methods to convert between SHIL values and the system's closest pixel size

--- Windows.Shell/ShellImageList.cs
+++ Windows.Shell/ShellImageList.cs
@@ -1,5 +1,7 @@
 using System;
+using System.Collections.Generic;
 using System.Drawing;
+using System.Linq;
 using Vanara.PInvoke;
 using static Vanara.PInvoke.ComCtl32;
 using static Vanara.PInvoke.Shell32;
@@ -24,8 +26,13 @@
 		///
 		ExtraLarge = SHIL.SHIL_EXTRALARGE,

+		///
+		/// These images are the size specified by GetSystemMetrics called with SM_CXSMICON and GetSystemMetrics called with SM_CYSMICON.
+		///
+		SystemSmall = SHIL.SHIL_SYSSMALL,
+
 		/// Windows Vista and later. The image is normally 256x256 pixels.
-		Jumbo = SHIL.SHIL_JUMBO
+		Jumbo = SHIL.SHIL_JUMBO,
 	}

 	/* *****************************
@@ -34,7 +41,22 @@
 	/// Represents the System Image List holding images for all shell icons.
 	public static class ShellImageList
 	{
+		private const string REGSTR_PATH_METRICS = "Control Panel\\Desktop\\WindowMetrics";
+		private static readonly Dictionary<ShellImageSize, ushort> g_rgshil;
+		private static readonly int SHIL_COUNT;
 		private static HIMAGELIST hSystemImageList;
+
+		static ShellImageList()
+		{
+			SHIL_COUNT = Enum.GetValues(typeof(ShellImageSize)).Length;
+			g_rgshil = new Dictionary<ShellImageSize, ushort>(SHIL_COUNT); // new ushort[SHIL_COUNT];
+			var sysCxIco = GetSystemMetrics(SystemMetric.SM_CXICON);
+			g_rgshil[ShellImageSize.Large] = (ushort)(int)Microsoft.Win32.Registry.CurrentUser.GetValue($"{REGSTR_PATH_METRICS}\\Shell Icon Size", sysCxIco);
+			g_rgshil[ShellImageSize.Small] = (ushort)(int)Microsoft.Win32.Registry.CurrentUser.GetValue($"{REGSTR_PATH_METRICS}\\Shell Small Icon Size", sysCxIco / 2);
+			g_rgshil[ShellImageSize.ExtraLarge] = (ushort)(3 * sysCxIco / 2);
+			g_rgshil[ShellImageSize.SystemSmall] = (ushort)GetSystemMetrics(SystemMetric.SM_CXSMICON);
+			g_rgshil[ShellImageSize.Jumbo] = 256;
+		}

 		/// Gets the Shell icon for the given file name or extension.
 		/// <param name="fileNameOrExtension">The file name or extension .</param>
@@ -71,10 +93,26 @@
 		/// <param name="index">The index of the system icon to retrieve.</param>
 		/// <param name="iconSize">Size of the icon.</param>
 		/// <returns>An <see cref="Icon"/> instance if found; otherwise <see langword="null"/>.</returns>
-		public static Icon GetSystemIcon(int index, ShellImageSize iconSize = ShellImageSize.Large)
+		public static Icon GetSystemIcon(int index, ShellImageSize iconSize = ShellImageSize.Large) => GetSystemIconHandle(index, iconSize)?.ToIcon();
+
+		/// Gets the system icon for and index and size.
+		/// <param name="index">The index of the system icon to retrieve.</param>
+		/// <param name="iconSize">Size of the icon.</param>
+		/// <returns>An <see cref="Icon"/> instance if found; otherwise <see langword="null"/>.</returns>
+		public static SafeHICON GetSystemIconHandle(int index, ShellImageSize iconSize = ShellImageSize.Large)
 		{
 			SHGetImageList((SHIL)iconSize, typeof(IImageList).GUID, out var il).ThrowIfFailed();
-			return il.GetIcon(index, IMAGELISTDRAWFLAGS.ILD_TRANSPARENT)?.ToIcon();
+			return il.GetIcon(index, IMAGELISTDRAWFLAGS.ILD_TRANSPARENT);
 		}
+
+		/// Given a pixel size, return the ShellImageSize value with the closest size.
+		/// <param name="pixels">Size, in pixels, of the image list size to search for.</param>
+		/// <returns>An image list size.</returns>
+		public static ShellImageSize PixelsToSHIL(int pixels) => g_rgshil.Aggregate((x, y) => Math.Abs(x.Value - pixels) < Math.Abs(y.Value - pixels) ? x : y).Key;
+
+		/// Given an image list size, return the related size, in pixels, of that size defined on the system.
+		/// <param name="imageListSize">Size of the image list.</param>
+		/// <returns>Pixel size of corresponding system value.</returns>
+		public static int SHILtoPixels(ShellImageSize imageListSize) => g_rgshil[imageListSize];
 	}
 }


Relax RNG exception conditions

Relax RNG exception conditions

--- osu.Framework/MathUtils/RNG.cs
+++ osu.Framework/MathUtils/RNG.cs
@@ -61,7 +61,7 @@
         /// <returns>A double-precision floating point number in the range [minValue,maxValue).</returns>
         public static double NextDouble(double minValue, double maxValue)
         {
-            if (minValue > maxValue)
+            if (minValue >= maxValue)
                 throw new ArgumentOutOfRangeException(nameof(minValue), "The given minimum value must be less than or equal to the given maximum value.");

             return minValue + random.NextDouble() * (maxValue - minValue);
@@ -94,7 +94,7 @@
         /// <returns>A single-precision floating point number in the range [minValue,maxValue).</returns>
         public static float NextSingle(float minValue, float maxValue)
         {
-            if (minValue > maxValue)
+            if (minValue >= maxValue)
                 throw new ArgumentOutOfRangeException(nameof(minValue), "The given minimum value must be less than or equal to the given maximum value.");

             return minValue + NextSingle() * (maxValue - minValue);


Fix certificate store problem xibosignage/xibo#827

--- Logic/HardwareKey.cs
+++ Logic/HardwareKey.cs
@@ -203,7 +203,7 @@
             const int PROVIDER_RSA_FULL = 1;
             CspParameters cspParams;
             cspParams = new CspParameters(PROVIDER_RSA_FULL);
-            cspParams.KeyContainerName = Application.ProductName + "RsaKey";
+            cspParams.KeyContainerName = Application.ProductName + "-" + Environment.UserName + "-" + "RsaKey";
             cspParams.Flags = CspProviderFlags.UseMachineKeyStore;
             cspParams.ProviderName = "Microsoft Strong Cryptographic Provider";

@@ -217,15 +217,23 @@

         public string getXmrPublicKey()
         {
-            AsymmetricCipherKeyPair key = getXmrKey();
-
-            using (TextWriter textWriter = new StringWriter())
-            {
-                PemWriter writer = new PemWriter(textWriter);
-                writer.WriteObject(key.Public);
-                writer.Writer.Flush();
-
-                return textWriter.ToString();
+            try
+            {
+                AsymmetricCipherKeyPair key = getXmrKey();
+
+                using (TextWriter textWriter = new StringWriter())
+                {
+                    PemWriter writer = new PemWriter(textWriter);
+                    writer.WriteObject(key.Public);
+                    writer.Writer.Flush();
+
+                    return textWriter.ToString();
+                }
+            }
+            catch (Exception e)
+            {
+                Trace.WriteLine(new LogMessage("HardwareKey - getXmrPublicKey", "Unable to get XMR public key. E = " + e.Message), LogType.Error.ToString());
+                return null;
             }
         }
     }


[Mac] Fix LinkLabel

[Mac] Fix LinkLabel

--- Xwt.Mac/Xwt.Mac/LabelBackend.cs
+++ Xwt.Mac/Xwt.Mac/LabelBackend.cs
@@ -35,13 +35,13 @@
 	public class LabelBackend: ViewBackend<NSView,IWidgetEventSink>, ILabelBackend
 	{
 		public LabelBackend ()
-			: this (new CustomAlignedContainer (new TextFieldView ()))
+			: this (new TextFieldView ())
 		{
 		}

 		protected LabelBackend (IViewObject viewObject)
 		{
-			ViewObject = viewObject;
+			ViewObject = new CustomAlignedContainer ((NSView)viewObject);
 			Widget.Editable = false;
 			Widget.Bezeled = false;
 			Widget.DrawsBackground = false;


activate IPluginLogoffRequestAddTime only if IPluginEventNotifications is enabled

--- pGina/src/Core/PluginLoader.cs
+++ pGina/src/Core/PluginLoader.cs
@@ -292,7 +292,7 @@
             if (typeof(T) == typeof(IPluginEventNotifications) && TestMask(mask, State.NotificationEnabled))
                 return true;

-            if (typeof(T) == typeof(IPluginLogoffRequestAddTime))
+            if (typeof(T) == typeof(IPluginLogoffRequestAddTime) && TestMask(mask, State.NotificationEnabled))
                 return true;

             return false;


Minor refactor to walking search tree

Minor refactor to walking search tree

--- MaxMind.Db/Reader.cs
+++ MaxMind.Db/Reader.cs
@@ -338,17 +338,15 @@

             var bitLength = rawAddress.Length * 8;
             var record = StartNode(bitLength);
-
-            for (prefixLength = 0; prefixLength < bitLength; prefixLength++)
-            {
-                if (record >= Metadata.NodeCount)
-                {
-                    break;
-                }
-                var b = rawAddress[prefixLength / 8];
-                var bit = 1 & (b >> 7 - (prefixLength % 8));
+            var nodeCount = Metadata.NodeCount;
+
+            var i = 0;
+            for (; i < bitLength && record < nodeCount; i++)
+            {
+                var bit = 1 & (rawAddress[i >> 3] >> (7 - (i % 8)));
                 record = ReadNode(record, bit);
             }
+            prefixLength = i;
             if (record == Metadata.NodeCount)
             {
                 // record is empty


fixed 2 bugs

fixed 2 bugs

--- Assets/MixedRealityToolkit.SDK/Features/UX/Scripts/BoundingBox/BoundingBox.cs
+++ Assets/MixedRealityToolkit.SDK/Features/UX/Scripts/BoundingBox/BoundingBox.cs
@@ -1799,7 +1799,10 @@
             // This can only happen by name unless there is a better idea of tracking the rigRoot that needs destruction

             List<Transform> childTransforms = new List<Transform>();
-            childTransforms.Add(Target.transform);
+            if (Target != null && Target != gameObject)
+            {
+                childTransforms.Add(Target.transform);
+            }

             foreach (Transform childTransform in Target.transform)
             {
@@ -1844,7 +1847,7 @@
                 if (boundsCalculationMethod == BoundsCalculationMethod.ColliderOnly ||
                     boundsCalculationMethod == BoundsCalculationMethod.ColliderOverRenderer)
                 {
-                    AddColliderBoundsToTarget(colliderByTransform);
+                    if (AddColliderBoundsToTarget(colliderByTransform) && boundsCalculationMethod == BoundsCalculationMethod.ColliderOverRenderer) { continue; }
                     if (boundsCalculationMethod == BoundsCalculationMethod.ColliderOnly) { continue; }
                 }

@@ -1852,7 +1855,7 @@

                 if (boundsCalculationMethod != BoundsCalculationMethod.ColliderOnly)
                 {
-                    AddRendererBoundsToTarget(rendererBoundsByTransform);
+                    if (AddRendererBoundsToTarget(rendererBoundsByTransform) && boundsCalculationMethod == BoundsCalculationMethod.RendererOverCollider) { continue; }
                     if (boundsCalculationMethod == BoundsCalculationMethod.RendererOnly) { continue; }
                 }

@@ -1874,21 +1877,25 @@
             return finalBounds;
         }

-        private void AddRendererBoundsToTarget(KeyValuePair<Transform, Bounds> rendererBoundsByTarget)
-        {
-            if (rendererBoundsByTarget.Key == null) { return; }
+        private bool AddRendererBoundsToTarget(KeyValuePair<Transform, Bounds> rendererBoundsByTarget)
+        {
+            if (rendererBoundsByTarget.Key == null) { return false; }

             Vector3[] cornersToWorld = null;
             rendererBoundsByTarget.Value.GetCornerPositions(rendererBoundsByTarget.Key, ref cornersToWorld);
             totalBoundsCorners.AddRange(cornersToWorld);
-        }
-
-        private void AddColliderBoundsToTarget(KeyValuePair<Transform, Collider> colliderByTransform)
+
+            return true;
+        }
+
+        private bool AddColliderBoundsToTarget(KeyValuePair<Transform, Collider> colliderByTransform)
         {
             if (colliderByTransform.Key != null)
             {
                 BoundsExtensions.GetColliderBoundsPoints(colliderByTransform.Value, totalBoundsCorners, 0);
             }
+
+            return colliderByTransform.Key != null;
         }

         private void SetMaterials()
@@ -2655,4 +2662,4 @@

         #endregion Unused Event Handlers
     }
-}+}


Hookup mouse event for ImGui

Hookup mouse event for ImGui

--- Source/Examples/SharpDX.Core/CoreTest/CoreTestApp.cs
+++ Source/Examples/SharpDX.Core/CoreTest/CoreTestApp.cs
@@ -35,6 +35,7 @@
         private MaterialCore[] materialList;
         private long previousTime;
         private bool resizeRequested = false;
+        private IO io = ImGui.GetIO();

         public CoreTestApp(Form window)
         {
@@ -43,6 +44,10 @@
             window.ResizeEnd += Window_ResizeEnd;
             window.Load += Window_Load;
             window.FormClosing += Window_FormClosing;
+            window.MouseMove += Window_MouseMove;
+            window.MouseDown += Window_MouseDown;
+            window.MouseUp += Window_MouseUp;
+            window.MouseWheel += Window_MouseWheel;
             effectsManager = new DefaultEffectsManager();
             effectsManager.AddTechnique(ImGuiNode.RenderTechnique);
             viewport.EffectsManager = effectsManager;
@@ -55,6 +60,8 @@
             viewport.BackgroundColor = new Color4(0.45f, 0.55f, 0.6f, 1f);
             InitializeScene();
         }
+
+

         private void InitializeScene()
         {
@@ -171,7 +178,7 @@
             {
                 if (resizeRequested)
                 {
-                    viewport.Resize(window.Width, window.Height);
+                    viewport.Resize(window.ClientSize.Width, window.ClientSize.Height);
                     resizeRequested = false;
                     return;
                 }
@@ -242,7 +249,51 @@

         private void Window_Load(object sender, EventArgs e)
         {
-            viewport.StartD3D(window.Width, window.Height);
-        }
+            viewport.StartD3D(window.ClientSize.Width, window.ClientSize.Height);
+        }
+        #region Handle mouse event
+        private void Window_MouseMove(object sender, MouseEventArgs e)
+        {
+            io.MousePosition = new System.Numerics.Vector2(e.X, e.Y);
+            Debug.WriteLine("Mouse: " + e.Location);
+        }
+
+        private void Window_MouseUp(object sender, MouseEventArgs e)
+        {
+            switch (e.Button)
+            {
+                case MouseButtons.Left:
+                    io.MouseDown[0] = false;
+                    break;
+                case MouseButtons.Right:
+                    io.MouseDown[1] = false;
+                    break;
+                case MouseButtons.Middle:
+                    io.MouseDown[2] = false;
+                    break;
+            }
+        }
+
+        private void Window_MouseDown(object sender, MouseEventArgs e)
+        {
+            switch (e.Button)
+            {
+                case MouseButtons.Left:
+                    io.MouseDown[0] = true;
+                    break;
+                case MouseButtons.Right:
+                    io.MouseDown[1] = true;
+                    break;
+                case MouseButtons.Middle:
+                    io.MouseDown[2] = true;
+                    break;
+            }
+        }
+
+        private void Window_MouseWheel(object sender, MouseEventArgs e)
+        {
+            io.MouseWheel = e.Delta;
+        }
+        #endregion
     }
 }


Fix wrong data validation (#342).

Fix wrong data validation (#342).

--- Source/MQTTnet/Formatter/V3/MqttV310DataConverter.cs
+++ Source/MQTTnet/Formatter/V3/MqttV310DataConverter.cs
@@ -244,11 +244,6 @@

         public MqttDisconnectPacket CreateDisconnectPacket(MqttClientDisconnectOptions options)
         {
-            if (options.ReasonCode != MqttClientDisconnectReason.NormalDisconnection || options.ReasonString != null)
-            {
-                throw new MqttProtocolViolationException("Reason codes and reason string for disconnect are only supported for MQTTv5.");
-            }
-
             return new MqttDisconnectPacket();
         }


Default error page updated

Default error page updated

--- Dinero.Tools.Difference/Dinero.Tools.Difference.Web/Views/Shared/Error.cshtml
+++ Dinero.Tools.Difference/Dinero.Tools.Difference.Web/Views/Shared/Error.cshtml
@@ -1 +1,11 @@
-
Dette er default Error siden...virker det nu?
+@model System.Web.Mvc.HandleErrorInfo
+@{
+    ViewBag.Title = (!String.IsNullOrEmpty(ViewBag.StatusCode)) ? ViewBag.StatusCode : "500 Error";
+}
+
+
@(!String.IsNullOrEmpty(ViewBag.StatusCode) ? ViewBag.StatusCode : "500 Error"):

+
+//@Model.ActionName
+//@Model.ControllerName
+//@Model.Exception.Message
+//@Model.Exception.StackTrace