| 120 | } |
| 121 | |
| 122 | void TrayFlyoutPage::SetStartupState(const wf::IReference<Windows::ApplicationModel::StartupTaskState> &state) |
| 123 | { |
| 124 | const auto startup = StartupState(); |
| 125 | if (state) |
| 126 | { |
| 127 | const auto stateUnbox = state.Value(); |
| 128 | |
| 129 | using enum Windows::ApplicationModel::StartupTaskState; |
| 130 | startup.IsChecked(stateUnbox == Enabled || stateUnbox == EnabledByPolicy); |
| 131 | startup.IsEnabled(stateUnbox == Disabled || stateUnbox == DisabledByUser || stateUnbox == Enabled); |
| 132 | } |
| 133 | else |
| 134 | { |
| 135 | startup.IsChecked(false); |
| 136 | startup.IsEnabled(false); |
| 137 | } |
| 138 | } |
| 139 | |
| 140 | void TrayFlyoutPage::AppearanceClicked(const IInspectable &sender, const wux::RoutedEventArgs &) |
| 141 | { |