X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/6e3515377ca94ccc018f7a5ba8f185914081e601..f4bc1aa27cb33f679d7e9c1518a7855bbc1fa471:/include/wx/utils.h diff --git a/include/wx/utils.h b/include/wx/utils.h index 2fd8ed4284..72004ffe13 100644 --- a/include/wx/utils.h +++ b/include/wx/utils.h @@ -224,6 +224,7 @@ public: wxCoord GetX() const { return m_x; } wxCoord GetY() const { return m_y; } + wxPoint GetPosition() const { return wxPoint(m_x, m_y); } bool LeftDown() const { return m_leftDown; } bool MiddleDown() const { return m_middleDown; } @@ -418,12 +419,14 @@ enum wxKillFlags enum wxShutdownFlags { - wxSHUTDOWN_POWEROFF, // power off the computer - wxSHUTDOWN_REBOOT // shutdown and reboot + wxSHUTDOWN_FORCE = 1,// can be combined with other flags (MSW-only) + wxSHUTDOWN_POWEROFF = 2,// power off the computer + wxSHUTDOWN_REBOOT = 4,// shutdown and reboot + wxSHUTDOWN_LOGOFF = 8 // close session (currently MSW-only) }; // Shutdown or reboot the PC -WXDLLIMPEXP_BASE bool wxShutdown(wxShutdownFlags wFlags); +WXDLLIMPEXP_BASE bool wxShutdown(int flags = wxSHUTDOWN_POWEROFF); // send the given signal to the process (only NONE and KILL are supported under // Windows, all others mean TERM), return 0 if ok and -1 on error @@ -571,12 +574,16 @@ WXDLLIMPEXP_BASE void wxQsort(void *const pbase, size_t total_elems, // flags for wxLaunchDefaultBrowser enum { - wxBROWSER_NEW_WINDOW = 1 + wxBROWSER_NEW_WINDOW = 0x01, + wxBROWSER_NOBUSYCURSOR = 0x02 }; // Launch url in the user's default internet browser WXDLLIMPEXP_CORE bool wxLaunchDefaultBrowser(const wxString& url, int flags = 0); +// Launch document in the user's default application +WXDLLIMPEXP_CORE bool wxLaunchDefaultApplication(const wxString& path, int flags = 0); + // ---------------------------------------------------------------------------- // Menu accelerators related things // ----------------------------------------------------------------------------