- SettingsDialog: more drafting.

- SettingsDialog: more drafting.

--- open3mod/SettingsDialog.Designer.cs
+++ open3mod/SettingsDialog.Designer.cs
@@ -31,6 +31,9 @@
             this.tabControl1 = new System.Windows.Forms.TabControl();
             this.tabPage1 = new System.Windows.Forms.TabPage();
             this.groupBox1 = new System.Windows.Forms.GroupBox();
+            this.label5 = new System.Windows.Forms.Label();
+            this.comboBox4 = new System.Windows.Forms.ComboBox();
+            this.label4 = new System.Windows.Forms.Label();
             this.checkBox2 = new System.Windows.Forms.CheckBox();
             this.comboBox3 = new System.Windows.Forms.ComboBox();
             this.label3 = new System.Windows.Forms.Label();
@@ -40,12 +43,12 @@
             this.comboBox1 = new System.Windows.Forms.ComboBox();
             this.checkBox1 = new System.Windows.Forms.CheckBox();
             this.tabPage2 = new System.Windows.Forms.TabPage();
+            this.tabPage3 = new System.Windows.Forms.TabPage();
             this.button1 = new System.Windows.Forms.Button();
             this.button2 = new System.Windows.Forms.Button();
-            this.tabPage3 = new System.Windows.Forms.TabPage();
-            this.comboBox4 = new System.Windows.Forms.ComboBox();
-            this.label4 = new System.Windows.Forms.Label();
-            this.label5 = new System.Windows.Forms.Label();
+            this.checkBox3 = new System.Windows.Forms.CheckBox();
+            this.label6 = new System.Windows.Forms.Label();
+            this.comboBox5 = new System.Windows.Forms.ComboBox();
             this.tabControl1.SuspendLayout();
             this.tabPage1.SuspendLayout();
             this.groupBox1.SuspendLayout();
@@ -62,7 +65,7 @@
             this.tabControl1.Location = new System.Drawing.Point(1, 4);
             this.tabControl1.Name = "tabControl1";
             this.tabControl1.SelectedIndex = 0;
-            this.tabControl1.Size = new System.Drawing.Size(540, 363);
+            this.tabControl1.Size = new System.Drawing.Size(540, 401);
             this.tabControl1.TabIndex = 0;
             //
             // tabPage1
@@ -72,13 +75,16 @@
             this.tabPage1.Location = new System.Drawing.Point(4, 22);
             this.tabPage1.Name = "tabPage1";
             this.tabPage1.Padding = new System.Windows.Forms.Padding(3);
-            this.tabPage1.Size = new System.Drawing.Size(532, 337);
+            this.tabPage1.Size = new System.Drawing.Size(532, 375);
             this.tabPage1.TabIndex = 0;
             this.tabPage1.Text = "Rendering";
             this.tabPage1.UseVisualStyleBackColor = true;
             //
             // groupBox1
             //
+            this.groupBox1.Controls.Add(this.label6);
+            this.groupBox1.Controls.Add(this.comboBox5);
+            this.groupBox1.Controls.Add(this.checkBox3);
             this.groupBox1.Controls.Add(this.label5);
             this.groupBox1.Controls.Add(this.comboBox4);
             this.groupBox1.Controls.Add(this.label4);
@@ -91,142 +97,10 @@
             this.groupBox1.Controls.Add(this.comboBox1);
             this.groupBox1.Location = new System.Drawing.Point(21, 61);
             this.groupBox1.Name = "groupBox1";
-            this.groupBox1.Size = new System.Drawing.Size(491, 251);
+            this.groupBox1.Size = new System.Drawing.Size(491, 293);
             this.groupBox1.TabIndex = 6;
             this.groupBox1.TabStop = false;
             this.groupBox1.Text = "Custom Settings";
-            //
-            // checkBox2
-            //
-            this.checkBox2.AutoSize = true;
-            this.checkBox2.Location = new System.Drawing.Point(362, 178);
-            this.checkBox2.Name = "checkBox2";
-            this.checkBox2.Size = new System.Drawing.Size(77, 17);
-            this.checkBox2.TabIndex = 6;
-            this.checkBox2.Text = "Linear MIP";
-            this.checkBox2.UseVisualStyleBackColor = true;
-            //
-            // comboBox3
-            //
-            this.comboBox3.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
-            this.comboBox3.FormattingEnabled = true;
-            this.comboBox3.Location = new System.Drawing.Point(186, 119);
-            this.comboBox3.Name = "comboBox3";
-            this.comboBox3.Size = new System.Drawing.Size(153, 21);
-            this.comboBox3.TabIndex = 5;
-            //
-            // label3
-            //
-            this.label3.AutoSize = true;
-            this.label3.Location = new System.Drawing.Point(17, 122);
-            this.label3.Name = "label3";
-            this.label3.Size = new System.Drawing.Size(96, 13);
-            this.label3.TabIndex = 4;
-            this.label3.Text = "Texture Resolution";
-            //
-            // label1
-            //
-            this.label1.AutoSize = true;
-            this.label1.Location = new System.Drawing.Point(17, 149);
-            this.label1.Name = "label1";
-            this.label1.Size = new System.Drawing.Size(139, 13);
-            this.label1.TabIndex = 0;
-            this.label1.Text = "Multisampling (MSAA) Mode";
-            //
-            // label2
-            //
-            this.label2.AutoSize = true;
-            this.label2.Location = new System.Drawing.Point(17, 174);
-            this.label2.Name = "label2";
-            this.label2.Size = new System.Drawing.Size(68, 13);
-            this.label2.TabIndex = 1;
-            this.label2.Text = "Texture Filter";
-            //
-            // comboBox2
-            //
-            this.comboBox2.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
-            this.comboBox2.FormattingEnabled = true;
-            this.comboBox2.Location = new System.Drawing.Point(186, 174);
-            this.comboBox2.Name = "comboBox2";
-            this.comboBox2.Size = new System.Drawing.Size(153, 21);
-            this.comboBox2.TabIndex = 3;
-            //
-            // comboBox1
-            //
-            this.comboBox1.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
-            this.comboBox1.FormattingEnabled = true;
-            this.comboBox1.Location = new System.Drawing.Point(186, 147);
-            this.comboBox1.Name = "comboBox1";
-            this.comboBox1.Size = new System.Drawing.Size(153, 21);
-            this.comboBox1.TabIndex = 2;
-            //
-            // checkBox1
-            //
-            this.checkBox1.AutoSize = true;
-            this.checkBox1.Location = new System.Drawing.Point(27, 25);
-            this.checkBox1.Name = "checkBox1";
-            this.checkBox1.Size = new System.Drawing.Size(398, 17);
-            this.checkBox1.TabIndex = 5;
-            this.checkBox1.Text = "Automatically select rendering settings based on measured system performance";
-            this.checkBox1.UseVisualStyleBackColor = true;
-            //
-            // tabPage2
-            //
-            this.tabPage2.Location = new System.Drawing.Point(4, 22);
-            this.tabPage2.Name = "tabPage2";
-            this.tabPage2.Padding = new System.Windows.Forms.Padding(3);
-            this.tabPage2.Size = new System.Drawing.Size(532, 337);
-            this.tabPage2.TabIndex = 1;
-            this.tabPage2.Text = "Import";
-            this.tabPage2.UseVisualStyleBackColor = true;
-            //
-            // button1
-            //
-            this.button1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
-            this.button1.Location = new System.Drawing.Point(430, 396);
-            this.button1.Name = "button1";
-            this.button1.Size = new System.Drawing.Size(97, 23);
-            this.button1.TabIndex = 1;
-            this.button1.Text = "OK";
-            this.button1.UseVisualStyleBackColor = true;
-            //
-            // button2
-            //
-            this.button2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
-            this.button2.Location = new System.Drawing.Point(336, 396);
-            this.button2.Name = "button2";
-            this.button2.Size = new System.Drawing.Size(88, 23);
-            this.button2.TabIndex = 2;
-            this.button2.Text = "Cancel";
-            this.button2.UseVisualStyleBackColor = true;
-            //
-            // tabPage3
-            //
-            this.tabPage3.Location = new System.Drawing.Point(4, 22);
-            this.tabPage3.Name = "tabPage3";
-            this.tabPage3.Padding = new System.Windows.Forms.Padding(3);
-            this.tabPage3.Size = new System.Drawing.Size(524, 407);
-            this.tabPage3.TabIndex = 2;
-            this.tabPage3.Text = "Animation";
-            this.tabPage3.UseVisualStyleBackColor = true;
-            //
-            // comboBox4
-            //
-            this.comboBox4.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
-            this.comboBox4.FormattingEnabled = true;
-            this.comboBox4.Location = new System.Drawing.Point(186, 35);
-            this.comboBox4.Name = "comboBox4";
-            this.comboBox4.Size = new System.Drawing.Size(153, 21);
-            this.comboBox4.TabIndex = 8;
-            //
-            // label4
-            //
-            this.label4.AutoSize = true;
-            this.label4.Location = new System.Drawing.Point(17, 38);
-            this.label4.Name = "label4";
-            this.label4.Size = new System.Drawing.Size(102, 13);
-            this.label4.TabIndex = 7;
-            this.label4.Text = "Rendering Backend";
             //
             // label5
             //
@@ -239,11 +113,188 @@
             this.label5.Text = "Note: some of the settings below are ignored for the \"Legacy\" \r\nbackend. Also, th" +
     "e legacy backend supports no GPU-based\r\nskinning so animations may run slowly.";
             //
