author | drw <drw> | 2004-04-21 18:20:31 (UTC) |
---|---|---|
committer | drw <drw> | 2004-04-21 18:20:31 (UTC) |
commit | ac414fa3802b471857bc84ecdd0d37200541b0a7 (patch) (side-by-side diff) | |
tree | b3557b5f67444c891f98fd3153a30d2cbd765636 | |
parent | a3c0ad0bddfdfd2a2ed476229df1ef8032a93871 (diff) | |
download | opie-ac414fa3802b471857bc84ecdd0d37200541b0a7.zip opie-ac414fa3802b471857bc84ecdd0d37200541b0a7.tar.gz opie-ac414fa3802b471857bc84ecdd0d37200541b0a7.tar.bz2 |
Added some missed QWhatsThis, removed OConfItem location as it is not used/needed, reordered includes to follow conventions, removed all using namespaces occurrances and updated documentation
22 files changed, 105 insertions, 139 deletions
diff --git a/noncore/settings/packagemanager/ChangeLog b/noncore/settings/packagemanager/ChangeLog index d53a2b3..c9e33c4 100644 --- a/noncore/settings/packagemanager/ChangeLog +++ b/noncore/settings/packagemanager/ChangeLog @@ -1,6 +1,15 @@ +2004-04-21 Dan Williams <drw@handhelds.org> + + * Released version 0.4.0 + * Added saving of ipkg configuration information + * Re-initialize ipkg when configuration information changes + * Added QWhatsThis for all UI controls + * Remove Location from OConfItem as it is not used/needed + * Re-ordered includes to follow Opie standards + 2004-02-13 Dan Williams <drw@handhelds.org> * Released version 0.3.0 * Fix handling of filtering options in View menu * Do proper version string comparison * Fix string alignment code in PromptDlg to eliminate QT warning messages diff --git a/noncore/settings/packagemanager/README b/noncore/settings/packagemanager/README index 9324f9c..bf93c98 100644 --- a/noncore/settings/packagemanager/README +++ b/noncore/settings/packagemanager/README @@ -1,11 +1,11 @@ /************************************************************************ /* /* Opie - Package Manager /* ======================== -/* Version 0.3.0 +/* Version 0.4.0 /* /* A package management client for Opie /* /************************************************************************ ------------------------------------------------------- diff --git a/noncore/settings/packagemanager/TODO b/noncore/settings/packagemanager/TODO index 448ade3..633c589 100644 --- a/noncore/settings/packagemanager/TODO +++ b/noncore/settings/packagemanager/TODO @@ -1,11 +1,11 @@ /************************************************************************ /* /* Opie - Package Manager /* ======================== -/* Version 0.3.0 +/* Version 0.4.0 /* /* A package management client for Opie /* /************************************************************************ --------------------------------------------- @@ -13,16 +13,15 @@ --------------------------------------------- ====================== = Current release = ====================== -1. Save configuration information (i.e. /etc/ipkg.conf) -2. Link non-root destination apps -3. Implement QCOP interface for installing, removing, etc. -4. Redesign configuration dialog +1. Link non-root destination apps +2. Implement QCOP interface for installing, removing, etc. +3. Redesign configuration dialog ====================== = Future releases = ====================== 1. ???
\ No newline at end of file diff --git a/noncore/settings/packagemanager/entrydlg.cpp b/noncore/settings/packagemanager/entrydlg.cpp index 663abd2..fd275e1 100644 --- a/noncore/settings/packagemanager/entrydlg.cpp +++ b/noncore/settings/packagemanager/entrydlg.cpp @@ -26,19 +26,19 @@ Boston, MA 02111-1307, USA. */ #include "entrydlg.h" +#include <qpe/qpeapplication.h> + #include <qlabel.h> #include <qlayout.h> #include <qlineedit.h> #include <qpushbutton.h> -#include <qpe/qpeapplication.h> - EntryDlg::EntryDlg( const QString &label, QWidget* parent, const char* name, bool modal ) : QDialog( parent, name, modal ) { QVBoxLayout *vbox = new QVBoxLayout( this, 6, 6 ); QLabel *l = new QLabel( label, this ); diff --git a/noncore/settings/packagemanager/filterdlg.h b/noncore/settings/packagemanager/filterdlg.h index de9ea80..bd89b42 100644 --- a/noncore/settings/packagemanager/filterdlg.h +++ b/noncore/settings/packagemanager/filterdlg.h @@ -27,21 +27,21 @@ */ #ifndef FILTERDLG_H #define FILTERDLG_H +#include "opackagemanager.h" + #include <qcheckbox.h> #include <qdialog.h> #include <qcombobox.h> #include <qlayout.h> #include <qlineedit.h> #include <qscrollview.h> -#include "opackagemanager.h" - class FilterDlg : public QDialog { Q_OBJECT public: FilterDlg( QWidget *parent = 0x0, OPackageManager *pm = 0x0, const QString &name = 0x0, diff --git a/noncore/settings/packagemanager/global.h b/noncore/settings/packagemanager/global.h deleted file mode 100644 index 0fe5b85..0000000 --- a/noncore/settings/packagemanager/global.h +++ b/dev/null @@ -1,37 +0,0 @@ -/* - This file is part of the Opie Project - - Copyright (c) 2003 Dan Williams <drw@handhelds.org> - =. - .=l. - .>+-= - _;:, .> :=|. This program is free software; you can -.> <`_, > . <= redistribute it and/or modify it under -:`=1 )Y*s>-.-- : the terms of the GNU Library General Public -.="- .-=="i, .._ License as published by the Free Software - - . .-<_> .<> Foundation; either version 2 of the License, - ._= =} : or (at your option) any later version. - .%`+i> _;_. - .i_,=:_. -<s. This program is distributed in the hope that - + . -:. = it will be useful, but WITHOUT ANY WARRANTY; - : .. .:, . . . without even the implied warranty of - =_ + =;=|` MERCHANTABILITY or FITNESS FOR A - _.=:. : :=>`: PARTICULAR PURPOSE. See the GNU -..}^=.= = ; Library General Public License for more -++= -. .` .: details. - : = ...= . :.=- - -. .:....=;==+<; You should have received a copy of the GNU - -_. . . )=. = Library General Public License along with - -- :-=` this library; see the file COPYING.LIB. - If not, write to the Free Software Foundation, - Inc., 59 Temple Place - Suite 330, - Boston, MA 02111-1307, USA. - -*/ - -#ifndef GLOBAL_H -#define GLOBAL_H - -#define VERSION "0.0.0" - -#endif
\ No newline at end of file diff --git a/noncore/settings/packagemanager/installdlg.cpp b/noncore/settings/packagemanager/installdlg.cpp index 4a55c10..0cb30e2 100644 --- a/noncore/settings/packagemanager/installdlg.cpp +++ b/noncore/settings/packagemanager/installdlg.cpp @@ -26,33 +26,32 @@ Boston, MA 02111-1307, USA. */ #include "installdlg.h" -#include <sys/vfs.h> +#include <opie2/ofiledialog.h> + +#include <qpe/fileselector.h> +#include <qpe/resource.h> +#include <qpe/storage.h> #include <qapplication.h> #include <qcombobox.h> #include <qfileinfo.h> #include <qgroupbox.h> #include <qlabel.h> #include <qlayout.h> #include <qmap.h> #include <qmultilineedit.h> #include <qpushbutton.h> -#include <qpe/fileselector.h> -#include <qpe/resource.h> -#include <qpe/storage.h> - -#include <opie2/ofiledialog.h> +#include <sys/vfs.h> #include "opackagemanager.h" -using namespace Opie::Ui; InstallDlg::InstallDlg( QWidget *parent, OPackageManager *pm, const QString &caption, bool showDestInfo, OPackage::Command command1, QStringList *packages1, OPackage::Command command2, QStringList *packages2, OPackage::Command command3, QStringList *packages3 ) : QWidget( 0x0 ) , m_packman( pm ) @@ -273,13 +272,13 @@ void InstallDlg::slotBtnOptions() QStringList text; text << "text/*"; map.insert(tr( "Text" ), text ); text << "*"; map.insert( tr( "All" ), text ); - QString filename = OFileDialog::getSaveFileName( 2, "/", "ipkg-output", map ); + QString filename = Opie::Ui::OFileDialog::getSaveFileName( 2, "/", "ipkg-output", map ); if( !filename.isEmpty() ) { QString currentFileName = QFileInfo( filename ).fileName(); DocLnk doc; doc.setType( "text/plain" ); doc.setFile( filename ); diff --git a/noncore/settings/packagemanager/main.cpp b/noncore/settings/packagemanager/main.cpp index c050e1a..3792881 100644 --- a/noncore/settings/packagemanager/main.cpp +++ b/noncore/settings/packagemanager/main.cpp @@ -28,8 +28,7 @@ */ #include "mainwindow.h" #include <opie2/oapplicationfactory.h> -using namespace Opie::Core; -OPIE_EXPORT_APP( OApplicationFactory<MainWindow> ) +OPIE_EXPORT_APP( Opie::Core::OApplicationFactory<MainWindow> ) diff --git a/noncore/settings/packagemanager/mainwindow.cpp b/noncore/settings/packagemanager/mainwindow.cpp index 810046f..991cc81 100644 --- a/noncore/settings/packagemanager/mainwindow.cpp +++ b/noncore/settings/packagemanager/mainwindow.cpp @@ -24,34 +24,34 @@ -- :-=` Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ +#include "mainwindow.h" +#include "installdlg.h" +#include "filterdlg.h" +#include "promptdlg.h" +#include "entrydlg.h" +#include "packageinfodlg.h" + +#include <qpe/qcopenvelope_qws.h> +#include <qpe/qpeapplication.h> +#include <qpe/resource.h> + #include <qaction.h> #include <qdir.h> #include <qlayout.h> #include <qlineedit.h> #include <qmenubar.h> #include <qmessagebox.h> #include <qpopupmenu.h> #include <qtimer.h> #include <qtoolbar.h> #include <qwhatsthis.h> -#include <qpe/qcopenvelope_qws.h> -#include <qpe/qpeapplication.h> -#include <qpe/resource.h> - -#include "mainwindow.h" -#include "installdlg.h" -#include "filterdlg.h" -#include "promptdlg.h" -#include "entrydlg.h" -#include "packageinfodlg.h" - MainWindow::MainWindow( QWidget *parent, const char *name, WFlags /*fl*/ ) : QMainWindow( parent, name, WStyle_ContextHelp ) , m_config( "packman" ) , m_packman( &m_config, this ) , m_menuBar( this ) , m_toolBar( this ) diff --git a/noncore/settings/packagemanager/mainwindow.h b/noncore/settings/packagemanager/mainwindow.h index fb555c5..632effb 100644 --- a/noncore/settings/packagemanager/mainwindow.h +++ b/noncore/settings/packagemanager/mainwindow.h @@ -27,24 +27,24 @@ */ #ifndef MAINWINDOW_H #define MAINWINDOW_H +#include "opackagemanager.h" + +#include <qpe/config.h> + #include <qlabel.h> #include <qlistview.h> #include <qmainwindow.h> #include <qpixmap.h> #include <qprogressbar.h> #include <qtoolbar.h> #include <qwidgetstack.h> -#include <qpe/config.h> - -#include "opackagemanager.h" - class QAction; class QLineEdit; class MainWindow :public QMainWindow { Q_OBJECT diff --git a/noncore/settings/packagemanager/oconfitem.cpp b/noncore/settings/packagemanager/oconfitem.cpp index 940a6de..a90730c 100644 --- a/noncore/settings/packagemanager/oconfitem.cpp +++ b/noncore/settings/packagemanager/oconfitem.cpp @@ -28,15 +28,14 @@ Boston, MA 02111-1307, USA. */ #include "oconfitem.h" -OConfItem::OConfItem( const QString &location, Type type, const QString &name, +OConfItem::OConfItem( Type type, const QString &name, const QString &value, bool active ) - : m_location( location ) - , m_type( type ) + : m_type( type ) , m_name( name ) , m_value( value ) , m_active( active ) { } diff --git a/noncore/settings/packagemanager/oconfitem.h b/noncore/settings/packagemanager/oconfitem.h index aeee511..db77980 100644 --- a/noncore/settings/packagemanager/oconfitem.h +++ b/noncore/settings/packagemanager/oconfitem.h @@ -37,29 +37,26 @@ class OConfItem { public: enum Type { Source, Destination, Option, Arch, NotDefined }; - OConfItem( const QString &location = 0x0, Type type = NotDefined, const QString &name = 0x0, - const QString &value = 0x0, bool active = true ); + OConfItem( Type type = NotDefined, const QString &name = 0x0, const QString &value = 0x0, + bool active = true ); - const QString &location() { return m_location; } Type type() { return m_type; } const QString &name() { return m_name; } const QString &value() { return m_value; } bool active() { return m_active; } - void setLocation( const QString &location ) { m_location = location; } - void setType( Type type ) { m_type = type; } - void setName( const QString &name ) { m_name = name; } - void setValue( const QString &value ) { m_value = value; } - void setActive( bool active ) { m_active = active; } + void setType( Type type ) { m_type = type; } + void setName( const QString &name ) { m_name = name; } + void setValue( const QString &value ) { m_value = value; } + void setActive( bool active ) { m_active = active; } private: - QString m_location; // Configuration file where item is located Type m_type; // Type of configuration item QString m_name; // Name of item QString m_value; // Value of item bool m_active; // Indicates whether item is currently active }; @@ -67,28 +64,28 @@ class OConfItemList : public QList<OConfItem> { private: int compareItems( QCollection::Item item1, QCollection::Item item2 ) { // Sort by OConfItem location then by type - QString loc1 = reinterpret_cast<OConfItem*>(item1)->location(); - QString loc2 = reinterpret_cast<OConfItem*>(item2)->location(); - if ( loc1 < loc2 ) + OConfItem::Type type1 = reinterpret_cast<OConfItem*>(item1)->type(); + OConfItem::Type type2 = reinterpret_cast<OConfItem*>(item2)->type(); + if ( type1 < type2 ) return -1; - else if ( loc1 == loc2 ) + else if ( type1 == type2 ) { - OConfItem::Type type1 = reinterpret_cast<OConfItem*>(item1)->type(); - OConfItem::Type type2 = reinterpret_cast<OConfItem*>(item2)->type(); - if ( type1 < type2 ) + QString name1 = reinterpret_cast<OConfItem*>(item1)->name(); + QString name2 = reinterpret_cast<OConfItem*>(item2)->name(); + if ( name1 < name2 ) return -1; - else if ( type1 == type2 ) + else if ( name1 == name2 ) return 0; - else /*if ( type1 > type2 )*/ + else /*if ( name1 > name2 )*/ return 1; } - else /*if ( loc1 > loc2 )*/ + else /*if ( type1 > type2 )*/ return 1; } }; typedef QListIterator<OConfItem> OConfItemListIterator; diff --git a/noncore/settings/packagemanager/oipkg.cpp b/noncore/settings/packagemanager/oipkg.cpp index 696a64a..87a30bb 100644 --- a/noncore/settings/packagemanager/oipkg.cpp +++ b/noncore/settings/packagemanager/oipkg.cpp @@ -28,19 +28,18 @@ Boston, MA 02111-1307, USA. */ #include "oipkg.h" -#include <stdlib.h> -#include <string.h> - #include <qdir.h> #include <qfile.h> #include <qtextstream.h> +#include <stdlib.h> + const QString IPKG_CONF = "/etc/ipkg.conf"; // Fully-qualified name of Ipkg primary configuration file const QString IPKG_CONF_DIR = "/etc/ipkg"; // Directory of secondary Ipkg configuration files const QString IPKG_PKG_PATH = "/usr/lib/ipkg/lists"; // Directory containing server package lists const QString IPKG_STATUS_PATH = "usr/lib/ipkg/status"; // Destination status file location OIpkg *oipkg; @@ -526,13 +525,13 @@ void OIpkg::loadConfiguration() value = line.right( line.length() - endpos - 1 ); // Active bool active = !line.startsWith( "#" ); // Add to list - m_confInfo->append( new OConfItem( absFile, type, name, value, active ) ); + m_confInfo->append( new OConfItem( type, name, value, active ) ); } } } f.close(); } diff --git a/noncore/settings/packagemanager/oipkg.h b/noncore/settings/packagemanager/oipkg.h index ea126cf..b8a859a 100644 --- a/noncore/settings/packagemanager/oipkg.h +++ b/noncore/settings/packagemanager/oipkg.h @@ -29,22 +29,22 @@ */ #ifndef OIPKG_H #define OIPKG_H -extern "C" { -#include <libipkg.h> -}; - -#include <qobject.h> +#include "oconfitem.h" +#include "opackage.h" #include <qpe/config.h> -#include "oconfitem.h" -#include "opackage.h" +#include <qobject.h> + +extern "C" { +#include <libipkg.h> +}; // Ipkg execution options (m_ipkgExecOptions) #define FORCE_DEPENDS 0x0001 #define FORCE_REMOVE 0x0002 #define FORCE_REINSTALL 0x0004 #define FORCE_OVERWRITE 0x0008 diff --git a/noncore/settings/packagemanager/oipkgconfigdlg.cpp b/noncore/settings/packagemanager/oipkgconfigdlg.cpp index d134651..7941ab8 100644 --- a/noncore/settings/packagemanager/oipkgconfigdlg.cpp +++ b/noncore/settings/packagemanager/oipkgconfigdlg.cpp @@ -28,25 +28,24 @@ Boston, MA 02111-1307, USA. */ #include "oipkgconfigdlg.h" +#include <qpe/resource.h> + #include <qcheckbox.h> #include <qcombobox.h> #include <qgroupbox.h> #include <qlabel.h> #include <qlineedit.h> #include <qlistbox.h> #include <qpushbutton.h> #include <qscrollview.h> #include <qwhatsthis.h> -#include <qpe/resource.h> - -using namespace Opie::Ui; OIpkgConfigDlg::OIpkgConfigDlg( OIpkg *ipkg, bool installOptions, QWidget *parent ) : QDialog( parent, QString::null, true, WStyle_ContextHelp ) , m_ipkg( ipkg ) , m_configs( 0x0 ) , m_installOptions( installOptions ) , m_serverNew( false ) @@ -98,37 +97,37 @@ void OIpkgConfigDlg::accept() if ( confItem ) { confItem->setValue( m_proxyHttpServer->text() ); confItem->setActive( m_proxyHttpActive->isChecked() ); } else - m_configs->append( new OConfItem( QString::null, OConfItem::Option, "http_proxy", + m_configs->append( new OConfItem( OConfItem::Option, "http_proxy", m_proxyHttpServer->text(), m_proxyHttpActive->isChecked() ) ); confItem = findConfItem( OConfItem::Option, "ftp_proxy" ); if ( confItem ) { confItem->setValue( m_proxyFtpServer->text() ); confItem->setActive( m_proxyFtpActive->isChecked() ); } else - m_configs->append( new OConfItem( QString::null, OConfItem::Option, "ftp_proxy", + m_configs->append( new OConfItem( OConfItem::Option, "ftp_proxy", m_proxyFtpServer->text(), m_proxyFtpActive->isChecked() ) ); confItem = findConfItem( OConfItem::Option, "proxy_username" ); if ( confItem ) confItem->setValue( m_proxyUsername->text() ); else - m_configs->append( new OConfItem( QString::null, OConfItem::Option, "proxy_username", + m_configs->append( new OConfItem( OConfItem::Option, "proxy_username", m_proxyUsername->text() ) ); confItem = findConfItem( OConfItem::Option, "proxy_password" ); if ( confItem ) confItem->setValue( m_proxyPassword->text() ); else - m_configs->append( new OConfItem( QString::null, OConfItem::Option, "proxy_password", + m_configs->append( new OConfItem( OConfItem::Option, "proxy_password", m_proxyPassword->text() ) ); m_ipkg->setConfigItems( m_configs ); } // Save options configuration @@ -529,13 +528,13 @@ void OIpkgConfigDlg::slotServerUpdate() } } } else { // Add new destination to configuration list - m_configs->append( new OConfItem( QString::null, OConfItem::Source, newName, + m_configs->append( new OConfItem( OConfItem::Source, newName, m_serverLocation->text(), m_serverActive->isChecked() ) ); m_configs->sort(); m_serverList->insertItem( newName ); m_serverList->setCurrentItem( m_serverList->count() ); m_serverNew = false; @@ -615,13 +614,13 @@ void OIpkgConfigDlg::slotDestUpdate() } } } else { // Add new destination to configuration list - m_configs->append( new OConfItem( QString::null, OConfItem::Destination, newName, + m_configs->append( new OConfItem( OConfItem::Destination, newName, m_destLocation->text(), m_destActive->isChecked() ) ); m_configs->sort(); m_destList->insertItem( newName ); m_destList->setCurrentItem( m_destList->count() ); m_destNew = false; diff --git a/noncore/settings/packagemanager/oipkgconfigdlg.h b/noncore/settings/packagemanager/oipkgconfigdlg.h index 0aba898..800d94a 100644 --- a/noncore/settings/packagemanager/oipkgconfigdlg.h +++ b/noncore/settings/packagemanager/oipkgconfigdlg.h @@ -30,17 +30,17 @@ */ #ifndef OIPKGCONFIGDLG_H #define OIPKGCONFIGDLG_H +#include <opie2/otabwidget.h> + #include <qdialog.h> #include <qlayout.h> -#include <opie2/otabwidget.h> - #include "oipkg.h" class QCheckBox; class QComboBox; class QLineEdit; class QListBox; @@ -70,18 +70,18 @@ private: // Destination cached information bool m_destNew; // Indicates if destination information is for a new destination int m_destCurrent; // Index of currently selected destination in m_destList QString m_destCurrName; // Name of currently selected destination in m_destList // UI controls - QVBoxLayout m_layout; // Main dialog layout control - Opie::Ui::OTabWidget m_tabWidget; // Main tab widget control - QWidget *m_serverWidget; // Widget containing server configuration controls - QWidget *m_destWidget; // Widget containing destination configuration controls - QWidget *m_proxyWidget; // Widget containing proxy configuration controls - QWidget *m_optionsWidget; // Widget containing ipkg execution configuration controls + QVBoxLayout m_layout; // Main dialog layout control + Opie::Ui::OTabWidget m_tabWidget; // Main tab widget control + QWidget *m_serverWidget; // Widget containing server configuration controls + QWidget *m_destWidget; // Widget containing destination configuration controls + QWidget *m_proxyWidget; // Widget containing proxy configuration controls + QWidget *m_optionsWidget; // Widget containing ipkg execution configuration controls // Server configuration UI controls QListBox *m_serverList; // Server list selection QLineEdit *m_serverName; // Server name edit box QLineEdit *m_serverLocation; // Server location URL edit box QCheckBox *m_serverActive; // Activate server check box diff --git a/noncore/settings/packagemanager/opackagemanager.cpp b/noncore/settings/packagemanager/opackagemanager.cpp index 3633e05..f75d3b3 100644 --- a/noncore/settings/packagemanager/opackagemanager.cpp +++ b/noncore/settings/packagemanager/opackagemanager.cpp @@ -26,18 +26,18 @@ If not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -#include <ctype.h> +#include "opackagemanager.h" +#include "oipkgconfigdlg.h" #include <qpe/qpeapplication.h> -#include "opackagemanager.h" -#include "oipkgconfigdlg.h" +#include <ctype.h> OPackageManager::OPackageManager( Config *config, QObject *parent, const char *name ) : QObject( parent, name ) , m_config( config ) , m_ipkg( m_config, this ) , m_packages( 9973 ) diff --git a/noncore/settings/packagemanager/opackagemanager.h b/noncore/settings/packagemanager/opackagemanager.h index b710a51..58e597b 100644 --- a/noncore/settings/packagemanager/opackagemanager.h +++ b/noncore/settings/packagemanager/opackagemanager.h @@ -29,19 +29,19 @@ */ #ifndef OPACKAGEMANAGER_H #define OPACKAGEMANAGER_H -#include <qdict.h> -#include <qobject.h> -#include <qstringlist.h> +#include "oipkg.h" #include <qpe/config.h> -#include "oipkg.h" +#include <qdict.h> +#include <qobject.h> +#include <qstringlist.h> class OPackageManager : public QObject { Q_OBJECT public: diff --git a/noncore/settings/packagemanager/opie-packagemanager.control b/noncore/settings/packagemanager/opie-packagemanager.control index aff8866..09bb18b 100644 --- a/noncore/settings/packagemanager/opie-packagemanager.control +++ b/noncore/settings/packagemanager/opie-packagemanager.control @@ -4,7 +4,7 @@ Priority: optional Section: opie/settings Depends: task-opie-minimal, libopiecore2, libopieui2, libipkg Replaces: packagemanager Architecture: arm Maintainer: Dan Williams (drw@handhelds.org) Description: Opie package management client -Version: 0.3.0$EXTRAVERSION +Version: 0.4.0$EXTRAVERSION diff --git a/noncore/settings/packagemanager/packageinfodlg.cpp b/noncore/settings/packagemanager/packageinfodlg.cpp index 73d3de7..d27eacb 100644 --- a/noncore/settings/packagemanager/packageinfodlg.cpp +++ b/noncore/settings/packagemanager/packageinfodlg.cpp @@ -28,36 +28,37 @@ */ #include "packageinfodlg.h" #include "opackage.h" #include "opackagemanager.h" -#include <qlayout.h> -#include <qpushbutton.h> +#include <opie2/otabwidget.h> #include <qpe/resource.h> -#include <opie2/otabwidget.h> +#include <qlayout.h> +#include <qpushbutton.h> +#include <qwhatsthis.h> -using namespace Opie::Ui; PackageInfoDlg::PackageInfoDlg( QWidget *parent, OPackageManager *pm, const QString &package ) : QWidget( 0x0 ) , m_packman( pm ) , m_information( this ) , m_files( this ) { // Initialize UI if ( parent ) parent->setCaption( package ); QVBoxLayout *layout = new QVBoxLayout( this, 4, 2 ); - OTabWidget *tabWidget = new OTabWidget( this ); + Opie::Ui::OTabWidget *tabWidget = new Opie::Ui::OTabWidget( this ); layout->addWidget( tabWidget ); // Information tab + QWhatsThis::add( &m_information, tr( "This area contains information about the package." ) ); m_information.reparent( tabWidget, QPoint( 0, 0 ) ); m_information.setReadOnly( true ); tabWidget->addTab( &m_information, "UtilsIcon", tr( "Information" ) ); // Retrive package information m_package = m_packman->findPackage( package ); @@ -79,18 +80,20 @@ PackageInfoDlg::PackageInfoDlg( QWidget *parent, OPackageManager *pm, const QStr // Files tab (display only if package is installed) if ( !m_package->versionInstalled().isNull() ) { QWidget *filesWidget = new QWidget( tabWidget ); QVBoxLayout *filesLayout = new QVBoxLayout( filesWidget, 2, 2 ); + QWhatsThis::add( &m_files, tr( "This area contains a list of files contained in this package." ) ); m_files.reparent( filesWidget, QPoint( 0, 0 ) ); m_files.setReadOnly( true ); filesLayout->addWidget( &m_files ); QPushButton *btn = new QPushButton( Resource::loadPixmap( "packagemanager/apply" ), tr( "Retrieve file list" ), filesWidget ); + QWhatsThis::add( btn, tr( "Tap here to retrieve list of files contained in this package." ) ); filesLayout->addWidget( btn ); connect( btn, SIGNAL(clicked()), this, SLOT(slotBtnFileScan()) ); tabWidget->addTab( filesWidget, "binary", tr( "File list" ) ); tabWidget->setCurrentTab( tr( "Information" ) ); diff --git a/noncore/settings/packagemanager/packageinfodlg.h b/noncore/settings/packagemanager/packageinfodlg.h index 7ed9f0a..ec031e1 100644 --- a/noncore/settings/packagemanager/packageinfodlg.h +++ b/noncore/settings/packagemanager/packageinfodlg.h @@ -27,17 +27,17 @@ */ #ifndef PACKAGEINFODLG_H #define PACKAGEINFODLG_H +#include "opackage.h" + #include <qmultilineedit.h> #include <qwidget.h> -#include "opackage.h" - class QPushButton; class OPackage; class OPackageManager; class PackageInfoDlg : public QWidget diff --git a/noncore/settings/packagemanager/promptdlg.cpp b/noncore/settings/packagemanager/promptdlg.cpp index 4e82ba9..841b98e 100644 --- a/noncore/settings/packagemanager/promptdlg.cpp +++ b/noncore/settings/packagemanager/promptdlg.cpp @@ -26,19 +26,19 @@ Boston, MA 02111-1307, USA. */ #include "promptdlg.h" +#include <qpe/qpeapplication.h> + #include <qlabel.h> #include <qlayout.h> #include <qpushbutton.h> #include <qwidgetlist.h> -#include <qpe/qpeapplication.h> - PromptDlg::PromptDlg( const QString &caption, const QString &text, const QString &btn1, const QString &btn2, QWidget *parent ) : QWidget( parent, QString::null, WType_Modal | WType_TopLevel | WStyle_Dialog ) , m_btnClicked( -1 ) { setCaption( caption ); |