Hello community, here is the log from the commit of package yast2-libyui for openSUSE:Factory checked in at Wed Apr 20 13:53:07 CEST 2011.
-------- --- yast2-libyui/yast2-libyui.changes 2011-02-11 11:40:03.000000000 +0100 +++ /mounts/work_src_done/STABLE/yast2-libyui/yast2-libyui.changes 2011-04-19 12:11:22.000000000 +0200 @@ -1,0 +2,12 @@ +Tue Apr 19 12:09:27 CEST 2011 - [email protected] + +- Don't allow recursive selection for non-multiselection widgets +- V 2.21.1 + +------------------------------------------------------------------- +Fri Apr 15 16:14:13 CEST 2011 - [email protected] + +- Added support for recursive selection in tree widgets +- V 2.20.3 + +------------------------------------------------------------------- calling whatdependson for head-i586 Old: ---- yast2-libyui-2.20.2.tar.bz2 New: ---- yast2-libyui-2.21.1.tar.bz2 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ yast2-libyui.spec ++++++ --- /var/tmp/diff_new_pack.FUNZDm/_old 2011-04-20 13:52:36.000000000 +0200 +++ /var/tmp/diff_new_pack.FUNZDm/_new 2011-04-20 13:52:36.000000000 +0200 @@ -19,11 +19,11 @@ Name: yast2-libyui -Version: 2.20.2 +Version: 2.21.1 Release: 1 BuildRoot: %{_tmppath}/%{name}-%{version}-build -Source0: yast2-libyui-2.20.2.tar.bz2 +Source0: yast2-libyui-2.21.1.tar.bz2 Prefix: /usr @@ -44,7 +44,7 @@ BuildRequires: boost-devel Summary: YaST2 - User Interface Engine -Provides: %{_libdir}/libyui.so.3.0.0 +Provides: %{_libdir}/libyui.so.4.0.0 %description This is the YaST2 user interface engine that provides the abstraction @@ -73,7 +73,7 @@ This package has very few dependencies. %prep -%setup -n yast2-libyui-2.20.2 +%setup -n yast2-libyui-2.21.1 %build %{prefix}/bin/y2tool y2autoconf @@ -124,4 +124,5 @@ %dir %{_datadir}/cmake/Modules %{_datadir}/cmake/Modules/* %doc %{prefix}/share/doc/packages/yast2-libyui + %changelog ++++++ yast2-libyui-2.20.2.tar.bz2 -> yast2-libyui-2.21.1.tar.bz2 ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-libyui-2.20.2/VERSION new/yast2-libyui-2.21.1/VERSION --- old/yast2-libyui-2.20.2/VERSION 2011-02-11 11:42:24.000000000 +0100 +++ new/yast2-libyui-2.21.1/VERSION 2011-04-19 12:09:14.000000000 +0200 @@ -1 +1 @@ -2.20.2 +2.21.1 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-libyui-2.20.2/configure new/yast2-libyui-2.21.1/configure --- old/yast2-libyui-2.20.2/configure 2011-02-11 11:42:56.000000000 +0100 +++ new/yast2-libyui-2.21.1/configure 2011-04-19 12:10:55.000000000 +0200 @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.65 for yast2-libyui 2.20.2. +# Generated by GNU Autoconf 2.65 for yast2-libyui 2.21.1. # # Report bugs to <http://bugs.opensuse.org/>. # @@ -701,8 +701,8 @@ # Identity of this package. PACKAGE_NAME='yast2-libyui' PACKAGE_TARNAME='yast2-libyui' -PACKAGE_VERSION='2.20.2' -PACKAGE_STRING='yast2-libyui 2.20.2' +PACKAGE_VERSION='2.21.1' +PACKAGE_STRING='yast2-libyui 2.21.1' PACKAGE_BUGREPORT='http://bugs.opensuse.org/' PACKAGE_URL='' @@ -1485,7 +1485,7 @@ # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures yast2-libyui 2.20.2 to adapt to many kinds of systems. +\`configure' configures yast2-libyui 2.21.1 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1556,7 +1556,7 @@ if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of yast2-libyui 2.20.2:";; + short | recursive ) echo "Configuration of yast2-libyui 2.21.1:";; esac cat <<\_ACEOF @@ -1669,7 +1669,7 @@ test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -yast2-libyui configure 2.20.2 +yast2-libyui configure 2.21.1 generated by GNU Autoconf 2.65 Copyright (C) 2009 Free Software Foundation, Inc. @@ -2068,7 +2068,7 @@ This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by yast2-libyui $as_me 2.20.2, which was +It was created by yast2-libyui $as_me 2.21.1, which was generated by GNU Autoconf 2.65. Invocation command line was $ $0 $@ @@ -2991,7 +2991,7 @@ # Define the identity of the package. PACKAGE='yast2-libyui' - VERSION='2.20.2' + VERSION='2.21.1' cat >>confdefs.h <<_ACEOF @@ -3113,7 +3113,7 @@ -VERSION="2.20.2" +VERSION="2.21.1" RPMNAME="yast2-libyui" MAINTAINER="Thomas Goettlicher <[email protected]>" @@ -16715,7 +16715,7 @@ # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by yast2-libyui $as_me 2.20.2, which was +This file was extended by yast2-libyui $as_me 2.21.1, which was generated by GNU Autoconf 2.65. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -16781,7 +16781,7 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ -yast2-libyui config.status 2.20.2 +yast2-libyui config.status 2.21.1 configured by $0, generated by GNU Autoconf 2.65, with options \\"\$ac_cs_config\\" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-libyui-2.20.2/configure.in new/yast2-libyui-2.21.1/configure.in --- old/yast2-libyui-2.20.2/configure.in 2011-02-11 11:42:46.000000000 +0100 +++ new/yast2-libyui-2.21.1/configure.in 2011-04-19 12:10:46.000000000 +0200 @@ -3,7 +3,7 @@ dnl -- This file is generated by y2autoconf 2.18.11 - DO NOT EDIT! -- dnl (edit configure.in.in instead) -AC_INIT(yast2-libyui, 2.20.2, http://bugs.opensuse.org/, yast2-libyui) +AC_INIT(yast2-libyui, 2.21.1, http://bugs.opensuse.org/, yast2-libyui) dnl Check for presence of file 'RPMNAME' AC_CONFIG_SRCDIR([RPMNAME]) @@ -18,7 +18,7 @@ AM_INIT_AUTOMAKE(tar-ustar -Wno-portability) dnl Important YaST2 variables -VERSION="2.20.2" +VERSION="2.21.1" RPMNAME="yast2-libyui" MAINTAINER="Thomas Goettlicher <[email protected]>" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-libyui-2.20.2/src/Makefile.am new/yast2-libyui-2.21.1/src/Makefile.am --- old/yast2-libyui-2.20.2/src/Makefile.am 2010-10-14 16:05:31.000000000 +0200 +++ new/yast2-libyui-2.21.1/src/Makefile.am 2011-04-18 17:29:22.000000000 +0200 @@ -14,7 +14,7 @@ lib_LTLIBRARIES = libyui.la -libyui_la_LDFLAGS = -version-info 3:0:0 -Wl,--no-undefined +libyui_la_LDFLAGS = -version-info 4:0:0 -Wl,--no-undefined libyui_la_LIBADD = -lpthread -ldl libyui_la_SOURCES = \ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-libyui-2.20.2/src/Makefile.in new/yast2-libyui-2.21.1/src/Makefile.in --- old/yast2-libyui-2.20.2/src/Makefile.in 2011-02-11 11:42:57.000000000 +0100 +++ new/yast2-libyui-2.21.1/src/Makefile.in 2011-04-19 12:10:57.000000000 +0200 @@ -308,7 +308,7 @@ AM_CPPFLAGS = -DLOCALEDIR=\"${localedir1}\" lib_LTLIBRARIES = libyui.la -libyui_la_LDFLAGS = -version-info 3:0:0 -Wl,--no-undefined +libyui_la_LDFLAGS = -version-info 4:0:0 -Wl,--no-undefined libyui_la_LIBADD = -lpthread -ldl libyui_la_SOURCES = \ YUI.cc \ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-libyui-2.20.2/src/YSelectionWidget.cc new/yast2-libyui-2.21.1/src/YSelectionWidget.cc --- old/yast2-libyui-2.20.2/src/YSelectionWidget.cc 2010-10-14 16:05:31.000000000 +0200 +++ new/yast2-libyui-2.21.1/src/YSelectionWidget.cc 2011-04-19 11:58:52.000000000 +0200 @@ -50,13 +50,16 @@ struct YSelectionWidgetPrivate { YSelectionWidgetPrivate( const string & label, - bool enforceSingleSelection ) + bool enforceSingleSelection, + bool recursiveSelection ) : label( label ) , enforceSingleSelection( enforceSingleSelection ) + , recursiveSelection ( recursiveSelection ) {} string label; bool enforceSingleSelection; + bool recursiveSelection; string iconBasePath; YItemCollection itemCollection; }; @@ -66,11 +69,16 @@ YSelectionWidget::YSelectionWidget( YWidget * parent, const string & label, - bool enforceSingleSelection ) + bool enforceSingleSelection , + bool recursiveSelection ) : YWidget( parent ) - , priv( new YSelectionWidgetPrivate( label, enforceSingleSelection ) ) + , priv( new YSelectionWidgetPrivate( label, enforceSingleSelection, recursiveSelection ) ) { YUI_CHECK_NEW( priv ); + + if ( enforceSingleSelection && recursiveSelection ) + YUI_THROW( YUIException( "recursiveSelection is only available for multiSelection Widgets.")); + } @@ -116,6 +124,12 @@ return priv->enforceSingleSelection; } +bool YSelectionWidget::recursiveSelection() const +{ + return priv->recursiveSelection; +} + + void YSelectionWidget::setEnforceSingleSelection( bool enforceSingleSelection ) { @@ -403,6 +417,17 @@ oldSelectedItem->setSelected( false ); } + + if ( recursiveSelection() && item->hasChildren() ) + { + for ( YItemIterator it = item->childrenBegin(); it != item->childrenEnd(); ++it ) + { + YItem * item = *it; + selectItem(item, selected ); + item->setSelected( selected ); + } + } + item->setSelected( selected ); } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-libyui-2.20.2/src/YSelectionWidget.h new/yast2-libyui-2.21.1/src/YSelectionWidget.h --- old/yast2-libyui-2.20.2/src/YSelectionWidget.h 2010-10-14 16:05:31.000000000 +0200 +++ new/yast2-libyui-2.21.1/src/YSelectionWidget.h 2011-04-18 17:29:22.000000000 +0200 @@ -69,7 +69,8 @@ **/ YSelectionWidget( YWidget * parent, const string & label, - bool enforceSingleSelection ); + bool enforceSingleSelection, + bool recurisveSelection = false ); public: /** @@ -301,6 +302,11 @@ bool enforceSingleSelection() const; /** + * Return 'true' if this base class should select children recursively. + **/ + bool recursiveSelection() const; + + /** * Recursively try to find the first selected item between iterators * 'begin' and 'end'. Return that item or 0 if there is none. **/ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-libyui-2.20.2/src/YTree.cc new/yast2-libyui-2.21.1/src/YTree.cc --- old/yast2-libyui-2.20.2/src/YTree.cc 2010-12-20 13:46:35.000000000 +0100 +++ new/yast2-libyui-2.21.1/src/YTree.cc 2011-04-18 17:29:22.000000000 +0200 @@ -57,9 +57,10 @@ }; -YTree::YTree( YWidget * parent, const string & label, bool multiSelection ) +YTree::YTree( YWidget * parent, const string & label, bool multiSelection, bool recursiveSelection ) : YSelectionWidget( parent, label, - ! multiSelection ) + ! multiSelection, + recursiveSelection ) , priv( new YTreePrivate() ) { YUI_CHECK_NEW( priv ); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-libyui-2.20.2/src/YTree.h new/yast2-libyui-2.21.1/src/YTree.h --- old/yast2-libyui-2.20.2/src/YTree.h 2011-02-08 12:11:17.000000000 +0100 +++ new/yast2-libyui-2.21.1/src/YTree.h 2011-04-18 17:29:22.000000000 +0200 @@ -74,8 +74,7 @@ /** * Constructor. **/ -// YTree( YWidget * parent, const string & label, bool multiSelection = false ); - YTree( YWidget * parent, const string & label, bool multiSelection); + YTree( YWidget * parent, const string & label, bool multiSelection, bool recursiveSelection); public: /** @@ -177,7 +176,6 @@ **/ bool hasMultiSelection() const; - /** * Return the the item that currently has the keyboard focus * or 0 if no item currently has the keyboard focus. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-libyui-2.20.2/src/YUILoader.cc new/yast2-libyui-2.21.1/src/YUILoader.cc --- old/yast2-libyui-2.20.2/src/YUILoader.cc 2010-10-14 16:05:31.000000000 +0200 +++ new/yast2-libyui-2.21.1/src/YUILoader.cc 2011-04-18 17:29:22.000000000 +0200 @@ -38,8 +38,10 @@ /-*/ #include <stdlib.h> // getenv() -#include <unistd.h> // isatty() +#include <unistd.h> // isatty()a +#include <sys/stat.h> +#include "YCommandLine.h" #include "YUILoader.h" #include "YUIPlugin.h" #include "YUIException.h" @@ -49,25 +51,38 @@ { const char * envDisplay = getenv( "DISPLAY" ); - if ( envDisplay ) + YCommandLine cmdline; + + bool wantNcurses = cmdline.find("--ncurses") != -1; + bool wantQt = cmdline.find("--qt") != -1; + bool wantGtk = cmdline.find("--gtk") != -1; + + bool haveQt = pluginExists( YUIPlugin_Qt ); + bool haveGtk = pluginExists( YUIPlugin_Gtk ); + + if ( envDisplay && !wantNcurses ) { - // - // Qt UI - // - + string wantedGUI; + + if ( haveQt && !wantGtk) + wantedGUI = YUIPlugin_Qt; + else if ( haveGtk && !wantQt ) + wantedGUI = YUIPlugin_Gtk; + try { - loadPlugin( YUIPlugin_Qt, withThreads ); + loadPlugin( wantedGUI, withThreads ); return; } catch ( YUIException & ex) { YUI_CAUGHT( ex ); } + } if ( isatty( STDOUT_FILENO ) ) - { + { // // NCurses UI // @@ -109,3 +124,17 @@ YUI_THROW( YUIPluginException( name ) ); } + +bool YUILoader::pluginExists( const string & pluginBaseName ) +{ + struct stat fileinfo; + string fullPath; + + fullPath.append( PLUGINDIR "/" ); // from -DPLUGINDIR in Makefile.am + fullPath.append( PLUGIN_PREFIX ); + fullPath.append( pluginBaseName ); + fullPath.append( PLUGIN_SUFFIX ); + + return stat( fullPath.c_str(), &fileinfo) == 0; + +} diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-libyui-2.20.2/src/YUILoader.h new/yast2-libyui-2.21.1/src/YUILoader.h --- old/yast2-libyui-2.20.2/src/YUILoader.h 2010-10-14 16:05:31.000000000 +0200 +++ new/yast2-libyui-2.21.1/src/YUILoader.h 2011-04-18 17:29:22.000000000 +0200 @@ -74,6 +74,8 @@ **/ static void loadPlugin( const string & name, bool withThreads = false ); + static bool pluginExists( const string & pluginBaseName ); + private: YUILoader() {} ~YUILoader() {} diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-libyui-2.20.2/src/YUIPlugin.cc new/yast2-libyui-2.21.1/src/YUIPlugin.cc --- old/yast2-libyui-2.20.2/src/YUIPlugin.cc 2010-10-14 16:05:31.000000000 +0200 +++ new/yast2-libyui-2.21.1/src/YUIPlugin.cc 2011-04-18 17:29:22.000000000 +0200 @@ -45,11 +45,6 @@ #include "YUIPlugin.h" - -#define PLUGIN_PREFIX "libpy2" -#define PLUGIN_SUFFIX ".so.2" - - using std::string; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-libyui-2.20.2/src/YUIPlugin.h new/yast2-libyui-2.21.1/src/YUIPlugin.h --- old/yast2-libyui-2.20.2/src/YUIPlugin.h 2010-10-14 16:05:31.000000000 +0200 +++ new/yast2-libyui-2.21.1/src/YUIPlugin.h 2011-04-18 17:29:22.000000000 +0200 @@ -41,6 +41,9 @@ #ifndef YUIPlugin_h #define YUIPlugin_h +#define PLUGIN_PREFIX "libpy2" +#define PLUGIN_SUFFIX ".so.2" + #include <string> using std::string; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-libyui-2.20.2/src/YUISymbols.h new/yast2-libyui-2.21.1/src/YUISymbols.h --- old/yast2-libyui-2.20.2/src/YUISymbols.h 2010-10-14 16:05:31.000000000 +0200 +++ new/yast2-libyui-2.21.1/src/YUISymbols.h 2011-04-18 17:29:22.000000000 +0200 @@ -265,6 +265,7 @@ #define YUIOpt_youMode "youMode" #define YUIOpt_zeroHeight "zeroHeight" #define YUIOpt_zeroWidth "zeroWidth" +#define YUIOpt_recursiveSelection "recursiveSelection" #define YUIOpt_key_F1 "key_F1" #define YUIOpt_key_F2 "key_F2" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-libyui-2.20.2/src/YWidgetFactory.h new/yast2-libyui-2.21.1/src/YWidgetFactory.h --- old/yast2-libyui-2.20.2/src/YWidgetFactory.h 2010-12-20 13:26:11.000000000 +0100 +++ new/yast2-libyui-2.21.1/src/YWidgetFactory.h 2011-04-18 17:29:22.000000000 +0200 @@ -122,7 +122,7 @@ virtual YRadioButton * createRadioButton ( YWidget * parent, const string & label, bool isChecked = false ) = 0; virtual YComboBox * createComboBox ( YWidget * parent, const string & label, bool editable = false ) = 0; virtual YSelectionBox * createSelectionBox ( YWidget * parent, const string & label ) = 0; - virtual YTree * createTree ( YWidget * parent, const string & label, bool multiselection = false ) = 0; + virtual YTree * createTree ( YWidget * parent, const string & label, bool multiselection = false, bool recursiveselection = false ) = 0; virtual YTable * createTable ( YWidget * parent, YTableHeader * header_disown, bool multiSelection = false ) = 0; virtual YProgressBar * createProgressBar ( YWidget * parent, const string & label, int maxValue = 100 ) = 0; virtual YRichText * createRichText ( YWidget * parent, const string & text = string(), bool plainTextMode = false ) = 0; ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Remember to have fun... -- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
