author | kergoth <kergoth> | 2003-08-09 16:12:19 (UTC) |
---|---|---|
committer | kergoth <kergoth> | 2003-08-09 16:12:19 (UTC) |
commit | 1c58d1407f9584fedcdae390a04e2b37e5853361 (patch) (unidiff) | |
tree | 3c6e741c4d382d1a53c182930052b684d6e35b91 /noncore/settings/aqpkg/packagewin.cpp | |
parent | e3f4607edd0c1ca1434adb446df1d4a1d27c6a86 (diff) | |
download | opie-1c58d1407f9584fedcdae390a04e2b37e5853361.zip opie-1c58d1407f9584fedcdae390a04e2b37e5853361.tar.gz opie-1c58d1407f9584fedcdae390a04e2b37e5853361.tar.bz2 |
Merge from BRANCH_1_0
Diffstat (limited to 'noncore/settings/aqpkg/packagewin.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/settings/aqpkg/packagewin.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/noncore/settings/aqpkg/packagewin.cpp b/noncore/settings/aqpkg/packagewin.cpp index 9553cd1..499d647 100644 --- a/noncore/settings/aqpkg/packagewin.cpp +++ b/noncore/settings/aqpkg/packagewin.cpp | |||
@@ -35,29 +35,30 @@ | |||
35 | 35 | ||
36 | #include <qlayout.h> | 36 | #include <qlayout.h> |
37 | #include <qpushbutton.h> | 37 | #include <qpushbutton.h> |
38 | #include <qstring.h> | 38 | #include <qstring.h> |
39 | #include <qtextview.h> | 39 | #include <qtextview.h> |
40 | 40 | ||
41 | PackageWindow::PackageWindow( Package *package, const QString &server ) | 41 | PackageWindow::PackageWindow( Package *package, const QString &server ) |
42 | : QWidget( 0, 0, 0 ) | 42 | : QWidget( 0, 0, 0 ) |
43 | { | 43 | { |
44 | QString str; | 44 | QString str; |
45 | if ( package ) | 45 | if ( package ) |
46 | { | 46 | { |
47 | Package *local = package->getLocalPackage(); | ||
47 | setCaption( package->getPackageName() ); | 48 | setCaption( package->getPackageName() ); |
48 | QString destName; | 49 | QString destName; |
49 | if ( package->getLocalPackage() ) | 50 | if ( local ) |
50 | { | 51 | { |
51 | if ( package->getLocalPackage()->getInstalledTo() ) | 52 | if ( local->getInstalledTo() ) |
52 | destName = package->getLocalPackage()->getInstalledTo()->getDestinationName(); | 53 | destName = package->getLocalPackage()->getInstalledTo()->getDestinationName(); |
53 | } | 54 | } |
54 | else | 55 | else |
55 | { | 56 | { |
56 | if ( package->getInstalledTo() ) | 57 | if ( package->getInstalledTo() ) |
57 | destName = package->getInstalledTo()->getDestinationName(); | 58 | destName = package->getInstalledTo()->getDestinationName(); |
58 | } | 59 | } |
59 | 60 | ||
60 | if ( !package->isPackageStoredLocally() ) | 61 | if ( !package->isPackageStoredLocally() ) |
61 | { | 62 | { |
62 | str.append( tr( "<b>Description</b> - " ) ); | 63 | str.append( tr( "<b>Description</b> - " ) ); |
63 | str.append( package->getDescription() ); | 64 | str.append( package->getDescription() ); |
@@ -77,25 +78,25 @@ PackageWindow::PackageWindow( Package *package, const QString &server ) | |||
77 | str.append( package->getFilename() ); | 78 | str.append( package->getFilename() ); |
78 | } | 79 | } |
79 | 80 | ||
80 | if ( server == LOCAL_SERVER ) | 81 | if ( server == LOCAL_SERVER ) |
81 | { | 82 | { |
82 | str.append( tr( "<p><b>Version Installed</b> - " ) ); | 83 | str.append( tr( "<p><b>Version Installed</b> - " ) ); |
83 | str.append( package->getVersion() ); | 84 | str.append( package->getVersion() ); |
84 | } | 85 | } |
85 | else | 86 | else |
86 | { | 87 | { |
87 | str.append( tr( "<p><b>Version Available</b> - " ) ); | 88 | str.append( tr( "<p><b>Version Available</b> - " ) ); |
88 | str.append( package->getVersion() ); | 89 | str.append( package->getVersion() ); |
89 | if ( package->getLocalPackage() ) | 90 | if ( local ) |
90 | { | 91 | { |
91 | if ( package->isInstalled() ) | 92 | if ( package->isInstalled() ) |
92 | { | 93 | { |
93 | str.append( tr( "<p><b>Version Installed</b> - " ) ); | 94 | str.append( tr( "<p><b>Version Installed</b> - " ) ); |
94 | str.append( package->getInstalledVersion() ); | 95 | str.append( package->getInstalledVersion() ); |
95 | } | 96 | } |
96 | } | 97 | } |
97 | } | 98 | } |
98 | } | 99 | } |
99 | else | 100 | else |
100 | { | 101 | { |
101 | setCaption( tr( "Package Information" ) ); | 102 | setCaption( tr( "Package Information" ) ); |