Skip to content

Commit

Permalink
Syncing content from committish 92bbc0043dbc1e02cc2a543b9cbae60ba78c245b
Browse files Browse the repository at this point in the history
  • Loading branch information
reunion-maestro-bot committed Feb 11, 2025
1 parent 256bdcd commit 689477e
Show file tree
Hide file tree
Showing 86 changed files with 2,196 additions and 1,131 deletions.
1 change: 1 addition & 0 deletions src/Directory.Build.targets
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,5 @@
<Import Project="eng\graph.targets" Condition="'$(IsGraphBuild)' == 'true'" />
<Import Project="eng\projectcaching.targets" />
<Import Project="eng\lightup.targets" />
<Import Project="$(ProjectRoot)\eng\WebView2ProjectionWorkaround.targets" />
</Project>
162 changes: 81 additions & 81 deletions src/controls/dev/Generated/TitleBar.properties.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,13 @@ namespace winrt::Microsoft::UI::Xaml::Controls

#include "TitleBar.g.cpp"

GlobalDependencyProperty TitleBarProperties::s_ContentProperty{ nullptr };
GlobalDependencyProperty TitleBarProperties::s_FooterProperty{ nullptr };
GlobalDependencyProperty TitleBarProperties::s_HeaderProperty{ nullptr };
GlobalDependencyProperty TitleBarProperties::s_CenterContentProperty{ nullptr };
GlobalDependencyProperty TitleBarProperties::s_IconSourceProperty{ nullptr };
GlobalDependencyProperty TitleBarProperties::s_IsBackButtonEnabledProperty{ nullptr };
GlobalDependencyProperty TitleBarProperties::s_IsBackButtonVisibleProperty{ nullptr };
GlobalDependencyProperty TitleBarProperties::s_IsBackEnabledProperty{ nullptr };
GlobalDependencyProperty TitleBarProperties::s_IsPaneToggleButtonVisibleProperty{ nullptr };
GlobalDependencyProperty TitleBarProperties::s_LeftContentProperty{ nullptr };
GlobalDependencyProperty TitleBarProperties::s_RightContentProperty{ nullptr };
GlobalDependencyProperty TitleBarProperties::s_SubtitleProperty{ nullptr };
GlobalDependencyProperty TitleBarProperties::s_TemplateSettingsProperty{ nullptr };
GlobalDependencyProperty TitleBarProperties::s_TitleProperty{ nullptr };
Expand All @@ -33,38 +33,16 @@ TitleBarProperties::TitleBarProperties()