+            // comboBox4
+            //
+            this.comboBox4.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
+            this.comboBox4.FormattingEnabled = true;
+            this.comboBox4.Items.AddRange(new object[] {
+            "OpenGl 3.0 / Shader Model 4.0",
+            "OpenGl Legacy / Fixed Function Pipeline"});
+            this.comboBox4.Location = new System.Drawing.Point(186, 35);
+            this.comboBox4.Name = "comboBox4";
+            this.comboBox4.Size = new System.Drawing.Size(153, 21);
+            this.comboBox4.TabIndex = 8;
+            //
+            // label4
+            //
+            this.label4.AutoSize = true;
+            this.label4.Location = new System.Drawing.Point(17, 38);
+            this.label4.Name = "label4";
+            this.label4.Size = new System.Drawing.Size(102, 13);
+            this.label4.TabIndex = 7;
+            this.label4.Text = "Rendering Backend";
+            //
+            // checkBox2
+            //
+            this.checkBox2.AutoSize = true;
+            this.checkBox2.Location = new System.Drawing.Point(362, 178);
+            this.checkBox2.Name = "checkBox2";
+            this.checkBox2.Size = new System.Drawing.Size(77, 17);
+            this.checkBox2.TabIndex = 6;
+            this.checkBox2.Text = "Linear MIP";
+            this.checkBox2.UseVisualStyleBackColor = true;
+            //
+            // comboBox3
+            //
+            this.comboBox3.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
+            this.comboBox3.FormattingEnabled = true;
+            this.comboBox3.Items.AddRange(new object[] {
+            "Full",
+            "Medium",
+            "Low"});
+            this.comboBox3.Location = new System.Drawing.Point(186, 119);
+            this.comboBox3.Name = "comboBox3";
+            this.comboBox3.Size = new System.Drawing.Size(153, 21);
+            this.comboBox3.TabIndex = 5;
+            //
+            // label3
+            //
+            this.label3.AutoSize = true;
+            this.label3.Location = new System.Drawing.Point(17, 122);
+            this.label3.Name = "label3";
+            this.label3.Size = new System.Drawing.Size(96, 13);
+            this.label3.TabIndex = 4;
+            this.label3.Text = "Texture Resolution";
+            //
+            // label1
+            //
+            this.label1.AutoSize = true;
+            this.label1.Location = new System.Drawing.Point(17, 149);
+            this.label1.Name = "label1";
+            this.label1.Size = new System.Drawing.Size(139, 13);
+            this.label1.TabIndex = 0;
+            this.label1.Text = "Multisampling (MSAA) Mode";
+            //
+            // label2
+            //
+            this.label2.AutoSize = true;
+            this.label2.Location = new System.Drawing.Point(17, 174);
+            this.label2.Name = "label2";
+            this.label2.Size = new System.Drawing.Size(68, 13);
+            this.label2.TabIndex = 1;
+            this.label2.Text = "Texture Filter";
+            //
+            // comboBox2
+            //
+            this.comboBox2.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
+            this.comboBox2.FormattingEnabled = true;
+            this.comboBox2.Items.AddRange(new object[] {
+            "None",
+            "Linear",
+            "Anisotropic Low",
+            "Anisotropic High"});
+            this.comboBox2.Location = new System.Drawing.Point(186, 174);
+            this.comboBox2.Name = "comboBox2";
+            this.comboBox2.Size = new System.Drawing.Size(153, 21);
+            this.comboBox2.TabIndex = 3;
+            //
+            // comboBox1
+            //
+            this.comboBox1.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
+            this.comboBox1.FormattingEnabled = true;
+            this.comboBox1.Items.AddRange(new object[] {
+            "None",
+            "2x",
+            "4x",
+            "6x"});
+            this.comboBox1.Location = new System.Drawing.Point(186, 147);
+            this.comboBox1.Name = "comboBox1";
+            this.comboBox1.Size = new System.Drawing.Size(153, 21);
+            this.comboBox1.TabIndex = 2;
+            //
+            // checkBox1
+            //
+            this.checkBox1.AutoSize = true;
+            this.checkBox1.Location = new System.Drawing.Point(27, 25);
+            this.checkBox1.Name = "checkBox1";
+            this.checkBox1.Size = new System.Drawing.Size(398, 17);
+            this.checkBox1.TabIndex = 5;
+            this.checkBox1.Text = "Automatically select rendering settings based on measured system performance";
+            this.checkBox1.UseVisualStyleBackColor = true;
+            //
+            // tabPage2
+            //
+            this.tabPage2.Location = new System.Drawing.Point(4, 22);
+            this.tabPage2.Name = "tabPage2";
+            this.tabPage2.Padding = new System.Windows.Forms.Padding(3);
+            this.tabPage2.Size = new System.Drawing.Size(532, 337);
+            this.tabPage2.TabIndex = 1;
+            this.tabPage2.Text = "Import";
+            this.tabPage2.UseVisualStyleBackColor = true;
+            //
+            // tabPage3
+            //
+            this.tabPage3.Location = new System.Drawing.Point(4, 22);
+            this.tabPage3.Name = "tabPage3";
+            this.tabPage3.Padding = new System.Windows.Forms.Padding(3);
+            this.tabPage3.Size = new System.Drawing.Size(532, 337);
+            this.tabPage3.TabIndex = 2;
+            this.tabPage3.Text = "Animation";
+            this.tabPage3.UseVisualStyleBackColor = true;
+            //
+            // button1
+            //
+            this.button1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
+            this.button1.Location = new System.Drawing.Point(430, 434);
+            this.button1.Name = "button1";
+            this.button1.Size = new System.Drawing.Size(97, 23);
+            this.button1.TabIndex = 1;
+            this.button1.Text = "OK";
+            this.button1.UseVisualStyleBackColor = true;
+            //
+            // button2
+            //
+            this.button2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
+            this.button2.Location = new System.Drawing.Point(336, 434);
+            this.button2.Name = "button2";
+            this.button2.Size = new System.Drawing.Size(88, 23);
+            this.button2.TabIndex = 2;
+            this.button2.Text = "Cancel";
+            this.button2.UseVisualStyleBackColor = true;
+            //
+            // checkBox3
+            //
+            this.checkBox3.AutoSize = true;
+            this.checkBox3.Location = new System.Drawing.Point(20, 253);
+            this.checkBox3.Name = "checkBox3";
+            this.checkBox3.Size = new System.Drawing.Size(152, 17);
+            this.checkBox3.TabIndex = 10;
+            this.checkBox3.Text = "Order-correct transparency";
+            this.checkBox3.UseVisualStyleBackColor = true;
+            //
+            // label6
+            //
+            this.label6.AutoSize = true;
+            this.label6.Location = new System.Drawing.Point(17, 201);
+            this.label6.Name = "label6";
+            this.label6.Size = new System.Drawing.Size(74, 13);
+            this.label6.TabIndex = 11;
+            this.label6.Text = "Lighting Mode";
+            //
+            // comboBox5
+            //
+            this.comboBox5.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
+            this.comboBox5.FormattingEnabled = true;
+            this.comboBox5.Location = new System.Drawing.Point(186, 201);
+            this.comboBox5.Name = "comboBox5";
+            this.comboBox5.Size = new System.Drawing.Size(153, 21);
+            this.comboBox5.TabIndex = 12;
+            //
             // SettingsDialog
             //
             this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
-            this.ClientSize = new System.Drawing.Size(539, 427);
+            this.ClientSize = new System.Drawing.Size(539, 465);
             this.Controls.Add(this.button2);
             this.Controls.Add(this.button1);
             this.Controls.Add(this.tabControl1);
@@ -281,5 +332,8 @@
         private System.Windows.Forms.Label label5;
         private System.Windows.Forms.ComboBox comboBox4;
         private System.Windows.Forms.Label label4;
+        private System.Windows.Forms.CheckBox checkBox3;
+        private System.Windows.Forms.Label label6;
+        private System.Windows.Forms.ComboBox comboBox5;
     }
 }


Add ENVIROAPPSYMBOL field

Add ENVIROAPPSYMBOL field

