Skip to content

Commit 3b1ac28

Browse files
[create-pull-request] automated change
1 parent 91aada4 commit 3b1ac28

File tree

358 files changed

+2506
-2469
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

358 files changed

+2506
-2469
lines changed

src/Compatibility/Core/src/Tizen/ResourcePath.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ public static string GetPath(string res)
1414
return res;
1515
}
1616

17-
foreach (AppFW.ResourceManager.Category category in Enum.GetValues<AppFW.ResourceManager.Category>())
17+
foreach (AppFW.ResourceManager.Category category in Enum.GetValues<AppFW.ResourceManager.Category>())
1818
{
1919
var path = AppFW.ResourceManager.TryGetPath(category, res);
2020

src/Compatibility/Core/src/Windows/TabbedPageRenderer.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -497,7 +497,7 @@ void UpdateBarIcons()
497497
#pragma warning disable RS0030 // Do not use banned APIs; Panel.Children is banned for performance reasons.
498498
var stackPanelItem = stackPanel.Children[i];
499499
#pragma warning restore RS0030 // Do not use banned APIs
500-
500+
501501
if (stackPanelItem is WImage tabBarImage)
502502
{
503503
// Update icon image.
Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
1-
using Microsoft.UI.Xaml;
1+
using System;
2+
using System.Collections.Generic;
3+
using System.IO;
4+
using System.Linq;
5+
using System.Runtime.InteropServices.WindowsRuntime;
6+
using Microsoft.UI.Xaml;
27
using Microsoft.UI.Xaml.Controls;
38
using Microsoft.UI.Xaml.Controls.Primitives;
49
using Microsoft.UI.Xaml.Data;
510
using Microsoft.UI.Xaml.Input;
611
using Microsoft.UI.Xaml.Media;
712
using Microsoft.UI.Xaml.Navigation;
813
using Microsoft.UI.Xaml.Shapes;
9-
using System;
10-
using System.Collections.Generic;
11-
using System.IO;
12-
using System.Linq;
13-
using System.Runtime.InteropServices.WindowsRuntime;
1414
using Windows.ApplicationModel;
1515
using Windows.ApplicationModel.Activation;
1616
using Windows.Foundation;
@@ -26,24 +26,24 @@ namespace Maui.Controls.Sample.WinUI;
2626
/// </summary>
2727
public partial class App : Microsoft.UI.Xaml.Application
2828
{
29-
/// <summary>
30-
/// Initializes the singleton application object. This is the first line of authored code
31-
/// executed, and as such is the logical equivalent of main() or WinMain().
32-
/// </summary>
33-
public App()
34-
{
35-
InitializeComponent();
36-
}
29+
/// <summary>
30+
/// Initializes the singleton application object. This is the first line of authored code
31+
/// executed, and as such is the logical equivalent of main() or WinMain().
32+
/// </summary>
33+
public App()
34+
{
35+
InitializeComponent();
36+
}
3737

38-
/// <summary>
39-
/// Invoked when the application is launched.
40-
/// </summary>
41-
/// <param name="args">Details about the launch request and process.</param>
42-
protected override void OnLaunched(Microsoft.UI.Xaml.LaunchActivatedEventArgs args)
43-
{
44-
m_window = new MainWindow();
45-
m_window.Activate();
46-
}
38+
/// <summary>
39+
/// Invoked when the application is launched.
40+
/// </summary>
41+
/// <param name="args">Details about the launch request and process.</param>
42+
protected override void OnLaunched(Microsoft.UI.Xaml.LaunchActivatedEventArgs args)
43+
{
44+
m_window = new MainWindow();
45+
m_window.Activate();
46+
}
4747

48-
private Microsoft.UI.Xaml.Window? m_window;
48+
private Microsoft.UI.Xaml.Window? m_window;
4949
}
Lines changed: 39 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
#nullable enable
2-
using Microsoft.Maui.Controls;
3-
using Microsoft.Maui.Controls.Xaml;
42
using System;
53
using System.Collections.Generic;
64
using System.Collections.ObjectModel;
75
using System.ComponentModel;
86
using System.Linq;
97
using System.Runtime.CompilerServices;
108
using System.Windows.Input;
9+
using Microsoft.Maui.Controls;
10+
using Microsoft.Maui.Controls.Xaml;
1111

1212
namespace Maui.Controls.Sample.Pages.CollectionViewGalleries.EmptyViewGalleries
1313
{
@@ -17,59 +17,59 @@ public partial class EmptyViewWithDataTemplateSelector : ContentPage
1717
public EmptyViewWithDataTemplateSelector()
1818
{
1919
InitializeComponent();
20-
var emptyViewTemplateSelector = new SearchTermDataTemplateSelector
21-
{
22-
DefaultTemplate = (DataTemplate)Resources["AdvancedTemplate"],
23-
OtherTemplate = (DataTemplate)Resources["BasicTemplate"]
24-
};
25-
collectionView.EmptyViewTemplate = emptyViewTemplateSelector;
26-
BindingContext = new EmptyViewWithDataTemplateSelectorViewModel();
20+
var emptyViewTemplateSelector = new SearchTermDataTemplateSelector
21+
{
22+
DefaultTemplate = (DataTemplate)Resources["AdvancedTemplate"],
23+
OtherTemplate = (DataTemplate)Resources["BasicTemplate"]
24+
};
25+
collectionView.EmptyViewTemplate = emptyViewTemplateSelector;
26+
BindingContext = new EmptyViewWithDataTemplateSelectorViewModel();
2727
}
2828

2929
public class Monkey
30-
{
31-
public string? Name { get; set; }
32-
public string? Location { get; set; }
33-
public string? Details { get; set; }
34-
}
30+
{
31+
public string? Name { get; set; }
32+
public string? Location { get; set; }
33+
public string? Details { get; set; }
34+
}
3535

3636
public class SearchTermDataTemplateSelector : DataTemplateSelector
37-
{
38-
public DataTemplate? DefaultTemplate { get; set; }
39-
public DataTemplate? OtherTemplate { get; set; }
37+
{
38+
public DataTemplate? DefaultTemplate { get; set; }
39+
public DataTemplate? OtherTemplate { get; set; }
4040

41-
protected override DataTemplate? OnSelectTemplate(object item, BindableObject container)
41+
protected override DataTemplate? OnSelectTemplate(object item, BindableObject container)
4242
{
4343
string query = (string)item;
4444
return query.Equals("xamarin", StringComparison.OrdinalIgnoreCase) ? OtherTemplate : DefaultTemplate;
4545
}
46-
}
46+
}
4747

4848
internal class EmptyViewWithDataTemplateSelectorViewModel
4949
{
5050
public ObservableCollection<Monkey> Monkeys { get; } = new();
51-
public ICommand FilterCommand => new Command<string>(FilterItems);
51+
public ICommand FilterCommand => new Command<string>(FilterItems);
5252

53-
public EmptyViewWithDataTemplateSelectorViewModel()
54-
{
55-
// Directly populate the ObservableCollection
56-
Monkeys.Add(new Monkey
57-
{
58-
Name = "Baboon",
59-
Location = "Africa & Asia",
60-
Details = "Baboons are African and Arabian Old World monkeys belonging to the genus Papio, part of the subfamily Cercopithecinae."
61-
});
62-
}
53+
public EmptyViewWithDataTemplateSelectorViewModel()
54+
{
55+
// Directly populate the ObservableCollection
56+
Monkeys.Add(new Monkey
57+
{
58+
Name = "Baboon",
59+
Location = "Africa & Asia",
60+
Details = "Baboons are African and Arabian Old World monkeys belonging to the genus Papio, part of the subfamily Cercopithecinae."
61+
});
62+
}
6363

64-
private void FilterItems(string filter)
65-
{
66-
var filteredItems = Monkeys.Where(monkey => monkey.Name?.Contains(filter, StringComparison.OrdinalIgnoreCase) ?? false).ToList();
67-
Monkeys.Clear();
68-
foreach (var monkey in filteredItems)
69-
{
70-
Monkeys.Add(monkey);
71-
}
72-
}
64+
private void FilterItems(string filter)
65+
{
66+
var filteredItems = Monkeys.Where(monkey => monkey.Name?.Contains(filter, StringComparison.OrdinalIgnoreCase) ?? false).ToList();
67+
Monkeys.Clear();
68+
foreach (var monkey in filteredItems)
69+
{
70+
Monkeys.Add(monkey);
71+
}
72+
}
7373
}
7474
}
7575
}

src/Controls/samples/Controls.Sample/Pages/Controls/TitleBarPage.xaml.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ async void PushNewTitleBarPage_Clicked(object sender, EventArgs e)
106106

107107
void ToggleTitleBarOnWindow_Clicked(object sender, EventArgs e)
108108
{
109-
if (Window.TitleBar is not null)
109+
if (Window.TitleBar is not null)
110110
Window.TitleBar = null;
111111
else
112112
Window.TitleBar = _customTitleBar;
@@ -169,7 +169,7 @@ private void TallModeCheckBox_CheckedChanged(object sender, CheckedChangedEventA
169169
_customTitleBar.HeightRequest = 36;
170170
#else
171171
_customTitleBar.HeightRequest = 32;
172-
#endif
172+
#endif
173173
}
174174
}
175175
}

