layout

layout

--- MomWorld/Views/Shared/_UserLayout.cshtml
+++ MomWorld/Views/Shared/_UserLayout.cshtml
@@ -8,11 +8,14 @@

+
     <link rel="stylesheet" href="@Url.Content("~/Content/css/vendor/bootstrap/bootstrap.min.css")">
     <link rel="stylesheet" href="@Url.Content("~/Content/css/vendor/font-awesome-4.2.0/css/font-awesome.min.css")">

-    <link rel="stylesheet" href="@Url.Content("~/Content/css/vendor/animate/animate.css")">
-    <link rel="stylesheet" href="@Url.Content("~/Content/js/vendor/mmenu/css/jquery.mmenu.all.css")" />
+
+    <link rel="stylesheet" href="@Url.Content("~/Content/css/vendor/animate/animate.min.css")">
+    <link rel="stylesheet" href="@Url.Content("~/Content/js/vendor/mmenu/css/jquery.mmenu.all.css")">
+    <link rel="stylesheet" href="@Url.Content("~/Content/js/vendor/videobackground/css/jquery.videobackground.css")">

     <link rel="stylesheet" href="@Url.Content("~/Content/css/vendor/bootstrap-checkbox.css")">
     <link rel="stylesheet" href="@Url.Content("~/Content/css/vendor/bootstrap/bootstrap-dropdown-multilevel.css")">
@@ -23,6 +26,12 @@
     <link rel="stylesheet" href="@Url.Content("~/Content/js/vendor/datatables/css/ColVis.css")">
     <link rel="stylesheet" href="@Url.Content("~/Content/js/vendor/datatables/css/TableTools.css")">

+    <link rel="stylesheet" href="@Url.Content("~/Content/js/vendor/rickshaw/css/rickshaw.min.css")">
+    <link rel="stylesheet" href="@Url.Content("~/Content/js/vendor/morris/css/morris.css")">
+    <link rel="stylesheet" href="@Url.Content("~/Content/js/vendor/tabdrop/css/tabdrop.css")">
+
+    <link rel="stylesheet" href="@Url.Content("~/Content/js/vendor/summernote/css/summernote.css")">
+    <link rel="stylesheet" href="@Url.Content("~/Content/js/vendor/summernote/css/summernote-bs3.css")">

     <link href="@Url.Content("~/Content/css/minimal.css")" rel="stylesheet">

@@ -32,9 +41,6 @@
           <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
           <script src="https://oss.maxcdn.com/libs/respond.js/1.3.0/respond.min.js"></script>
         <![endif]-->
