author | mickeyl <mickeyl> | 2005-01-15 23:01:55 (UTC) |
---|---|---|
committer | mickeyl <mickeyl> | 2005-01-15 23:01:55 (UTC) |
commit | 490b0398b7e11f1485b902a6d9b99b9152be2492 (patch) (unidiff) | |
tree | 8db1a44b807c5eab120cc23d5450440cd5ea59ca | |
parent | 9cdc5a15a6eaae0ddb782c5bd98210dc462c4621 (diff) | |
download | opie-490b0398b7e11f1485b902a6d9b99b9152be2492.zip opie-490b0398b7e11f1485b902a6d9b99b9152be2492.tar.gz opie-490b0398b7e11f1485b902a6d9b99b9152be2492.tar.bz2 |
remove tmpfs entry which confuses users and show mountpoints. patches courtesy hrw
-rw-r--r-- | noncore/settings/sysinfo/storage.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/noncore/settings/sysinfo/storage.cpp b/noncore/settings/sysinfo/storage.cpp index fc583e3..9f70fc5 100644 --- a/noncore/settings/sysinfo/storage.cpp +++ b/noncore/settings/sysinfo/storage.cpp | |||
@@ -69,32 +69,37 @@ void FileSysInfo::updateMounts() | |||
69 | 69 | ||
70 | if ( rebuildDisks ) | 70 | if ( rebuildDisks ) |
71 | { | 71 | { |
72 | disks.clear(); | 72 | disks.clear(); |
73 | lines.clear(); | 73 | lines.clear(); |
74 | 74 | ||
75 | delete vb; | 75 | delete vb; |
76 | vb = new QVBoxLayout( container/*, n > 3 ? 1 : 5*/ ); | 76 | vb = new QVBoxLayout( container/*, n > 3 ? 1 : 5*/ ); |
77 | 77 | ||
78 | bool frst=TRUE; | 78 | bool frst=TRUE; |
79 | 79 | ||
80 | FileSystem *fs; | 80 | FileSystem *fs; |
81 | for ( QListIterator<FileSystem> it(storage->fileSystems()); it.current(); ++it ) | 81 | for ( QListIterator<FileSystem> it(storage->fileSystems()); it.current(); ++it ) |
82 | { | 82 | { |
83 | fs = it.current(); | 83 | fs = it.current(); |
84 | 84 | ||
85 | if(fs->disk().left(5) == "tmpfs") | ||
86 | { | ||
87 | continue; | ||
88 | } | ||
89 | |||
85 | if ( !frst ) | 90 | if ( !frst ) |
86 | { | 91 | { |
87 | QFrame *f = new QFrame( container ); | 92 | QFrame *f = new QFrame( container ); |
88 | vb->addWidget(f); | 93 | vb->addWidget(f); |
89 | f->setFrameStyle( QFrame::HLine | QFrame::Sunken ); | 94 | f->setFrameStyle( QFrame::HLine | QFrame::Sunken ); |
90 | lines.append(f); | 95 | lines.append(f); |
91 | f->show(); | 96 | f->show(); |
92 | } | 97 | } |
93 | frst = FALSE; | 98 | frst = FALSE; |
94 | 99 | ||
95 | MountInfo *mi = new MountInfo( fs, container ); | 100 | MountInfo *mi = new MountInfo( fs, container ); |
96 | vb->addWidget( mi ); | 101 | vb->addWidget( mi ); |
97 | disks.insert( fs->path(), mi ); | 102 | disks.insert( fs->path(), mi ); |
98 | mi->show(); | 103 | mi->show(); |
99 | QString tempstr = fs->name().left( 2 ); | 104 | QString tempstr = fs->name().left( 2 ); |
100 | if ( tempstr == tr( "CF" ) ) | 105 | if ( tempstr == tr( "CF" ) ) |
@@ -122,33 +127,33 @@ void FileSysInfo::updateMounts() | |||
122 | } | 127 | } |
123 | 128 | ||
124 | void FileSysInfo::disksChanged() | 129 | void FileSysInfo::disksChanged() |
125 | { | 130 | { |
126 | rebuildDisks = TRUE; | 131 | rebuildDisks = TRUE; |
127 | } | 132 | } |
128 | 133 | ||
129 | MountInfo::MountInfo( FileSystem *filesys, QWidget *parent, const char *name ) | 134 | MountInfo::MountInfo( FileSystem *filesys, QWidget *parent, const char *name ) |
130 | : QWidget( parent, name ) | 135 | : QWidget( parent, name ) |
131 | { | 136 | { |
132 | QVBoxLayout *vb = new QVBoxLayout( this, 3 ); | 137 | QVBoxLayout *vb = new QVBoxLayout( this, 3 ); |
133 | 138 | ||
134 | totalSize = new QLabel( this ); | 139 | totalSize = new QLabel( this ); |
135 | vb->addWidget( totalSize ); | 140 | vb->addWidget( totalSize ); |
136 | 141 | ||
137 | fs = filesys; | 142 | fs = filesys; |
138 | title = fs->name(); | 143 | title = fs->name() + "\t (" + fs->path() + ')'; |
139 | 144 | ||
140 | data = new GraphData(); | 145 | data = new GraphData(); |
141 | graph = new BarGraph( this ); | 146 | graph = new BarGraph( this ); |
142 | graph->setFrameStyle( QFrame::Panel | QFrame::Sunken ); | 147 | graph->setFrameStyle( QFrame::Panel | QFrame::Sunken ); |
143 | vb->addWidget( graph, 1 ); | 148 | vb->addWidget( graph, 1 ); |
144 | graph->setData( data ); | 149 | graph->setData( data ); |
145 | 150 | ||
146 | legend = new GraphLegend( this ); | 151 | legend = new GraphLegend( this ); |
147 | legend->setOrientation(Horizontal); | 152 | legend->setOrientation(Horizontal); |
148 | vb->addWidget( legend ); | 153 | vb->addWidget( legend ); |
149 | legend->setData( data ); | 154 | legend->setData( data ); |
150 | 155 | ||
151 | updateData(); | 156 | updateData(); |
152 | } | 157 | } |
153 | 158 | ||
154 | MountInfo::~MountInfo() | 159 | MountInfo::~MountInfo() |