Skip to content

Commit

Permalink
Build warning fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
dotMorten committed May 15, 2024
1 parent 3dd2dce commit eb3774f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/Toolkit/Toolkit.UI.Controls/TimeSlider/TimeSlider.cs
Original file line number Diff line number Diff line change
Expand Up @@ -344,7 +344,7 @@ private Size CalculateTextSize(TextBlock textBlock, string? text = null)
textBlock.FontSize, textBlock.Foreground, new NumberSubstitution(), TextFormattingMode.Display, 1);
#else
var formattedText = new FormattedText(text ?? textBlock.Text, CultureInfo.CurrentCulture, textBlock.FlowDirection, typeface,
textBlock.FontSize, textBlock.Foreground, new NumberSubstitution(), TextFormattingMode.Display);
textBlock.FontSize, textBlock.Foreground, new NumberSubstitution(), TextFormattingMode.Display, 96);
#endif
return new Size(formattedText.Width, formattedText.Height);
#endif
Expand Down
2 changes: 2 additions & 0 deletions src/Toolkit/Toolkit.WinUI/Internal/StringFormatConverter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@ namespace Esri.ArcGISRuntime.Toolkit.Internal
public class StringFormatConverter : IValueConverter
{
/// <inheritdoc />
#pragma warning disable CA1033 // Interface methods should be callable by child types: Solution is to seal the class, but this would be a binary breaking change, so disabling warning instead
object? IValueConverter.Convert(object? value, Type targetType, object? parameter, string language)
#pragma warning restore CA1033 // Interface methods should be callable by child types
{
if (value != null && parameter is string formatString)
{
Expand Down

0 comments on commit eb3774f

Please sign in to comment.