aboutsummaryrefslogtreecommitdiff
path: root/ui.cpp
diff options
context:
space:
mode:
authors_nakamoto <s_nakamoto@1a98c847-1fd6-4fd8-948a-caf3550aa51b>2009-12-17 23:16:27 +0000
committers_nakamoto <s_nakamoto@1a98c847-1fd6-4fd8-948a-caf3550aa51b>2009-12-17 23:16:27 +0000
commit9a36562347122482fd1e6e77c74df66ad8cf2c3f (patch)
tree8ccd807e2b11eced4abfb04daa6a14401f5bda40 /ui.cpp
parent312c2c42b6d38dc7bfeef849722c8e231c38e8e4 (diff)
command line switch -noui
git-svn-id: https://bitcoin.svn.sourceforge.net/svnroot/bitcoin/trunk@52 1a98c847-1fd6-4fd8-948a-caf3550aa51b
Diffstat (limited to 'ui.cpp')
-rw-r--r--ui.cpp34
1 files changed, 15 insertions, 19 deletions
diff --git a/ui.cpp b/ui.cpp
index 6d65720d76..67895c127b 100644
--- a/ui.cpp
+++ b/ui.cpp
@@ -190,6 +190,9 @@ void CalledMessageBox(const string& message, const string& caption, int style, w
int ThreadSafeMessageBox(const string& message, const string& caption, int style, wxWindow* parent, int x, int y)
{
+ if (mapArgs.count("-noui"))
+ return wxOK;
+
#ifdef __WXMSW__
return wxMessageBox(message, caption, style, parent, x, y);
#else
@@ -3716,16 +3719,19 @@ bool CMyApp::OnInit2()
//
// Create the main frame window
//
- pframeMain = new CMainFrame(NULL);
- if (mapArgs.count("-min"))
- pframeMain->Iconize(true);
- pframeMain->Show(true); // have to show first to get taskbar button to hide
- if (fMinimizeToTray && pframeMain->IsIconized())
- fClosedToTray = true;
- pframeMain->Show(!fClosedToTray);
- ptaskbaricon->Show(fMinimizeToTray || fClosedToTray);
+ if (!mapArgs.count("-noui"))
+ {
+ pframeMain = new CMainFrame(NULL);
+ if (mapArgs.count("-min"))
+ pframeMain->Iconize(true);
+ pframeMain->Show(true); // have to show first to get taskbar button to hide
+ if (fMinimizeToTray && pframeMain->IsIconized())
+ fClosedToTray = true;
+ pframeMain->Show(!fClosedToTray);
+ ptaskbaricon->Show(fMinimizeToTray || fClosedToTray);
- CreateThread(ThreadDelayedRepaint, NULL);
+ CreateThread(ThreadDelayedRepaint, NULL);
+ }
if (!CheckDiskSpace())
return false;
@@ -3928,13 +3934,3 @@ void SetStartOnSystemStartup(bool fAutoStart)
bool GetStartOnSystemStartup() { return false; }
void SetStartOnSystemStartup(bool fAutoStart) { }
#endif
-
-
-
-
-
-
-
-
-
-