summaryrefslogtreecommitdiffstats
path: root/Source/CursesDialog
diff options
context:
space:
mode:
authorBerk Geveci <berk.geveci@kitware.com>2002-01-14 19:49:05 (GMT)
committerBerk Geveci <berk.geveci@kitware.com>2002-01-14 19:49:05 (GMT)
commit5adda3463ac039c41da61ade37fa2e8ba6e1f7c7 (patch)
treed889b3d5a2ba09026b5493c9111321f42393385e /Source/CursesDialog
parentd0397266d2883a98133d0e72c8e1c510ffc4f73d (diff)
downloadCMake-5adda3463ac039c41da61ade37fa2e8ba6e1f7c7.zip
CMake-5adda3463ac039c41da61ade37fa2e8ba6e1f7c7.tar.gz
CMake-5adda3463ac039c41da61ade37fa2e8ba6e1f7c7.tar.bz2
BUG: Curses was being used without initialization.
Diffstat (limited to 'Source/CursesDialog')
-rw-r--r--Source/CursesDialog/cmCursesMainForm.cxx19
1 files changed, 11 insertions, 8 deletions
diff --git a/Source/CursesDialog/cmCursesMainForm.cxx b/Source/CursesDialog/cmCursesMainForm.cxx
index 0a4a31d..3e17ea1 100644
--- a/Source/CursesDialog/cmCursesMainForm.cxx
+++ b/Source/CursesDialog/cmCursesMainForm.cxx
@@ -310,8 +310,8 @@ void cmCursesMainForm::Render(int left, int top, int width, int height)
post_form(m_Form);
// Update toolbar
this->UpdateStatusBar();
- this->PrintKeys()
-;
+ this->PrintKeys();
+
touchwin(stdscr);
refresh();
}
@@ -517,7 +517,15 @@ void cmCursesMainForm::RunCMake(bool generateMakefiles)
// run the generate process
m_OkToGenerate = true;
- if(make.Generate(m_Args, generateMakefiles) != 0 || !m_Errors.empty())
+ int retVal = make.Generate(m_Args, generateMakefiles);
+
+ initscr(); /* Initialization */
+ noecho(); /* Echo off */
+ cbreak(); /* nl- or cr not needed */
+ keypad(stdscr,TRUE); /* Use key symbols as
+ KEY_DOWN*/
+
+ if( retVal != 0 || !m_Errors.empty())
{
// see if there was an error
if(cmSystemTools::GetErrorOccuredFlag())
@@ -537,11 +545,6 @@ void cmCursesMainForm::RunCMake(bool generateMakefiles)
this->Render(1,1,x,y);
}
- initscr(); /* Initialization */
- noecho(); /* Echo off */
- cbreak(); /* nl- or cr not needed */
- keypad(stdscr,TRUE); /* Use key symbols as
- KEY_DOWN*/
this->InitializeUI();
this->Render(1, 1, x, y);