-
-
-
     <!-- jQuery (necessary for Bootstrap's JavaScript plugins) -->
     <script src="@Url.Content("~/Content/js/vendor/jquery/jquery.js")"></script>
     <!-- Include all compiled plugins (below), or include individual files as needed -->
@@ -62,14 +68,19 @@
     <script src="@Url.Content("~/Content/js/vendor/datatables/tabletools/dataTables.tableTools.min.js")"></script>
     <script src="@Url.Content("~/Content/js/vendor/datatables/dataTables.bootstrap.js")"></script>

+    <script src="@Url.Content("~/Content/js/vendor/flot/jquery.flot.min.js")"></script>
+    <script src="@Url.Content("~/Content/js/vendor/flot/jquery.flot.time.min.js")"></script>
+    <script src="@Url.Content("~/Content/js/vendor/flot/jquery.flot.selection.min.js")"></script>
+    <script src="@Url.Content("~/Content/js/vendor/flot/jquery.flot.animator.min.js")"></script>
+    <script src="@Url.Content("~/Content/js/vendor/flot/jquery.flot.orderBars.js")"></script>
+    <script src="@Url.Content("~/Content/js/vendor/easypiechart/jquery.easypiechart.min.js")"></script>
+    <script src="@Url.Content("~/Content/js/vendor/rickshaw/raphael-min.js")"></script>
+    <script src="@Url.Content("~/Content/js/vendor/rickshaw/d3.v2.js")"></script>
+    <script src="@Url.Content("~/Content/js/vendor/rickshaw/rickshaw.min.js")"></script>
+    <script src="@Url.Content("~/Content/js/vendor/morris/morris.min.js")"></script>
+    <script src="@Url.Content("~/Content/js/vendor/tabdrop/bootstrap-tabdrop.min.js")"></script>
+
     <script src="@Url.Content("~/Content/js/minimal.js")"></script>
-
-    <!-- Logic dependences -->
-    @*<script src="@Url.Content("~/Scripts/angular.min.js")"></script>
-    <script src="https://cdn.firebase.com/js/client/2.2.2/firebase.js"></script>
-    <script src="https://cdn.firebase.com/libs/angularfire/1.0.0/angularfire.min.js"></script>*@
-
-

 </head>


Try correct the failing tests.

Try correct the failing tests.

--- MongoDB.Net-Tests/Bson/TestBsonWriter.cs
+++ MongoDB.Net-Tests/Bson/TestBsonWriter.cs
@@ -151,7 +151,7 @@
         public void TestWriteDateTimeFromOtherTimeZone(){
             var europeStd = TimeZoneInfo.FindSystemTimeZoneById("W. Europe Standard Time");

-            var referenceTime = TimeZoneInfo.ConvertTimeFromUtc(new DateTime(2010, 1, 1, 10, 0, 0, DateTimeKind.Utc), europeStd);
+            var referenceTime = TimeZoneInfo.ConvertTime(new DateTime(2010, 1, 1, 10, 0, 0, DateTimeKind.Utc), europeStd);

             var bson = Serialize(new Document("Value", referenceTime));


PartNameクラスにregionを追加

PartNameクラスにregionを追加

--- MusicXMLUtils/Structure/Part/PartName.cs
+++ MusicXMLUtils/Structure/Part/PartName.cs
@@ -38,7 +38,9 @@
     [XmlType(TypeName = "part-name")]
     public class PartName
     {
+        #region -- Public Properties --
         [XmlText]
         public string Value { get; set; }
+        #endregion
     }
 }


Improved naming.

Improved naming.

--- NodaMoney.UnitTests/ExchangeRateTests.cs
+++ NodaMoney.UnitTests/ExchangeRateTests.cs
@@ -71,17 +71,17 @@
         [TestClass]
         public class GivenIWantToConvertMoney
         {
-            private readonly Currency euro = Currency.FromCode("EUR");
-            private readonly Currency dollar = Currency.FromCode("USD");
-            private ExchangeRate fx = new ExchangeRate(Currency.FromCode("EUR"), Currency.FromCode("USD"), 1.2591); // EUR/USD 1.2591
+            private readonly Currency _euro = Currency.FromCode("EUR");
+            private readonly Currency _dollar = Currency.FromCode("USD");
+            private ExchangeRate _exchangeRate = new ExchangeRate(Currency.FromCode("EUR"), Currency.FromCode("USD"), 1.2591); // EUR/USD 1.2591

             [TestMethod, Description("When Converting €100,99 With EUR/USD 1.2591, Then Result Should Be $127.16")]
             public void WhenConvertingEurosToDollars_ThenConversionShouldBeCorrect()
             {
                 // Convert €100,99 to $127.156509 (= €100.99 * 1.2591)
-                var converted = fx.Convert(Money.Euro(100.99M));
+                var converted = _exchangeRate.Convert(Money.Euro(100.99M));

-                converted.Currency.Should().Be(dollar);
+                converted.Currency.Should().Be(_dollar);
                 converted.Amount.Should().Be(127.16M);
             }

@@ -89,12 +89,12 @@
             public void WhenConvertingEurosToDollarsAndThenBack_ThenEndResultShouldBeTheSameAsInTheBeginning()
             {
                 // Convert €100,99 to $127.156509 (= €100.99 * 1.2591)
-                var converted = fx.Convert(Money.Euro(100.99M));
+                var converted = _exchangeRate.Convert(Money.Euro(100.99M));

                 // Convert $127.16 to €100,99 (= $127.16 / 1.2591)
-                var revert = fx.Convert(converted);
+                var revert = _exchangeRate.Convert(converted);

-                revert.Currency.Should().Be(euro);
+                revert.Currency.Should().Be(_euro);
                 revert.Amount.Should().Be(100.99M);
             }
         }
@@ -102,16 +102,16 @@
         [TestClass]
         public class GivenIWantToCreateAnExchangeRate
         {
-            private readonly Currency euro = Currency.FromCode("EUR");
-            private readonly Currency dollar = Currency.FromCode("USD");
+            private readonly Currency _euro = Currency.FromCode("EUR");
+            private readonly Currency _dollar = Currency.FromCode("USD");

             [TestMethod]
             public void WhenRateIsDouble_ThenCreatingShouldSucceed()
             {
-                var fx = new ExchangeRate(euro, dollar, 1.2591);
+                var fx = new ExchangeRate(_euro, _dollar, 1.2591);

-                fx.BaseCurrency.Should().Be(euro);
-                fx.QuoteCurrency.Should().Be(dollar);
+                fx.BaseCurrency.Should().Be(_euro);
+                fx.QuoteCurrency.Should().Be(_dollar);
                 // TODO: Can doubles be compared for equality? See https://github.com/dennisdoomen/fluentassertions/wiki
                 fx.Value.Should().Be(1.2591M);
             }
@@ -119,20 +119,20 @@
             [TestMethod]
             public void WhenRateIsDecimal_ThenCreatingShouldSucceed()
             {
-                var fx = new ExchangeRate(euro, dollar, 1.2591M);
+                var fx = new ExchangeRate(_euro, _dollar, 1.2591M);

-                fx.BaseCurrency.Should().Be(euro);
-                fx.QuoteCurrency.Should().Be(dollar);
+                fx.BaseCurrency.Should().Be(_euro);
+                fx.QuoteCurrency.Should().Be(_dollar);
                 fx.Value.Should().Be(1.2591M);
             }

             [TestMethod]
             public void WhenRateIsFloat_ThenCreatingShouldSucceed()
             {
-                var fx = new ExchangeRate(euro, dollar, 1.2591F);
+                var fx = new ExchangeRate(_euro, _dollar, 1.2591F);

-                fx.BaseCurrency.Should().Be(euro);
-                fx.QuoteCurrency.Should().Be(dollar);
+                fx.BaseCurrency.Should().Be(_euro);
+                fx.QuoteCurrency.Should().Be(_dollar);
                 fx.Value.Should().Be(1.2591M);
             }

@@ -140,7 +140,7 @@
             public void WhenBaseAndQuoteCurrencyAreTheSame_ThenCreatingShouldThrow()
             {
                 // Arrange, Act
-                Action action = () => new ExchangeRate(euro, euro, 1.2591F);
+                Action action = () => new ExchangeRate(_euro, _euro, 1.2591F);

                 // Assert
                 action.ShouldThrow<ArgumentException>();


Update radManager.cs

Update radManager.cs

--- Source/radManager.cs
+++ Source/radManager.cs
@@ -96,6 +96,7 @@
                 radiationLevel = radiationLevel + (alwaysDose - atmoDeep / 10000); //At ground level, the radiation level is about 0,35.
                 return radiationLevel;
             }
+            //From here everything is WIP!
             if (activeBody == "Dres")
             {
                 double alwaysDose = 19.79;  //AVERAGE radiation dose on moho's orbit altitude.


Updated sponsors for 2019

Updated sponsors for 2019

--- OmahaMtg.Web/Views/Pages/Sponsors.cshtml
+++ OmahaMtg.Web/Views/Pages/Sponsors.cshtml
@@ -35,90 +35,172 @@

-
2018

+
2019

+
2018

2017

+

+

+
2019 Sponsors

+

+

+                            Month
+                            Sponsor
+                            Speaker
+                            Topic
+

+

+

+

+                            January
+                             Kiewit
+                            Brian Olson
+                            Rebuilding OmahaMTG – Tips and Tricks
+

+

+                            February
+                            Sogeti
+                            Brandon Dunlap & Matt Elmore
+                            Demystifying the ASP .NET Core Middleware Pipeline
+

+

+                            March
+                            Gallup
+                            Vaibhav Gujral
+                            Upcoming
+

+

+                            April
+                            Don't Panic Labs
+                            TBA
+
+

+

+                            May
+                            Aureus Group
+                            Dustin Horne
+
+

+

+                            June
+                            Farm Credit Services of America
+                            Jeff Bramwell
+
+

+

+                            July
+                            BuilderTrend
+                            TBA
+
+

+

+                            August
+                            Diversified Solutions
+                            TBA
+
+

+

+                            September
+                            Harbinger Partners
+                            TBA
+
+

+

+                            October
+                            Advantage Tech
+                            TBA
+
+

+

+                            November/December
+                            Blue Cross Blue Shield
+                            TBA
+
+

+

+

+

2018 Sponsors

-

-                        Month
-                        Sponsor
-                        Speaker
-                        Topic
-

+

+                            Month
+                            Sponsor
+                            Speaker
+                            Topic
+

-

-                        January
-                         Sogeti
-                        Eric Peters
-                        SmartThings.NET
-

-

-                        February
-                        Farm Credit Services of America
-                        Dustin Horne
-                        Demystifying the ASP .NET Core Middleware Pipeline
-

-

-                        March
-                        Aureus
-                        Vaibhav Gujral
-                        Building Microservices on Azure
-

-

-                        April
-                        LyncStream
-                        Thomas Pizzo
-                        Basics of OAuth and OpenID Connect
-

-

-                        May
-                        ProKarma
-                        Joel Becker
-                        The World of Computer Vision
-

-

-                        June
-                        TEKSystems
-                        Jonathan Ayoub
-                        Automated Unit Testing in .NET
-

-

-                        July
-                        BuilderTrend
-                        Sam Kirkland & Dan Drews
-                        Machine Learning and Regular Expressions
-

-

-                        August
-                        Diversified Solutions
-                        Lighting Rounds
-                        Various topics
-

-

-                        September
-                        Nebraska Furniture Mart
-                        Vaibhav Gujral
-                        Going Serverless with Azure Functions
-

-

-                        October
-                        Don't Panic Labs
-                        Doug Durham
-                        Azure Service Fabric
-

-

-                        November/December
-                        CSG International
-                        Marcus Kern
-                        Facial Recognition
-

+

+                            January
+                             Sogeti
+                            Eric Peters
+                            SmartThings.NET
+

+

+                            February
+                            Farm Credit Services of America
+                            Dustin Horne
+                            Demystifying the ASP .NET Core Middleware Pipeline
+

+

+                            March
+                            Aureus
+                            Vaibhav Gujral
+                            Building Microservices on Azure
+

+

+                            April
+                            LyncStream
+                            Thomas Pizzo
+                            Basics of OAuth and OpenID Connect
+

+

+                            May
+                            ProKarma
+                            Joel Becker
+                            The World of Computer Vision
+

+

+                            June
+                            TEKSystems
+                            Jonathan Ayoub
+                            Automated Unit Testing in .NET
+

+

+                            July
+                            BuilderTrend
+                            Sam Kirkland & Dan Drews
+                            Machine Learning and Regular Expressions
+

+

+                            August
+                            Diversified Solutions
+                            Lighting Rounds
+                            Various topics
+

+

+                            September
+                            Nebraska Furniture Mart
+                            Vaibhav Gujral
+                            Going Serverless with Azure Functions
+

+

+                            October
+                            Don't Panic Labs
+                            Doug Durham
+                            Azure Service Fabric
+

+

+                            November/December
+                            CSG International
+                            Marcus Kern
+                            Facial Recognition
+

@@ -126,80 +208,80 @@

2017 Sponsors

-

-                        Month
-                        Sponsor
-                        Speaker
-                        Topic
-

+

+                            Month
+                            Sponsor
+                            Speaker
+                            Topic
+

-

-                        January
-                         Sogeti
-                        Eric Peters
-                         A brief journey to Microsoft Intellitest.
-

-

-                        February
-                        LyncStream
-                        Brian Newton
-                         Functional Programming in .NET
-

-

-                        March
-                        TEKSystems
-                        Nate Taylor
-                         Professionalism in Software Development
-

-

-                        April
-                        Aureus
-                        Vaibhav Gujral
-                        Microsoft Azure Essentials for Developers
-

-

-                        May
-                        Don't Panic Labs
-                        Doug Durham
-                        Enabling Innovation through Integrating Agile and Software Development Best Practices
-

-

-                        June
-                        CRi
-                        Vaibhav Gujral
-                        Azure Web Apps Deep Dive
-

-

-                        July
-                        Harbinger Partners
-                        Tom Huynh
-                        Machine Learning
-

-

-                        August
-                        Diversified Solutions
-                        Brian Olson
-                        GPU for Fun and Profit
-

-

-                        September
-                        Farm Credit Services of America
-                        Travis Ellis
-                        Introduction to Azure Service Fabric
-

-

-                        October
-                        BuilderTrend
-                        Collin Forrester
-                        Angular Universal & .NET
-

-

-                        November/December
-                        Aviture
-                        Matthew Huck
-                        Azure Active Directory B2C
-

+

+                            January
+                             Sogeti
+                            Eric Peters
+                             A brief journey to Microsoft Intellitest.
+

+

+                            February
+                            LyncStream
+                            Brian Newton
+                             Functional Programming in .NET
+

+

+                            March
+                            TEKSystems
+                            Nate Taylor
+                             Professionalism in Software Development
+

+

+                            April
+                            Aureus
+                            Vaibhav Gujral
+                            Microsoft Azure Essentials for Developers
+

+

+                            May
+                            Don't Panic Labs
+                            Doug Durham
+                            Enabling Innovation through Integrating Agile and Software Development Best Practices
+

+

+                            June
+                            CRi
+                            Vaibhav Gujral
+                            Azure Web Apps Deep Dive
+

+

+                            July
+                            Harbinger Partners
+                            Tom Huynh
+                            Machine Learning
+

+

+                            August
+                            Diversified Solutions
+                            Brian Olson
+                            GPU for Fun and Profit
+

+

+                            September
+                            Farm Credit Services of America
+                            Travis Ellis
+                            Introduction to Azure Service Fabric
+

+

+                            October
+                            BuilderTrend
+                            Collin Forrester
+                            Angular Universal & .NET
+

+

+                            November/December
+                            Aviture
+                            Matthew Huck
+                            Azure Active Directory B2C
+


don't send an empty command

don't send an empty command

--- source_code/Form1.cs
+++ source_code/Form1.cs
@@ -112,6 +112,7 @@
 			this.CommandBox.Size = new System.Drawing.Size(440, 217);
 			this.CommandBox.TabIndex = 0;
 			this.CommandBox.WordWrap = false;
+			this.CommandBox.TextChanged += new System.EventHandler(this.CommandBox_TextChanged);
 			//
 			// CommandList
 			//
@@ -176,6 +177,7 @@
 			// button1
 			//
 			this.button1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
+			this.button1.Enabled = false;
 			this.button1.Location = new System.Drawing.Point(336, 241);
 			this.button1.Name = "button1";
 			this.button1.Size = new System.Drawing.Size(112, 23);
@@ -499,6 +501,8 @@

 		private void button1_Click(object sender, System.EventArgs e)
 		{
+			if (String.IsNullOrEmpty(CommandBox.Text.Trim()))
+				return;
 			if (ns != null && ns.CanWrite && ns.CanRead)
 			{
 				try
@@ -575,6 +579,11 @@
 		{
 			ResponseBox.Text = "";
 		}
+
+		private void CommandBox_TextChanged(object sender, EventArgs e)
+		{
+			button1.Enabled = !String.IsNullOrEmpty(CommandBox.Text.Trim());
+		}
 	}

 	/// <summary>


* Extend inventory name and description length checks to UpdateItem for mssql

--- OpenSim/Data/MSSQL/MSSQLInventoryData.cs
+++ OpenSim/Data/MSSQL/MSSQLInventoryData.cs
@@ -414,17 +414,20 @@
                              @creationDate, @groupID, @groupOwned, @flags)";

             string itemName = item.Name;
+
             if (item.Name.Length > 64)
             {
                 itemName = item.Name.Substring(0, 64);
                 m_log.Warn("[INVENTORY DB]: Name field truncated from " + item.Name.Length.ToString() + " to " + itemName.Length.ToString() + " characters");
             }
+
             string itemDesc = item.Description;
             if (item.Description.Length > 128)
             {
                 itemDesc = item.Description.Substring(0, 128);
                 m_log.Warn("[INVENTORY DB]: Description field truncated from " + item.Description.Length.ToString() + " to " + itemDesc.Length.ToString() + " characters");
             }
+
             using (AutoClosingSqlCommand command = database.Query(sql))
             {
                 command.Parameters.Add(database.CreateParameter("inventoryID", item.ID));
@@ -499,6 +502,21 @@
                                                 groupOwned = @groupOwned,
                                                 flags = @flags
                                         WHERE inventoryID = @keyInventoryID";
+
+            string itemName = item.Name;
+            if (item.Name.Length > 64)
+            {
+                itemName = item.Name.Substring(0, 64);
+                m_log.Warn("[INVENTORY DB]: Name field truncated from " + item.Name.Length.ToString() + " to " + itemName.Length.ToString() + " characters on update");
+            }
+
+            string itemDesc = item.Description;
+            if (item.Description.Length > 128)
+            {
+                itemDesc = item.Description.Substring(0, 128);
+                m_log.Warn("[INVENTORY DB]: Description field truncated from " + item.Description.Length.ToString() + " to " + itemDesc.Length.ToString() + " characters on update");
+            }
+
             using (AutoClosingSqlCommand command = database.Query(sql))
             {
                 command.Parameters.Add(database.CreateParameter("inventoryID", item.ID));
@@ -506,8 +524,8 @@
                 command.Parameters.Add(database.CreateParameter("assetType", item.AssetType));
                 command.Parameters.Add(database.CreateParameter("parentFolderID", item.Folder));
                 command.Parameters.Add(database.CreateParameter("avatarID", item.Owner));
-                command.Parameters.Add(database.CreateParameter("inventoryName", item.Name));
-                command.Parameters.Add(database.CreateParameter("inventoryDescription", item.Description));
+                command.Parameters.Add(database.CreateParameter("inventoryName", itemName));
+                command.Parameters.Add(database.CreateParameter("inventoryDescription", itemDesc));
                 command.Parameters.Add(database.CreateParameter("inventoryNextPermissions", item.NextPermissions));
                 command.Parameters.Add(database.CreateParameter("inventoryCurrentPermissions", item.CurrentPermissions));
                 command.Parameters.Add(database.CreateParameter("invType", item.InvType));


Now working on 0.9.32 on master.

Now working on 0.9.32 on master.

--- OpenSim/Framework/Servers/VersionInfo.cs
+++ OpenSim/Framework/Servers/VersionInfo.cs
@@ -30,7 +30,7 @@
 // Using a * for the third number means auto-fill with the # days since 2000. Good for us here.
 // That only leaves us with two in front, so we'll divide the first number by 10.
 // i.e. 9.18.R in the assembly is presented as 0.9.18.R
-[assembly: AssemblyVersion("9.31.*")]
+[assembly: AssemblyVersion("9.32.*")]
 // Do not provide AssemblyFileVersion and it will be kept in sync.

 namespace OpenSim


* Putting the resending x packet into debug mode only.   Set your loglevel to debug to see them or pull up the simulator statistics in the client to see the 'un acked packet bytes'.

--- OpenSim/Region/ClientStack/ClientView.cs
+++ OpenSim/Region/ClientStack/ClientView.cs
@@ -2584,7 +2584,7 @@
                 {
                     if ((now - packet.TickCount > RESEND_TIMEOUT) && (!packet.Header.Resent))
                     {
-                        m_log.Info("[NETWORK]: Resending " + packet.Type.ToString() + " packet, " +
+                        m_log.Debug("[NETWORK]: Resending " + packet.Type.ToString() + " packet, " +
                                                             (now - packet.TickCount) + "ms have passed");

                         packet.Header.Resent = true;


remove a call ToList from dictionary in a loop (#1436)

--- src/NJsonSchema.CodeGeneration/GeneratorBase.cs
+++ src/NJsonSchema.CodeGeneration/GeneratorBase.cs
@@ -74,7 +74,7 @@
             var types = new Dictionary<string, CodeArtifact>();
             while (_resolver.Types.Any(t => !processedTypes.Contains(t.Value)))
             {
-                foreach (var pair in _resolver.Types.ToList())
+                foreach (var pair in _resolver.Types)
                 {
                     processedTypes.Add(pair.Value);
                     var result = GenerateType(pair.Key, pair.Value);


Adjust Scene.DeleteAllSceneObjects() to not delete objects attached to avatars.

This is going to be the right behaviour in all cases, I should think.
This means that avatars in region when an oar is loaded do not lose their attachments

--- OpenSim/Region/Framework/Scenes/Scene.cs
+++ OpenSim/Region/Framework/Scenes/Scene.cs
@@ -2121,7 +2121,7 @@
         }

         /// <summary>
-        /// Delete every object from the scene
+        /// Delete every object from the scene.  This does not include attachments worn by avatars.
         /// </summary>
         public void DeleteAllSceneObjects()
         {
@@ -2132,7 +2132,11 @@
                 foreach (EntityBase e in entities)
                 {
                     if (e is SceneObjectGroup)
-                        DeleteSceneObject((SceneObjectGroup)e, false);
+                    {
+                        SceneObjectGroup sog = (SceneObjectGroup)e;
+                        if (!sog.IsAttachment)
+                            DeleteSceneObject((SceneObjectGroup)e, false);
+                    }
                 }
             }
         }


Message pumps now start and stop concurrently.

--- src/Nimbus/Configuration/MessagePumpsManager.cs
+++ src/Nimbus/Configuration/MessagePumpsManager.cs
@@ -49,7 +49,7 @@
             var messagePumpsToHandleInBackground = GetMessagePumps(typesToProcessInBackground).ToArray();

             await messagePumpsToWaitFor
-                .Select(action)
+                .Select(pump => Task.Run(() => action(pump)))
                 .WhenAll();

 #pragma warning disable 4014
@@ -61,7 +61,7 @@
                                await Task.Delay(100);

                                await messagePumpsToHandleInBackground
-                                   .Select(action)
+                                   .Select(pump => Task.Run(() => action(pump)))
                                    .WhenAll();
                            });
 #pragma warning restore 4014


Disabling some validations in Intervention model

--- Models/Intervention.cs
+++ Models/Intervention.cs
@@ -26,23 +26,18 @@
         public Person Interventor { get; set; }

         [BelongsTo("interventor_institution_id")]
-        [ValidateNonEmpty]
         public Institution InterventorInstitution { get; set; }

         [BelongsTo("interventor_affiliation_type_id")]
-        [ValidateNonEmpty]
         public AffiliationType InterventorAffiliationType { get; set; }

         [BelongsTo("supporter_id")]
-        [ValidateNonEmpty]
         public Person Supporter { get; set; }

         [BelongsTo("supporter_institution_id")]
-        [ValidateNonEmpty]
         public Institution SupporterInstitution { get; set; }

         [BelongsTo("supporter_affiliation_type_id")]
-        [ValidateNonEmpty]
         public AffiliationType SupporterAffiliationType { get; set; }

         [Property]


On logout, send close child agent requests to neighbours asynchronously, so user is not prevented from relogging if many neighbours are present but not responsive.

The symptom here is that previous user connections are still present but are labelled active == false

--- OpenSim/Region/Framework/Scenes/Scene.cs
+++ OpenSim/Region/Framework/Scenes/Scene.cs
@@ -3435,16 +3435,13 @@
                     if (closeChildAgents && CapsModule != null)
                         CapsModule.RemoveCaps(agentID);

-//                    // REFACTORING PROBLEM -- well not really a problem, but just to point out that whatever
-//                    // this method is doing is HORRIBLE!!!
-                    // Commented pending deletion since this method no longer appears to do anything at all
-//                    avatar.Scene.NeedSceneCacheClear(avatar.UUID);
-
                     if (closeChildAgents && !isChildAgent)
                     {
                         List<ulong> regions = avatar.KnownRegionHandles;
                         regions.Remove(RegionInfo.RegionHandle);
-                        m_sceneGridService.SendCloseChildAgentConnections(agentID, regions);
+
+                        // We must do this asynchronously so that a logout isn't held up where there are many present but unresponsive neighbours.
+                        Util.FireAndForget(delegate { m_sceneGridService.SendCloseChildAgentConnections(agentID, regions); });
                     }

                     m_eventManager.TriggerClientClosed(agentID, this);


debug stuff

debug stuff

--- TCC.Core/App.xaml.cs
+++ TCC.Core/App.xaml.cs
@@ -5,6 +5,7 @@
 using System.Linq;
 using System.Net;
 using System.Reflection;
+using System.Runtime.InteropServices;
 using System.Text;
 using System.Threading;
 using System.Windows;
@@ -96,14 +97,28 @@

             if (Settings.LastRegion == "NA" || Settings.LastRegion == "")
                 WindowManager.FloatingButton.NotifyExtended("So long, and thanks for all the fish", ThankYou_mEME, NotificationType.Error, 15000);
-            if(Debug) DebugStuff();
+            if (Debug) DebugStuff();
             Loading = false;
         }

+        private static System.Timers.Timer _t;
         private static void DebugStuff()
         {
-
-
+            SessionManager.Logged = true;
+            SessionManager.LoadingScreen = false;
+            _t = new System.Timers.Timer { Interval = 1000 };
+            _t.Elapsed += (_, __) =>
+            {
+                SessionManager.SetPlayerSt(10, SessionManager.CurrentPlayer.CurrentST + 100 > SessionManager.CurrentPlayer.MaxST ?
+                    0 : SessionManager.CurrentPlayer.CurrentST + 100);
+            };
+            SessionManager.CurrentPlayer.Class = Class.Brawler;
+            ClassWindowViewModel.Instance.CurrentClass = SessionManager.CurrentPlayer.Class;
+            SessionManager.SetSorcererElements(true, true, true);
+            SessionManager.SetPlayerMaxSt(10, 1000);
+            //SessionManager.SetPlayerSt(10, 1000);
+
+            _t.Start();
             //var i = 0;
             //while (i < 20000)
             //{


Narrow cert icons

Narrow cert icons

--- src/YuukoBlog/Views/Default/Shared/About.cshtml
+++ src/YuukoBlog/Views/Default/Shared/About.cshtml
@@ -4,7 +4,7 @@

ABOUT

-
Amamiya Yuuko

+
@ViewBag.Site

@@ -12,25 +12,7 @@

-
-

-

-
-

-

-

-

-
-

-

-
-

-

-
-

-

-


Skip native cpp compilation on Windows

Skip native cpp compilation on Windows

--- test/E2E/E2ETest.cs
+++ test/E2E/E2ETest.cs
@@ -68,6 +68,12 @@
         [Fact]
         public void TestDotnetCompileNativeCpp()
         {
+            // Skip this test on windows
+            if(SkipForOS(OSPlatform.Windows, "https://github.com/dotnet/cli/issues/335"))
+            {
+                return;
+            }
+
             TestSetup();

             TestRunCommand("dotnet", $"compile --native --cpp -o {OutputDirectory}");


minor: Eliminate more unnecessary code copying individual parameters for Vector3 copying in Scene - this is not necessary as Vector3 is a value type

--- OpenSim/Region/Framework/Scenes/Scene.cs
+++ OpenSim/Region/Framework/Scenes/Scene.cs
@@ -2110,8 +2110,8 @@
                 SceneObjectPart target = GetSceneObjectPart(RayTargetID);

                 Vector3 direction = Vector3.Normalize(RayEnd - RayStart);
-                Vector3 AXOrigin = new Vector3(RayStart.X, RayStart.Y, RayStart.Z);
-                Vector3 AXdirection = new Vector3(direction.X, direction.Y, direction.Z);
+                Vector3 AXOrigin = RayStart;
+                Vector3 AXdirection = direction;

                 if (target != null)
                 {
@@ -2127,19 +2127,19 @@
                     EntityIntersection ei = target.TestIntersectionOBB(NewRay, Quaternion.Identity, frontFacesOnly, FaceCenter);

                     // Un-comment out the following line to Get Raytrace results printed to the console.
-                   // m_log.Info("[RAYTRACERESULTS]: Hit:" + ei.HitTF.ToString() + " Point: " + ei.ipoint.ToString() + " Normal: " + ei.normal.ToString());
+                    // m_log.Info("[RAYTRACERESULTS]: Hit:" + ei.HitTF.ToString() + " Point: " + ei.ipoint.ToString() + " Normal: " + ei.normal.ToString());
                     float ScaleOffset = 0.5f;

                     // If we hit something
                     if (ei.HitTF)
                     {
-                        Vector3 scaleComponent = new Vector3(ei.AAfaceNormal.X, ei.AAfaceNormal.Y, ei.AAfaceNormal.Z);
+                        Vector3 scaleComponent = ei.AAfaceNormal;
                         if (scaleComponent.X != 0) ScaleOffset = scale.X;
                         if (scaleComponent.Y != 0) ScaleOffset = scale.Y;
                         if (scaleComponent.Z != 0) ScaleOffset = scale.Z;
                         ScaleOffset = Math.Abs(ScaleOffset);
-                        Vector3 intersectionpoint = new Vector3(ei.ipoint.X, ei.ipoint.Y, ei.ipoint.Z);
-                        Vector3 normal = new Vector3(ei.normal.X, ei.normal.Y, ei.normal.Z);
+                        Vector3 intersectionpoint = ei.ipoint;
+                        Vector3 normal = ei.normal;
                         // Set the position to the intersection point
                         Vector3 offset = (normal * (ScaleOffset / 2f));
                         pos = (intersectionpoint + offset);
@@ -2164,8 +2164,9 @@

                     if (ei.HitTF)
                     {
-                        pos = new Vector3(ei.ipoint.X, ei.ipoint.Y, ei.ipoint.Z);
-                    } else
+                        pos = ei.ipoint;
+                    }
+                    else
                     {
                         // fall back to our stupid functionality
                         pos = RayEnd;
@@ -3218,8 +3219,8 @@
             if (target != null && target2 != null)
             {
                 Vector3 direction = Vector3.Normalize(RayEnd - RayStart);
-                Vector3 AXOrigin = new Vector3(RayStart.X, RayStart.Y, RayStart.Z);
-                Vector3 AXdirection = new Vector3(direction.X, direction.Y, direction.Z);
+                Vector3 AXOrigin = RayStart;
+                Vector3 AXdirection = direction;

                 pos = target2.AbsolutePosition;
                 //m_log.Info("[OBJECT_REZ]: TargetPos: " + pos.ToString() + ", RayStart: " + RayStart.ToString() + ", RayEnd: " + RayEnd.ToString() + ", Volume: " + Util.GetDistanceTo(RayStart,RayEnd).ToString() + ", mag1: " + Util.GetMagnitude(RayStart).ToString() + ", mag2: " + Util.GetMagnitude(RayEnd).ToString());
@@ -3240,13 +3241,13 @@
                 if (ei.HitTF)
                 {
                     Vector3 scale = target.Scale;
-                    Vector3 scaleComponent = new Vector3(ei.AAfaceNormal.X, ei.AAfaceNormal.Y, ei.AAfaceNormal.Z);
+                    Vector3 scaleComponent = ei.AAfaceNormal;
                     if (scaleComponent.X != 0) ScaleOffset = scale.X;
                     if (scaleComponent.Y != 0) ScaleOffset = scale.Y;
                     if (scaleComponent.Z != 0) ScaleOffset = scale.Z;
                     ScaleOffset = Math.Abs(ScaleOffset);
-                    Vector3 intersectionpoint = new Vector3(ei.ipoint.X, ei.ipoint.Y, ei.ipoint.Z);
-                    Vector3 normal = new Vector3(ei.normal.X, ei.normal.Y, ei.normal.Z);
+                    Vector3 intersectionpoint = ei.ipoint;
+                    Vector3 normal = ei.normal;
                     Vector3 offset = normal * (ScaleOffset / 2f);
                     pos = intersectionpoint + offset;

@@ -3266,6 +3267,7 @@
                     {
                         copy = m_sceneGraph.DuplicateObject(localID, pos, target.GetEffectiveObjectFlags(), AgentID, GroupID, Quaternion.Identity);
                     }
+
                     if (copy != null)
                         EventManager.TriggerObjectAddedToScene(copy);
                 }
@@ -5098,7 +5100,7 @@
                 case PhysicsJointType.Ball:
                     {
                         Vector3 jointAnchor = PhysicsScene.GetJointAnchor(joint);
-                        Vector3 proxyPos = new Vector3(jointAnchor.X, jointAnchor.Y, jointAnchor.Z);
+                        Vector3 proxyPos = jointAnchor;
                         jointProxyObject.ParentGroup.UpdateGroupPosition(proxyPos); // schedules the entire group for a terse update
                     }
                     break;
@@ -5123,7 +5125,7 @@
                             jointErrorMessage(joint, "joint.TrackedBodyName is null, joint " + joint.ObjectNameInScene);
                         }

-                        Vector3 proxyPos = new Vector3(jointAnchor.X, jointAnchor.Y, jointAnchor.Z);
+                        Vector3 proxyPos = jointAnchor;
                         Quaternion q = trackedBody.RotationOffset * joint.LocalRotation;

                         jointProxyObject.ParentGroup.UpdateGroupPosition(proxyPos); // schedules the entire group for a terse update
@@ -5224,8 +5226,8 @@
                 y = Heightmap.Height - 1;

             Vector3 p0 = new Vector3(x, y, (float)Heightmap[(int)x, (int)y]);
-            Vector3 p1 = new Vector3(p0);
-            Vector3 p2 = new Vector3(p0);
+            Vector3 p1 = p0;
+            Vector3 p2 = p0;

             p1.X += 1.0f;
             if (p1.X < Heightmap.Width)


Move the health monitoring stuff where it will do some good

--- OpenSim/Region/Framework/Scenes/Scene.cs
+++ OpenSim/Region/Framework/Scenes/Scene.cs
@@ -1232,9 +1232,6 @@

                 while (!shuttingdown)
                     Update(-1);
-
-                m_lastUpdate = Util.EnvironmentTickCount();
-                m_firstHeartbeat = false;
             }
             finally
             {
@@ -1440,6 +1437,9 @@

                 if (maintc > 0)
                     Thread.Sleep(maintc);
+
+                m_lastUpdate = Util.EnvironmentTickCount();
+                m_firstHeartbeat = false;

                 // Optionally warn if a frame takes double the amount of time that it should.
 //                if (Util.EnvironmentTickCountSubtract(m_lastFrameTick, previousFrameTick) > (int)(MinFrameTime * 1000 * 2))


Update

Update

--- Orlandia2015/Views/Shared/_Layout.cshtml
+++ Orlandia2015/Views/Shared/_Layout.cshtml
@@ -23,6 +23,8 @@

@Html.ActionLink("Home", "Index", "Home")

@Html.ActionLink("Players", "Index", "Players")

+
@Html.ActionLink("Ranks", "Index", "Ranks")

+
@Html.ActionLink("Missions", "Index", "Missions")

                 @Html.Partial("_LoginPartial")


Minor update to 7 Days to Die hooks test [ci skip]

--- Oxide.Ext.SevenDays/Plugins/HooksTest.cs
+++ Oxide.Ext.SevenDays/Plugins/HooksTest.cs
@@ -62,7 +62,7 @@

         private void OnInitLogging()
         {
-            // Called from Assembly-CSharp/
+            // Called from Assembly-CSharp/??
             // No return behavior
             // Used internally by Oxide to start Unity logging
             HookCalled("OnInitLogging");
@@ -70,7 +70,7 @@

         private void OnServerInitialized()
         {
-            // Called from Assembly-CSharp/
+            // Called from Assembly-CSharp/??
             // No return behavior
             // Is called after the server startup has been completed and is awaiting connections
             HookCalled("OnServerInitialized");
@@ -78,7 +78,7 @@

         private void OnServerSave()
         {
-            // Called from Assembly-CSharp/
+            // Called from Assembly-CSharp/??
             // No return behavior
             // Is called before the server saves world and player data
             HookCalled("OnServerSave");
@@ -86,7 +86,7 @@

         private void OnServerQuit()
         {
-            // Called from Assembly-CSharp/
+            // Called from Assembly-CSharp/??
             // No return behavior
             // Is called before the server starts the shutdown sequence
             HookCalled("OnServerQuit");
@@ -94,10 +94,9 @@

         private void OnPlayerConnected(ClientInfo client)
         {
-            // Called from Assembly-CSharp/
+            // Called from Assembly-CSharp/??
             // No return behavior
             // Is called before the player object is created, but after the player has been approved to join the game
-            // Can get the connection from packet.connection
             HookCalled("OnPlayerConnected");
             PrintWarning("{0} has connected!", client.playerName);
             PrintToChat(client.playerName + " has connected!");
@@ -105,7 +104,7 @@

         private void OnPlayerDisconnected(ClientInfo client)
         {
-            // Called from Assembly-CSharp/
+            // Called from Assembly-CSharp/??
             // No return behavior
             // Is called before the player object is created, but after the player has been approved to join the game
             HookCalled("OnPlayerDisconnected");
@@ -115,13 +114,13 @@

         private void OnPlayerChat(string message, int team, string playerName)
         {
-            // Called from
+            // Called from Assembly-CSharp/??
             HookCalled("OnPlayerChat");
         }

         private void OnEntityDeath(cl0006 entity)
         {
-            // Called from
+            // Called from Assembly-CSharp/??
             HookCalled("OnEntityDeath");
             PrintWarning("{0} has died!", entity.EntityName);
             PrintToChat(entity.EntityName + " has died!");
@@ -129,7 +128,7 @@

         private void OnEntitySpawned(Entity entity)
         {
-            // Called from
+            // Called from Assembly-CSharp/??
             HookCalled("OnEntitySpawned");
             //PrintWarning("{0} has spawned!", entity._entity);
             //PrintToChat(entity._entity + " has spawned!");
@@ -137,13 +136,13 @@

         private void OnEntityHurt(cl0006 entity, DamageSource source)
         {
-            // Called from
+            // Called from Assembly-CSharp/??
             HookCalled("OnEntityHurt");
         }

         private void OnRunCommand(ConsoleCommand command, String arg, String[] args)
         {
-            // Called from
+            // Called from Assembly-CSharp/??
             HookCalled("OnRunCommand");
         }
     }


修复带后缀名时找不到文件的bug

修复带后缀名时找不到文件的bug


Completed draft of ElementCategory controller

--- PIWebSharp/PIWebSharp/PIRequestClient.cs
+++ PIWebSharp/PIWebSharp/PIRequestClient.cs
@@ -852,5 +852,48 @@
                 return _client.Execute<ResponseList<AFEventFrame>>(request).Data;
             }
         #endregion
+
+        #region "ElementCategory"
+
+            public ElementCategory GetElementCategory(string webID)
+            {
+                var request = new RestRequest("/elementcategories/{webId}");
+                request.AddUrlSegment("webId", WebID);
+
+                return _client.Execute<ElementCategory>(webID).Data;
+            }
+
+            public ElementCategory GetElementCategoryByPath(string path)
+            {
+                var request = new RestRequest("/elementcategories");
+                request.AddParameter("path", path);
+
+                return _client.Execute<ElementCategory>(request).Data;
+            }
+
+            public bool UpdateElementCategory(ElementCategory category)
+            {
+                var request = new RestRequest("/elementcategorie/{webId}");
+                request.AddUrlSegment("webId", category.WebID);
+                request.AddBody(category);
+
+                var statusCode = _client.Execute(request).StatusCode;
+
+                return ((int)statusCode == 204);
+            }
+
+            public bool DeleteElementCategory(string webID)
+            {
+                var request = new RestRequest("/elementcategories/{webId}");
+                request.AddUrlSegment("webId", webID);
+
+                var statusCode = _client.Execute(request).StatusCode;
+
+                return ((int)statusCode == 204)
+            }
+        #endregion
+
+        #region "ElementTemplate"
+        #endregion
     }
 }


Updated param attributes for GetCommandString

--- PInvoke/Shell32/ShObjIdl.IContextMenu.cs
+++ PInvoke/Shell32/ShObjIdl.IContextMenu.cs
@@ -249,7 +249,7 @@
 			/// <param name="pszName">The reference of the buffer to receive the null-terminated string being retrieved.</param>
 			/// <param name="cchMax">Size of the buffer, in characters, to receive the null-terminated string.</param>
 			/// <returns>If the method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.</returns>
-			void GetCommandString([In] IntPtr idCmd, GCS uType, [Optional] IntPtr pReserved, [Out] IntPtr pszName, uint cchMax);
+			void GetCommandString([In] IntPtr idCmd, GCS uType, [In, Optional] IntPtr pReserved, [Out] IntPtr pszName, uint cchMax);
 		}

 		///
@@ -319,7 +319,7 @@
 			/// <param name="pszName">The reference of the buffer to receive the null-terminated string being retrieved.</param>
 			/// <param name="cchMax">Size of the buffer, in characters, to receive the null-terminated string.</param>
 			/// <returns>If the method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.</returns>
-			new void GetCommandString([In] IntPtr idCmd, GCS uType, [Optional] IntPtr pReserved, [Out] IntPtr pszName, uint cchMax);
+			new void GetCommandString([In] IntPtr idCmd, GCS uType, [In, Optional] IntPtr pReserved, [Out] IntPtr pszName, uint cchMax);

 			/// Enables client objects of the IContextMenu interface to handle messages associated with owner-drawn menu items.
 			/// <param name="uMsg">
@@ -390,7 +390,7 @@
 			/// <param name="pszName">The reference of the buffer to receive the null-terminated string being retrieved.</param>
 			/// <param name="cchMax">Size of the buffer, in characters, to receive the null-terminated string.</param>
 			/// <returns>If the method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.</returns>
-			new void GetCommandString(IntPtr idCmd, GCS uType, IntPtr pReserved, IntPtr pszName, uint cchMax);
+			new void GetCommandString([In] IntPtr idCmd, GCS uType, [In, Optional] IntPtr pReserved, [Out] IntPtr pszName, uint cchMax);

 			/// Enables client objects of the IContextMenu interface to handle messages associated with owner-drawn menu items.
 			/// <param name="uMsg">


Invoke ShowMessageBox on UI Thread

Invoke ShowMessageBox on UI Thread

--- PartPreviewWindow/View3D/View3DWidget.cs
+++ PartPreviewWindow/View3D/View3DWidget.cs
@@ -1692,12 +1692,18 @@
             }
             catch (System.UnauthorizedAccessException)
             {
-                //Do something special when unauthorized?
-                StyledMessageBox.ShowMessageBox(null, "Oops! Unable to save changes.", "Unable to save");
+                UiThread.RunOnIdle((state) =>
+                {
+                    //Do something special when unauthorized?
+                    StyledMessageBox.ShowMessageBox(null, "Oops! Unable to save changes.", "Unable to save");
+                });
             }
             catch
             {
-                StyledMessageBox.ShowMessageBox(null, "Oops! Unable to save changes.", "Unable to save");
+                UiThread.RunOnIdle((state) =>
+                {
+                    StyledMessageBox.ShowMessageBox(null, "Oops! Unable to save changes.", "Unable to save");
+                });
             }
         }


Add PropertyClass documentation (closes #31)

--- Ndapi/PropertyClass.cs
+++ Ndapi/PropertyClass.cs
@@ -5,26 +5,74 @@

 namespace Ndapi
 {
+    /// <summary>
+    /// Represent a property class.
+    /// </summary>
     public class PropertyClass : NdapiObject
     {
+        /// <summary>
+        /// Creates a property class.
+        /// </summary>
+        /// <param name="module">Property class owner.</param>
+        /// <param name="name">Property class name.</param>
         public PropertyClass(FormModule module, string name)
         {
             Create(name, ObjectType.PropertyClass, module);
+        }
+
+        /// <summary>
+        /// Creates a property class.
+        /// </summary>
+        /// <param name="module">Property class owner.</param>
+        /// <param name="name">Property class name.</param>
+        public PropertyClass(MenuModule module, string name)
+        {
+            Create(name, ObjectType.PropertyClass, module);
+        }
+
+        /// <summary>
+        /// Creates a property class.
+        /// </summary>
+        /// <param name="group">Property class owner.</param>
+        /// <param name="name">Property class name.</param>
+        public PropertyClass(ObjectGroup group, string name)
+        {
+            Create(name, ObjectType.PropertyClass, group);
+        }
+
+        /// <summary>
+        /// Creates a property class.
+        /// </summary>
+        /// <param name="library">Property class owner.</param>
+        /// <param name="name">Property class name.</param>
+        public PropertyClass(LibraryModule library, string name)
+        {
+            Create(name, ObjectType.PropertyClass, library);
         }

         internal PropertyClass(ObjectSafeHandle handle) : base(handle)
         {
         }

+        /// <summary>
+        /// Gets or sets the comment.
+        /// </summary>
         public string Comment
         {
             get { return GetStringProperty(NdapiConstants.D2FP_COMMENT); }
             set { SetStringProperty(NdapiConstants.D2FP_COMMENT, value); }
         }

+        /// <summary>
+        /// Gets all the triggers attached to this property class.
+        /// </summary>
         public IEnumerable<Trigger> Triggers =>
             GetObjectList<Trigger>(NdapiConstants.D2FP_TRIGGER);

+        /// <summary>
+        /// Remove the specified property from the property class.
+        /// </summary>
+        /// <param name="propertyId">Property id (see <see cref="NdapiConstants"/>).</param>
         public void RemoveProperty(int propertyId)
         {
             var status = NativeMethods.d2fppcrp_RemoveProp(NdapiContext.Context, _handle, propertyId);


Formatting

Formatting

--- Test/ColumnTester.cs
+++ Test/ColumnTester.cs
@@ -3,58 +3,58 @@

 namespace SchemaZen.Tests;

-	public class ColumnTester {
+public class ColumnTester {

-		public class ScriptCreate {
-			[Fact]
-			public void int_no_trailing_space() {
-				var c = new Column("test", "int", false, null);
-				Assert.Equal("[test] [int] NOT NULL", c.ScriptCreate());
-			}
+	public class ScriptCreate {
+		[Fact]
+		public void int_no_trailing_space() {
+			var c = new Column("test", "int", false, null);
+			Assert.Equal("[test] [int] NOT NULL", c.ScriptCreate());
+		}

-			[Fact]
-			public void varchar_no_trailing_space() {
-				var c = new Column("test", "varchar", 10, false, null);
-				Assert.Equal("[test] [varchar](10) NOT NULL", c.ScriptCreate());
-			}
+		[Fact]
+		public void varchar_no_trailing_space() {
+			var c = new Column("test", "varchar", 10, false, null);
+			Assert.Equal("[test] [varchar](10) NOT NULL", c.ScriptCreate());
+		}

-			[Fact]
-			public void decimal_no_trailing_space() {
-				var c = new Column("test", "decimal", 4, 2, false, null);
-				Assert.Equal("[test] [decimal](4,2) NOT NULL", c.ScriptCreate());
-			}
+		[Fact]
+		public void decimal_no_trailing_space() {
+			var c = new Column("test", "decimal", 4, 2, false, null);
+			Assert.Equal("[test] [decimal](4,2) NOT NULL", c.ScriptCreate());
+		}

-			[Fact]
-			public void no_trailing_space_with_default() {
-				var c = new Column("test", "int", true, new Default("df_test", "0", false));
-				var lines = c.ScriptCreate()
-					.Split(new[] { Environment.NewLine }, StringSplitOptions.None);
-				Assert.Equal("[test] [int] NULL", lines[0]);
-				Assert.Equal("      CONSTRAINT [df_test] DEFAULT 0", lines[1]);
-			}
+		[Fact]
+		public void no_trailing_space_with_default() {
+			var c = new Column("test", "int", true, new Default("df_test", "0", false));
+			var lines = c.ScriptCreate()
+				.Split(new[] { Environment.NewLine }, StringSplitOptions.None);
+			Assert.Equal("[test] [int] NULL", lines[0]);
+			Assert.Equal("      CONSTRAINT [df_test] DEFAULT 0", lines[1]);
+		}

-			[Fact]
-			public void no_trailing_space_with_no_name_default() {
-				var c = new Column("test", "int", true, new Default("df_ABCDEF", "0", true));
-				var lines = c.ScriptCreate()
-					.Split(new[] { Environment.NewLine }, StringSplitOptions.None);
-				Assert.Equal("[test] [int] NULL", lines[0]);
-				Assert.Equal("       DEFAULT 0", lines[1]);
-			}
+		[Fact]
+		public void no_trailing_space_with_no_name_default() {
+			var c = new Column("test", "int", true, new Default("df_ABCDEF", "0", true));
+			var lines = c.ScriptCreate()
+				.Split(new[] { Environment.NewLine }, StringSplitOptions.None);
+			Assert.Equal("[test] [int] NULL", lines[0]);
+			Assert.Equal("       DEFAULT 0", lines[1]);
+		}

-			[Fact]
-			public void computed_column() {
-				var c = new Column("test", "int", false, null) { ComputedDefinition = "(A + B)" };
+		[Fact]
+		public void computed_column() {
+			var c = new Column("test", "int", false, null) { ComputedDefinition = "(A + B)" };

-				Assert.Equal("[test] AS (A + B)", c.ScriptCreate());
-			}
+			Assert.Equal("[test] AS (A + B)", c.ScriptCreate());
+		}

-			[Fact]
-			public void computed_column_persisted() {
-				var c = new Column("test", "int", false, null)
-					{ ComputedDefinition = "(A + B)", Persisted = true };
+		[Fact]
+		public void computed_column_persisted() {
+			var c = new Column("test", "int", false, null)
+				{ ComputedDefinition = "(A + B)", Persisted = true };

-				Assert.Equal("[test] AS (A + B) PERSISTED", c.ScriptCreate());
-			}
+			Assert.Equal("[test] AS (A + B) PERSISTED", c.ScriptCreate());
 		}
 	}
+}


Save torrent files to top folder if there are small uploads.

--- NyaaConsole/RssFeed.cs
+++ NyaaConsole/RssFeed.cs
@@ -16,6 +16,9 @@
     [JsonObject]
     class RssFeed
     {
+        [JsonIgnore]
+        public const int SaveToTopFolder = 3;
+
         [JsonIgnore]
         private static Logger logger = LogManager.GetCurrentClassLogger();

@@ -50,8 +53,33 @@
             }
             logger.Info("Retrieve RSS successful: {0}+{1}", Config.KeywordPrefix, Keyword);

-            // create download folder
-            string dlFolder = String.Format(@".\{0}\{1}", Config.FolderPrefix, DownloadFolder);
+            // count download item
+            int downloadItem = 0;
+            foreach (SyndicationItem item in RssFeed.Items)
+            {
+                if (item.Links.Count > 0)
+                {
+                    if (LastDownload < item.PublishDate)
+                    {
+                        downloadItem++;
+                    }
+                }
+            }
+
+            // build download folder URL
+            string dlFolder;
+
+            if (downloadItem <= SaveToTopFolder)
+            {
+                // if there is zero, one or two item(s), download to top folder;
+                dlFolder = String.Format(@".\{0}", Config.FolderPrefix);
+            }
+            else
+            {
+                // there is two or more items, create folder...
+                dlFolder = String.Format(@".\{0}\{1}", Config.FolderPrefix, DownloadFolder);
+            }
+
             try
             {
                 // No need to check path existence because CreateDirectory does it.


test TargetClass.JustMe()

test TargetClass.JustMe()

--- Tests/WeaverTests.cs
+++ Tests/WeaverTests.cs
@@ -4,6 +4,7 @@
 using Mono.Cecil;
 using NUnit.Framework;
 using System.Diagnostics;
+using Microsoft.CSharp.RuntimeBinder;

 [TestFixture]
 public class WeaverTests
@@ -38,6 +39,16 @@
         assembly = Assembly.LoadFile(newAssemblyPath);
         targetClass = assembly.GetType("TargetClass");
         targetStruct = assembly.GetType("TargetStruct");
+    }
+
+    [Test]
+    public void ValidateJustMe()
+    {
+        dynamic instance = Activator.CreateInstance(targetClass);
+
+        Assert.AreEqual(instance, instance.JustMe());
+
+        Assert.Throws<RuntimeBinderException>(() => instance.JustMeDutiful());
     }

     [Test]


★マーカーインターフェイス＋通常インターフェイス復帰目印

★マーカーインターフェイス＋通常インターフェイス復帰目印

--- Project/Test/MapIInstanceGenerateTest.cs
+++ Project/Test/MapIInstanceGenerateTest.cs
@@ -76,3 +76,4 @@
         //@@@Generic interface
     }
 }
+


Implement tag and layer options

Implement tag and layer options

--- OnCollisionActivate.cs
+++ OnCollisionActivate.cs
@@ -68,30 +68,89 @@

         // todo add doc
         public void Activate(RaycastHit hitInfo) {
-            var hitGOTag = hitInfo.transform.gameObject.tag;
-            var hitGoLayer = hitInfo.transform.gameObject.layer;

-            foreach (var obj in ObjectsToEnable) {
-                switch (obj.TagOption) {
-                    case TagOptions.Include:
-                        if (hitGOTag != obj.Tag) {
-                            break;
-                        }
-                        obj.ObjToEnable.SetActive(true);
-                        break;
+            foreach (var objectSlot in ObjectsToEnable) {
+                HandleActivateGameObject(objectSlot, hitInfo);
+                //switch (obj.TagOption) {
+                //    case TagOptions.Include:
+                //        if (hitGOTag != obj.Tag) {
+                //            break;
+                //        }
+                //        obj.ObjToEnable.SetActive(true);
+                //        break;

-                    case TagOptions.Exclude:
-                        // Don't enable target object when hit a GO with
-                        // excluded tag.
-                        if (hitGOTag == obj.Tag) {
-                            break;
-                        }
-                        obj.ObjToEnable.SetActive(true);
-                        break;
-                }
+                //    case TagOptions.Exclude:
+                //        // Don't enable target object when hit a GO with
+                //        // excluded tag.
+                //        if (hitGOTag == obj.Tag) {
+                //            break;
+                //        }
+                //        obj.ObjToEnable.SetActive(true);
+                //        break;
+                //}
             }

             GameObjectsActivatedCallback.Invoke();
+        }
+
+        private void HandleActivateGameObject(
+            GameObjectSlot gameObjectSlot,
+            RaycastHit hitInfo) {
+
+            HandleActivateByTag(gameObjectSlot, hitInfo);
+            HandleActivateByLayer(gameObjectSlot, hitInfo);
+        }
+
+        private void HandleActivateByLayer(
+            GameObjectSlot gameObjectSlot,
+            RaycastHit hitInfo) {
+
+            if (gameObjectSlot.IncludeExcludeType != InludeExcludeType.Layer) {
+                return;
+            }
+
+            var hitGoLayer = hitInfo.transform.gameObject.layer;
+
+            // Handle include/exclude option.
+            switch (gameObjectSlot.TagOption) {
+                case TagOptions.Include:
+                    // Check layer.
+                    if (hitGoLayer == gameObjectSlot.Layer) {
+                        gameObjectSlot.ObjToEnable.SetActive(true);
+                    }
+                    break;
+                case TagOptions.Exclude:
+                    if (hitGoLayer != gameObjectSlot.Layer) {
+                        gameObjectSlot.ObjToEnable.SetActive(true);
+                    }
+                    break;
+            }
+        }
+
+        private void HandleActivateByTag(
+            GameObjectSlot gameObjectSlot,
+            RaycastHit hitInfo) {
+
+            if (gameObjectSlot.IncludeExcludeType != InludeExcludeType.Tag) {
+                return;
+            }
+
+            var hitGOTag = hitInfo.transform.gameObject.tag;
+
+            // Handle include/exclude option.
+            switch (gameObjectSlot.TagOption) {
+                case TagOptions.Include:
+                    // Check tag.
+                    if (hitGOTag == gameObjectSlot.Tag) {
+                        gameObjectSlot.ObjToEnable.SetActive(true);
+                    }
+                    break;
+                case TagOptions.Exclude:
+                    if (hitGOTag != gameObjectSlot.Tag) {
+                        gameObjectSlot.ObjToEnable.SetActive(true);
+                    }
+                    break;
+            }
         }

         #endregion METHODS


Fixed a bug where Discovery timeout failed to trigger. The exception being raised for a discovery timeout event wasn't properly checking the base exception type.

--- Open.Nat/NatUtility.cs
+++ Open.Nat/NatUtility.cs
@@ -180,7 +180,7 @@
             var task = Task.Factory.StartNew(SearchAndListen, TaskCreationOptions.LongRunning);
             task.ContinueWith(o =>
                 {
-                    var exceptionType = task.Exception.GetType();
+                    var exceptionType = task.Exception.GetBaseException().GetType();
                     if (exceptionType == typeof(TimeoutException) && DiscoveryTimedout != null)
                     {
                         DiscoveryTimedout(typeof (NatUtility), new DiscoveryTimeoutEventArgs());


[Core] re-add file logger

[Core] re-add file logger

--- Oxide.Core/OxideMod.cs
+++ Oxide.Core/OxideMod.cs
@@ -143,11 +143,9 @@
             RegisterLibrarySearchPath(Path.Combine(ExtensionDirectory, IntPtr.Size == 8 ? "x64" : "x86"));

             // Create the loggers
-            //filelogger = new RotatingFileLogger();
-            //filelogger.Directory = LogDirectory;
             RootLogger = new CompoundLogger();
+            RootLogger.AddLogger(new RotatingFileLogger { Directory = LogDirectory });
             if (debugCallback != null) RootLogger.AddLogger(new CallbackLogger(debugCallback));
-            //RootLogger.AddLogger(filelogger);

             // Log Oxide core loading
             LogInfo("Loading Oxide core v{0}...", Version);


* expand the number of encodings recognised by HttpRequest

--- Net/HTTPRequest.cs
+++ Net/HTTPRequest.cs
@@ -55,7 +55,11 @@
                 { "ascii", Encoding.ASCII },
                 { "us-ascii", Encoding.ASCII },
                 { "utf-8", Encoding.UTF8 },
-                { "utf8", Encoding.UTF8 }
+                { "utf8", Encoding.UTF8 },
+                { "iso-8859-1", Encoding.GetEncoding("ISO-8859-1") },
+                { "latin-1", Encoding.GetEncoding("ISO-8859-1") },
+                { "windows-1252", Encoding.GetEncoding(1252) },
+                { "cp-1252", Encoding.GetEncoding(1252) }
             };

         /// <summary>


use Comparer<T> instead of IComparer<T> for defaults

--- PermuteUtil/Permute.cs
+++ PermuteUtil/Permute.cs
@@ -9,7 +9,7 @@
     {
         public static bool NextPermutation<Datum>(ref List<Datum> data) where Datum : IComparable
         {
-            return NextPermutation(ref data, new DefaultComparer<Datum>());
+            return NextPermutation(ref data, Comparer<Datum>.Default);
         }

         public static bool NextPermutation<Datum>(ref List<Datum> data, IComparer<Datum> comparer)
@@ -38,47 +38,19 @@

         public static bool PreviousPermutation<Datum>(ref List<Datum> data) where Datum : IComparable
         {
-            return PreviousPermutation(ref data, new DefaultComparer<Datum>());
+            return PreviousPermutation(ref data, Comparer<Datum>.Default);
         }

         public static bool PreviousPermutation<Datum>(ref List<Datum> data, IComparer<Datum> comparer)
         {
-            return NextPermutation(ref data, makeReverseComparer(comparer));
+            return NextPermutation(ref data, new ReverseComparer<Datum>());
         }

-        private static IComparer<Datum> makeReverseComparer<Datum>(IComparer<Datum> comparer)
+        class ReverseComparer<Datum> : Comparer<Datum>
         {
-            return new ReverseAnotherComparer<Datum>(comparer);
-        }
-
-        class DefaultComparer<Datum> : IComparer<Datum> where Datum : IComparable
-        {
-            int IComparer<Datum>.Compare(Datum x, Datum y)
+            override public int Compare(Datum x, Datum y)
             {
-                return x.CompareTo(y);
-            }
-        }
-
-        class ReverseComparer<Datum> : IComparer<Datum> where Datum : IComparable
-        {
-            int IComparer<Datum>.Compare(Datum x, Datum y)
-            {
-                return y.CompareTo(x);
-            }
-        }
-
-        class ReverseAnotherComparer<Datum> : IComparer<Datum>
-        {
-            private IComparer<Datum> comparer;
-
-            public ReverseAnotherComparer(IComparer<Datum> comparer)
-            {
-                this.comparer = comparer;
-            }
-
-            int IComparer<Datum>.Compare(Datum x, Datum y)
-            {
-                return comparer.Compare(y, x);
+                return Comparer<Datum>.Default.Compare(y, x);
             }
         }
     }


Don't show autoblankers if the row/column is (already) invalid.

--- Picross/AutoBlanker.cs
+++ Picross/AutoBlanker.cs
@@ -4,13 +4,17 @@
 {
     class AutoBlanker : Solver
     {
-        // TODO: if the whole column is invalid already before we start, we probably don't want to show anything!
         private AutoBlanker(Puzzle puzzle, Puzzle puzzleForNumbers)
             : base(puzzle, puzzleForNumbers) { }

         public static bool[] GetRow(Puzzle puzzle, Puzzle puzzleForNumbers, int y) {
             AutoBlanker solver = new AutoBlanker(null, puzzleForNumbers);
             bool[] result = new bool[puzzle.Width];
+
+            // If the whole row is invalid already before we start, we don't show anything.
+            solver.Puzzle = puzzle.Clone();
+            if (!solver.canFindValidRowConfiguration(0, y))
+                return result;

             // This has some performance problems, you are (have the risk of) bruteforcing all solutions #width times, rather than once.
             // (Every time it tries to find a configuration for the same row remember).
@@ -30,6 +34,11 @@
         public static bool[] GetCol(Puzzle puzzle, Puzzle puzzleForNumbers, int x) {
             AutoBlanker solver = new AutoBlanker(null, puzzleForNumbers);
             bool[] result = new bool[puzzle.Height];
+
+            // If the whole column is invalid already before we start, we don't show anything.
+            solver.Puzzle = puzzle.Clone();
+            if (!solver.canFindValidColConfiguration(x, 0))
+                return result;

             // This has some performance problems, you are (have the risk of) bruteforcing all solutions #height times, rather than once.
             // (Every time it tries to find a configuration for the same column remember).
@@ -68,7 +77,7 @@
                     return true;

             // None of the values worked, so start backtracking
-            this.Puzzle[x,y] = Puzzle.Unknown;
+            this.Puzzle[x, y] = Puzzle.Unknown;
             return false;
         }


minor change to getting member info

minor change to getting member info

--- Platforms/Component.cs
+++ Platforms/Component.cs
@@ -18,10 +18,7 @@
         protected IWebElement FindElement(string elementName)
         {
             IWebElement element = null;
-            MemberInfo member = GetType()
-                .GetMember(elementName.ToPascalCase(), BindingFlags.NonPublic | BindingFlags.Instance).FirstOrDefault();
-            if (member == null)
-                throw new NoSuchElementException(elementName + " is not found");
+            var member = GetMemberInfo(elementName);

             var property = member as PropertyInfo;
             if (property != null)
@@ -48,13 +45,19 @@
             return null;
         }

+        protected MemberInfo GetMemberInfo(string elementName)
+        {
+            MemberInfo member = GetType()
+                .GetMember(elementName.ToPascalCase(), BindingFlags.NonPublic | BindingFlags.Instance).FirstOrDefault();
+            if (member == null)
+                throw new NoSuchElementException(elementName + " is not found");
+            return member;
+        }
+
         protected IList<IWebElement> FindElements(string collectionName)
         {
             IList<IWebElement> elements = null;
-            MemberInfo member = GetType()
-                .GetMember(collectionName.ToPascalCase(), BindingFlags.NonPublic | BindingFlags.Instance).FirstOrDefault();
-            if (member == null)
-                throw new NoSuchElementException(collectionName + " is not found");
+            MemberInfo member = GetMemberInfo(collectionName);

             var property = member as PropertyInfo;
             if (property != null)


added checks to the constructor, consistent with R

--- ACQ.Math/Regression/Lowess.cs
+++ ACQ.Math/Regression/Lowess.cs
@@ -25,20 +25,22 @@
     *  https://www.R-project.org/Licenses/
     */
     /// <summary>
-    /// Lowess regression, adapted from R source code,
+    /// Lowess regression, adapted from R source code,http://svn.r-project.org/R/trunk/src/library/stats/src/lowess.c
+    /// it attempts to faithfully reporoduce R code without any "improvments"
     /// </summary>
     public class Lowess
     {
         ACQ.Math.Interpolation.LinearInterpolation m_interpolator;

         /// <summary>
-        /// Construct Loess
+        /// Construct Lowess
         /// </summary>
         /// <param name="x"></param>
         /// <param name="y"></param>
         /// <param name="nsteps"> number of robustifying iterations which should be performed. (default = 3) </param>
-        /// <param name="span">smoother span. default(2/3) This gives the proportion of points in the plot which influence the smooth at each value. Larger values give more smoothness</param>
-        public Lowess(double[] x, double[] y, double span = 2.0/3.0, int nsteps = 3, double delta = 0.001)
+        /// <param name="span">smoother span [0, 1], default = 2/3. This gives the proportion of points in the plot which influence the smooth at each value. Larger values give more smoothness</param>
+        /// <param name="delta">Defaults to 1/100th of the range of x</param>
+        public Lowess(double[] x, double[] y, double span = 2.0/3.0, int nsteps = 3, double delta = 0.0)
         {
             if (x == null || y == null)
                 throw new ArgumentNullException("Lowess input arrays can not be null");
@@ -49,10 +51,20 @@
             if (x.Length < 2)
                 throw new ArgumentException("Lowess input arrays should have at least 2 nodes");

+            if (nsteps < 0)
+                throw new ArgumentException("Lowess nsteps must be >= 0");
+
+            //the code below actually will work for any value of span (because it checks later), but R checks for negative span, so we as well for consistency
+            if (span < 0)
+                throw new ArgumentException("Lowess span must be > 0");
+
+            int n = x.Length;
+
+            //check that x is sorted
             bool ordered = true;
-            for (int i = 0; i < x.Length - 1; i++)
-            {
-                if (x[i + 1] < x[i])
+            for (int i = 0; i < n - 1; i++)
+            {
+                if (x[i + 1] < x[i]) //same values are allowed
                 {
                     ordered = false;
                     break;
@@ -71,27 +83,66 @@
                 Array.Sort<double, double>(x_in, y_in);
             }

-            int n = x.Length;
+            if (delta <= 0.0)
+            {
+                delta = 0.01 * (x_in[n - 1] - x_in[0]); //same default as in R
+            }

             double[] ys = new double[n];
-            double[] rw = new double[n];
-            double[] res= new double[n];
-
-            clowess(x_in, y_in, span, nsteps, delta, ys, rw, res);
-
-            m_interpolator = new ACQ.Math.Interpolation.LinearInterpolation(x_in, ys);
+
+            clowess(x_in, y_in, ys, span, nsteps, delta); //this is main r - function
+
+            //check that all values of x_in are uniques
+            bool unique = true;
+            for (int i = 0; i < n - 1; i++)
+            {
+                if (x[i + 1] == x[i]) //same values are allowed
+                {
+                    unique = false;
+                    break;
+                }
+            }
+
+            if (unique)
+            {
+                m_interpolator = new ACQ.Math.Interpolation.LinearInterpolation(x_in, ys);
+            }
+            else
+            {
+                List<double> xu = new List<double>(n);
+                List<double> yu = new List<double>(n);
+
+                xu.Add(x_in[0]);
+                yu.Add(ys[0]);
+
+                double prev_x = x_in[0];
+
+                for (int i = 1; i < n; i++)
+                {
+                    if(x_in[i] > prev_x)
+                    {
+                        xu.Add(x_in[i]);
+                        yu.Add(ys[i]);
+                        prev_x = x_in[i];
+                    }
+                }
+                m_interpolator = new ACQ.Math.Interpolation.LinearInterpolation(xu.ToArray(), yu.ToArray());
+            }
         }

         public double Eval(double xp)
         {
-            return m_interpolator.Eval(xp);
+            double result = m_interpolator.Eval(xp);
+            return result;
         }

-        private static void lowest(double[] x, double[] y, double xs, out double ys, int nleft, int nright, double[] w, bool userw, double[] rw, out bool ok)
+        #region R routines
+        private static bool lowest(double[] x, double[] y, double xs, out double ys, int nleft, int nright, double[] w, bool userw, double[] rw)
         {
             int n = x.Length;
             int nrt, j;
             double a, b, c, h, h1, h9, r, range;
+            bool success = false;

             range = x[n-1] - x[0];
             h = System.Math.Max(xs - x[nleft], x[nright] - xs);
@@ -131,11 +182,11 @@
             nrt = j - 1;
             if (a <= 0.0)
             {
-                ok = false;
+                success = false;
             }
             else
             {
-                ok = true;
+                success = true;
             }

             // weighted least squares
@@ -178,21 +229,25 @@
             {
                 ys += w[j] * y[j];
             }
+
+            return success;
         }

-        private static void clowess(double[] x, double[] y, double span, int nsteps, double delta, double[] ys, double[] rw, double[] res)
+        private static void clowess(double[] x, double[] y, double[] ys, double f, int nsteps, double delta)
         {
             int i, j, last, m1, m2, nleft, nright, ns;
-            bool ok;
             double alpha, c1, c9, cmad, cut, d1, d2, denom, r;
             int n = x.Length; // n >= 2

+            double[] rw = new double[n];
+            double[] res = new double[n];
+
             // at least two, at most n points
-            ns = System.Math.Max(2, System.Math.Min(n, (int)(span * n)));
+            ns = System.Math.Max(2, System.Math.Min(n, (int)(f * n + 1.0e-7)));

             // robustness iterations
-            for (int iter = 0; iter < nsteps; iter++)
+            for (int iter = 0; iter <= nsteps; iter++)
             {
                 nleft = 0;
                 nright = ns - 1;
@@ -219,8 +274,9 @@

                     // fitted value at x[i]
                     double y_temp;
-                    lowest(x, y, x[i], out y_temp, nleft, nright, res, iter > 0, rw, out ok);
-                    if (ok)
+                    bool success = lowest(x, y, x[i], out y_temp, nleft, nright, res, iter > 0, rw);
+
+                    if (success)
                     {
                         ys[i] = y_temp;
                     }
@@ -281,7 +337,7 @@
                 sc /= n;

                 // compute robustness weights, except last time
-                if (iter < nsteps - 1)
+                if (iter < nsteps)
                 {
                     for (i = 0; i < n; i++)
                     {
@@ -322,6 +378,7 @@
                 }
             }
         }
+        #endregion

     }
 }


renamed variables for future maintenance and readability

--- amazon/Solution.cs
+++ amazon/Solution.cs
@@ -32,11 +32,11 @@
         {
             rn = rn.ToUpperInvariant();
             int sum = 0;
-            char[] numerals;
-            var lt=BuildLookupTable(out numerals);
+            char[] baseNumerals;
+            var numeralValue=BuildLookupTable(out baseNumerals);

-            string re = MakeNumberParser(numerals);
-            Regex regex = new Regex(re, RegexOptions.IgnoreCase | RegexOptions.Compiled);
+            string expr = MakeNumberParser(baseNumerals);
+            Regex regex = new Regex(expr, RegexOptions.IgnoreCase | RegexOptions.Compiled);
             if (string.IsNullOrWhiteSpace(rn) || !regex.IsMatch(rn)) throw new Exception("Invalid Roman Numeral"); //TODO: localize this text.

             MatchCollection mc = regex.Matches(rn);
@@ -48,16 +48,17 @@
                     switch (v.Length)
                     {
                         case 0: /*skip the item, group with no matches. safe to ignore.*/ break;
-                        case 1: sum += lt[v[0]]; break;
+                        case 1: sum += numeralValue[v[0]]; break;
                         default: // subtractive or just stacked, handles an arbitrary number of numerals
                             {
-                                var vv = v.ToCharArray().ToList();
+                                var numerals = v.ToCharArray().ToList();
                                 // sort acending according to the lookup table.
-                                vv.Sort(new Comparison<char>((l, r) => lt[l] - lt[r]));
+                                numerals.Sort(new Comparison<char>((l, r) => numeralValue[l] - numeralValue[r]));
                                 // subtract/add the first numeral.
-                                sum += (lt[vv[0]] < lt[vv[1]]) ? -lt[vv[0]] : lt[vv[0]];
+                                // if the first item is less than the second it's a subtraction. Otherwise it's an add.
+                                sum += (numeralValue[numerals[0]] < numeralValue[numerals[1]]) ? -numeralValue[numerals[0]] : numeralValue[numerals[0]];
                                 // add the remaining numerals
-                                sum += lt[vv[1]] * (vv.Count - 1);
+                                sum += numeralValue[numerals[1]] * (numerals.Count - 1);
                             }
                             break;
                     }
@@ -68,13 +69,13 @@

         private static Dictionary<char, int> BuildLookupTable(out char[] numerals)
         {
-            var lt= new Dictionary<char, int>();
+            var lookupTable= new Dictionary<char, int>();
             // this implementation assumes the 5's-10s pattern will repeat when/if the alphabet changes.
-            int[] vals = { 1, 5, 10, 50, 100, 500, 1000 };
+            int[] vals =         {  1,   5,  10,  50,  100, 500, 1000 };
             numerals = new char[]{ 'I', 'V', 'X', 'L', 'C', 'D', 'M' };
             // build the base value lookup table lt
-            for (int i = 0; i < vals.Length; i++) lt.Add(numerals[i], vals[i]);
-            return lt;
+            for (int i = 0; i < vals.Length; i++) lookupTable.Add(numerals[i], vals[i]);
+            return lookupTable;
         }

         private static string MakeNumberParser(char[] N)


Only lock memoizedRequests around operations that use it

--- Akavache/PersistentBlobCache.cs
+++ Akavache/PersistentBlobCache.cs
@@ -141,35 +141,37 @@

             // NB: Since FetchOrWriteBlobFromDisk is guaranteed to not block,
             // we never sit on this lock for any real length of time
+            var err = default(AsyncSubject<byte[]>);
             lock (memoizedRequests)
             {
                 if (disposed) return Observable.Throw<Unit>(new ObjectDisposedException("PersistentBlobCache"));

                 memoizedRequests.Invalidate(key);
-                var err = memoizedRequests.Get(key, data);
-
-                // If we fail trying to fetch/write the key on disk, we want to
-                // try again instead of replaying the same failure
-                err.LogErrors("Insert").Subscribe(
-                    x => CacheIndex[key] = new CacheIndexEntry(Scheduler.Now, absoluteExpiration),
-                    ex => Invalidate(key));
-
-                return err.Select(_ => Unit.Default);
-            }
+                err = memoizedRequests.Get(key, data);
+            }
+
+            // If we fail trying to fetch/write the key on disk, we want to
+            // try again instead of replaying the same failure
+            err.LogErrors("Insert").Subscribe(
+                x => CacheIndex[key] = new CacheIndexEntry(Scheduler.Now, absoluteExpiration),
+                ex => Invalidate(key));
+
+            return err.Select(_ => Unit.Default);
         }

         public IObservable<byte[]> GetAsync(string key)
         {
-            lock (memoizedRequests)
-            {
-                if (disposed) return Observable.Throw<byte[]>(new ObjectDisposedException("PersistentBlobCache"));
-
-                if (IsKeyStale(key))
-                {
-                    Invalidate(key);
-                    return ObservableThrowKeyNotFoundException(key);
-                }
-
+            if (disposed) return Observable.Throw<byte[]>(new ObjectDisposedException("PersistentBlobCache"));
+
+            if (IsKeyStale(key))
+            {
+                Invalidate(key);
+                return ObservableThrowKeyNotFoundException(key);
+            }
+
+            var ret = default(AsyncSubject<byte[]>);
+            lock (memoizedRequests)
+            {
                 // There are three scenarios here, and we handle all of them
                 // with aplomb and elegance:
                 //
@@ -185,15 +187,15 @@
                 //    this case, FetchOrWriteBlobFromDisk will be called which
                 //    will immediately return an AsyncSubject representing the
                 //    queued disk read.
-                var ret = memoizedRequests.Get(key);
-
-                // If we fail trying to fetch/write the key on disk, we want to
-                // try again instead of replaying the same failure
-                ret.LogErrors("GetAsync")
-                   .Subscribe(x => {}, ex => Invalidate(key));
-
-                return ret;
-            }
+                ret = memoizedRequests.Get(key);
+            }
+
+            // If we fail trying to fetch/write the key on disk, we want to
+            // try again instead of replaying the same failure
+            ret.LogErrors("GetAsync")
+               .Subscribe(x => {}, ex => Invalidate(key));
+
+            return ret;
         }

         bool IsKeyStale(string key)
@@ -215,11 +217,8 @@

         public IEnumerable<string> GetAllKeys()
         {
-            lock (memoizedRequests)
-            {
-                if (disposed) throw new ObjectDisposedException("PersistentBlobCache");
-                return CacheIndex.Keys.ToArray();
-            }
+            if (disposed) throw new ObjectDisposedException("PersistentBlobCache");
+            return CacheIndex.Keys.ToArray();
         }

         public IObservable<Unit> Invalidate(string key)
@@ -229,10 +228,10 @@
                 if (disposed) return Observable.Throw<Unit>(new ObjectDisposedException("PersistentBlobCache"));
                 this.Log().Debug("Invalidating {0}", key);
                 memoizedRequests.Invalidate(key);
-
-                CacheIndexEntry dontcare;
-                CacheIndex.TryRemove(key, out dontcare);
-            }
+            }
+
+            CacheIndexEntry dontcare;
+            CacheIndex.TryRemove(key, out dontcare);

             var path = GetPathForKey(key);
             var ret = opQueue.EnqueueObservableOperation(key, () =>


Minor formatting.

Minor formatting.

--- PsFtpProvider/Cache.cs
+++ PsFtpProvider/Cache.cs
@@ -292,7 +292,7 @@
 		private FtpClient client;

 		public CacheDirectoryNode(FtpListItem item, CacheDirectoryNode parent, FtpClient client)
-			:base(item, parent)
+			: base(item, parent)
 		{
 			this.client = client;


Fixes incorrect equals check

Fixes incorrect equals check

--- Amplified.CSharp/src/Maybe.cs
+++ Amplified.CSharp/src/Maybe.cs
@@ -80,7 +80,7 @@
         public bool Equals(Maybe<T> other)
         {
             return (IsNone && other.IsNone) ||
-                   (IsSome && IsSome && EqualityComparer<T>.Default.Equals(_value, other._value));
+                   (IsSome && other.IsSome && EqualityComparer<T>.Default.Equals(_value, other._value));
         }

         public override bool Equals(object obj)
@@ -170,4 +170,4 @@
             return value == null ? Maybe<T>.None : new Maybe<T>(value);
         }
     }
-}+}


Twitter_About label Size enlarge

Twitter_About label Size enlarge

--- App/Form/MainForm.Designer.cs
+++ App/Form/MainForm.Designer.cs
@@ -308,7 +308,7 @@
             this.label_TwitterAbout.Font = new System.Drawing.Font("Malgun Gothic", 8F);
             this.label_TwitterAbout.Location = new System.Drawing.Point(13, 61);
             this.label_TwitterAbout.Name = "label_TwitterAbout";
-            this.label_TwitterAbout.Size = new System.Drawing.Size(379, 41);
+            this.label_TwitterAbout.Size = new System.Drawing.Size(407, 50);
             this.label_TwitterAbout.TabIndex = 0;
             this.label_TwitterAbout.Text = "매칭이 됐을 시 입력된 트위터 계정으로 멘션을 보내 해당 사실을 알립니다.\r\n원하는 돌발이 발생했을 시에도 멘션을 보내 해당 사실을 알립니다.\r\n" +
     "계정명 입력시 앞의 @ 표시는 제외하고 순수 계정명만 입력해주세요.";


(Xp3Stream): dispose of segments enumerator.

--- ArcFormats/KiriKiri/ArcXP3.cs
+++ ArcFormats/KiriKiri/ArcXP3.cs
@@ -827,9 +827,11 @@
         {
             if (!disposed)
             {
-                if (disposing && null != m_stream)
-                {
-                    m_stream.Dispose();
+                if (disposing)
+                {
+                    if (null != m_stream)
+                        m_stream.Dispose();
+                    m_segment.Dispose();
                 }
                 disposed = true;
                 base.Dispose (disposing);


(Ai6Win): check for invalid chars to reduce false positives.

--- ArcFormats/Silky/ArcAi6Win.cs
+++ ArcFormats/Silky/ArcAi6Win.cs
@@ -69,7 +69,7 @@
                 for (int j = 0; j < name_length; ++j)
                 {
                     name_buffer[j] -= key--;
-                    if (name_buffer[j]  < 0x20)
+                    if (VFS.InvalidFileNameChars.Contains ((char)name_buffer[j])) // XXX
                         return null;
                 }
                 var name = Encodings.cp932.GetString (name_buffer, 0, name_length);


일단 주석처리 (해결에 시간이 조금 걸릴 듯)

일단 주석처리 (해결에 시간이 조금 걸릴 듯)

--- App/Network/Network.Analyser.cs
+++ App/Network/Network.Analyser.cs
@@ -168,11 +168,11 @@
                         {
                             if (type == 0x0B)
                             {
-                                mainForm.overlayForm.Hide();
+                                // mainForm.overlayForm.Hide();
                             }
                             else if (type == 0x0C)
                             {
-                                mainForm.overlayForm.Show();
+                                // mainForm.overlayForm.Show();
                             }
                         });
                     }