--- api/Deq.Search.Soe/Configuration/DebugConfiguration.cs
+++ api/Deq.Search.Soe/Configuration/DebugConfiguration.cs
@@ -31,7 +31,7 @@
         public ApplicationSettings GetSettings(IPropertySet props) {
             var settings = new ApplicationSettings {
                 ReturnFields = new[] {
-                    "ID", "NAME", "ADDRESS", "CITY", "TYPE", "OBJECTID", "ENVIROAPPLABEL"
+                    "ID", "NAME", "ADDRESS", "CITY", "TYPE", "OBJECTID", "ENVIROAPPLABEL", "ENVIROAPPSYMBOL"
                 },
                 ProgramId = "ID",
                 SiteName = "NAME",


Unregister from Window.Current.SizeChanged event on unload

--- src/AppStudio.Uwp/Controls/VisualBreakpoints/VisualBreakpoints.cs
+++ src/AppStudio.Uwp/Controls/VisualBreakpoints/VisualBreakpoints.cs
@@ -1,225 +1,262 @@
-using AppStudio.Uwp;
-using Newtonsoft.Json;
-using System;
-using System.Collections.Generic;
-using System.ComponentModel;
-using System.Diagnostics;
-using System.Dynamic;
-using System.IO;
-using System.Linq;
-using System.Runtime.CompilerServices;
-using System.Text;
-using System.Threading;
-using System.Threading.Tasks;
-using Windows.Storage;
-using Windows.UI.Xaml;
-
-namespace AppStudio.Uwp.Controls
-{
-    public sealed class VisualBreakpoints : ObservableBase
-    {
-        private static Dictionary<string, string> _configCache = new Dictionary<string, string>();
-        private static SemaphoreSlim readFileSemaphore = new SemaphoreSlim(1);
-
-        private int _lastActive = -1;
-        private int[] _breakpointsIndex = new int[0];
-        private BreakpointsTable _fallBackBreakPoint = new BreakpointsTable();
-        private BreakpointsDictionary _breakpointsTable = new BreakpointsDictionary();
-
-        private string _configFile;
-        public string ConfigFile
-        {
-            get { return _configFile; }
-            set
-            {
-                _configFile = value;
-
-                Initialize();
-            }
-        }
-
-        public dynamic Active { get; set; }
-
-        public VisualBreakpoints()
-        {
-            Active = new ExpandoObject();
-
-            Window.Current.SizeChanged += ((sender, e) => { TrySetActive(e.Size.Width); });
-            TrySetActive(Window.Current.Bounds.Width);
-        }
-
-        private void TrySetActive(double width)
-        {
-            if (_breakpointsIndex != null && _breakpointsIndex.Length > 0)
-            {
-                var currentActive = _breakpointsIndex.FirstOrDefault(b => width < b);
-                if (currentActive != _lastActive)
-                {
-                    var activeBreakpoint = GetActiveBreakpoint(currentActive);
-                    SetActiveProperties(activeBreakpoint);
-
-                    _lastActive = currentActive;
-                }
-            }
-        }
-
-        private void SetActiveProperties(BreakpointsTable activeBreakpoint)
-        {
-            if (activeBreakpoint != null)
-            {
-                var activeDict = Active as IDictionary<string, object>;
-
-                foreach (var props in activeBreakpoint)
-                {
-                    activeDict[props.Name] = props.Value;
-                }
-
-                //this is because: System.Reflection.MemberInfo.get_MetadataToken()' cannot be used on the current platform. See http://go.microsoft.com/fwlink/?LinkId=248273 for more information.
-                OnPropertyChanged("Active");
-            }
-        }
-
-        private BreakpointsTable GetActiveBreakpoint(int currentActive)
-        {
-            BreakpointsTable activeBreakpoint;
-
-            if (_breakpointsTable.ContainsKey(currentActive.ToString()))
-            {
-                activeBreakpoint = _breakpointsTable[currentActive.ToString()];
-            }
-            else
-            {
-                activeBreakpoint = _fallBackBreakPoint;
-            }
-
-            return activeBreakpoint;
-        }
-
-        private async void Initialize()
-        {
-            await InitBreakPoints();
-
-            TrySetActive(Window.Current.Bounds.Width);
-        }
-
-        private async Task InitBreakPoints()
-        {
-            var loadedFiles = new List<string>();
-
-            var rawConfigContents = await GetConfigContents(_configFile, loadedFiles);
-            await ReadBreakPoints(rawConfigContents, loadedFiles);
-        }
-
-        private async Task<string> GetConfigContents(string configFile, List<string> loadedFiles)
-        {
-            var cacheKey = configFile.ToLowerInvariant();
-            if (loadedFiles.Any(f => f == cacheKey))
-            {
-                throw new OverflowException($"Config file: '{configFile}' was already loaded.");
-            }
-
-            //lock the execution in order to not request the same file several times
-            await readFileSemaphore.WaitAsync();
-            try
-            {
-                if (!_configCache.ContainsKey(cacheKey))
-                {
-                    var fileContents = await GetConfigContentsFromFile(configFile);
-
-                    loadedFiles.Add(configFile);
-                    _configCache.Add(cacheKey, fileContents);
-                }
-            }
-            finally
-            {
-                readFileSemaphore.Release();
-            }
-
-            return _configCache[cacheKey];
-        }
-
-        private async Task<string> GetConfigContentsFromFile(string configFile)
-        {
-            var uri = new Uri(string.Format("ms-appx://{0}", configFile));
-
-            try
-            {
-                var file = await StorageFile.GetFileFromApplicationUriAsync(uri);
-                var randomStream = await file.OpenReadAsync();
-
-                using (var r = new StreamReader(randomStream.AsStreamForRead()))
-                {
-                    return await r.ReadToEndAsync();
-                }
-            }
-            catch (FileNotFoundException)
-            {
-                throw new ArgumentException($"Config file '{uri}' does not found");
-            }
-        }
-
-        private async Task ReadBreakPoints(string contents, List<string> loadedFiles)
-        {
-            var configContents = JsonConvert.DeserializeObject<BreakpointsConfig>(contents);
-
-            if (configContents == null)
-            {
-                return;
-            }
-
-            await ReadImport(configContents, loadedFiles);
-
-            if (configContents.breakpoints == null)
-            {
-                return;
-            }
-
-            ReBuildIndex(configContents);
-
-            foreach (var b in configContents.breakpoints)
-            {
-                if (b.maxwidth.IsNumeric())
-                {
-                    _breakpointsTable.Merge(b);
-                }
-            }
-
-            var fallBack = configContents.breakpoints
-                                            .FirstOrDefault(b => !b.maxwidth.IsNumeric());
-            if (fallBack != null)
-            {
-                _fallBackBreakPoint.Merge(fallBack);
-            }
-        }
-
-        private async Task ReadImport(BreakpointsConfig configContents, List<string> loadedFiles)
-        {
-            if (!string.IsNullOrWhiteSpace(configContents._import))
-            {
-                var rawConfigContents = await GetConfigContents(configContents._import, loadedFiles);
-                await ReadBreakPoints(rawConfigContents, loadedFiles);
-            }
-        }
-
-        private void ReBuildIndex(BreakpointsConfig breakpointsConfig)
-        {
-            var tmpIndex = new List<int>(_breakpointsIndex);
-
-            var newItems = breakpointsConfig.breakpoints
-                                                .Where(b => b.maxwidth.IsNumeric())
-                                                .Select(b => int.Parse(b.maxwidth));
-
-            foreach (var item in newItems)
-            {
-                if (!tmpIndex.Any(i => i == item))
-                {
-                    tmpIndex.Add(item);
-                }
-            }
-
-            _breakpointsIndex = tmpIndex
-                                    .OrderBy(i => i)
-                                    .ToArray();
-        }
-    }
-}
+using AppStudio.Uwp;
+using Newtonsoft.Json;
+using System;
+using System.Collections.Generic;
+using System.ComponentModel;
+using System.Diagnostics;
+using System.Dynamic;
+using System.IO;
+using System.Linq;
+using System.Runtime.CompilerServices;
+using System.Text;
+using System.Threading;
+using System.Threading.Tasks;
+using Windows.Storage;
+using Windows.UI.Core;
+using Windows.UI.Xaml;
+using Windows.UI.Xaml.Controls;
+
+namespace AppStudio.Uwp.Controls
+{
+    public sealed class VisualBreakpoints : Control, INotifyPropertyChanged
+    {
+        private static Dictionary<string, string> _configCache = new Dictionary<string, string>();
+        private static SemaphoreSlim readFileSemaphore = new SemaphoreSlim(1);
+
+        private int _lastActive = -1;
+        private int[] _breakpointsIndex = new int[0];
+        private BreakpointsTable _fallBackBreakPoint = new BreakpointsTable();
+        private BreakpointsDictionary _breakpointsTable = new BreakpointsDictionary();
+
+        private string _configFile;
+        public string ConfigFile
+        {
+            get { return _configFile; }
+            set
+            {
+                _configFile = value;
+
+                Initialize();
+            }
+        }
+
+        public dynamic Active { get; set; }
+
+        public event PropertyChangedEventHandler PropertyChanged;
+
+        public VisualBreakpoints()
+        {
+            Active = new ExpandoObject();
+
+            Loaded += VisualBreakpoints_Loaded;
+            Unloaded += VisualBreakpoints_Unloaded;
+        }
+
+        private void VisualBreakpoints_Unloaded(object sender, RoutedEventArgs e)
+        {
+            Window.Current.SizeChanged -= Window_SizeChanged;
+        }
+
+        private void VisualBreakpoints_Loaded(object sender, RoutedEventArgs e)
+        {
+            Window.Current.SizeChanged += Window_SizeChanged;
+            TrySetActive(Window.Current.Bounds.Width);
+        }
+
+        private void Window_SizeChanged(object sender, WindowSizeChangedEventArgs e)
+        {
+            TrySetActive(e.Size.Width);
+        }
+
+        private bool SetProperty<T>(ref T storage, T value, [CallerMemberName]string propertyName = null)
+        {
+            if (Equals(storage, value)) return false;
+
+            storage = value;
+            OnPropertyChanged(propertyName);
+            return true;
+        }
+
+        private void OnPropertyChanged(string propertyName)
+        {
+            if (PropertyChanged != null)
+            {
+                PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
+            }
+        }
+
+        private void TrySetActive(double width)
+        {
+            if (_breakpointsIndex != null && _breakpointsIndex.Length > 0)
+            {
+                var currentActive = _breakpointsIndex.FirstOrDefault(b => width < b);
+                if (currentActive != _lastActive)
+                {
+                    var activeBreakpoint = GetActiveBreakpoint(currentActive);
+                    SetActiveProperties(activeBreakpoint);
+
+                    _lastActive = currentActive;
+                }
+            }
+        }
+
+        private void SetActiveProperties(BreakpointsTable activeBreakpoint)
+        {
+            if (activeBreakpoint != null)
+            {
+                var activeDict = Active as IDictionary<string, object>;
+
+                foreach (var props in activeBreakpoint)
+                {
+                    activeDict[props.Name] = props.Value;
+                }
+
+                //this is because: System.Reflection.MemberInfo.get_MetadataToken()' cannot be used on the current platform. See http://go.microsoft.com/fwlink/?LinkId=248273 for more information.
+                OnPropertyChanged("Active");
+            }
+        }
+
+        private BreakpointsTable GetActiveBreakpoint(int currentActive)
+        {
+            BreakpointsTable activeBreakpoint;
+
+            if (_breakpointsTable.ContainsKey(currentActive.ToString()))
+            {
+                activeBreakpoint = _breakpointsTable[currentActive.ToString()];
+            }
+            else
+            {
+                activeBreakpoint = _fallBackBreakPoint;
+            }
+
+            return activeBreakpoint;
+        }
+
+        private async void Initialize()
+        {
+            await InitBreakPoints();
+
+            TrySetActive(Window.Current.Bounds.Width);
+        }
+
+        private async Task InitBreakPoints()
+        {
+            var loadedFiles = new List<string>();
+
+            var rawConfigContents = await GetConfigContents(_configFile, loadedFiles);
+            await ReadBreakPoints(rawConfigContents, loadedFiles);
+        }
+
+        private async Task<string> GetConfigContents(string configFile, List<string> loadedFiles)
+        {
+            var cacheKey = configFile.ToLowerInvariant();
+            if (loadedFiles.Any(f => f == cacheKey))
+            {
+                throw new OverflowException($"Config file: '{configFile}' was already loaded.");
+            }
+
+            //lock the execution in order to not request the same file several times
+            await readFileSemaphore.WaitAsync();
+            try
+            {
+                if (!_configCache.ContainsKey(cacheKey))
+                {
+                    var fileContents = await GetConfigContentsFromFile(configFile);
+
+                    loadedFiles.Add(configFile);
+                    _configCache.Add(cacheKey, fileContents);
+                }
+            }
+            finally
+            {
+                readFileSemaphore.Release();
+            }
+
+            return _configCache[cacheKey];
+        }
+
+        private async Task<string> GetConfigContentsFromFile(string configFile)
+        {
+            var uri = new Uri(string.Format("ms-appx://{0}", configFile));
+
+            try
+            {
+                var file = await StorageFile.GetFileFromApplicationUriAsync(uri);
+                var randomStream = await file.OpenReadAsync();
+
+                using (var r = new StreamReader(randomStream.AsStreamForRead()))
+                {
+                    return await r.ReadToEndAsync();
+                }
+            }
+            catch (FileNotFoundException)
+            {
+                throw new ArgumentException($"Config file '{uri}' does not found");
+            }
+        }
+
+        private async Task ReadBreakPoints(string contents, List<string> loadedFiles)
+        {
+            var configContents = JsonConvert.DeserializeObject<BreakpointsConfig>(contents);
+
+            if (configContents == null)
+            {
+                return;
+            }
+
+            await ReadImport(configContents, loadedFiles);
+
+            if (configContents.breakpoints == null)
+            {
+                return;
+            }
+
+            ReBuildIndex(configContents);
+
+            foreach (var b in configContents.breakpoints)
+            {
+                if (b.maxwidth.IsNumeric())
+                {
+                    _breakpointsTable.Merge(b);
+                }
+            }
+
+            var fallBack = configContents.breakpoints
+                                            .FirstOrDefault(b => !b.maxwidth.IsNumeric());
+            if (fallBack != null)
+            {
+                _fallBackBreakPoint.Merge(fallBack);
+            }
+        }
+
+        private async Task ReadImport(BreakpointsConfig configContents, List<string> loadedFiles)
+        {
+            if (!string.IsNullOrWhiteSpace(configContents._import))
+            {
+                var rawConfigContents = await GetConfigContents(configContents._import, loadedFiles);
+                await ReadBreakPoints(rawConfigContents, loadedFiles);
+            }
+        }
+
+        private void ReBuildIndex(BreakpointsConfig breakpointsConfig)
+        {
+            var tmpIndex = new List<int>(_breakpointsIndex);
+
+            var newItems = breakpointsConfig.breakpoints
+                                                .Where(b => b.maxwidth.IsNumeric())
+                                                .Select(b => int.Parse(b.maxwidth));
+
+            foreach (var item in newItems)
+            {
+                if (!tmpIndex.Any(i => i == item))
+                {
+                    tmpIndex.Add(item);
+                }
+            }
+
+            _breakpointsIndex = tmpIndex
+                                    .OrderBy(i => i)
+                                    .ToArray();
+        }
+    }
+}


Fix AzureSilo startup (#5213)

Fix AzureSilo startup (#5213)

--- src/Azure/Orleans.Hosting.AzureCloudServices/Hosting/AzureSilo.cs
+++ src/Azure/Orleans.Hosting.AzureCloudServices/Hosting/AzureSilo.cs
@@ -7,6 +7,7 @@
 using Orleans.Runtime.Configuration;
 using System.Threading.Tasks;
 using Microsoft.Extensions.Logging;
+using Microsoft.Extensions.Options;
 using Orleans.Logging;
 using Orleans.AzureUtils.Utilities;
 using Orleans.Configuration;
@@ -51,8 +52,6 @@
         public Action<ISiloHostBuilder> ConfigureSiloHostDelegate { get; set; }

         private SiloHost host;
-        private OrleansSiloInstanceManager siloInstanceManager;
-        private SiloInstanceTableEntry myEntry;
         private readonly ILogger logger;
         private readonly IServiceRuntimeWrapper serviceRuntimeWrapper;
         //TODO: hook this up with SiloBuilder when SiloBuilder supports create AzureSilo
@@ -111,7 +110,7 @@

                 try
                 {
-                    var manager = siloInstanceManager ?? await OrleansSiloInstanceManager.GetManager(clusterId, connectionString, AzureStorageClusteringOptions.DEFAULT_TABLE_NAME, loggerFactory);
+                    var manager = await OrleansSiloInstanceManager.GetManager(clusterId, connectionString, AzureStorageClusteringOptions.DEFAULT_TABLE_NAME, loggerFactory);
                     var instances = await manager.DumpSiloInstanceTable();
                     logger.Debug(instances);
                 }
@@ -220,10 +219,6 @@

             host.SetSiloType(Silo.SiloType.Secondary);

-            int generation = SiloAddress.AllocateNewGeneration();
-
-            // Bootstrap this Orleans silo instance
-
             // If clusterId was not direclty provided, take the value in the config. If it is not
             // in the config too, just take the ClusterId from Azure
             if (clusterId == null)
@@ -231,42 +226,8 @@
                     ? serviceRuntimeWrapper.DeploymentId
                     : host.Config.Globals.ClusterId;

-            myEntry = new SiloInstanceTableEntry
-            {
-                DeploymentId = clusterId,
-                Address = myEndpoint.Address.ToString(),
-                Port = myEndpoint.Port.ToString(CultureInfo.InvariantCulture),
-                Generation = generation.ToString(CultureInfo.InvariantCulture),
-
-                HostName = host.Config.GetOrCreateNodeConfigurationForSilo(host.Name).DNSHostName,
-                ProxyPort = (proxyEndpoint != null ? proxyEndpoint.Port : 0).ToString(CultureInfo.InvariantCulture),
-
-                RoleName = serviceRuntimeWrapper.RoleName,
-                SiloName = instanceName,
-                UpdateZone = serviceRuntimeWrapper.UpdateDomain.ToString(CultureInfo.InvariantCulture),
-                FaultZone = serviceRuntimeWrapper.FaultDomain.ToString(CultureInfo.InvariantCulture),
-                StartTime = LogFormatter.PrintDate(DateTime.UtcNow),
-
-                PartitionKey = clusterId,
-                RowKey = myEndpoint.Address + "-" + myEndpoint.Port + "-" + generation
-            };
-
-			if (connectionString == null)
-				connectionString = serviceRuntimeWrapper.GetConfigurationSettingValue(DataConnectionConfigurationSettingName);
-
-            try
-            {
-                siloInstanceManager = OrleansSiloInstanceManager.GetManager(
-                    clusterId, connectionString, AzureStorageClusteringOptions.DEFAULT_TABLE_NAME, this.loggerFactory).WithTimeout(AzureTableDefaultPolicies.TableCreationTimeout).Result;
-            }
-            catch (Exception exc)
-            {
-                var error = String.Format("Failed to create OrleansSiloInstanceManager. This means CreateTableIfNotExist for silo instance table has failed with {0}",
-                    LogFormatter.PrintException(exc));
-                Trace.TraceError(error);
-                logger.Error((int)AzureSiloErrorCode.AzureTable_34, error, exc);
-                throw new OrleansException(error, exc);
-            }
+            if (connectionString == null)
+                connectionString = serviceRuntimeWrapper.GetConfigurationSettingValue(DataConnectionConfigurationSettingName);

             // Always use Azure table for membership when running silo in Azure
             host.SetSiloLivenessType(GlobalConfiguration.LivenessProviderType.AzureTable);
@@ -276,11 +237,10 @@
                 host.SetReminderServiceType(GlobalConfiguration.ReminderServiceProviderType.AzureTable);
             }
             host.SetExpectedClusterSize(serviceRuntimeWrapper.RoleInstanceCount);
-            siloInstanceManager.RegisterSiloInstance(myEntry);

             // Initialize this Orleans silo instance
             host.SetDeploymentId(clusterId, connectionString);
-            host.SetSiloEndpoint(myEndpoint, generation);
+            host.SetSiloEndpoint(myEndpoint, 0);
             host.SetProxyEndpoint(proxyEndpoint);

             host.ConfigureSiloHostDelegate = ConfigureSiloHostDelegate;


restrict to space and dots for group and decimal chars accordingly.

--- WalletWasabi.Fluent/Controls/CurrencyEntryBox.axaml.cs
+++ WalletWasabi.Fluent/Controls/CurrencyEntryBox.axaml.cs
@@ -36,7 +36,6 @@
 		private Button? _swapButton;
 		private CompositeDisposable _disposable;
 		private bool _allowConversions = true;
-		private NumberFormatInfo _cultureNumberFormatInfo;
 		private readonly char _currentCultureDecimalSeparator = '.';
 		private readonly char _currentCultureGroupSeparator = ' ';
 		private Regex _matchRegexDecimal;
@@ -47,8 +46,6 @@
 			this.GetObservable(TextProperty).Subscribe(_ => DoConversion());
 			this.GetObservable(ConversionRateProperty).Subscribe(_ => DoConversion());
 			Text = "0";
-
-			_cultureNumberFormatInfo = Thread.CurrentThread.CurrentCulture.NumberFormat;

 			_matchRegexDecimal =
 				new Regex(


Changed accessibility of PathFacetHandler.PathValueConverter.Convert method to virtual.

--- src/BoboBrowse.Net/BoboBrowse.Net/Facets/Impl/PathFacetHandler.cs
+++ src/BoboBrowse.Net/BoboBrowse.Net/Facets/Impl/PathFacetHandler.cs
@@ -188,7 +188,7 @@
                 }
             }

-            public int[] Convert(FacetDataCache dataCache, string[] vals)
+            public virtual int[] Convert(FacetDataCache dataCache, string[] vals)
             {
                 IList<int> intSet = new List<int>();
                 GetFilters(dataCache, intSet, vals, _depth, _strict);


Changed the layout of Footer.

Changed the layout of Footer.

--- yafsrc/YAF.Controls/Footer.cs
+++ yafsrc/YAF.Controls/Footer.cs
@@ -88,7 +88,6 @@
 		{
 			// BEGIN FOOTER
 			StringBuilder footer = new StringBuilder();
-			footer.AppendFormat( "
" );

 			/* Commented out by Jaben on 9/27/2007: No longer needed with the RSS feed on the main forum.
 			if ( PageContext.BoardSettings.ShowRSSLink )
@@ -101,48 +100,50 @@
 			// it's not really an error if it doesn't exist
 			string themeCredit = PageContext.Theme.GetItem( "THEME", "CREDIT", null );

-			if ( themeCredit != null && themeCredit.Length > 0 )
-			{
-				themeCredit = @"" + themeCredit + @"
";
-			}
-
 			StopWatch.Stop();
 			double duration = ( double ) StopWatch.ElapsedMilliseconds / 1000.0;

-			if ( YAF.Classes.Config.IsDotNetNuke )
+			footer.Append( @"

" );
+
+			// append theme Credit if it exists...
+			if ( !String.IsNullOrEmpty( themeCredit ) )
 			{
-				if ( themeCredit != null && themeCredit.Length > 0 ) footer.Append( themeCredit );
-        footer.AppendFormat( "Yet Another Forum.NET version {0} running under DotNetNuke.", YafForumInfo.AppVersionName );
-        footer.AppendFormat( "
Copyright © 2003-2007 Yet Another Forum.NET. All rights reserved." );
-			}
-			else if ( YAF.Classes.Config.IsRainbow )
-			{
-				if ( themeCredit != null && themeCredit.Length > 0 ) footer.Append( themeCredit );
-        footer.AppendFormat( "Yet Another Forum.NET version {0} running under Rainbow.", YafForumInfo.AppVersionName );
-        footer.AppendFormat( "
Copyright © 2003-2007 Yet Another Forum.NET. All rights reserved." );
-			}
-			else if ( PageContext.Settings.LockedForum == 0 )
-			{
-				if ( themeCredit != null && themeCredit.Length > 0 ) footer.Append( themeCredit );
-				footer.AppendFormat( PageContext.Localization.GetText( "COMMON", "POWERED_BY" ),
-					String.Format( "Yet Another Forum.NET" ),
-					String.Format( "{0} (NET v{2}.{3}) - {1}", YafForumInfo.AppVersionName, YafDateTime.FormatDateShort( YafForumInfo.AppVersionDate ), System.Environment.Version.Major.ToString(), System.Environment.Version.Minor.ToString() )
-					);
-				footer.AppendFormat( "
Copyright © 2003-2007 Yet Another Forum.NET. All rights reserved." );
-				footer.AppendFormat( "
" );
-				footer.AppendFormat( PageContext.AdminLoadString ); // Append a error message for an admin to see (but not nag)
-
-				if ( PageContext.BoardSettings.ShowPageGenerationTime )
-					footer.AppendFormat( PageContext.Localization.GetText( "COMMON", "GENERATED" ), duration );
+				footer.Append( @"" + themeCredit + @"
" );
 			}

+			footer.Append( @"" );
+			footer.Append( PageContext.Localization.GetText( "COMMON", "POWERED_BY" ) );
+			footer.Append( @" YAF" );
+
+			if ( PageContext.BoardSettings.ShowYAFVersion )
+			{
+				footer.AppendFormat( " {0} ", YafForumInfo.AppVersionName );
+				if ( YAF.Classes.Config.IsDotNetNuke )
+				{
+					footer.Append( " Under DNN " );
+				}
+				else if ( YAF.Classes.Config.IsRainbow )
+				{
+					footer.Append( " Under Rainbow " );
+				}
+			}
+
+			footer.AppendFormat( @" | YAF © 2003-2007, Yet Another Forum.NET", "YetAnotherForum.NET", "http://www.yetanotherforum.net" );
+
+			if ( PageContext.BoardSettings.ShowPageGenerationTime )
+			{
+				footer.Append( "
" );
+				footer.AppendFormat( PageContext.Localization.GetText( "COMMON", "GENERATED" ), duration );
+			}
+
+			footer.Append( @"
" );
+			footer.Append( PageContext.AdminLoadString ); // Append a error message for an admin to see (but not nag)
+
 #if DEBUG
-      footer.AppendFormat( @"

YAF Compiled in DEBUG MODE.
Recompile in RELEASE MODE to remove this information:" );
+      footer.AppendFormat( @"

YAF Compiled in DEBUG MODE.
Recompile in RELEASE MODE to remove this information:" );
 			footer.AppendFormat( @"
{0} sql queries ({1:N3} seconds, {2:N2}%).
{3}", QueryCounter.Count, QueryCounter.Duration, ( 100 * QueryCounter.Duration ) / duration, QueryCounter.Commands );
       footer.Append( "
" );
 #endif
-      footer.AppendFormat( "
" );
-			// END FOOTER

 			// write CSS, Refresh, then header...
 			writer.Write( footer );


Fix Backfire FleetManager adding data["replaced_id"] again

--- ElectronicObserver/Backfire/Data/FleetManager.cs
+++ ElectronicObserver/Backfire/Data/FleetManager.cs
@@ -105,7 +105,7 @@
 			switch ( apiname ) {
 				case "api_req_hensei/change": {
 						int memberID = int.Parse( data["api_ship_idx"] );		//変更スロット
-						if ( memberID != -1 )
+						if ( memberID != -1 && !data.ContainsKey("replaced_id"))
 							data.Add( "replaced_id", Fleets[int.Parse( data["api_id"] )].Members[memberID].ToString() );

 						foreach ( int i in Fleets.Keys )


fixxx

fixxx

--- WebNoodle/Reflection/ImplicitConversionMethodHelper.cs
+++ WebNoodle/Reflection/ImplicitConversionMethodHelper.cs
@@ -18,8 +18,9 @@

         public static MethodInfo UncachedGetImplicitConversionMethod(Type from, Type to)
         {
-            return to.GetMethods(BindingFlags.Public | BindingFlags.DeclaredOnly | BindingFlags.Static)
+            return to.GetMethods(BindingFlags.Public | BindingFlags.Static)
                 .Where(x => x.Name == "op_Implicit")
+                .Where(x => x.DeclaringType != typeof(object))
                 .Where(x => to.IsAssignableFrom(x.ReturnType))
                 .Where(x => x.GetParameters().Single().ParameterType == from)
                 .FirstOrDefault();


Clear out cookies before logging in.

Clear out cookies before logging in.

--- XamarinApp/MyTrips/MyTrips/ViewModel/LoginViewModel.cs
+++ XamarinApp/MyTrips/MyTrips/ViewModel/LoginViewModel.cs
@@ -63,6 +63,7 @@
             MobileServiceUser user = null;
             try
             {
+                authentication.ClearCookies();
                 user = await authentication.LoginAsync(client, MobileServiceAuthenticationProvider.Twitter);
                 if (user != null)
                 {
@@ -113,7 +114,8 @@
             MobileServiceUser user = null;
             try
             {
-                user = user = await authentication.LoginAsync(client, MobileServiceAuthenticationProvider.MicrosoftAccount);
+                authentication.ClearCookies();
+                user = await authentication.LoginAsync(client, MobileServiceAuthenticationProvider.MicrosoftAccount);
                 if (user != null)
                 {
                     IsBusy = true;
@@ -158,6 +160,7 @@
             MobileServiceUser user = null;
             try
             {
+                authentication.ClearCookies();
                 user = await authentication.LoginAsync(client, MobileServiceAuthenticationProvider.Facebook);
                 if (user != null)
                 {


better styling for login card

better styling for login card

--- src/Admin/Views/Login/Index.cshtml
+++ src/Admin/Views/Login/Index.cshtml
@@ -3,21 +3,24 @@
     ViewData["Title"] = "Login";
 }

-

-

-
Please enter your email address below to log in.

-        <form asp-action="" method="post">
-            <input type="hidden" asp-for="ReturnUrl" />
-

-

-                Email Address
-                <input asp-for="Email" type="email" class="form-control" placeholder="ex. john@example.com"
-                       required autofocus>
-
-                We'll email you a secure login link.
+

+

+

+

+
Please enter your email address below to log in.

+                <form asp-action="" method="post">
+                    <input type="hidden" asp-for="ReturnUrl" />
+

+

+                        Email Address
+                        <input asp-for="Email" type="email" class="form-control" placeholder="ex. john@example.com"
+                               required autofocus>
+
+                        We'll email you a secure login link.
+

+                    <button class="btn btn-primary" type="submit">Continue</button>
+                </form>

-            <button class="btn btn-primary" type="submit">Continue</button>
-        </form>
+

-


load and update manifest android:versionCode attribute as well

--- src/AndroidManifestUtil/Program.cs
+++ src/AndroidManifestUtil/Program.cs
@@ -1,11 +1,7 @@
 using System;
-using System.Collections;
-using System.Collections.Generic;
 using System.IO;
 using System.Linq;
-using System.Text;
 using System.Text.RegularExpressions;
-using System.Threading.Tasks;
 using System.Xml;

 namespace AndroidManifestUtil
@@ -19,9 +15,9 @@
     {
       if (args.Length < 1)
       {
-        Console.WriteLine("Usage: AndroidManifestUtil.exe -filename=<file containing assembly version>");
+        Console.WriteLine("Usage: AndroidManifestUtil.exe -filename=<path\\to\\manifest.xml file>");
         Console.WriteLine(
-          "e.g. AndroidManifestUtil.exe ..\\src\\MyProject\\Properties\\AndroidManifest.xml\tWill increment the build revision in manifest/android:versionName");
+          "e.g. AndroidManifestUtil.exe ..\\src\\MyProject\\Properties\\AndroidManifest.xml\tWill increment the version code in manifest/android:versionCode, and build revision in manifest/android:versionName");
       }
       else
       {
@@ -30,12 +26,54 @@
         if (string.IsNullOrWhiteSpace(fileName)) throw new ArgumentException("Version file name must not be empty");
         if (!File.Exists(fileName)) throw new ArgumentException(string.Format("Couldn't locate file '{0}'", fileName));

+        LoadAndUpdateVersionCodeFor(fileName);
         LoadAndUpdateBuildRevisionFor(fileName);
       }

       // Console.ReadLine();
     }

+    /// <summary>
+    /// Tries to locate and increment the 'android:versionCode' attribute of the 'manifest' tag
+    /// </summary>
+    /// <param name="fileName"></param>
+    private static void LoadAndUpdateVersionCodeFor(string fileName)
+    {
+      Console.ForegroundColor = ConsoleColor.Green;
+      Console.WriteLine("Loading {0}", fileName);
+      var xmldoc = new XmlDocument();
+      xmldoc.Load(fileName);
+      Console.WriteLine("Loaded {0}", fileName);
+
+      Console.WriteLine("Loading manifest node...");
+      var manifestNode = xmldoc.SelectSingleNode("/manifest");
+      Console.WriteLine("Getting manifest attributes...");
+      var attributes = manifestNode.Attributes;
+      var versionCode = attributes.GetNamedItem("android:versionCode");
+      if (versionCode != null)
+      {
+        Console.WriteLine("Found android:versionCode attribute: {0}", versionCode.Value);
+        int newValue = int.Parse(versionCode.Value);
+        versionCode.Value = string.Format("{0}", ++newValue);
+        Console.WriteLine("Updating android:versionName attribute to {0}", versionCode.Value);
+        manifestNode.Attributes.SetNamedItem(versionCode);
+        Console.WriteLine("Writing out updated manifest file: {0}", fileName);
+        xmldoc.Save(fileName);
+      }
+      else
+      {
+        Console.ForegroundColor = ConsoleColor.Yellow;
+        Console.WriteLine("Did not find android:versionCode attribute, aborting!");
+        Console.ResetColor();
+      }
+      Console.ResetColor();
+      Console.WriteLine("Done");
+    }
+
+    /// <summary>
+    /// Tries to locate and update the 'android:versionName' attribute of the 'manifest' tag
+    /// </summary>
+    /// <param name="fileName"></param>
     private static void LoadAndUpdateBuildRevisionFor(string fileName)
     {
       Console.ForegroundColor = ConsoleColor.Green;


Use Interlocked.Increment()

Use Interlocked.Increment()

--- Connection.cs
+++ Connection.cs
@@ -74,10 +74,12 @@
 			ns = new NetworkStream (sock);
 		}

-		uint serial = 0;
+		//Interlocked.Increment() handles the overflow condition for uint correctly, so it's ok to store the value as an int but cast it to uint
+		protected int serial = 0;
 		public uint GenerateSerial ()
 		{
-			return ++serial;
+			//return ++serial;
+			return (uint)System.Threading.Interlocked.Increment (ref serial);
 		}


Still broken build, part way to allowing non-generic registrations

--- TinyIoC/TinyIoC.cs
+++ TinyIoC/TinyIoC.cs
@@ -146,12 +146,12 @@
             /// <exception cref="TinyIoCInstantiationTypeException"></exception>
             public RegisterOptions AsMultiInstance()
             {
-                var currentFactory = _Container.GetCurrentFactory<RegisterType>(_Name);
+                var currentFactory = _Container.GetCurrentFactory(_Registration);

                 if (currentFactory == null)
-                    throw new TinyIoCRegistrationException(typeof(RegisterType), "multi-instance");
-
-                return _Container.AddUpdateRegistration<RegisterType, RegisterImplementation>(currentFactory.MultiInstanceVariant);
+                    throw new TinyIoCRegistrationException(_Registration.Type, "multi-instance");
+
+                return _Container.AddUpdateRegistration(_Registration, currentFactory.MultiInstanceVariant);
             }

             /// <summary>
@@ -159,14 +159,14 @@
             /// </summary>
             /// <returns>RegisterOptions</returns>
             /// <exception cref="TinyIoCInstantiationTypeException"></exception>
-            public RegisterOptions<RegisterType, RegisterImplementation> WithWeakReference()
-            {
-                var currentFactory = _Container.GetCurrentFactory<RegisterType>();
+            public RegisterOptions WithWeakReference()
+            {
+                var currentFactory = _Container.GetCurrentFactory(_Registration);

                 if (currentFactory == null)
-                    throw new TinyIoCRegistrationException(typeof(RegisterType), "weak reference");
-
-                return _Container.AddUpdateRegistration<RegisterType, RegisterImplementation>(currentFactory.WeakReferenceVariant);
+                    throw new TinyIoCRegistrationException(_Registration.Type, "weak reference");
+
+                return _Container.AddUpdateRegistration(_Registration, currentFactory.WeakReferenceVariant);
             }

             /// <summary>
@@ -174,14 +174,14 @@
             /// </summary>
             /// <returns>RegisterOptions</returns>
             /// <exception cref="TinyIoCInstantiationTypeException"></exception>
-            public RegisterOptions<RegisterType, RegisterImplementation> WithStrongReference()
-            {
-                var currentFactory = _Container.GetCurrentFactory<RegisterType>();
+            public RegisterOptions WithStrongReference()
+            {
+                var currentFactory = _Container.GetCurrentFactory(_Registration);

                 if (currentFactory == null)
-                    throw new TinyIoCRegistrationException(typeof(RegisterType), "strong reference");
-
-                return _Container.AddUpdateRegistration<RegisterType, RegisterImplementation>(currentFactory.StrongReferenceVariant);
+                    throw new TinyIoCRegistrationException(_Registration.Type, "strong reference");
+
+                return _Container.AddUpdateRegistration(_Registration, currentFactory.StrongReferenceVariant);
             }
         }
         #endregion
@@ -193,10 +193,10 @@
         /// </summary>
         /// <typeparam name="RegisterImplementation">Type to register</typeparam>
         /// <returns>RegisterOptions for fluent API</returns>
-        public RegisterOptions<RegisterImplementation, RegisterImplementation> Register<RegisterImplementation>()
-            where RegisterImplementation : class
-        {
-            return Register<RegisterImplementation, RegisterImplementation>();
+        public RegisterOptions Register<RegisterType>()
+            where RegisterType : class
+        {
+            return Register(typeof(RegisterType));
         }

         /// <summary>
@@ -205,10 +205,10 @@
         /// <typeparam name="RegisterImplementation">Type to register</typeparam>
         /// <param name="name">Name of registration</param>
         /// <returns>RegisterOptions for fluent API</returns>
-        public RegisterOptions<RegisterImplementation, RegisterImplementation> Register<RegisterImplementation>(string name)
-            where RegisterImplementation : class
-        {
-            return Register<RegisterImplementation, RegisterImplementation>(name);
+        public RegisterOptions Register<RegisterType>(string name)
+            where RegisterType : class
+        {
+            return Register(typeof(RegisterType), name);
         }

         /// <summary>
@@ -217,11 +217,11 @@
         /// <typeparam name="RegisterType">Type to register</typeparam>
         /// <typeparam name="RegisterImplementation">Type to instantiate that implements RegisterType</typeparam>
         /// <returns>RegisterOptions for fluent API</returns>
-        public RegisterOptions<RegisterType, RegisterImplementation> Register<RegisterType, RegisterImplementation>()
+        public RegisterOptions Register<RegisterType, RegisterImplementation>()
             where RegisterType : class
             where RegisterImplementation : class, RegisterType
         {
-            return AddUpdateRegistration<RegisterType, RegisterImplementation>(GetDefaultObjectFactory<RegisterType, RegisterImplementation>());
+            return Register(typeof(RegisterType), typeof(RegisterImplementation));
         }

         /// <summary>
@@ -231,11 +231,11 @@
         /// <typeparam name="RegisterImplementation">Type to instantiate that implements RegisterType</typeparam>
         /// <param name="name">Name of registration</param>
         /// <returns>RegisterOptions for fluent API</returns>
-        public RegisterOptions<RegisterType, RegisterImplementation> Register<RegisterType, RegisterImplementation>(string name)
+        public RegisterOptions Register<RegisterType, RegisterImplementation>(string name)
             where RegisterType : class
             where RegisterImplementation : class, RegisterType
         {
-            return AddUpdateRegistration<RegisterType, RegisterImplementation>(GetDefaultObjectFactory<RegisterType, RegisterImplementation>(), name);
+            return Register(typeof(RegisterType), typeof(RegisterImplementation), name);
         }

         /// <summary>
@@ -244,10 +244,10 @@
         /// <typeparam name="RegisterImplementation">Type to register</typeparam>
         /// <param name="instance">Instance of RegisterType to register</param>
         /// <returns>RegisterOptions for fluent API</returns>
-        public RegisterOptions<RegisterType, RegisterType> Register<RegisterType>(RegisterType instance)
+        public RegisterOptions Register<RegisterType>(RegisterType instance)
            where RegisterType : class
         {
-            return AddUpdateRegistration<RegisterType, RegisterType>(new InstanceFactory<RegisterType, RegisterType>(instance));
+            return Register(typeof(RegisterType), instance);
         }

         /// <summary>
@@ -257,10 +257,10 @@
         /// <param name="instance">Instance of RegisterType to register</param>
         /// <param name="name">Name of registration</param>
         /// <returns>RegisterOptions for fluent API</returns>
-        public RegisterOptions<RegisterType, RegisterType> Register<RegisterType>(RegisterType instance, string name)
-            where RegisterType : class
-        {
-            return AddUpdateRegistration<RegisterType, RegisterType>(new InstanceFactory<RegisterType, RegisterType>(instance), name);
+        public RegisterOptions Register<RegisterType>(RegisterType instance, string name)
+            where RegisterType : class
+        {
+            return Register(typeof(RegisterType), instance, name);
         }

         /// <summary>
@@ -269,10 +269,10 @@
         /// <typeparam name="RegisterType">Type to register</typeparam>
         /// <param name="factory">Factory/lambda that returns an instance of RegisterType</param>
         /// <returns>RegisterOptions for fluent API</returns>
-        public RegisterOptions<RegisterType, RegisterType> Register<RegisterType>(Func<TinyIoC, NamedParameterOverloads, RegisterType> factory)
-            where RegisterType : class
-        {
-            return AddUpdateRegistration<RegisterType, RegisterType>(new DelegateFactory<RegisterType>(factory));
+        public RegisterOptions Register<RegisterType>(Func<TinyIoC, NamedParameterOverloads, RegisterType> factory)
+            where RegisterType : class
+        {
+            return Register(typeof(RegisterType), factory);
         }

         /// <summary>
@@ -282,11 +282,32 @@
         /// <param name="factory">Factory/lambda that returns an instance of RegisterType</param>
         /// <param name="name">Name of registation</param>
         /// <returns>RegisterOptions for fluent API</returns>
-        public RegisterOptions<RegisterType, RegisterType> Register<RegisterType>(Func<TinyIoC, NamedParameterOverloads, RegisterType> factory, string name)
-            where RegisterType : class
-        {
-            return AddUpdateRegistration<RegisterType, RegisterType>(new DelegateFactory<RegisterType>(factory), name);
-        }
+        public RegisterOptions Register<RegisterType>(Func<TinyIoC, NamedParameterOverloads, RegisterType> factory, string name)
+            where RegisterType : class
+        {
+            return Register(typeof(RegisterType), factory, name);
+        }
+
+        public RegisterOptions Register(Type registerType)
+        {
+            return RegisterInternal(registerType, registerType, String.Empty, GetDefaultObjectFactory(registerType, registerType));
+        }
+
+        public RegisterOptions Register(Type registerType, string name)
+        {
+            throw new NotImplementedException();
+        }
+
+        public RegisterOptions Register(Type registerType, Type registerImplementation)
+        {
+            throw new NotImplementedException();
+        }
+
+        public RegisterOptions Register(Type registerType, Type registerImplementation, string name)
+        {
+            throw new NotImplementedException();
+        }
+
         #endregion

         #region Resolution
@@ -396,7 +417,7 @@
         public RegisterType Resolve<RegisterType>(string name, NamedParameterOverloads parameters, ResolveOptions options)
             where RegisterType : class
         {
-            return (ResolveInternal(typeof(RegisterType), name, parameters, options) as RegisterType);
+            return (Resolve(typeof(RegisterType), name, parameters, options) as RegisterType);
         }

         /// <summary>
@@ -1105,29 +1126,25 @@
             this.Register<TinyIoC>(this);
         }

-        private ObjectFactoryBase GetCurrentFactory(Type registerType, string name)
+        private ObjectFactoryBase GetCurrentFactory(TypeRegistration registration)
         {
             ObjectFactoryBase current = null;

-            _RegisteredTypes.TryGetValue(new TypeRegistration(registerType), out current);
+            _RegisteredTypes.TryGetValue(registration, out current);

             return current;
         }

-        private RegisterOptions<RegisterType, RegisterImplementation> AddUpdateRegistration<RegisterType, RegisterImplementation>(ObjectFactoryBase factory)
-            where RegisterType : class
-            where RegisterImplementation : class, RegisterType
-        {
-            return AddUpdateRegistration<RegisterType, RegisterImplementation>(factory, string.Empty);
-        }
-
-        private RegisterOptions<RegisterType, RegisterImplementation> AddUpdateRegistration<RegisterType, RegisterImplementation>(ObjectFactoryBase factory, string name)
-            where RegisterType : class
-            where RegisterImplementation : class, RegisterType
+        private RegisterOptions RegisterInternal(Type registerType, Type registerImplementation, string name, ObjectFactoryBase factory)
+        {
+            var typeRegistration = new TypeRegistration(registerType, name);
+
+            return AddUpdateRegistration(typeRegistration, factory);
+        }
+
+        private RegisterOptions AddUpdateRegistration(TypeRegistration typeRegistration, ObjectFactoryBase factory)
         {
             ObjectFactoryBase current;
-
-            var typeRegistration = new TypeRegistration(typeof(RegisterType), name);

             lock (RegistrationLock)
             {
@@ -1142,18 +1159,11 @@
                 _RegisteredTypes[typeRegistration] = factory;
             }

-            return new RegisterOptions<RegisterType, RegisterImplementation>(this);
-        }
-
-        private void RemoveRegistration<RegisterType>()
-        {
-            RemoveRegistration<RegisterType>(string.Empty);
-        }
-
-        private void RemoveRegistration<RegisterType>(string name)
-        {
-            var typeRegistration = new TypeRegistration(typeof(RegisterType), name);
-
+            return new RegisterOptions(this, typeRegistration);
+        }
+
+        private void RemoveRegistration(TypeRegistration typeRegistration)
+        {
             lock (RegistrationLock)
             {
                 _RegisteredTypes.Remove(typeRegistration);


監視サービスのDispose呼び出し

監視サービスのDispose呼び出し

--- imageClipPaste/ViewModel/MainViewModel.cs
+++ imageClipPaste/ViewModel/MainViewModel.cs
@@ -136,6 +136,8 @@
         public override void Cleanup()
         {
             _clipboardMonitorService.Stop();
+            _clipboardMonitorService.CapturedNewerImage -= imageWatcher_CapturedNewerImage;
+            _clipboardMonitorService.Dispose();
             CleanupImagePaste();
             base.Cleanup();
         }


Fix array sizing in Base64ToBinary

Fix array sizing in Base64ToBinary

Fix provided by @samuel-lucas6
Fixes #63

--- src/Sodium.Core/Utilities.cs
+++ src/Sodium.Core/Utilities.cs
@@ -168,14 +168,14 @@
             }

             int base64MaxLen = SodiumLibrary.sodium_base64_encoded_len(data.Length, (int)variant);
-            var b64 = new byte[base64MaxLen - 1];
+            var b64 = new byte[base64MaxLen];
             var base64 = SodiumLibrary.sodium_bin2base64(b64, base64MaxLen, data, data.Length, (int)variant);
             if (base64 == IntPtr.Zero)
             {
                 throw new OverflowException("Internal error, encoding failed.");
             }

-            return Marshal.PtrToStringAnsi(base64);
+            return Marshal.PtrToStringAnsi(base64)?.TrimEnd('\0');
         }

         /// <summary>Converts Base64 encoded string to byte array.</summary>


Modified displaying number and statement control's parameter to read-only.

--- CalculatorApp/FormCalc.Designer.cs
+++ CalculatorApp/FormCalc.Designer.cs
@@ -206,6 +206,7 @@
             this.buttonPoint.TabIndex = 14;
             this.buttonPoint.Text = "．";
             this.buttonPoint.UseVisualStyleBackColor = true;
+            this.buttonPoint.Visible = false;
             this.buttonPoint.Click += new System.EventHandler(this.buttonPoint_Click);
             //
             // buttonInputMul
@@ -253,6 +254,7 @@
             this.textBoxDisplayExpr.Font = new System.Drawing.Font("MS UI Gothic", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
             this.textBoxDisplayExpr.Location = new System.Drawing.Point(3, 4);
             this.textBoxDisplayExpr.Name = "textBoxDisplayExpr";
+            this.textBoxDisplayExpr.ReadOnly = true;
             this.textBoxDisplayExpr.Size = new System.Drawing.Size(288, 27);
             this.textBoxDisplayExpr.TabIndex = 19;
             this.textBoxDisplayExpr.TabStop = false;
@@ -264,8 +266,10 @@
             this.textBoxDispNumber.Font = new System.Drawing.Font("MS UI Gothic", 20F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
             this.textBoxDispNumber.Location = new System.Drawing.Point(3, 34);
             this.textBoxDispNumber.Name = "textBoxDispNumber";
+            this.textBoxDispNumber.ReadOnly = true;
             this.textBoxDispNumber.Size = new System.Drawing.Size(288, 41);
             this.textBoxDispNumber.TabIndex = 20;
+            this.textBoxDispNumber.TabStop = false;
             this.textBoxDispNumber.TextAlign = System.Windows.Forms.HorizontalAlignment.Right;
             //
             // panelOutput


Fix path parsing

Fix path parsing

--- Cascara/Src/LayoutFileProcessor.cs
+++ Cascara/Src/LayoutFileProcessor.cs
@@ -742,7 +742,7 @@
             string parent;
             LayoutFile top = layoutFileStack.Peek();

-            if (top.SourcePath == null)
+            if (top.SourcePath != null)
             {
                 parent = Path.GetDirectoryName(top.SourcePath);
             }


clean up

clean up

--- src/TweetMapR/Model/Tweet.cs
+++ src/TweetMapR/Model/Tweet.cs
@@ -1,28 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Web;
-
-namespace TweetMapR.Model {
-
-    public class Tweet {
-
-        public string User { get; set; }
-        public string TweetText { get; set; }
-        public string CreatedAt { get; set; }
-        public string ImageUrl { get; set; }
-        public string Location { get; set; }
-        public string Longitude { get; set; }
-        public string Latitude { get; set; }
-
-        public string TweetTextHtml {
-
-            get {
-
-                return (!string.IsNullOrEmpty(TweetText)) ?
-                    TweetText.ParseURL().ParseHashtag().ParseUsername() :
-                    TweetText;
-            }
-        }
-    }
-}


Added the BoboBrowse.Net.Facets.Data namespace to the BasicTests.

--- src/BoboBrowse.Tests/BasicTests.cs
+++ src/BoboBrowse.Tests/BasicTests.cs
@@ -2,6 +2,7 @@
 {
     using BoboBrowse.Net;
     using BoboBrowse.Net.Facets;
+    using BoboBrowse.Net.Facets.Data;
     using BoboBrowse.Net.Facets.Impl;
     using BoboBrowse.Net.Search;
     using Lucene.Net.Analysis;


OffScreen - Simplify BitmapBuffer.ResizeBuffer

Was using Array.Resize to modify the existing array, unfortunately this doesn't yield the performance result the name implies.
A new array is created and copies elements from the old array, so performance is actually worse than allocating a new array.
For now we'll just create a new empty array.

https://msdn.microsoft.com/en-us/library/bb348051(v=vs.110).aspx

--- CefSharp.OffScreen/BitmapBuffer.cs
+++ CefSharp.OffScreen/BitmapBuffer.cs
@@ -50,22 +50,13 @@
 		//TODO: May need to Pin the buffer in memory using GCHandle.Alloc(this.buffer, GCHandleType.Pinned);
 		private void ResizeBuffer(int width, int height)
 		{
-			if (buffer == null)
+			if (buffer == null || width != Width || height != Height)
 			{
 				//No of Pixels (width * height) * BytesPerPixel
 				NumberOfBytes = width * height * BytesPerPixel;

 				buffer = new byte[NumberOfBytes];

-				Width = width;
-				Height = height;
-			}
-			else if (width != Width || height != Height)
-			{
-				//No of Pixels (width * height) * BytesPerPixel
-				NumberOfBytes = width * height * BytesPerPixel;
-
-				Array.Resize(ref buffer, NumberOfBytes);
 				Width = width;
 				Height = height;
 			}


Removed Akka.Actor using statement to match the instructions

--- src/Unit-1/DoThis/Program.cs
+++ src/Unit-1/DoThis/Program.cs
@@ -1,5 +1,4 @@
 using System;
-using Akka.Actor;

 namespace WinTail
 {


Fix typo

Fix typo

--- src/Cake.Core/IO/ProcessWrapper.cs
+++ src/Cake.Core/IO/ProcessWrapper.cs
@@ -77,7 +77,7 @@
                 {
                     continue;
                 }
-                _log.Debug(log => log("{0}", _filterOutput(line)));
+                _log.Debug(log => log("{0}", _filterError(line)));
                 yield return line;
             }
         }


added correct extension for an updated Linux package so that updates work

--- AboutPage/UpdateControlData.cs
+++ AboutPage/UpdateControlData.cs
@@ -129,7 +129,7 @@
 				}
 				else if (OsInformation.OperatingSystem == OSType.X11)
 				{
-					return "deb";
+					return "tar.gz";
 				}
 				else if (OsInformation.OperatingSystem == OSType.Android)
 				{


WPF Popup bind layout transform to parent

Popup needs to allow transparency or only ScaleTrasnform will work (comment in reference source see https://referencesource.microsoft.com/#PresentationFramework/src/Framework/System/Windows/Controls/Primitives/Popup.cs,1713)
Bind the parent LayoutTransformProperty to the popup LayoutTransformProperty

Resolves #2151

--- CefSharp.Wpf/ChromiumWebBrowser.cs
+++ CefSharp.Wpf/ChromiumWebBrowser.cs
@@ -1821,7 +1821,16 @@
                 Child = popupImage = CreateImage(),
                 PlacementTarget = this,
                 Placement = PlacementMode.Absolute,
+                //Needs to allow transparency or only ScaleTransforms are allowed
+                //https://referencesource.microsoft.com/#PresentationFramework/src/Framework/System/Windows/Controls/Primitives/Popup.cs,1713
+                AllowsTransparency = true
             };
+
+            BindingOperations.SetBinding(newPopup, FrameworkElement.LayoutTransformProperty, new Binding
+            {
+                Path = new PropertyPath(FrameworkElement.LayoutTransformProperty),
+                Source = this,
+            });

             newPopup.Opened += PopupOpened;
             newPopup.Closed += PopupClosed;


Show the administrator message as a dialog too...

--- ChocolateyExplorer.WPF/App.xaml.cs
+++ ChocolateyExplorer.WPF/App.xaml.cs
@@ -57,7 +57,7 @@
                 {
                     Process.Start(processInfo);
                 }
-                catch (Exception)
+                catch
                 {
                     var messageBox = new ModernDialog
                     {
@@ -65,7 +65,7 @@
                         Content = new ErrorDialog(new InvalidOperationException("Chocolatey Explorer must be run as an administrator."))
                     };

-                    messageBox.Show();
+                    messageBox.ShowDialog();
                 }

                 this.Shutdown();


Remove "Printing Window..." menu item from Release

--- ApplicationView/MenuRow/MenuOptionFile.cs
+++ ApplicationView/MenuRow/MenuOptionFile.cs
@@ -31,9 +31,10 @@
 		{
 			return new List<MenuItemAction>
 			{
-				// TODO: Helper while building printing window prototype... remove once finalized
+#if DEBUG
 				new MenuItemAction("Printing Window...".Localize(), () => PrintingWindow.Show()),
 				new MenuItemAction("------------------------", null),
+#endif
 				new MenuItemAction("Add Printer".Localize(), AddPrinter_Click),
 				new MenuItemAction("Import Printer".Localize(), ImportPrinter),
 				new MenuItemAction("Add File To Queue".Localize(), importFile_Click),


退避完了後のエラーを修正

退避完了後のエラーを修正

--- Assets/Cleaner/Editor/FindUnusedAssets.cs
+++ Assets/Cleaner/Editor/FindUnusedAssets.cs
@@ -108,11 +108,16 @@
 			using (var horizonal = new EditorGUILayout.HorizontalScope("box")) {
 				EditorGUILayout.Space();
 				if (GUILayout.Button ("Exclude from Project", GUILayout.Width (160)) && deleteAssets.Count != 0) {
-					RemoveFiles ();
-					Close ();
-				}
-			}
-
+					EditorApplication.delayCall += Exclude;
+				}
+			}
+
+		}
+
+		void Exclude()
+		{
+			RemoveFiles ();
+			Close ();
 		}

 	     static void CleanDir()


Fixed bug created by residu of testing code.

--- Assets/Scripts/AdaptiveMusicController.cs
+++ Assets/Scripts/AdaptiveMusicController.cs
@@ -11,7 +11,6 @@
 	void Start () {
 		InitialiseTracks();
 		PlayAll();
-		StartCoroutine(VolumeTest());
 	}

 	void InitialiseTracks() {


cameracontroller comments

cameracontroller comments

--- Assets/Scripts/Camera/CameraController.cs
+++ Assets/Scripts/Camera/CameraController.cs
@@ -4,7 +4,7 @@

 public class CameraController : MonoBehaviour {

-	//player(and controller) and camera(and controller) objects
+	//player(with controller) and camera(with controller) objects
 	[SerializeField] private GameObject player;
 	[SerializeField] private Camera camera;
 	[SerializeField] private CameraController cameraCont;
@@ -41,7 +41,7 @@
 		if (UnityDepth.instance.PPU == null) {
 			UnityDepth.instance.PPU = 32;
 		}
-		camera = this.GetComponent<Camera> ();//Camera.FindObjectOfType (typeof(Camera)) as Camera;
+		camera = this.GetComponent<Camera> ();
 		player = GameObject.FindWithTag ("Player");

 		playerCont = player.GetComponent<PlayerController>();


Add namespace

Add namespace

--- Assets/Scripts/Map/MapHighlightManager.cs
+++ Assets/Scripts/Map/MapHighlightManager.cs
@@ -1,15 +1,11 @@
 using UnityEngine;
 using System.Collections;

-public class MapHighlightManager : MonoBehaviour {
+namespace ecorealms.map {
+	public class MapHighlightManager : MonoBehaviour {

-	// Use this for initialization
-	void Start () {
-
-	}
-
-	// Update is called once per frame
-	void Update () {
-
+		void Setup () {
+
+		}
 	}
 }


final tweaks

final tweaks

- disable skybox mipmaps
- disable skybox edge smoothing
• change skybox resolution to 1024x1024

--- Assets/Voxelgon/Scripts/StarController.cs
+++ Assets/Voxelgon/Scripts/StarController.cs
@@ -4,9 +4,8 @@

 	public void Begin() {
-		var map = new Cubemap(2048, TextureFormat.RGB24, true);
+		var map = new Cubemap(1024, TextureFormat.RGB24, false);
 		if (gameObject.GetComponent<Camera>().RenderToCubemap(map)) {
-			map.SmoothEdges(200);
 			Camera.main.gameObject.GetComponent<Skybox>().material.SetTexture("_Tex", map);
 		}
 		Destroy(gameObject);


Fix `InputManager` potentially switching focus while target not visible

--- osu.Framework/Input/InputManager.cs
+++ osu.Framework/Input/InputManager.cs
@@ -384,7 +384,7 @@
             if (potentialFocusTarget == FocusedDrawable)
                 return true;

-            if (potentialFocusTarget != null && (!potentialFocusTarget.IsPresent || !potentialFocusTarget.AcceptsFocus))
+            if (potentialFocusTarget != null && !isDrawableValidForFocus(potentialFocusTarget))
                 return false;

             var previousFocus = FocusedDrawable;
@@ -906,18 +906,28 @@
         {
             if (FocusedDrawable == null) return true;

-            bool stillValid = FocusedDrawable.IsAlive && FocusedDrawable.IsPresent && FocusedDrawable.Parent != null;
-
-            if (stillValid)
+            if (isDrawableValidForFocus(FocusedDrawable))
+                return false;
+
+            Logger.Log($"Focus on \"{FocusedDrawable}\" no longer valid as a result of {nameof(unfocusIfNoLongerValid)}.", LoggingTarget.Runtime, LogLevel.Debug);
+            ChangeFocus(null);
+            return true;
+        }
+
+        private bool isDrawableValidForFocus(Drawable drawable)
+        {
+            bool valid = drawable.IsAlive && drawable.IsPresent && drawable.Parent != null;
+
+            if (valid)
             {
                 //ensure we are visible
-                CompositeDrawable d = FocusedDrawable.Parent;
+                CompositeDrawable d = drawable.Parent;

                 while (d != null)
                 {
                     if (!d.IsPresent || !d.IsAlive)
                     {
-                        stillValid = false;
+                        valid = false;
                         break;
                     }

@@ -925,12 +935,7 @@
                 }
             }

-            if (stillValid)
-                return false;
-
-            Logger.Log($"Focus on \"{FocusedDrawable}\" no longer valid as a result of {nameof(unfocusIfNoLongerValid)}.", LoggingTarget.Runtime, LogLevel.Debug);
-            ChangeFocus(null);
-            return true;
+            return valid;
         }

         protected virtual void ChangeFocusFromClick(Drawable clickedDrawable)


Use nameof operator

Use nameof operator

--- Blaze/Blaze/Randomization/RandomHelper.cs
+++ Blaze/Blaze/Randomization/RandomHelper.cs
@@ -13,7 +13,7 @@

         public static double NextDouble(double maxValue)
         {
-            if (maxValue < 0) throw new ArgumentOutOfRangeException("maxValue", "maxValue is less than 0.");
+            if (maxValue < 0) throw new ArgumentOutOfRangeException(nameof(maxValue), maxValue, "The value must be non-negative.");

             return NextDouble(0, maxValue);
         }
@@ -30,7 +30,7 @@

         public static IEnumerable<TSource> Shuffle<TSource>(this IEnumerable<TSource> source)
         {
-            if (source == null) throw new ArgumentNullException("source");
+            if (source == null) throw new ArgumentNullException(nameof(source));

             var l = source.ToList();

@@ -44,16 +44,16 @@

         public static T GetRandomElement<T>(this IList<T> source)
         {
-            if (source == null) throw new ArgumentNullException("source");
-            if (source.Count == 0) throw new ArgumentException("The source must not be empty.", "source");
+            if (source == null) throw new ArgumentNullException(nameof(source));
+            if (source.Count == 0) throw new ArgumentException("The source must not be empty.", nameof(source));

             return source[_random.Next(source.Count)];
         }

         public static IEnumerable<T> GetRandomPiece<T>(this IList<T> source, int count)
         {
-            if (source == null) throw new ArgumentNullException("source");
-            if (count < 0) throw new ArgumentOutOfRangeException("count", count, "The value must be non-negative.");
+            if (source == null) throw new ArgumentNullException(nameof(source));
+            if (count < 0) throw new ArgumentOutOfRangeException(nameof(count), count, "The value must be non-negative.");

             if (count == 0) return Enumerable.Empty<T>();
             if (count >= source.Count) return source;


Reduce stddev buffer size to allow faster adjusting after FPS changes

--- osu.Framework/Timing/FramedClock.cs
+++ osu.Framework/Timing/FramedClock.cs
@@ -30,7 +30,7 @@

         public FrameTimeInfo TimeInfo => new FrameTimeInfo { Elapsed = ElapsedFrameTime, Current = CurrentTime };

-        private readonly double[] betweenFrameTimes = new double[256];
+        private readonly double[] betweenFrameTimes = new double[128];

         private long totalFramesProcessed;


Update grammar in StringBuilderInLoopAnalyzer.cs #839

--- src/CSharp/CodeCracker/Performance/StringBuilderInLoopAnalyzer.cs
+++ src/CSharp/CodeCracker/Performance/StringBuilderInLoopAnalyzer.cs
@@ -14,8 +14,7 @@
         internal const string Title = "Don't concatenate strings in loops";
         internal const string MessageFormat = "Don't concatenate '{0}' in a loop";
         internal const string Category = SupportedCategories.Performance;
-        const string Description = "Do not concatenate a string on a loop. It will alocate a lot of memory."
-            + "Use a StringBuilder instead. It will will require less allocation, less garbage collector work, less CPU cycles, and less overall time.";
+        const string Description = "Don't concatenate strings in a loop. Using a StringBuilder will require less memory and time.";

         internal static readonly DiagnosticDescriptor Rule = new DiagnosticDescriptor(
             DiagnosticId.StringBuilderInLoop.ToDiagnosticId(),
@@ -84,4 +83,4 @@
             context.ReportDiagnostic(diagnostic);
         }
     }
-}+}


In components event dispatch, use explicit fire-and-forget instead of async void (#10149)

--- src/Components/Blazor/Blazor/src/Rendering/WebAssemblyRenderer.cs
+++ src/Components/Blazor/Blazor/src/Rendering/WebAssemblyRenderer.cs
@@ -152,13 +152,16 @@

                     if (deferredIncomingEvents.Count > 0)
                     {
-                        ProcessNextDeferredEvent();
+                        // Fire-and-forget because the task we return from this method should only reflect the
+                        // completion of its own event dispatch, not that of any others that happen to be queued.
+                        // Also, ProcessNextDeferredEventAsync deals with its own async errors.
+                        _ = ProcessNextDeferredEventAsync();
                     }
                 }
             }
         }

-        private async void ProcessNextDeferredEvent()
+        private async Task ProcessNextDeferredEventAsync()
         {
             var info = deferredIncomingEvents.Dequeue();
             var taskCompletionSource = info.TaskCompletionSource;


removed useless overload

removed useless overload

--- src/EventStore.Tools.Infrastructure/EventStoreDomainRepository.cs
+++ src/EventStore.Tools.Infrastructure/EventStoreDomainRepository.cs
@@ -89,11 +89,6 @@

         public override Task<WriteResult> SaveAsync<TAggregate>(TAggregate aggregate)
         {
-            return SaveAsync(aggregate, _expectedVersion, _metadata);
-        }
-
-        private Task<WriteResult> SaveAsync<TAggregate>(TAggregate aggregate, int expectedMetastreamVersion, StreamMetadata metadata) where TAggregate : IAggregate
-        {
             var streamName = AggregateToStreamName(aggregate.GetType(), aggregate.AggregateId);
             SaveMetadata(streamName);
             var events = aggregate.UncommitedEvents().ToList();


-n  Fixed a problem with cross-context injections that could cause a named binding to unmap an unnamed one

--- extensions/injector/impl/CrossContextInjectionBinder.cs
+++ extensions/injector/impl/CrossContextInjectionBinder.cs
@@ -69,7 +69,7 @@
 					}
 					else
 					{
-						Unbind(key); //remove this cross context binding from the local binder
+						Unbind(key, binding.name); //remove this cross context binding from the local binder
 						CrossContextBinder.ResolveBinding(binding, key);
 					}
 				}


Address Eyal's comments

Address Eyal's comments

--- src/Integration.UnitTests/Service/SonarQubeServiceWrapperTests.cs
+++ src/Integration.UnitTests/Service/SonarQubeServiceWrapperTests.cs
@@ -886,8 +886,10 @@

             private void HandlePathRequest(IOwinContext context)
             {
+                string path = context.Request.Uri.PathAndQuery.TrimStart('/');
+
                 RequestHandler handler;
-                if (this.uriRequestHandler.TryGetValue(context.Request.Uri.PathAndQuery.TrimStart('/'), out handler))
+                if (this.uriRequestHandler.TryGetValue(path, out handler))
                 {
                     try
                     {
@@ -902,7 +904,7 @@
                 }
                 else
                 {
-                    Debug.WriteLine("Handler not found", context.Request.Uri.PathAndQuery.TrimStart('/'));
+                    Debug.WriteLine("Handler not found", path);
                     context.Response.StatusCode = (int)HttpStatusCode.NotFound;
                 }
             }
@@ -971,7 +973,7 @@

             protected void Dispose(bool disposing)
             {
-                if (!isDisposed)
+                if (!this.isDisposed)
                 {
                     if (disposing)
                     {
@@ -979,14 +981,14 @@
                         this.server = null;
                     }

-                    isDisposed = true;
+                    this.isDisposed = true;
                 }
             }

             public void Dispose()
             {
                 // Do not change this code. Put cleanup code in Dispose(bool disposing) above.
-                Dispose(true);
+                this.Dispose(true);
             }

             #endregion


Fix a few tests

Fix a few tests

--- NBi.Testing/Unit/Core/Variable/TestVariableFactoryTest.cs
+++ NBi.Testing/Unit/Core/Variable/TestVariableFactoryTest.cs
@@ -21,18 +21,20 @@
             var resolver = new CSharpScalarResolver<object>(new CSharpScalarResolverArgs("DateTime.Now.Year"));
             var variable = factory.Instantiate(resolver);

-            Assert.That(variable, Is.TypeOf<ITestVariable>());
+            Assert.That(variable, Is.AssignableTo<ITestVariable>());
+            Assert.That(variable, Is.TypeOf<TestVariable>());
         }

         [Test]
         public void Instantiate_QueryScalar_TestVariable()
         {
             var factory = new TestVariableFactory();
-            var queryResolverArgsMock = Mock.Of<QueryResolverArgs>();
-            var resolver = new QueryScalarResolver<object>(new QueryScalarResolverArgs(queryResolverArgsMock));
+            var queryResolverArgsMock = new Mock<QueryResolverArgs>(null, null, null, null);
+            var resolver = new QueryScalarResolver<object>(new QueryScalarResolverArgs(queryResolverArgsMock.Object));
             var variable = factory.Instantiate(resolver);

-            Assert.That(variable, Is.TypeOf<ITestVariable>());
+            Assert.That(variable, Is.AssignableTo<ITestVariable>());
+            Assert.That(variable, Is.TypeOf<TestVariable>());
         }

         [Test]


Fixed logic for sending foreign user information (HG).

--- OpenSim/Region/Communications/Hypergrid/HGGridServices.cs
+++ OpenSim/Region/Communications/Hypergrid/HGGridServices.cs
@@ -893,20 +893,31 @@
         public bool SendUserInformation(RegionInfo regInfo, AgentCircuitData agentData)
         {
             CachedUserInfo uinfo = m_userProfileCache.GetUserDetails(agentData.AgentID);
-            if ((uinfo == null) || !IsGoingHome(uinfo, regInfo))
-            {
-                m_log.Info("[HGrid]: User seems to be going to foreign region " + uinfo.UserProfile.FirstName + " " + uinfo.UserProfile.SurName);
+
+            if ((IsLocalUser(uinfo) && IsHyperlinkRegion(regInfo.RegionHandle)) ||
+                (!IsLocalUser(uinfo) && !IsGoingHome(uinfo, regInfo)))
+            {
+                m_log.Info("[HGrid]: Local user is going to foreign region or foreign user is going elsewhere");
                 if (!InformRegionOfUser(regInfo, agentData))
                 {
                     m_log.Warn("[HGrid]: Could not inform remote region of transferring user.");
                     return false;
                 }
             }
-            else
-                m_log.Info("[HGrid]: User seems to be going home " + uinfo.UserProfile.FirstName + " " + uinfo.UserProfile.SurName);
+            //if ((uinfo == null) || !IsGoingHome(uinfo, regInfo))
+            //{
+            //    m_log.Info("[HGrid]: User seems to be going to foreign region.");
+            //    if (!InformRegionOfUser(regInfo, agentData))
+            //    {
+            //        m_log.Warn("[HGrid]: Could not inform remote region of transferring user.");
+            //        return false;
+            //    }
+            //}
+            //else
+            //    m_log.Info("[HGrid]: User seems to be going home " + uinfo.UserProfile.FirstName + " " + uinfo.UserProfile.SurName);

             // May need to change agent's name
-            if (IsLocalUser(uinfo))
+            if (IsLocalUser(uinfo) && IsHyperlinkRegion(regInfo.RegionHandle))
             {
                 agentData.firstname = agentData.firstname + "." + agentData.lastname;
                 agentData.lastname = "@" + serversInfo.UserURL.Replace("http://", ""); ; //HGNetworkServersInfo.Singleton.LocalUserServerURI;


Fix build.

Fix build.

--- OpenSim/Region/CoreModules/World/Terrain/TerrainModule.cs
+++ OpenSim/Region/CoreModules/World/Terrain/TerrainModule.cs
@@ -667,7 +667,7 @@
             {
                 if (!m_terrainPatchesSent.ContainsKey(client.AgentId))
                 {
-                    m_terrainPatchesSent.Add(client.AgentId.UUID, new bool[(int)m_scene.RegionInfo.RegionSizeX / 16,
+                    m_terrainPatchesSent.Add(client.AgentId, new bool[(int)m_scene.RegionInfo.RegionSizeX / 16,
                         (int)m_scene.RegionInfo.RegionSizeY / 16]);
                 }
             }


check column width changed

check column width changed

--- FTAnalyser/Forms/Controls/VirtualDataGridView.cs
+++ FTAnalyser/Forms/Controls/VirtualDataGridView.cs
@@ -18,6 +18,7 @@
             VirtualMode = true;
             CellValueNeeded += OnCellValueNeeded;
             ColumnHeaderMouseClick += OnColumnHeaderMouseClick;
+            ColumnWidthChanged += OnColumnWidthChanged; // for debugging purposes
             AllowUserToAddRows = false;
             AllowUserToOrderColumns = true;
             AllowUserToResizeColumns = true;
@@ -106,6 +107,11 @@
             e.Value = GetValueFor(data, Columns[e.ColumnIndex].DataPropertyName);
         }

+        void OnColumnWidthChanged(object sender, DataGridViewColumnEventArgs e)
+        {
+            Console.WriteLine($"Column {e.Column.Name} changed width to {e.Column.Width}");
+        }
+
         protected abstract object GetValueFor(T data, string propertyName);

         class PropertyComparer : IComparer<T>


Give a meaningful message if terrain save fails because of a file IO error. Fixes Mantis #3348

--- OpenSim/Region/CoreModules/World/Terrain/TerrainModule.cs
+++ OpenSim/Region/CoreModules/World/Terrain/TerrainModule.cs
@@ -234,6 +234,11 @@
                 m_log.Error("Unable to save to " + filename + ", saving of this file format has not been implemented.");
                 throw new TerrainException(String.Format("Unable to save heightmap: saving of this file format not implemented"));
             }
+            catch (IOException ioe)
+            {
+                m_log.Error(String.Format("[TERRAIN]: Unable to save to {0}, {1}", filename, ioe.Message));
+                throw new TerrainException(String.Format("Unable to save heightmap: {0}", ioe.Message));
+            }
         }

         /// <summary>


BulletSim: recalculate the compound shape bounding box when built.

--- OpenSim/Region/Physics/BulletSPlugin/BSLinksetCompound.cs
+++ OpenSim/Region/Physics/BulletSPlugin/BSLinksetCompound.cs
@@ -264,6 +264,8 @@
         float linksetMass = LinksetMass;
         LinksetRoot.UpdatePhysicalMassProperties(linksetMass);

+        BulletSimAPI.RecalculateCompoundShapeLocalAabb2(LinksetRoot.PhysShape.ptr);
+
         // DEBUG: see of inter-linkset collisions are causing problems for constraint linksets.
         // BulletSimAPI.SetCollisionFilterMask2(LinksetRoot.BSBody.ptr,
         //                     (uint)CollisionFilterGroups.LinksetFilter, (uint)CollisionFilterGroups.LinksetMask);


Bugfix: correct initialization of ExtractStagingQueue in ImportFileInSteps()

--- PART/Source/CprBroker/CPRDirect/Extract/ExtractManager.cs
+++ PART/Source/CprBroker/CPRDirect/Extract/ExtractManager.cs
@@ -213,7 +213,7 @@
                                     conn.BulkInsertAll<ExtractItem>(extractResult.ToExtractItems(extract.ExtractId, Constants.DataObjectMap, Constants.RelationshipMap, Constants.MultiRelationshipMap));
                                     conn.BulkInsertAll<ExtractError>(extractResult.ToExtractErrors(extract.ExtractId));

-                                    var stagingQueue = new ExtractStagingQueue();
+                                    var stagingQueue = Queue.GetQueues<ExtractStagingQueue>().First();
                                     stagingQueue.Enqueue(extractResult.ToQueueItems(extract.ExtractId, allPnrs), semaphore);

                                     // Update counts and commit