Use a messagebox to display the error when -server is provided without providing...
[novacoin.git] / src / qtui.h
1 // Copyright (c) 2010 Satoshi Nakamoto
2 // Distributed under the MIT/X11 software license, see the accompanying
3 // file license.txt or http://www.opensource.org/licenses/mit-license.php.
4 #ifndef BITCOIN_EXTERNUI_H
5 #define BITCOIN_EXTERNUI_H
6
7 #include <string>
8 #include <boost/function/function0.hpp>
9 #include "wallet.h"
10
11 typedef void wxWindow;
12 #define wxYES                   0x00000002
13 #define wxOK                    0x00000004
14 #define wxNO                    0x00000008
15 #define wxYES_NO                (wxYES|wxNO)
16 #define wxCANCEL                0x00000010
17 #define wxAPPLY                 0x00000020
18 #define wxCLOSE                 0x00000040
19 #define wxOK_DEFAULT            0x00000000
20 #define wxYES_DEFAULT           0x00000000
21 #define wxNO_DEFAULT            0x00000080
22 #define wxCANCEL_DEFAULT        0x80000000
23 #define wxICON_EXCLAMATION      0x00000100
24 #define wxICON_HAND             0x00000200
25 #define wxICON_WARNING          wxICON_EXCLAMATION
26 #define wxICON_ERROR            wxICON_HAND
27 #define wxICON_QUESTION         0x00000400
28 #define wxICON_INFORMATION      0x00000800
29 #define wxICON_STOP             wxICON_HAND
30 #define wxICON_ASTERISK         wxICON_INFORMATION
31 #define wxICON_MASK             (0x00000100|0x00000200|0x00000400|0x00000800)
32 #define wxFORWARD               0x00001000
33 #define wxBACKWARD              0x00002000
34 #define wxRESET                 0x00004000
35 #define wxHELP                  0x00008000
36 #define wxMORE                  0x00010000
37 #define wxSETUP                 0x00020000
38 // Force blocking, modal message box dialog (not just notification)
39 #define wxMODAL                 0x00040000
40
41 extern int MyMessageBox(const std::string& message, const std::string& caption="Message", int style=wxOK, wxWindow* parent=NULL, int x=-1, int y=-1);
42 #define wxMessageBox  MyMessageBox
43 extern int ThreadSafeMessageBox(const std::string& message, const std::string& caption, int style=wxOK, wxWindow* parent=NULL, int x=-1, int y=-1);
44 extern bool ThreadSafeAskFee(int64 nFeeRequired, const std::string& strCaption, wxWindow* parent);
45 extern void CalledSetStatusBar(const std::string& strText, int nField);
46 extern void UIThreadCall(boost::function0<void> fn);
47 extern void MainFrameRepaint();
48 extern void InitMessage(const std::string &message);
49 extern std::string _(const char* psz);
50
51 #endif