Skip to content

Commit 769ebb2

Browse files
committed
use int instead of bool
1 parent f6deeb0 commit 769ebb2

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

source/MoorDyn.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ int OwnConsoleWindow = 0;
6767
#endif
6868

6969
// Default is false, meaning the console will open
70-
bool disableConsole = false;
70+
int disableConsole = 0;
7171

7272
/**
7373
* @}
@@ -88,7 +88,7 @@ MoorDyn md_singleton = NULL;
8888
int DECLDIR
8989
MoorDynInit(const double x[], const double xd[], const char* infilename)
9090
{
91-
if (!disableConsole) {
91+
if (disableConsole == 0) {
9292
#ifdef WIN32
9393
// ------------ create console window for messages if none already available
9494
// ----------------- adapted from Andrew S. Tucker, "Adding Console I/O to a
@@ -300,7 +300,7 @@ AllOutput(double t, double dt)
300300
}
301301

302302
void DECLDIR
303-
SetDisableConsole(bool disable)
303+
SetDisableConsole(int disable)
304304
{
305305
disableConsole = disable;
306306
}

source/MoorDyn.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -155,10 +155,10 @@ AllOutput(double, double);
155155
/** @brief Set the variable to disable the console window.
156156
*
157157
* Use this function to control display of the console window popup.
158-
* @param disable Set disable to true to disable the console window.
158+
* @param disable Set disable to 1 to disable the console window.
159159
*/
160160
void DECLDIR
161-
SetDisableConsole(bool disable);
161+
SetDisableConsole(int disable);
162162

163163
/**
164164
* @}

0 commit comments

Comments
 (0)