]> cloud.milkyroute.net Git - dolphin.git/blob - src/dolphindetailsview.cpp
SVN_SILENT made messages (.desktop file)
[dolphin.git] / src / dolphindetailsview.cpp
1 /***************************************************************************
2 * Copyright (C) 2006 by Peter Penz *
3 * peter.penz@gmx.at *
4 * *
5 * This program is free software; you can redistribute it and/or modify *
6 * it under the terms of the GNU General Public License as published by *
7 * the Free Software Foundation; either version 2 of the License, or *
8 * (at your option) any later version. *
9 * *
10 * This program is distributed in the hope that it will be useful, *
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
13 * GNU General Public License for more details. *
14 * *
15 * You should have received a copy of the GNU General Public License *
16 * along with this program; if not, write to the *
17 * Free Software Foundation, Inc., *
18 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA *
19 ***************************************************************************/
20
21 #include "dolphindetailsview.h"
22
23 #include "dolphinmodel.h"
24 #include "dolphincontroller.h"
25 #include "dolphinsettings.h"
26 #include "dolphinsortfilterproxymodel.h"
27 #include "draganddrophelper.h"
28 #include "selectionmanager.h"
29 #include "viewproperties.h"
30
31 #include "dolphin_detailsmodesettings.h"
32 #include "dolphin_generalsettings.h"
33
34 #include <kdirmodel.h>
35 #include <klocale.h>
36 #include <kmenu.h>
37
38 #include <QAbstractProxyModel>
39 #include <QAction>
40 #include <QApplication>
41 #include <QHeaderView>
42 #include <QRubberBand>
43 #include <QPainter>
44 #include <QScrollBar>
45
46 DolphinDetailsView::DolphinDetailsView(QWidget* parent, DolphinController* controller) :
47 QTreeView(parent),
48 m_autoResize(true),
49 m_controller(controller),
50 m_font(),
51 m_decorationSize(),
52 m_dragging(false),
53 m_showElasticBand(false),
54 m_elasticBandOrigin(),
55 m_elasticBandDestination()
56 {
57 const DetailsModeSettings* settings = DolphinSettings::instance().detailsModeSettings();
58 Q_ASSERT(settings != 0);
59 Q_ASSERT(controller != 0);
60
61 setAcceptDrops(true);
62 setSortingEnabled(true);
63 setUniformRowHeights(true);
64 setSelectionBehavior(SelectItems);
65 setDragDropMode(QAbstractItemView::DragDrop);
66 setDropIndicatorShown(false);
67 setAlternatingRowColors(true);
68 setRootIsDecorated(settings->expandableFolders());
69 setItemsExpandable(settings->expandableFolders());
70
71 setMouseTracking(true);
72 viewport()->setAttribute(Qt::WA_Hover);
73
74 const ViewProperties props(controller->url());
75 setSortIndicatorSection(props.sorting());
76 setSortIndicatorOrder(props.sortOrder());
77
78 QHeaderView* headerView = header();
79 connect(headerView, SIGNAL(sectionClicked(int)),
80 this, SLOT(synchronizeSortingState(int)));
81 headerView->setContextMenuPolicy(Qt::CustomContextMenu);
82 connect(headerView, SIGNAL(customContextMenuRequested(const QPoint&)),
83 this, SLOT(configureColumns(const QPoint&)));
84 connect(headerView, SIGNAL(sectionResized(int, int, int)),
85 this, SLOT(slotHeaderSectionResized(int, int, int)));
86 connect(headerView, SIGNAL(sectionHandleDoubleClicked(int)),
87 this, SLOT(disableAutoResizing()));
88
89 connect(parent, SIGNAL(sortingChanged(DolphinView::Sorting)),
90 this, SLOT(setSortIndicatorSection(DolphinView::Sorting)));
91 connect(parent, SIGNAL(sortOrderChanged(Qt::SortOrder)),
92 this, SLOT(setSortIndicatorOrder(Qt::SortOrder)));
93
94 // TODO: Connecting to the signal 'activated()' is not possible, as kstyle
95 // does not forward the single vs. doubleclick to it yet (KDE 4.1?). Hence it is
96 // necessary connecting the signal 'singleClick()' or 'doubleClick' and to handle the
97 // RETURN-key in keyPressEvent().
98 if (KGlobalSettings::singleClick()) {
99 connect(this, SIGNAL(clicked(const QModelIndex&)),
100 controller, SLOT(triggerItem(const QModelIndex&)));
101 if (DolphinSettings::instance().generalSettings()->showSelectionToggle()) {
102 SelectionManager* selManager = new SelectionManager(this);
103 connect(selManager, SIGNAL(selectionChanged()),
104 this, SLOT(requestActivation()));
105 connect(m_controller, SIGNAL(urlChanged(const KUrl&)),
106 selManager, SLOT(reset()));
107 }
108 } else {
109 connect(this, SIGNAL(doubleClicked(const QModelIndex&)),
110 controller, SLOT(triggerItem(const QModelIndex&)));
111 }
112 connect(this, SIGNAL(entered(const QModelIndex&)),
113 this, SLOT(slotEntered(const QModelIndex&)));
114 connect(this, SIGNAL(viewportEntered()),
115 controller, SLOT(emitViewportEntered()));
116 connect(controller, SIGNAL(zoomIn()),
117 this, SLOT(zoomIn()));
118 connect(controller, SIGNAL(zoomOut()),
119 this, SLOT(zoomOut()));
120 connect(controller->dolphinView(), SIGNAL(additionalInfoChanged()),
121 this, SLOT(updateColumnVisibility()));
122
123 if (settings->useSystemFont()) {
124 m_font = KGlobalSettings::generalFont();
125 } else {
126 m_font = QFont(settings->fontFamily(),
127 settings->fontSize(),
128 settings->fontWeight(),
129 settings->italicFont());
130 }
131
132 setVerticalScrollMode(QTreeView::ScrollPerPixel);
133 setHorizontalScrollMode(QTreeView::ScrollPerPixel);
134
135 updateDecorationSize();
136
137 setFocus();
138
139 connect(KGlobalSettings::self(), SIGNAL(kdisplayFontChanged()),
140 this, SLOT(updateFont()));
141 }
142
143 DolphinDetailsView::~DolphinDetailsView()
144 {
145 }
146
147 bool DolphinDetailsView::event(QEvent* event)
148 {
149 if (event->type() == QEvent::Polish) {
150 QHeaderView* headerView = header();
151 headerView->setResizeMode(QHeaderView::Interactive);
152 headerView->setMovable(false);
153
154 updateColumnVisibility();
155
156 hideColumn(DolphinModel::Rating);
157 hideColumn(DolphinModel::Tags);
158 } else if (event->type() == QEvent::UpdateRequest) {
159 // a wheel movement will scroll 4 items
160 if (model()->rowCount() > 0) {
161 verticalScrollBar()->setSingleStep((sizeHintForRow(0) / 3) * 4);
162 }
163 }
164
165 return QTreeView::event(event);
166 }
167
168 QStyleOptionViewItem DolphinDetailsView::viewOptions() const
169 {
170 QStyleOptionViewItem viewOptions = QTreeView::viewOptions();
171 viewOptions.font = m_font;
172 viewOptions.showDecorationSelected = true;
173 viewOptions.decorationSize = m_decorationSize;
174 return viewOptions;
175 }
176
177 void DolphinDetailsView::contextMenuEvent(QContextMenuEvent* event)
178 {
179 QTreeView::contextMenuEvent(event);
180 m_controller->triggerContextMenuRequest(event->pos());
181 }
182
183 void DolphinDetailsView::mousePressEvent(QMouseEvent* event)
184 {
185 m_controller->requestActivation();
186
187 QTreeView::mousePressEvent(event);
188
189 const QModelIndex index = indexAt(event->pos());
190 if (!index.isValid() || (index.column() != DolphinModel::Name)) {
191 const Qt::KeyboardModifiers modifier = QApplication::keyboardModifiers();
192 if (!(modifier & Qt::ShiftModifier) && !(modifier & Qt::ControlModifier)) {
193 clearSelection();
194 }
195 }
196
197 if (event->button() == Qt::LeftButton) {
198 m_showElasticBand = true;
199
200 const QPoint pos(contentsPos());
201 m_elasticBandOrigin = event->pos();
202 m_elasticBandOrigin.setX(m_elasticBandOrigin.x() + pos.x());
203 m_elasticBandOrigin.setY(m_elasticBandOrigin.y() + pos.y());
204 m_elasticBandDestination = event->pos();
205 }
206 }
207
208 void DolphinDetailsView::mouseMoveEvent(QMouseEvent* event)
209 {
210 if (m_showElasticBand) {
211 const QPoint mousePos = event->pos();
212 const QModelIndex index = indexAt(mousePos);
213 if (!index.isValid()) {
214 // the destination of the selection rectangle is above the viewport. In this
215 // case QTreeView does no selection at all, which is not the wanted behavior
216 // in Dolphin -> select all items within the elastic band rectangle
217 clearSelection();
218
219 const int nameColumnWidth = header()->sectionSize(DolphinModel::Name);
220 QRect selRect = QRect(m_elasticBandOrigin, m_elasticBandDestination).normalized();
221 const QRect nameColumnsRect(0, 0, nameColumnWidth, viewport()->height());
222 selRect = nameColumnsRect.intersected(selRect);
223
224 setSelection(selRect, QItemSelectionModel::Select);
225 }
226
227 // TODO: enable QTreeView::mouseMoveEvent(event) again, as soon
228 // as the Qt-issue #199631 has been fixed.
229 // QTreeView::mouseMoveEvent(event);
230 QAbstractItemView::mouseMoveEvent(event);
231 updateElasticBand();
232 } else {
233 // TODO: enable QTreeView::mouseMoveEvent(event) again, as soon
234 // as the Qt-issue #199631 has been fixed.
235 // QTreeView::mouseMoveEvent(event);
236 QAbstractItemView::mouseMoveEvent(event);
237 }
238 }
239
240 void DolphinDetailsView::mouseReleaseEvent(QMouseEvent* event)
241 {
242 QTreeView::mouseReleaseEvent(event);
243 if (m_showElasticBand) {
244 updateElasticBand();
245 m_showElasticBand = false;
246 }
247 }
248
249 void DolphinDetailsView::startDrag(Qt::DropActions supportedActions)
250 {
251 DragAndDropHelper::startDrag(this, supportedActions);
252 }
253
254 void DolphinDetailsView::dragEnterEvent(QDragEnterEvent* event)
255 {
256 if (event->mimeData()->hasUrls()) {
257 event->acceptProposedAction();
258 }
259
260 if (m_showElasticBand) {
261 updateElasticBand();
262 m_showElasticBand = false;
263 }
264 m_dragging = true;
265 }
266
267 void DolphinDetailsView::dragLeaveEvent(QDragLeaveEvent* event)
268 {
269 QTreeView::dragLeaveEvent(event);
270
271 // TODO: remove this code when the issue #160611 is solved in Qt 4.4
272 m_dragging = false;
273 setDirtyRegion(m_dropRect);
274 }
275
276 void DolphinDetailsView::dragMoveEvent(QDragMoveEvent* event)
277 {
278 QTreeView::dragMoveEvent(event);
279
280 // TODO: remove this code when the issue #160611 is solved in Qt 4.4
281 setDirtyRegion(m_dropRect);
282 const QModelIndex index = indexAt(event->pos());
283 if (!index.isValid() || (index.column() != DolphinModel::Name)) {
284 m_dragging = false;
285 } else {
286 m_dragging = true;
287 const KFileItem item = m_controller->itemForIndex(index);
288 if (!item.isNull() && item.isDir()) {
289 m_dropRect = visualRect(index);
290 } else {
291 m_dropRect.setSize(QSize()); // set as invalid
292 }
293 setDirtyRegion(m_dropRect);
294 }
295
296 if (event->mimeData()->hasUrls()) {
297 // accept url drops, independently from the destination item
298 event->acceptProposedAction();
299 }
300 }
301
302 void DolphinDetailsView::dropEvent(QDropEvent* event)
303 {
304 const KUrl::List urls = KUrl::List::fromMimeData(event->mimeData());
305 if (!urls.isEmpty()) {
306 event->acceptProposedAction();
307 const QModelIndex index = indexAt(event->pos());
308 KFileItem item;
309 if (index.isValid() && (index.column() == DolphinModel::Name)) {
310 item = m_controller->itemForIndex(index);
311 }
312 m_controller->indicateDroppedUrls(urls,
313 m_controller->url(),
314 item);
315 }
316 QTreeView::dropEvent(event);
317 m_dragging = false;
318 }
319
320 void DolphinDetailsView::paintEvent(QPaintEvent* event)
321 {
322 QTreeView::paintEvent(event);
323 if (m_showElasticBand) {
324 // The following code has been taken from QListView
325 // and adapted to DolphinDetailsView.
326 // (C) 1992-2007 Trolltech ASA
327 QStyleOptionRubberBand opt;
328 opt.initFrom(this);
329 opt.shape = QRubberBand::Rectangle;
330 opt.opaque = false;
331 opt.rect = elasticBandRect();
332
333 QPainter painter(viewport());
334 painter.save();
335 style()->drawControl(QStyle::CE_RubberBand, &opt, &painter);
336 painter.restore();
337 }
338
339 // TODO: remove this code when the issue #160611 is solved in Qt 4.4
340 if (m_dragging) {
341 const QBrush& brush = viewOptions().palette.brush(QPalette::Normal, QPalette::Highlight);
342 DragAndDropHelper::drawHoverIndication(this, m_dropRect, brush);
343 }
344 }
345
346 void DolphinDetailsView::keyPressEvent(QKeyEvent* event)
347 {
348 QTreeView::keyPressEvent(event);
349 m_controller->handleKeyPressEvent(event);
350 }
351
352 void DolphinDetailsView::resizeEvent(QResizeEvent* event)
353 {
354 if (m_autoResize) {
355 resizeColumns();
356 }
357 QTreeView::resizeEvent(event);
358 }
359
360 void DolphinDetailsView::wheelEvent(QWheelEvent* event)
361 {
362 // let Ctrl+wheel events propagate to the DolphinView for icon zooming
363 if (event->modifiers() & Qt::ControlModifier) {
364 event->ignore();
365 return;
366 }
367 QTreeView::wheelEvent(event);
368 }
369
370 void DolphinDetailsView::currentChanged(const QModelIndex& current, const QModelIndex& previous)
371 {
372 QTreeView::currentChanged(current, previous);
373 selectionModel()->select(current, QItemSelectionModel::ClearAndSelect);
374 }
375
376 void DolphinDetailsView::setSortIndicatorSection(DolphinView::Sorting sorting)
377 {
378 QHeaderView* headerView = header();
379 headerView->setSortIndicator(sorting, headerView->sortIndicatorOrder());
380 }
381
382 void DolphinDetailsView::setSortIndicatorOrder(Qt::SortOrder sortOrder)
383 {
384 QHeaderView* headerView = header();
385 headerView->setSortIndicator(headerView->sortIndicatorSection(), sortOrder);
386 }
387
388 void DolphinDetailsView::synchronizeSortingState(int column)
389 {
390 // The sorting has already been changed in QTreeView if this slot is
391 // invoked, but Dolphin is not informed about this.
392 DolphinView::Sorting sorting = DolphinSortFilterProxyModel::sortingForColumn(column);
393 const Qt::SortOrder sortOrder = header()->sortIndicatorOrder();
394 m_controller->indicateSortingChange(sorting);
395 m_controller->indicateSortOrderChange(sortOrder);
396 }
397
398 void DolphinDetailsView::slotEntered(const QModelIndex& index)
399 {
400 const QPoint pos = viewport()->mapFromGlobal(QCursor::pos());
401 const int nameColumnWidth = header()->sectionSize(DolphinModel::Name);
402 if (pos.x() < nameColumnWidth) {
403 m_controller->emitItemEntered(index);
404 }
405 else {
406 m_controller->emitViewportEntered();
407 }
408 }
409
410 void DolphinDetailsView::updateElasticBand()
411 {
412 if (m_showElasticBand) {
413 QRect dirtyRegion(elasticBandRect());
414 m_elasticBandDestination = viewport()->mapFromGlobal(QCursor::pos());
415 dirtyRegion = dirtyRegion.united(elasticBandRect());
416 setDirtyRegion(dirtyRegion);
417 }
418 }
419
420 QRect DolphinDetailsView::elasticBandRect() const
421 {
422 const QPoint pos(contentsPos());
423 const QPoint topLeft(m_elasticBandOrigin.x() - pos.x(), m_elasticBandOrigin.y() - pos.y());
424 return QRect(topLeft, m_elasticBandDestination).normalized();
425 }
426
427 void DolphinDetailsView::zoomIn()
428 {
429 if (isZoomInPossible()) {
430 DetailsModeSettings* settings = DolphinSettings::instance().detailsModeSettings();
431 switch (settings->iconSize()) {
432 case KIconLoader::SizeSmall: settings->setIconSize(KIconLoader::SizeMedium); break;
433 case KIconLoader::SizeMedium: settings->setIconSize(KIconLoader::SizeLarge); break;
434 default: Q_ASSERT(false); break;
435 }
436 updateDecorationSize();
437 }
438 }
439
440 void DolphinDetailsView::zoomOut()
441 {
442 if (isZoomOutPossible()) {
443 DetailsModeSettings* settings = DolphinSettings::instance().detailsModeSettings();
444 switch (settings->iconSize()) {
445 case KIconLoader::SizeLarge: settings->setIconSize(KIconLoader::SizeMedium); break;
446 case KIconLoader::SizeMedium: settings->setIconSize(KIconLoader::SizeSmall); break;
447 default: Q_ASSERT(false); break;
448 }
449 updateDecorationSize();
450 }
451 }
452
453 void DolphinDetailsView::configureColumns(const QPoint& pos)
454 {
455 KMenu popup(this);
456 popup.addTitle(i18nc("@title:menu", "Columns"));
457
458 QHeaderView* headerView = header();
459 for (int i = DolphinModel::Size; i <= DolphinModel::Type; ++i) {
460 const int logicalIndex = headerView->logicalIndex(i);
461 const QString text = model()->headerData(i, Qt::Horizontal).toString();
462 QAction* action = popup.addAction(text);
463 action->setCheckable(true);
464 action->setChecked(!headerView->isSectionHidden(logicalIndex));
465 action->setData(i);
466 }
467
468 QAction* activatedAction = popup.exec(header()->mapToGlobal(pos));
469 if (activatedAction != 0) {
470 const bool show = activatedAction->isChecked();
471 const int columnIndex = activatedAction->data().toInt();
472
473 KFileItemDelegate::InformationList list = m_controller->dolphinView()->additionalInfo();
474 const KFileItemDelegate::Information info = infoForColumn(columnIndex);
475 if (show) {
476 Q_ASSERT(!list.contains(info));
477 list.append(info);
478 } else {
479 Q_ASSERT(list.contains(info));
480 const int index = list.indexOf(info);
481 list.removeAt(index);
482 }
483
484 m_controller->indicateAdditionalInfoChange(list);
485 setColumnHidden(columnIndex, !show);
486 }
487 }
488
489 void DolphinDetailsView::updateColumnVisibility()
490 {
491 const KFileItemDelegate::InformationList list = m_controller->dolphinView()->additionalInfo();
492 for (int i = DolphinModel::Size; i <= DolphinModel::Type; ++i) {
493 const KFileItemDelegate::Information info = infoForColumn(i);
494 const bool hide = !list.contains(info);
495 if (isColumnHidden(i) != hide) {
496 setColumnHidden(i, hide);
497 }
498 }
499
500 resizeColumns();
501 }
502
503 void DolphinDetailsView::slotHeaderSectionResized(int logicalIndex, int oldSize, int newSize)
504 {
505 Q_UNUSED(logicalIndex);
506 Q_UNUSED(oldSize);
507 Q_UNUSED(newSize);
508 if (QApplication::mouseButtons() & Qt::LeftButton) {
509 disableAutoResizing();
510 }
511 }
512
513 void DolphinDetailsView::disableAutoResizing()
514 {
515 m_autoResize = false;
516 }
517
518 void DolphinDetailsView::requestActivation()
519 {
520 m_controller->requestActivation();
521 }
522
523 void DolphinDetailsView::updateFont()
524 {
525 const DetailsModeSettings* settings = DolphinSettings::instance().detailsModeSettings();
526 Q_ASSERT(settings != 0);
527
528 if (settings->useSystemFont()) {
529 m_font = KGlobalSettings::generalFont();
530 }
531 }
532
533 bool DolphinDetailsView::isZoomInPossible() const
534 {
535 DetailsModeSettings* settings = DolphinSettings::instance().detailsModeSettings();
536 return settings->iconSize() < KIconLoader::SizeLarge;
537 }
538
539 bool DolphinDetailsView::isZoomOutPossible() const
540 {
541 DetailsModeSettings* settings = DolphinSettings::instance().detailsModeSettings();
542 return settings->iconSize() > KIconLoader::SizeSmall;
543 }
544
545 void DolphinDetailsView::updateDecorationSize()
546 {
547 DetailsModeSettings* settings = DolphinSettings::instance().detailsModeSettings();
548 const int iconSize = settings->iconSize();
549 setIconSize(QSize(iconSize, iconSize));
550 m_decorationSize = QSize(iconSize, iconSize);
551
552 m_controller->setZoomInPossible(isZoomInPossible());
553 m_controller->setZoomOutPossible(isZoomOutPossible());
554
555 doItemsLayout();
556 }
557
558 QPoint DolphinDetailsView::contentsPos() const
559 {
560 // implementation note: the horizonal position is ignored currently, as no
561 // horizontal scrolling is done anyway during a selection
562 const QScrollBar* scrollbar = verticalScrollBar();
563 Q_ASSERT(scrollbar != 0);
564
565 const int maxHeight = maximumViewportSize().height();
566 const int height = scrollbar->maximum() - scrollbar->minimum() + 1;
567 const int visibleHeight = model()->rowCount() + 1 - height;
568 if (visibleHeight <= 0) {
569 return QPoint(0, 0);
570 }
571
572 const int y = scrollbar->sliderPosition() * maxHeight / visibleHeight;
573 return QPoint(0, y);
574 }
575
576 KFileItemDelegate::Information DolphinDetailsView::infoForColumn(int columnIndex) const
577 {
578 KFileItemDelegate::Information info = KFileItemDelegate::NoInformation;
579
580 switch (columnIndex) {
581 case DolphinModel::Size: info = KFileItemDelegate::Size; break;
582 case DolphinModel::ModifiedTime: info = KFileItemDelegate::ModificationTime; break;
583 case DolphinModel::Permissions: info = KFileItemDelegate::Permissions; break;
584 case DolphinModel::Owner: info = KFileItemDelegate::Owner; break;
585 case DolphinModel::Group: info = KFileItemDelegate::OwnerAndGroup; break;
586 case DolphinModel::Type: info = KFileItemDelegate::FriendlyMimeType; break;
587 default: break;
588 }
589
590 return info;
591 }
592
593 void DolphinDetailsView::resizeColumns()
594 {
595 // Using the resize mode QHeaderView::ResizeToContents is too slow (it takes
596 // around 3 seconds for each (!) resize operation when having > 10000 items).
597 // This gets a problem especially when opening large directories, where several
598 // resize operations are received for showing the currently available items during
599 // loading (the application hangs around 20 seconds when loading > 10000 items).
600
601 QHeaderView* headerView = header();
602 QFontMetrics fontMetrics(viewport()->font());
603
604 int columnWidth[KDirModel::ColumnCount];
605 columnWidth[KDirModel::Size] = fontMetrics.width("00000 Items");
606 columnWidth[KDirModel::ModifiedTime] = fontMetrics.width("0000-00-00 00:00");
607 columnWidth[KDirModel::Permissions] = fontMetrics.width("xxxxxxxxxx");
608 columnWidth[KDirModel::Owner] = fontMetrics.width("xxxxxxxxxx");
609 columnWidth[KDirModel::Group] = fontMetrics.width("xxxxxxxxxx");
610 columnWidth[KDirModel::Type] = fontMetrics.width("XXXX Xxxxxxx");
611
612 int requiredWidth = 0;
613 for (int i = KDirModel::Size; i <= KDirModel::Type; ++i) {
614 if (!isColumnHidden(i)) {
615 columnWidth[i] += 20; // provide a default gap
616 requiredWidth += columnWidth[i];
617 headerView->resizeSection(i, columnWidth[i]);
618 }
619 }
620
621 // resize the name column in a way that the whole available width is used
622 columnWidth[KDirModel::Name] = viewport()->width() - requiredWidth;
623 if (columnWidth[KDirModel::Name] < 120) {
624 columnWidth[KDirModel::Name] = 120;
625 }
626 headerView->resizeSection(KDirModel::Name, columnWidth[KDirModel::Name]);
627 }
628
629 #include "dolphindetailsview.moc"