Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions DotnetRuntimeMetadata.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
{
"sdk": {
"channel": "release/6.0.1xx-preview2",
"packageVersionPattern": "6.0.0-preview.2",
"channel": "release/6.0.1xx-preview4",
"packageVersionPattern": "6.0.0-preview.4",
"sdkImageVersion": "6.0.100",
"nextChannel": "6.0.1xx-preview2/daily"
"nextChannel": "6.0.1xx-preview4/daily"
},
"internalfeed" : {
"url": null
Expand Down
1 change: 1 addition & 0 deletions PowerShell.Common.props
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@
<TargetFramework>net6.0</TargetFramework>
<LangVersion>9.0</LangVersion>
<PublishReadyToRun Condition=" '$(Configuration)' != 'Debug' ">true</PublishReadyToRun>
<PublishReadyToRunUseCrossgen2>false</PublishReadyToRunUseCrossgen2>

<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
Expand Down
6 changes: 3 additions & 3 deletions assets/wix/files.wxs
Original file line number Diff line number Diff line change
Expand Up @@ -3063,8 +3063,8 @@
<Component Id="cmp3547A55EA9D04784B4CF2FC717447E16">
<File Id="fil463DDA419769417A8D5A34C433E194F2" KeyPath="yes" Source="$(var.ProductSourcePath)\System.Speech.dll" />
</Component>
<Component Id="cmpB04D9BE0F32F4D029D3CAD90DF288929">
<File Id="fil0EBD96C46E4F4537A32B8B1210CAF9C6" KeyPath="yes" Source="$(var.ProductSourcePath)\mscordaccore_$(var.FileArchitecture)_$(var.FileArchitecture)_6.0.21.20104.dll" />
<Component Id="cmp378D79CF3DEC49979D7FA8A029141F0A">
<File Id="filC405FF3776264022973EF4C1E94C8C3B" KeyPath="yes" Source="$(var.ProductSourcePath)\mscordaccore_$(var.FileArchitecture)_$(var.FileArchitecture)_6.0.21.25307.dll" />
</Component>
</DirectoryRef>
</Fragment>
Expand Down Expand Up @@ -4053,7 +4053,7 @@
<ComponentRef Id="cmp2BB002B115C247FFB3353C80CAAC10B3" />
<ComponentRef Id="cmp68158D010ECB439582D041355BFACCBB" />
<ComponentRef Id="cmp3547A55EA9D04784B4CF2FC717447E16" />
<ComponentRef Id="cmpB04D9BE0F32F4D029D3CAD90DF288929" />
<ComponentRef Id="cmp378D79CF3DEC49979D7FA8A029141F0A" />
</ComponentGroup>
</Fragment>
</Wix>
2 changes: 1 addition & 1 deletion global.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"sdk": {
"version": "6.0.100-preview.3.21202.5"
"version": "6.0.100-preview.4.21255.9"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
using System;
using System.ComponentModel;
using System.Diagnostics;
using System.Diagnostics.CodeAnalysis;
using System.Globalization;
using System.Management.Automation;
using System.Windows.Documents;
Expand Down Expand Up @@ -273,11 +274,13 @@ private void SetMatchesLabel()
/// <param name="propertyName">Property name.</param>
private void OnNotifyPropertyChanged(string propertyName)
{
#pragma warning disable IDE1005 // IDE1005: Delegate invocation can be simplified.
PropertyChangedEventHandler handler = this.PropertyChanged;
if (handler != null)
{
handler(this, new PropertyChangedEventArgs(propertyName));
}
#pragma warning restore IDE1005s
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Diagnostics.CodeAnalysis;
using System.Text;
using System.Windows.Documents;
using System.Windows.Media;
Expand Down Expand Up @@ -107,10 +108,15 @@ internal void BuildParagraph()
bool newHighlighted = false;

ParagraphBuilder.MoveSpanToPosition(ref currentBoldIndex, ref currentBoldSpan, i, this.boldSpans);

#pragma warning disable IDE0075 // IDE0075: Conditional expression can be simplified
newBold = currentBoldSpan == null ? false : currentBoldSpan.Value.Contains(i);
#pragma warning restore IDE0075

ParagraphBuilder.MoveSpanToPosition(ref currentHighlightedIndex, ref currentHighlightedSpan, i, this.highlightedSpans);
#pragma warning disable IDE0075 // IDE0075: Conditional expression can be simplified
newHighlighted = currentHighlightedSpan == null ? false : currentHighlightedSpan.Value.Contains(i);
#pragma warning restore IDE0075

if (newBold != currentBold || newHighlighted != currentHighlighted)
{
Expand Down Expand Up @@ -301,11 +307,13 @@ private void AddHighlight(int start, int length)
/// <param name="propertyName">Property name.</param>
private void OnNotifyPropertyChanged(string propertyName)
{
#pragma warning disable IDE1005 // IDE1005: Delegate invocation can be simplified.s
PropertyChangedEventHandler handler = this.PropertyChanged;
if (handler != null)
{
handler(this, new PropertyChangedEventArgs(propertyName));
}
#pragma warning restore IDE1005
}

/// <summary>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@

using System;
using System.Diagnostics;
using System.Diagnostics.CodeAnalysis;
using System.Windows;
using System.Windows.Automation;
using System.Windows.Controls.Primitives;
Expand Down Expand Up @@ -79,6 +80,7 @@ protected override void OnClosed(EventArgs e)
}
}

[SuppressMessage("Performance", "CA1822: Mark members as static", Justification = "Potential breaking change")]
private void SetFocus(UIElement element)
{
if (element.Focusable)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ public static FocusNavigationDirection GetNavigationDirection(DependencyObject e
/// <returns>True if a control is is pressed.</returns>
public static bool IsControlPressed()
{
if (ModifierKeys.Control == (Keyboard.Modifiers & ModifierKeys.Control))
if ((Keyboard.Modifiers & ModifierKeys.Control) == ModifierKeys.Control)
{
return true;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,9 @@ public bool IsInEditMode
{
get
{
#pragma warning disable IDE0075 // IDE0075: Conditional expression can be simplified
return (this.renameButton != null) ? this.renameButton.IsChecked.Value : false;
#pragma warning restore IDE0075
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
using System.Collections.ObjectModel;
using System.Collections.Specialized;
using System.ComponentModel;
using System.Diagnostics.CodeAnalysis;

namespace Microsoft.Management.UI.Internal
{
Expand Down Expand Up @@ -97,6 +98,8 @@ public Exception OperationError
#endregion IAsyncProgress

#region Private Methods

#pragma warning disable IDE1005 // IDE1005: Delegate invocation can be simplified.
private void OnCollectionChanged(NotifyCollectionChangedEventArgs args)
{
NotifyCollectionChangedEventHandler eh = this.CollectionChanged;
Expand All @@ -117,6 +120,8 @@ private void OnPropertyChanged(PropertyChangedEventArgs args)
}
}

#pragma warning restore IDE1005

// forward CollectionChanged events from the base list to our listeners
private void HandleCollectionChanged(object sender, NotifyCollectionChangedEventArgs e)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
using System;
using System.ComponentModel;
using System.Diagnostics;
using System.Diagnostics.CodeAnalysis;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Controls.Primitives;
Expand Down Expand Up @@ -202,6 +203,7 @@ private double GetNewWidth(ResizeGripLocation location, double horzDelta)
return this.GetConstrainedValue(newWidth, this.MaxWidth, this.MinWidth);
}

[SuppressMessage("Performance", "CA1822: Mark members as static", Justification = "Potential breaking change")]
private double GetHorizontalDelta(ResizeGripLocation location, double horzDelta)
{
double realDelta;
Expand All @@ -219,6 +221,7 @@ private double GetHorizontalDelta(ResizeGripLocation location, double horzDelta)
return realDelta;
}

[SuppressMessage("Performance", "CA1822: Mark members as static", Justification = "Potential breaking change")]
private double GetConstrainedValue(double value, double max, double min)
{
return Math.Min(max, Math.Max(value, min));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Diagnostics;
using System.Diagnostics.CodeAnalysis;
using System.Globalization;
using System.Reflection;

Expand Down Expand Up @@ -196,6 +197,7 @@ public override string GetErrorMessageForInvalidValue(string value, Type typeToP

#region Helpers

[SuppressMessage("Performance", "CA1822: Mark members as static", Justification = "Potential breaking change")]
private bool TryGetGenericParameterForComparableValueFilterRule(FilterRule rule, out Type genericParameter)
{
genericParameter = null;
Expand All @@ -217,6 +219,7 @@ private bool TryGetGenericParameterForComparableValueFilterRule(FilterRule rule,
return true;
}

[SuppressMessage("Performance", "CA1822: Mark members as static", Justification = "Potential breaking change")]
private object GetValueFromValidatingValue(FilterRule rule, string propertyName)
{
Debug.Assert(rule != null && !string.IsNullOrEmpty(propertyName), "rule and propertyname are not null");
Expand All @@ -236,6 +239,7 @@ private object GetValueFromValidatingValue(FilterRule rule, string propertyName)
return property.GetValue(validatingValue, null);
}

[SuppressMessage("Performance", "CA1822: Mark members as static", Justification = "Potential breaking change")]
private void SetValueOnValidatingValue(FilterRule rule, string propertyName, object value)
{
Debug.Assert(rule != null && !string.IsNullOrEmpty(propertyName), "rule and propertyname are not null");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
using System.Collections.ObjectModel;
using System.ComponentModel;
using System.Diagnostics;
using System.Diagnostics.CodeAnalysis;

namespace Microsoft.Management.UI.Internal
{
Expand Down Expand Up @@ -173,6 +174,8 @@ public void RemoveFilterExpressionProvider(IFilterExpressionProvider provider)

#region NotifyPropertyChanged

#pragma warning disable IDE1005 // IDE1005: Delegate invocation can be simplified.

/// <summary>
/// Notifies listeners that a property has changed.
/// </summary>
Expand Down Expand Up @@ -214,6 +217,8 @@ protected virtual void NotifyFilterExpressionChanged()
}
}

#pragma warning restore IDE1005

private void FilterProvider_FilterExpressionChanged(object sender, EventArgs e)
{
// Update HasFilterExpression \\
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
// Licensed under the MIT License.

using System;
using System.Diagnostics.CodeAnalysis;

namespace Microsoft.Management.UI.Internal
{
Expand Down Expand Up @@ -66,12 +67,14 @@ protected FilterRule()
/// </summary>
protected void NotifyEvaluationResultInvalidated()
{
#pragma warning disable IDE1005 // IDE1005: Delegate invocation can be simplified.
var eh = this.EvaluationResultInvalidated;

if (eh != null)
{
eh(this, new EventArgs());
}
#pragma warning restore IDE1005
}

#endregion
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@

using System;
using System.Collections.Generic;
using System.Diagnostics.CodeAnalysis;
using System.Globalization;
using System.Windows.Data;

Expand Down Expand Up @@ -214,12 +215,14 @@ protected override DataErrorInfoValidationResult Validate(string columnName)
/// </param>
protected void NotifySelectedValueChanged(T oldValue, T newValue)
{
#pragma warning disable IDE1005 // IDE1005: Delegate invocation can be simplified.
EventHandler<PropertyChangedEventArgs<T>> eh = this.SelectedValueChanged;

if (eh != null)
{
eh(this, new PropertyChangedEventArgs<T>(oldValue, newValue));
}
#pragma warning restore IDE1005
}

#endregion NotifySelectedValueChanged
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@

using System;
using System.Diagnostics;
using System.Diagnostics.CodeAnalysis;
using System.Globalization;

namespace Microsoft.Management.UI.Internal
Expand Down Expand Up @@ -190,6 +191,7 @@ private bool TryGetCastValue(object rawValue, out T castValue)
}
}

[SuppressMessage("Performance", "CA1822: Mark members as static", Justification = "Potential breaking change")]
private bool TryGetEnumValue(object rawValue, out T castValue)
{
Debug.Assert(rawValue != null, "rawValue not null");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
using System.Collections.ObjectModel;
using System.ComponentModel;
using System.Diagnostics;
using System.Diagnostics.CodeAnalysis;
using System.Globalization;

namespace Microsoft.Management.UI.Internal
Expand Down Expand Up @@ -260,12 +261,14 @@ protected void InvalidateValidationResult()
/// </param>
protected void NotifyPropertyChanged(string propertyName)
{
#pragma warning disable IDE1005 // IDE1005: Delegate invocation can be simplified.
PropertyChangedEventHandler eh = this.PropertyChanged;

if (eh != null)
{
eh(this, new PropertyChangedEventArgs(propertyName));
}
#pragma warning restore IDE1005
}

#endregion NotifyPropertyChanged
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
using System;
using System.Collections.ObjectModel;
using System.ComponentModel;
using System.Diagnostics.CodeAnalysis;
using System.Windows.Controls;

namespace Microsoft.Management.UI.Internal
Expand Down Expand Up @@ -49,9 +50,11 @@ public ObservableCollection<AddFilterRulePickerItem> ColumnFilterRules

partial void OnOkAddFilterRulesCanExecuteImplementation(System.Windows.Input.CanExecuteRoutedEventArgs e)
{
#pragma warning disable IDE0075 // IDE0075: Conditional expression can be simplified
e.CanExecute = (this.AddFilterRulesCommand != null)
? CommandHelper.CanExecuteCommand(this.AddFilterRulesCommand, null, this.AddFilterRulesCommandTarget)
: false;
#pragma warning restore IDE0075
}

partial void OnOkAddFilterRulesExecutedImplementation(System.Windows.Input.ExecutedRoutedEventArgs e)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,12 +70,14 @@ public AddFilterRulePickerItem(FilterRulePanelItem filterRule)
/// </param>
protected void NotifyPropertyChanged(string propertyName)
{
#pragma warning disable IDE1005 // IDE1005: Delegate invocation can be simplified.
PropertyChangedEventHandler eh = this.PropertyChanged;

if (eh != null)
{
eh(this, new PropertyChangedEventArgs(propertyName));
}
#pragma warning restore IDE1005
}

#endregion NotifyPropertyChanged
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -213,11 +213,13 @@ public void ClearContentTemplates()
/// </summary>
protected virtual void NotifyFilterExpressionChanged()
{
#pragma warning disable IDE1005 // IDE1005: Delegate invocation can be simplified.
EventHandler eh = this.FilterExpressionChanged;
if (eh != null)
{
eh(this, new EventArgs());
}
#pragma warning restore IDE1005
}

private void Controller_FilterExpressionChanged(object sender, EventArgs e)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -266,11 +266,13 @@ private void UpdateFilterRulePanelItemTypes()
/// </summary>
protected virtual void NotifyFilterExpressionChanged()
{
#pragma warning disable IDE1005 // IDE1005: Delegate invocation can be simplified.
EventHandler eh = this.FilterExpressionChanged;
if (eh != null)
{
eh(this, new EventArgs());
}
#pragma warning restore IDE1005
}

#endregion Notify Filter Expression Changed
Expand Down
Loading