void TitleBarProperties::EnsureProperties()
{
if (!s_ContentProperty)
if (!s_CenterContentProperty)
{
s_ContentProperty =
s_CenterContentProperty =
InitializeDependencyProperty(
L"Content",
winrt::name_of<winrt::IInspectable>(),
L"CenterContent",
winrt::name_of<winrt::UIElement>(),
winrt::name_of<winrt::TitleBar>(),
false /* isAttached */,
ValueHelper<winrt::IInspectable>::BoxedDefaultValue(),
winrt::PropertyChangedCallback(&OnContentPropertyChanged));
}
if (!s_FooterProperty)
{
s_FooterProperty =
InitializeDependencyProperty(
L"Footer",
winrt::name_of<winrt::IInspectable>(),
winrt::name_of<winrt::TitleBar>(),
false /* isAttached */,
ValueHelper<winrt::IInspectable>::BoxedDefaultValue(),
winrt::PropertyChangedCallback(&OnFooterPropertyChanged));
}
if (!s_HeaderProperty)
{
s_HeaderProperty =
InitializeDependencyProperty(
L"Header",
winrt::name_of<winrt::IInspectable>(),
winrt::name_of<winrt::TitleBar>(),
false /* isAttached */,
ValueHelper<winrt::IInspectable>::BoxedDefaultValue(),
winrt::PropertyChangedCallback(&OnHeaderPropertyChanged));
ValueHelper<winrt::UIElement>::BoxedDefaultValue(),
winrt::PropertyChangedCallback(&OnCenterContentPropertyChanged));
}
if (!s_IconSourceProperty)
{
Expand All @@ -77,27 +55,27 @@ void TitleBarProperties::EnsureProperties()
ValueHelper<winrt::IconSource>::BoxedDefaultValue(),
winrt::PropertyChangedCallback(&OnIconSourcePropertyChanged));
}
if (!s_IsBackButtonVisibleProperty)
if (!s_IsBackButtonEnabledProperty)
{
s_IsBackButtonVisibleProperty =
s_IsBackButtonEnabledProperty =
InitializeDependencyProperty(
L"IsBackButtonVisible",
L"IsBackButtonEnabled",
winrt::name_of<bool>(),
winrt::name_of<winrt::TitleBar>(),
false /* isAttached */,
ValueHelper<bool>::BoxValueIfNecessary(false),
winrt::PropertyChangedCallback(&OnIsBackButtonVisiblePropertyChanged));
ValueHelper<bool>::BoxValueIfNecessary(true),
winrt::PropertyChangedCallback(&OnIsBackButtonEnabledPropertyChanged));
}
if (!s_IsBackEnabledProperty)
if (!s_IsBackButtonVisibleProperty)
{
s_IsBackEnabledProperty =
s_IsBackButtonVisibleProperty =
InitializeDependencyProperty(
L"IsBackEnabled",
L"IsBackButtonVisible",
winrt::name_of<bool>(),
winrt::name_of<winrt::TitleBar>(),
false /* isAttached */,
ValueHelper<bool>::BoxValueIfNecessary(true),
winrt::PropertyChangedCallback(&OnIsBackEnabledPropertyChanged));
ValueHelper<bool>::BoxValueIfNecessary(false),
winrt::PropertyChangedCallback(&OnIsBackButtonVisiblePropertyChanged));
}
if (!s_IsPaneToggleButtonVisibleProperty)
{
Expand All @@ -110,6 +88,28 @@ void TitleBarProperties::EnsureProperties()
ValueHelper<bool>::BoxValueIfNecessary(false),
winrt::PropertyChangedCallback(&OnIsPaneToggleButtonVisiblePropertyChanged));
}
if (!s_LeftContentProperty)
{
s_LeftContentProperty =
InitializeDependencyProperty(
L"LeftContent",
winrt::name_of<winrt::UIElement>(),
winrt::name_of<winrt::TitleBar>(),
false /* isAttached */,
ValueHelper<winrt::UIElement>::BoxedDefaultValue(),
winrt::PropertyChangedCallback(&OnLeftContentPropertyChanged));
}
if (!s_RightContentProperty)
{
s_RightContentProperty =
InitializeDependencyProperty(
L"RightContent",
winrt::name_of<winrt::UIElement>(),
winrt::name_of<winrt::TitleBar>(),
false /* isAttached */,
ValueHelper<winrt::UIElement>::BoxedDefaultValue(),
winrt::PropertyChangedCallback(&OnRightContentPropertyChanged));
}
if (!s_SubtitleProperty)
{
s_SubtitleProperty =
Expand Down Expand Up @@ -147,67 +147,67 @@ void TitleBarProperties::EnsureProperties()

void TitleBarProperties::ClearProperties()
{
s_ContentProperty = nullptr;
s_FooterProperty = nullptr;
s_HeaderProperty = nullptr;
s_CenterContentProperty = nullptr;
s_IconSourceProperty = nullptr;
s_IsBackButtonEnabledProperty = nullptr;
s_IsBackButtonVisibleProperty = nullptr;
s_IsBackEnabledProperty = nullptr;
s_IsPaneToggleButtonVisibleProperty = nullptr;
s_LeftContentProperty = nullptr;
s_RightContentProperty = nullptr;
s_SubtitleProperty = nullptr;
s_TemplateSettingsProperty = nullptr;
s_TitleProperty = nullptr;
}

void TitleBarProperties::OnContentPropertyChanged(
void TitleBarProperties::OnCenterContentPropertyChanged(
winrt::DependencyObject const& sender,
winrt::DependencyPropertyChangedEventArgs const& args)
{
auto owner = sender.as<winrt::TitleBar>();
winrt::get_self<TitleBar>(owner)->OnPropertyChanged(args);
}

void TitleBarProperties::OnFooterPropertyChanged(
void TitleBarProperties::OnIconSourcePropertyChanged(
winrt::DependencyObject const& sender,
winrt::DependencyPropertyChangedEventArgs const& args)
{
auto owner = sender.as<winrt::TitleBar>();
winrt::get_self<TitleBar>(owner)->OnPropertyChanged(args);
}

void TitleBarProperties::OnHeaderPropertyChanged(
void TitleBarProperties::OnIsBackButtonEnabledPropertyChanged(
winrt::DependencyObject const& sender,
winrt::DependencyPropertyChangedEventArgs const& args)
{
auto owner = sender.as<winrt::TitleBar>();
winrt::get_self<TitleBar>(owner)->OnPropertyChanged(args);
}

void TitleBarProperties::OnIconSourcePropertyChanged(
void TitleBarProperties::OnIsBackButtonVisiblePropertyChanged(
winrt::DependencyObject const& sender,
winrt::DependencyPropertyChangedEventArgs const& args)
{
auto owner = sender.as<winrt::TitleBar>();
winrt::get_self<TitleBar>(owner)->OnPropertyChanged(args);
}

void TitleBarProperties::OnIsBackButtonVisiblePropertyChanged(
void TitleBarProperties::OnIsPaneToggleButtonVisiblePropertyChanged(
winrt::DependencyObject const& sender,
winrt::DependencyPropertyChangedEventArgs const& args)
{
auto owner = sender.as<winrt::TitleBar>();
winrt::get_self<TitleBar>(owner)->OnPropertyChanged(args);
}

void TitleBarProperties::OnIsBackEnabledPropertyChanged(
void TitleBarProperties::OnLeftContentPropertyChanged(
winrt::DependencyObject const& sender,
winrt::DependencyPropertyChangedEventArgs const& args)
{
auto owner = sender.as<winrt::TitleBar>();
winrt::get_self<TitleBar>(owner)->OnPropertyChanged(args);
}

void TitleBarProperties::OnIsPaneToggleButtonVisiblePropertyChanged(
void TitleBarProperties::OnRightContentPropertyChanged(
winrt::DependencyObject const& sender,
winrt::DependencyPropertyChangedEventArgs const& args)
{
Expand Down Expand Up @@ -239,95 +239,95 @@ void TitleBarProperties::OnTitlePropertyChanged(
winrt::get_self<TitleBar>(owner)->OnPropertyChanged(args);
}

void TitleBarProperties::Content(winrt::IInspectable const& value)
void TitleBarProperties::CenterContent(winrt::UIElement const& value)
{
[[gsl::suppress(con)]]
{
static_cast<TitleBar*>(this)->SetValue(s_ContentProperty, ValueHelper<winrt::IInspectable>::BoxValueIfNecessary(value));
static_cast<TitleBar*>(this)->SetValue(s_CenterContentProperty, ValueHelper<winrt::UIElement>::BoxValueIfNecessary(value));
}
}

winrt::IInspectable TitleBarProperties::Content()
winrt::UIElement TitleBarProperties::CenterContent()
{
return ValueHelper<winrt::IInspectable>::CastOrUnbox(static_cast<TitleBar*>(this)->GetValue(s_ContentProperty));
return ValueHelper<winrt::UIElement>::CastOrUnbox(static_cast<TitleBar*>(this)->GetValue(s_CenterContentProperty));
}

void TitleBarProperties::Footer(winrt::IInspectable const& value)
void TitleBarProperties::IconSource(winrt::IconSource const& value)
{
[[gsl::suppress(con)]]
{
static_cast<TitleBar*>(this)->SetValue(s_FooterProperty, ValueHelper<winrt::IInspectable>::BoxValueIfNecessary(value));
static_cast<TitleBar*>(this)->SetValue(s_IconSourceProperty, ValueHelper<winrt::IconSource>::BoxValueIfNecessary(value));
}
}

winrt::IInspectable TitleBarProperties::Footer()
winrt::IconSource TitleBarProperties::IconSource()
{
return ValueHelper<winrt::IInspectable>::CastOrUnbox(static_cast<TitleBar*>(this)->GetValue(s_FooterProperty));
return ValueHelper<winrt::IconSource>::CastOrUnbox(static_cast<TitleBar*>(this)->GetValue(s_IconSourceProperty));
}

void TitleBarProperties::Header(winrt::IInspectable const& value)
void TitleBarProperties::IsBackButtonEnabled(bool value)
{
[[gsl::suppress(con)]]
{
static_cast<TitleBar*>(this)->SetValue(s_HeaderProperty, ValueHelper<winrt::IInspectable>::BoxValueIfNecessary(value));
static_cast<TitleBar*>(this)->SetValue(s_IsBackButtonEnabledProperty, ValueHelper<bool>::BoxValueIfNecessary(value));
}
}

winrt::IInspectable TitleBarProperties::Header()
bool TitleBarProperties::IsBackButtonEnabled()
{
return ValueHelper<winrt::IInspectable>::CastOrUnbox(static_cast<TitleBar*>(this)->GetValue(s_HeaderProperty));
return ValueHelper<bool>::CastOrUnbox(static_cast<TitleBar*>(this)->GetValue(s_IsBackButtonEnabledProperty));
}

void TitleBarProperties::IconSource(winrt::IconSource const& value)
void TitleBarProperties::IsBackButtonVisible(bool value)
{
[[gsl::suppress(con)]]
{
static_cast<TitleBar*>(this)->SetValue(s_IconSourceProperty, ValueHelper<winrt::IconSource>::BoxValueIfNecessary(value));
static_cast<TitleBar*>(this)->SetValue(s_IsBackButtonVisibleProperty, ValueHelper<bool>::BoxValueIfNecessary(value));
}
}

winrt::IconSource TitleBarProperties::IconSource()
bool TitleBarProperties::IsBackButtonVisible()
{
return ValueHelper<winrt::IconSource>::CastOrUnbox(static_cast<TitleBar*>(this)->GetValue(s_IconSourceProperty));
return ValueHelper<bool>::CastOrUnbox(static_cast<TitleBar*>(this)->GetValue(s_IsBackButtonVisibleProperty));
}

void TitleBarProperties::IsBackButtonVisible(bool value)
void TitleBarProperties::IsPaneToggleButtonVisible(bool value)
{
[[gsl::suppress(con)]]
{
static_cast<TitleBar*>(this)->SetValue(s_IsBackButtonVisibleProperty, ValueHelper<bool>::BoxValueIfNecessary(value));
static_cast<TitleBar*>(this)->SetValue(s_IsPaneToggleButtonVisibleProperty, ValueHelper<bool>::BoxValueIfNecessary(value));
}
}

bool TitleBarProperties::IsBackButtonVisible()
bool TitleBarProperties::IsPaneToggleButtonVisible()
{
return ValueHelper<bool>::CastOrUnbox(static_cast<TitleBar*>(this)->GetValue(s_IsBackButtonVisibleProperty));
return ValueHelper<bool>::CastOrUnbox(static_cast<TitleBar*>(this)->GetValue(s_IsPaneToggleButtonVisibleProperty));
}

void TitleBarProperties::IsBackEnabled(bool value)
void TitleBarProperties::LeftContent(winrt::UIElement const& value)
{
[[gsl::suppress(con)]]
{
static_cast<TitleBar*>(this)->SetValue(s_IsBackEnabledProperty, ValueHelper<bool>::BoxValueIfNecessary(value));
static_cast<TitleBar*>(this)->SetValue(s_LeftContentProperty, ValueHelper<winrt::UIElement>::BoxValueIfNecessary(value));
}
}

bool TitleBarProperties::IsBackEnabled()
winrt::UIElement TitleBarProperties::LeftContent()
{
return ValueHelper<bool>::CastOrUnbox(static_cast<TitleBar*>(this)->GetValue(s_IsBackEnabledProperty));
return ValueHelper<winrt::UIElement>::CastOrUnbox(static_cast<TitleBar*>(this)->GetValue(s_LeftContentProperty));
}

void TitleBarProperties::IsPaneToggleButtonVisible(bool value)
void TitleBarProperties::RightContent(winrt::UIElement const& value)
{
[[gsl::suppress(con)]]
{
static_cast<TitleBar*>(this)->SetValue(s_IsPaneToggleButtonVisibleProperty, ValueHelper<bool>::BoxValueIfNecessary(value));
static_cast<TitleBar*>(this)->SetValue(s_RightContentProperty, ValueHelper<winrt::UIElement>::BoxValueIfNecessary(value));
}
}

bool TitleBarProperties::IsPaneToggleButtonVisible()
winrt::UIElement TitleBarProperties::RightContent()
{
return ValueHelper<bool>::CastOrUnbox(static_cast<TitleBar*>(this)->GetValue(s_IsPaneToggleButtonVisibleProperty));
return ValueHelper<winrt::UIElement>::CastOrUnbox(static_cast<TitleBar*>(this)->GetValue(s_RightContentProperty));
}

void TitleBarProperties::Subtitle(winrt::hstring const& value)
Expand Down
Loading

0 comments on commit 689477e

Please sign in to comment.