Hello community, here is the log from the commit of package yast2-ncurses checked in at Sat Aug 25 00:13:05 CEST 2007. -------- --- yast2-ncurses/yast2-ncurses.changes 2007-08-22 17:35:34.000000000 +0200 +++ /mounts/work_src_done/STABLE/yast2-ncurses/yast2-ncurses.changes 2007-08-24 15:18:33.830255000 +0200 @@ -1,0 +2,8 @@ +Fri Aug 24 14:18:24 CEST 2007 - kmachalkova@suse.cz + +- Smaller (vertical) default size of MultiLineEdit widget (partly + #292282) +- Redirecting stdout/stderr to log is now separate function +- 2.15.26 + +------------------------------------------------------------------- Old: ---- yast2-ncurses-2.15.25.tar.bz2 New: ---- yast2-ncurses-2.15.26.tar.bz2 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ yast2-ncurses.spec ++++++ --- /var/tmp/diff_new_pack.GN9688/_old 2007-08-25 00:12:45.000000000 +0200 +++ /var/tmp/diff_new_pack.GN9688/_new 2007-08-25 00:12:45.000000000 +0200 @@ -1,5 +1,5 @@ # -# spec file for package yast2-ncurses (Version 2.15.25) +# spec file for package yast2-ncurses (Version 2.15.26) # # Copyright (c) 2007 SUSE LINUX Products GmbH, Nuernberg, Germany. # This file and all modifications and additions to the pristine @@ -11,12 +11,12 @@ # norootforbuild Name: yast2-ncurses -Version: 2.15.25 +Version: 2.15.26 Release: 1 License: GPL v2 or later Group: System/YaST BuildRoot: %{_tmppath}/%{name}-%{version}-build -Source0: yast2-ncurses-2.15.25.tar.bz2 +Source0: yast2-ncurses-2.15.26.tar.bz2 prefix: /usr BuildRequires: dejagnu doxygen gcc-c++ libzypp-devel yast2-core-devel yast2-devtools BuildRequires: blocxx-devel libxcrypt-devel ncurses-devel @@ -44,7 +44,7 @@ %prep -%setup -n yast2-ncurses-2.15.25 +%setup -n yast2-ncurses-2.15.26 %build %{prefix}/bin/y2tool y2autoconf @@ -80,6 +80,11 @@ %doc %{prefix}/share/doc/packages/yast2-ncurses %changelog +* Fri Aug 24 2007 - kmachalkova@suse.cz +- Smaller (vertical) default size of MultiLineEdit widget (partly + [#292282]) +- Redirecting stdout/stderr to log is now separate function +- 2.15.26 * Wed Aug 22 2007 - kmachalkova@suse.cz - Correct setValue for CheckBoxFrame (added missing Redraw() call) (#301370) ++++++ yast2-ncurses-2.15.25.tar.bz2 -> yast2-ncurses-2.15.26.tar.bz2 ++++++ diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-ncurses-2.15.25/src/NCMultiLineEdit.cc new/yast2-ncurses-2.15.26/src/NCMultiLineEdit.cc --- old/yast2-ncurses-2.15.25/src/NCMultiLineEdit.cc 2007-05-18 10:55:40.000000000 +0200 +++ new/yast2-ncurses-2.15.26/src/NCMultiLineEdit.cc 2007-08-23 18:21:44.000000000 +0200 @@ -34,7 +34,7 @@ , NCPadWidget( parent ) { WIDDBG << endl; - defsze = wsze( 5, 5 ) + 2; + defsze = wsze( 5, 5 ) + wsze(0,2); setLabel( nlabel ); setText( initialText ); } diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-ncurses-2.15.25/src/NCurses.cc new/yast2-ncurses-2.15.26/src/NCurses.cc --- old/yast2-ncurses-2.15.25/src/NCurses.cc 2007-08-22 15:32:29.000000000 +0200 +++ new/yast2-ncurses-2.15.26/src/NCurses.cc 2007-08-24 14:15:29.000000000 +0200 @@ -209,8 +209,6 @@ if ( title_line() && ::ripoffline( 1, ripinit ) != OK ) throw NCursesError( "ripoffline() failed" ); - - string log = get_log_filename(); UIMIL << "isatty(stdin)" << (isatty(0) ? "yes" : "no") << endl; if (isatty( 0 )) { @@ -256,21 +254,15 @@ } } } + + //FIXME: Enable these with multithread support + //duplicate stdout and stderr before redirecting them to log + //so that they can be regenerated before system() call + //stdout_save = dup(1); + //stderr_save = dup(2); - UIMIL << "isatty(stderr)" << (isatty(2) ? "yes" : "no") << endl; - if (isatty(2) && theTerm) { - // redirect stderr to log - close(2); - open(log.c_str(), O_APPEND | O_CREAT); - } - - UIMIL << "isatty(stdout)" << (isatty(1) ? "yes" : "no") << endl; - if (isatty(1) && theTerm) { - // redirect stdout to log - close(1); - open(log.c_str(), O_APPEND | O_CREAT); - } - + RedirectToLog(); + if ( !theTerm ) { UIMIL << "no term so fall back to initscr" << endl; if ( ::initscr() == NULL ) @@ -574,6 +566,31 @@ /////////////////////////////////////////////////////////////////// // // +// METHOD NAME : NCurses::RedirectToLog +// METHOD TYPE : void +// +void NCurses::RedirectToLog() +{ + string log = get_log_filename(); + + UIMIL << "isatty(stderr)" << (isatty(2) ? "yes" : "no") << endl; + if (isatty(2) && theTerm) { + // redirect stderr to log + close(2); + open(log.c_str(), O_APPEND | O_CREAT); + } + + UIMIL << "isatty(stdout)" << (isatty(1) ? "yes" : "no") << endl; + if (isatty(1) && theTerm) { + // redirect stdout to log + close(1); + open(log.c_str(), O_APPEND | O_CREAT); + } + +} +/////////////////////////////////////////////////////////////////// +// +// // METHOD NAME : NCurses::ResizeEvent // METHOD TYPE : void // diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-ncurses-2.15.25/src/NCurses.h new/yast2-ncurses-2.15.26/src/NCurses.h --- old/yast2-ncurses-2.15.25/src/NCurses.h 2007-08-22 15:32:29.000000000 +0200 +++ new/yast2-ncurses-2.15.26/src/NCurses.h 2007-08-24 14:15:28.000000000 +0200 @@ -173,6 +173,10 @@ NCurses(); virtual ~NCurses(); + //FIXME: Enable these with multithread support + //int stdout_save; + //int stderr_save; + static int cols() { return ::COLS; } static int lines() { return ::LINES; } @@ -194,6 +198,7 @@ // actually not for public use static void ForgetDlg( NCDialog * dlg_r ); static void RememberDlg( NCDialog * dlg_r ); + void RedirectToLog(); static void ResizeEvent(); private: static set<NCDialog*> _knownDlgs; diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-ncurses-2.15.25/src/YNCursesUI.cc new/yast2-ncurses-2.15.26/src/YNCursesUI.cc --- old/yast2-ncurses-2.15.25/src/YNCursesUI.cc 2007-08-22 15:32:29.000000000 +0200 +++ new/yast2-ncurses-2.15.26/src/YNCursesUI.cc 2007-08-24 14:18:15.000000000 +0200 @@ -773,6 +773,12 @@ ::def_prog_mode(); ::endwin(); + //FIXME: Enable these with multithread support + //Regenerate saved stdout and stderr, so that app called + //via system() can use them and draw something to the terminal + //dup2(NCurses::stdout_save, 1); + //dup2(NCurses::stderr_save, 2); + //Call external program ret = system(cmd.c_str()); @@ -781,6 +787,10 @@ NCERR << cmd << " returned:" << ret << endl; } + //FIXME: Enable these with multithread support + //Redirect stdout and stderr to y2log again + //NCurses::RedirectToLog(); + //Resume tty modes and refresh the screen ::reset_prog_mode(); ::refresh(); diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-ncurses-2.15.25/VERSION new/yast2-ncurses-2.15.26/VERSION --- old/yast2-ncurses-2.15.25/VERSION 2007-08-22 17:19:16.000000000 +0200 +++ new/yast2-ncurses-2.15.26/VERSION 2007-08-24 14:44:21.000000000 +0200 @@ -1 +1 @@ -2.15.25 +2.15.26 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Remember to have fun... --------------------------------------------------------------------- To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-commit+help@opensuse.org