From a724578991eb4da6ec0ba1f393920643aaedef68 Mon Sep 17 00:00:00 2001 From: dmacvicar Date: Fri, 7 Dec 2007 16:42:15 +0000 Subject: [PATCH] YQSimplePatchSelector QT3_SUPPORT git-svn-id: http://svn.opensuse.org/svn/yast/trunk/qt4@42826 e0cc52ee-31ee-0310-8b87-e83c4596d67c --- src/pkg/YQSimplePatchSelector.cc | 47 +++++++++++++++++++------------- 1 file changed, 28 insertions(+), 19 deletions(-) diff --git a/src/pkg/YQSimplePatchSelector.cc b/src/pkg/YQSimplePatchSelector.cc index 758fc76..d13ff63 100644 --- a/src/pkg/YQSimplePatchSelector.cc +++ b/src/pkg/YQSimplePatchSelector.cc @@ -18,13 +18,11 @@ /-*/ -#define QT3_SUPPORT 1 - -#include -#include -#include -#include -#include +#include +#include +#include +#include +#include #define y2log_component "qt-pkg" #include @@ -97,23 +95,29 @@ YQSimplePatchSelector::basicLayout() { QSplitter * splitter = new QSplitter( Qt::Vertical, this ); Q_CHECK_PTR( splitter ); - splitter->setMargin( MARGIN ); // // PatchFilterView // - Q3VBox * upper_vbox = new Q3VBox( splitter ); + QBoxLayout *layout = new QVBoxLayout; + layout->setMargin( MARGIN ); + QWidget * upper_vbox = new QWidget( splitter ); Q_CHECK_PTR( upper_vbox ); - splitter->setResizeMode( upper_vbox, QSplitter::Stretch ); + upper_vbox->setLayout(layout); + splitter->addWidget(upper_vbox); + + + splitter->setStretchFactor( 0, 1 ); _patchFilterView = new YQPkgPatchFilterView( upper_vbox ); Q_CHECK_PTR( _patchFilterView ); - + layout->addWidget(_patchFilterView); + _patchList = _patchFilterView->patchList(); Q_CHECK_PTR( _patchList ); - addVSpacing( upper_vbox, MARGIN ); + //addVSpacing( upper_vbox, MARGIN ); // // Disk Usage @@ -121,12 +125,16 @@ YQSimplePatchSelector::basicLayout() #if SHOW_DISK_USAGE - Q3VBox * lower_vbox = new Q3VBox( splitter ); + layout = new QVBoxLayout; + QWidget * lower_vbox = new QWidget( splitter ); + lower_vbox->setLayout(layout); + Q_CHECK_PTR( lower_vbox ); - addVSpacing( lower_vbox, MARGIN ); + //addVSpacing( lower_vbox, MARGIN ); _diskUsageList = new YQPkgDiskUsageList( lower_vbox ); Q_CHECK_PTR( _diskUsageList ); + layout->addWidget(_diskUsageList); splitter->setResizeMode( lower_vbox, QSplitter::FollowSizeHint ); #endif @@ -142,18 +150,19 @@ YQSimplePatchSelector::basicLayout() // "Details" button // - addVSpacing( this, SPACING ); - - Q3HBox * hbox = new Q3HBox( this ); + //addVSpacing( this, SPACING ); + layout = new QHBoxLayout; + QWidget * hbox = new QWidget( this ); Q_CHECK_PTR( hbox ); - + hbox->setLayout(layout); QPushButton * details_button = new QPushButton( _( "&Details..." ), hbox ); + layout->addWidget(details_button); Q_CHECK_PTR( details_button ); connect( details_button, SIGNAL( clicked() ), this, SLOT ( detailedPackageSelection() ) ); - addHStretch( hbox ); + //addHStretch( hbox ); } else // ! _wizard { -- 2.39.2