xtd - Reference Guide  0.1.2
Modern c++17/20 framework to create console, GUI and unit test applications on Windows, macOS, Linux, iOS and android.
Loading...
Searching...
No Matches
dialog_result.h
Go to the documentation of this file.
1
4#pragma once
5#include <xtd/ustring.h>
6
8namespace xtd {
10 namespace forms {
39 enum class dialog_result {
41 none = 0,
43 ok = 1,
45 cancel = 2,
47 abort = 3,
49 retry = 4,
51 ignore = 5,
53 yes = 6,
55 no = 7
56 };
57
59 inline std::ostream& operator<<(std::ostream& os, dialog_result value) {return os << to_string(value, {{dialog_result::none, "none"}, {dialog_result::ok, "ok"}, {dialog_result::cancel, "cancel"}, {dialog_result::abort, "abort"}, {dialog_result::retry, "retry"}, {dialog_result::ignore, "ignore"}, {dialog_result::yes, "yes"}, {dialog_result::no, "no"}});}
60 inline std::wostream& operator<<(std::wostream& os, dialog_result value) {return os << to_string(value, {{dialog_result::none, L"none"}, {dialog_result::ok, L"ok"}, {dialog_result::cancel, L"cancel"}, {dialog_result::abort, L"abort"}, {dialog_result::retry, L"retry"}, {dialog_result::ignore, L"ignore"}, {dialog_result::yes, L"yes"}, {dialog_result::no, L"no"}});}
62 }
63}
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
dialog_result
Specifies identifiers to indicate the return value of a dialog box.
Definition dialog_result.h:39
@ cancel
The dialog box return value is Cancel (usually sent from a button labeled Cancel).
@ retry
The dialog box return value is Retry (usually sent from a button labeled Retry).
@ none
Nothing is returned from the dialog box. This means that the modal dialog continues running.
@ ok
The dialog box return value is OK (usually sent from a button labeled OK).
@ ignore
The dialog box return value is Ignore (usually sent from a button labeled Ignore).
@ abort
The dialog box return value is Abort (usually sent from a button labeled Abort).
@ no
The dialog box return value is No (usually sent from a button labeled No).
@ yes
The dialog box return value is Yes (usually sent from a button labeled Yes).
@ none
The cause of the closure was not defined or could not be determined.
The xtd::forms namespace contains classes for creating Windows-based applications that take full adva...
Definition about_box.h:13
The xtd namespace contains all fundamental classes to access Hardware, Os, System,...
Definition system_report.h:17
Contains xtd::ustring class.