xtd - Reference Guide  0.2.0
Modern c++17/20 framework to create console, GUI and unit test applications on Windows, macOS, Linux, iOS and android.
close_reason.h
Go to the documentation of this file.
1 #pragma once
5 #include <xtd/ustring.h>
6 
8 namespace xtd {
10  namespace forms {
18  enum class close_reason {
20  none = 0,
24  mdi_form_closing = 2,
26  user_closing = 3,
33  };
34 
36  inline std::ostream& operator<<(std::ostream& os, close_reason value) {return os << to_string(value, {{close_reason::none, "none"}, {close_reason::windows_shut_down, "windows_shut_down"}, {close_reason::mdi_form_closing, "mdi_form_closing"}, {close_reason::user_closing, "user_closing"}, {close_reason::task_manager_closing, "task_manager_closing"}, {close_reason::form_owner_closing, "form_owner_closing"}, {close_reason::application_exit_call, "application_exit_call"}});}
37  inline std::wostream& operator<<(std::wostream& os, close_reason value) {return os << to_string(value, {{close_reason::none, L"none"}, {close_reason::windows_shut_down, L"windows_shut_down"}, {close_reason::mdi_form_closing, L"mdi_form_closing"}, {close_reason::user_closing, L"user_closing"}, {close_reason::task_manager_closing, L"task_manager_closing"}, {close_reason::form_owner_closing, L"form_owner_closing"}, {close_reason::application_exit_call, L"application_exit_call"}});}
39  }
40 }
The xtd namespace contains all fundamental classes to access Hardware, Os, System, and more.
Definition: system_report.h:17
The user is closing the form through the user interface (UI), for example by clicking the Close butto...
close_reason
Specifies the reason that a form was closed.
Definition: close_reason.h:18
The Microsoft Windows Task Manager is closing the application.
The parent form of this multiple document interface (MDI) form is closing.
Contains xtd::ustring class.
The cause of the closure was not defined or could not be determined.
The operating system is closing all applications before shutting down.
The xtd::forms namespace contains classes for creating Windows-based applications that take full adva...
Definition: about_box.h:13
The Exit method of the Application class was invoked.
std::string to_string(const value_t &value, const std::string &fmt, const std::locale &loc)
Convert a specified value into a string with specified format and locale.
Definition: to_string.h:37