Tenho seguinte código winui c++ app.xaml <?xml version="1.0" encoding="utf-8"?>…
- User
Tenho seguinte código winui c++
app.xaml
<Application.Resources> <ResourceDictionary.MergedDictionaries> </ResourceDictionary.MergedDictionaries> </Application.Resources>
app.xaml.cpp
#include "pch.h" #include "App.xaml.h" #include "MainWindow.xaml.h"
#include <winrt/Microsoft.UI.Windowing.h>
using namespace winrt; using namespace Microsoft::UI::Xaml; using namespace winrt::Microsoft::UI::Windowing; using namespace winrt::Windows::Foundation;
// To learn more about WinUI, the WinUI project structure, // and more about our project templates, see: http://aka.ms/winui-project-info.
namespace winrt::DataIntegrityTools::implementation { /// /// Initializes the singleton application object. This is the first line of authored code /// executed, and as such is the logical equivalent of main() or WinMain(). /// App::App() { // Xaml objects should not call InitializeComponent during construction. // See https://github.com/microsoft/cppwinrt/tree/master/nuget#initializecomponent
#if defined _DEBUG && !defined DISABLE_XAML_GENERATED_BREAK_ON_UNHANDLED_EXCEPTION UnhandledException([](IInspectable const&, UnhandledExceptionEventArgs const& e) { if (IsDebuggerPresent()) { auto errorMessage = e.Message(); __debugbreak(); } }); #endif }
/// <summary> /// Invoked when the application is launched. /// </summary> /// <param name="e">Details about the launch request and process.</param> void App::OnLaunched([[maybe_unused]] LaunchActivatedEventArgs const& e) { window = make<MainWindow>(); window.Title(L"Data Integrity Tools"); window.Activate(); }}
Como posso alterar o icone e do app em OnLaunched ?
- Assistant
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.