src/Controls/src/Build.Tasks/NodeILExtensions.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ public static IEnumerable<Instruction> PushConvertedValue(this ValueNode node, I
126126
var typeConverter = bpRef.GetBindablePropertyTypeConverter(context.Cache, module);
127127

128128
//we're gonna SetValue. if the BP type is Nullable, we only need to convert/box to the non-nullable type? why, because the CSC compiler does it like that
129-
if (targetTypeRef.ResolveCached(context.Cache).FullName == "System.Nullable`1")
129+
if (targetTypeRef.ResolveCached(context.Cache).FullName == "System.Nullable`1")
130130
targetTypeRef = ((GenericInstanceType)targetTypeRef).GenericArguments[0];
131131

132132
return node.PushConvertedValue(context, targetTypeRef, typeConverter, pushServiceProvider, boxValueTypes,

src/Controls/src/Build.Tasks/SetPropertiesVisitor.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -683,7 +683,7 @@ static bool TryParsePath(ILContext context, string path, TypeReference tSourceRe
683683
{
684684
if (previousPartTypeRef.IsArray)
685685
previousPartTypeRef = previousPartTypeRef.GetElementType();
686-
686+
687687
previousPartTypeRef.ResolveCached(context.Cache);
688688
}
689689

src/Controls/src/Build.Tasks/XamlCTask.cs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -283,14 +283,16 @@ public override bool Execute(out IList<Exception> thrownExceptions)
283283

284284
LoggingHelper.LogMessage(Low, $"{new string(' ', 6)}Parsing Xaml");
285285
ILRootNode rootnode = null;
286-
try {
286+
try
287+
{
287288
rootnode = ParseXaml(resource.GetResourceStream(), typeDef);
288289
if (rootnode == null)
289290
{
290291
LoggingHelper.LogMessage(Low, $"{new string(' ', 8)}failed.");
291292
continue;
292293
}
293-
} catch (XamlParseException xpe)
294+
}
295+
catch (XamlParseException xpe)
294296
{
295297
LoggingHelper.LogMessage(Low, $"{new string(' ', 8)}failed.");
296298
xamlFilePath = LoggingHelper.GetXamlFilePath(xamlFilePath);

src/Controls/src/Core/Compatibility/Handlers/ListView/Tizen/CellContentFactory.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#nullable disable
2-
using Microsoft.Maui.Graphics;
32
using Microsoft.Maui.Controls.Internals;
3+
using Microsoft.Maui.Graphics;
44

55
namespace Microsoft.Maui.Controls.Handlers.Compatibility
66
{

src/Controls/src/Core/Compatibility/Handlers/ListView/Windows/ListViewRenderer.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
using System.Linq;
99
using System.Reflection;
1010
using System.Threading.Tasks;
11+
using Microsoft.Maui.ApplicationModel;
1112
using Microsoft.Maui.Controls.Internals;
1213
using Microsoft.Maui.Controls.Platform;
1314
using Microsoft.Maui.Controls.Platform.Compatibility;
@@ -19,7 +20,6 @@
1920
using Microsoft.UI.Xaml.Data;
2021
using Microsoft.UI.Xaml.Input;
2122
using Microsoft.UI.Xaml.Media;
22-
using Microsoft.Maui.ApplicationModel;
2323
using Windows.Foundation;
2424
using Specifics = Microsoft.Maui.Controls.PlatformConfiguration.WindowsSpecific.ListView;
2525
using UwpScrollBarVisibility = Microsoft.UI.Xaml.Controls.ScrollBarVisibility;

0 commit comments

Comments
 (0)