]> cloud.milkyroute.net Git - dolphin.git/log
dolphin.git
14 years agoEnable "menu key" functionality
Peter Penz [Wed, 7 Dec 2011 22:04:09 +0000 (23:04 +0100)]
Enable "menu key" functionality

Bring back the functionality that a context-menu is opened if the "menu key" has been pressed. In opposite to Dolphin 1.7 the context-menu is shown above the selected item and not on the (probably unrelated) mouse position.

A new method KItemListView::itemContextRect() has been introduced: The method is now also used as reference for tooltips which fixes the issue that tooltips had a wrong horizontal alignment in the details-view.

BUG: 288366
FIXED-IN: 4.8.0

14 years agoPrevent unwanted item animations
Peter Penz [Wed, 7 Dec 2011 20:55:55 +0000 (21:55 +0100)]
Prevent unwanted item animations

When splitting the view or opening a new tab there should not be
any animation of the items due to a wrong initial viewport size.

14 years agoFix issue of unknown icon-types
Peter Penz [Wed, 7 Dec 2011 17:35:30 +0000 (18:35 +0100)]
Fix issue of unknown icon-types

If the split-view is used and/or the Folders Panel is activated
it might happen that the "unknown"-icon of an item is shown instead
of the correct icon. The root-cause is that one model might already
have been resolved the MIME-type of a KFileItem while the other
model has not updated the icon yet. As KFileItems are shared the
check whether the MIME-type has been resolved is wrong. As at that
stage it is assured anyhow that the MIME-type is known just
applying the icon-name in any case won't slow down the performance.

14 years agoFix icon boundaries issue
Peter Penz [Wed, 7 Dec 2011 14:30:55 +0000 (15:30 +0100)]
Fix icon boundaries issue

The size of the icon boundaries should be as minimal as possible.
The patch for fixing the zooming-issues with the selection resulted
into a minor regression where the icon boundaries might be too large.
This patch remembers the original size of the pixmap to be able
to scale m_iconRect.

14 years agoSVN_SILENT made messages (.desktop file)
Script Kiddy [Wed, 7 Dec 2011 08:21:22 +0000 (09:21 +0100)]
SVN_SILENT made messages (.desktop file)

14 years agoUse scaled size for KFileItemListWidget::iconRect()
Peter Penz [Tue, 6 Dec 2011 20:35:20 +0000 (21:35 +0100)]
Use scaled size for KFileItemListWidget::iconRect()

This prevents temporary selection rectangle issues when zooming
the icon sizes.

BUG: 287542
FIXED-IN: 4.8.0

14 years agoVersion control: Don't tint unversioned files
Peter Penz [Tue, 6 Dec 2011 20:24:44 +0000 (21:24 +0100)]
Version control: Don't tint unversioned files

BUG: 287742
FIXED-IN: 4.8.0

14 years agoSelection and current item fixes
Peter Penz [Tue, 6 Dec 2011 20:15:36 +0000 (21:15 +0100)]
Selection and current item fixes

- Remember selection + current item when switching view-modes
- Fix the current item indicator alignment for selections
- Set the item as current item when the selection toggle has
  been clicked

14 years agoDon't animate when switching view-modes
Peter Penz [Tue, 6 Dec 2011 18:46:31 +0000 (19:46 +0100)]
Don't animate when switching view-modes

Currently when switching the view-modes an animation of the items
is done, where the position and size is adjusted for the new
view-mode.

Although this might look nice initially I'd consider this as a
kind of animation that is distracting and hence it has been
turned off.

14 years agoFix possible crash in SearchPanel::urlChanged()
Peter Penz [Tue, 6 Dec 2011 18:28:39 +0000 (19:28 +0100)]
Fix possible crash in SearchPanel::urlChanged()

m_lastSetUrlStatJob gets a dangling pointer if we don't have a
Nepomuk URL.

Thanks to Frank Reininghaus for the analysis and the hint!

BUG: 287075
FIXED-IN: 4.8.0

14 years agoFolders Panel cleanups
Peter Penz [Tue, 6 Dec 2011 18:20:48 +0000 (19:20 +0100)]
Folders Panel cleanups

- Reactivate dropping of URLs
- Remove unused/obsolete code
- Simplify DragAndDropHelper interface

14 years agoFix selection issue for Information Panel
Peter Penz [Tue, 6 Dec 2011 17:49:12 +0000 (18:49 +0100)]
Fix selection issue for Information Panel

When the selection changes during the Information Panel is
invisible, it still should get applied so that when making the
Information Panel visible again a valid selection is shown.

Thanks to A. Janardhan Reddy for the patch!

(Additionally the obsolete check for an empty selection has
been removed, as this cannot happen anymore with the new view
engine)

BUG: 281452
FIXED-IN: 4.8.0

14 years agoReactivate drop-above-places-panel functionality
Peter Penz [Tue, 6 Dec 2011 15:28:04 +0000 (16:28 +0100)]
Reactivate drop-above-places-panel functionality

Dropping items into the Places panel has been temporary deactivated because
of switching to the new view-engine -> reactivate it again

BUG: 204359
FIXED-IN: 4.8.0

14 years agoFix calculation of maximum scroll offset
Peter Penz [Mon, 5 Dec 2011 18:56:41 +0000 (19:56 +0100)]
Fix calculation of maximum scroll offset

The maximum scroll offset must be the maximum y-range of the last
row, not only the maximum of the last item.

Thanks to Frank Reininghaus for analysing the root-cause and
for providing the initial patch!

BUG: 287211
FIXED-IN: 4.8.0

14 years agoUpdate the view if an item is renamed
Frank Reininghaus [Sun, 4 Dec 2011 18:33:56 +0000 (19:33 +0100)]
Update the view if an item is renamed

14 years agoFix crash #2 when filtering items
Peter Penz [Sun, 4 Dec 2011 19:45:54 +0000 (20:45 +0100)]
Fix crash #2 when filtering items

When KFileItems get removed from the model it is temporary possible
that the pending items are still part of the KFileItemModelRolesUpdater
while they have already been removed from the model (this happens
in the context during the signal itemsRemoved() gets emitted).

BUG: 287642

14 years agoFix crash #1 when filtering items
Peter Penz [Sun, 4 Dec 2011 17:16:39 +0000 (18:16 +0100)]
Fix crash #1 when filtering items

When filtering items it was possible that the current index got
an invalid value which resulted in accessing the URL of a
null-KFileItem.

There is still one (general) open issue in KFileItemModelRolesUpdater
(crash #2) where a KFileItem that is already null gets read.
It is not really related to filtering but can be triggered
quite easy when filtering huge directories with enabled previews.

CCBUG: 287642

14 years agoMake sure that enabling previews triggers the generation of previews
Frank Reininghaus [Sun, 4 Dec 2011 13:41:30 +0000 (14:41 +0100)]
Make sure that enabling previews triggers the generation of previews

Before this commit, no previews were generated if the icon size was the
same with and without previews.

14 years agoUpdate the zoom slider if the previews setting is changed
Frank Reininghaus [Sun, 4 Dec 2011 13:10:20 +0000 (14:10 +0100)]
Update the zoom slider if the previews setting is changed

This is important if the zoom levels are different with previews
enabled/disabled.

14 years agoClear the selection in MousePressEvent() rather than MouseReleaseEvent()
Frank Reininghaus [Sun, 4 Dec 2011 12:37:51 +0000 (13:37 +0100)]
Clear the selection in MousePressEvent() rather than MouseReleaseEvent()

This fixes the problem that clicking an unselected item in order to drag
it would result in dragging all previously selected items as well. With
this commit, previously selected items are unselected when a new item is
clicked.

The reason why clearing the selection was moved to MouseReleaseEvent()
in commit b583dd6d4d3a03e3af2ec8d370132b84935ff871 was that clicking one
of several selected items should not result in unselecting the other
items (to make sure that dragging multiple items is possible). However,
this can also be assured by just checking in MousePressEvent() if the
clicked item has been selected already and not clearing the previous
selection in that case. This applies equally to the case that a context
menu is requested when several items are selected.

14 years agoavoid double margins
Ni Hui [Sun, 4 Dec 2011 10:17:58 +0000 (18:17 +0800)]
avoid double margins

14 years agoUpdate the current item during rubber band selections
Frank Reininghaus [Sat, 3 Dec 2011 17:09:34 +0000 (18:09 +0100)]
Update the current item during rubber band selections

14 years agoSVN_SILENT made messages (.desktop file)
Script Kiddy [Sat, 3 Dec 2011 08:31:16 +0000 (09:31 +0100)]
SVN_SILENT made messages (.desktop file)

14 years agoSVN_SILENT made messages (.desktop file)
Script Kiddy [Fri, 2 Dec 2011 08:58:31 +0000 (09:58 +0100)]
SVN_SILENT made messages (.desktop file)

14 years agoReimplement name-filtering
Peter Penz [Tue, 29 Nov 2011 23:18:22 +0000 (00:18 +0100)]
Reimplement name-filtering

The filtering of items has not been implemented yet in
the KFileItemModel of the new view-engine. The patch brings back
this functionality again, but some minor issues are open:
- When filtering trees expanded directories should only get
  hidden if no child is visible
- Regular expressions are not supported yet (they have not been
  supported in Dolphin 1.x but it is now quite simple to implement).
- When filtering previews and removing the filter it might be
  possible that the preview is not shown (is most probably an
  an already existing bug in KFileItemModelRolesUpdater).

BUG: 287642
FIXED-IN: 4.8.0

14 years agoReactivate the "Open folders during drag operations" feature
Peter Penz [Tue, 29 Nov 2011 21:01:16 +0000 (22:01 +0100)]
Reactivate the "Open folders during drag operations" feature

The feature got temporary lost due to the port to the new view
engine.

14 years agoSVN_SILENT made messages (.desktop file)
Script Kiddy [Tue, 29 Nov 2011 15:47:26 +0000 (16:47 +0100)]
SVN_SILENT made messages (.desktop file)

14 years agonepomuk config option change strigiservice -> fileindexer
Weng Xuetian [Sun, 27 Nov 2011 16:19:15 +0000 (00:19 +0800)]
nepomuk config option change strigiservice -> fileindexer

14 years agoApply icon effect for cut items
Peter Penz [Sat, 26 Nov 2011 23:27:59 +0000 (00:27 +0100)]
Apply icon effect for cut items

Fix issue that no icon effect got applied to icons that have
been cut.

14 years agoFolders Panel fixes
Peter Penz [Sat, 26 Nov 2011 00:05:58 +0000 (01:05 +0100)]
Folders Panel fixes

The following functionality from Dolphin 1.x has
been ported to the new view-engine:
- Allow expanding/collapsing of items
- Automatically select the current item
- Context menu for items

Related improvements to the view-engine:
- Make the expanding/collapsing interface already accessible
  in the base classes KItemModelBase and KItemListView. If
  no expanding/collapsing is supported at all by derived models
  (which is usually the default case) simply not reimplementing
  those 3 methods is sufficient and it does not introduce an
  additional complexity like in QAbstractItemModel/QModelIndex.

- Automatically handle the expanding/collapsing in KItemListController.
  This also includes the key-handling, which is quite special for
  expandable items.

- Don't let KItemListView automatically scroll to the current item
  if the current item got changed. The automatic scrolling should
  only be done if the current item has been changed by the user.
  Hence this functionality has been moved to the KItemListController
  which currently only triggers the automatic scrolling if the current
  item has been changed by the keyboard (we might extend the usecases
  later if required).

14 years agoUse correct selection color for inactive windows
Peter Penz [Fri, 25 Nov 2011 20:32:34 +0000 (21:32 +0100)]
Use correct selection color for inactive windows

14 years agoUse KFileItem::text() instead of KFileItem::name().
Sebastian Trueg [Fri, 25 Nov 2011 15:02:49 +0000 (16:02 +0100)]
Use KFileItem::text() instead of KFileItem::name().

This way Nepomuk search results get their proper user readable names.
BUG: 287472
REVIEW: 103237

14 years agoFix restoring expanded URLs
Frank Reininghaus [Thu, 24 Nov 2011 22:38:36 +0000 (23:38 +0100)]
Fix restoring expanded URLs

When navigating back or forward in history, DolphinView tells the
KFileItemModel about the expanded URLs which should be restored before
the folder is entered. In this case, the algorithm in the new function
KFileItemModel::setExpanded(const QSet<KUrl>&) does not work. To fix
this, the old function
KFileItemModel::restoreExpandedUrls(const QSet<KUrl>&) is restored.

Unit test included.

14 years agoSVN_SILENT made messages (.desktop file)
Script Kiddy [Wed, 23 Nov 2011 08:18:21 +0000 (09:18 +0100)]
SVN_SILENT made messages (.desktop file)

14 years agoDon't try to divide by zero.
Frank Reininghaus [Mon, 21 Nov 2011 23:52:28 +0000 (00:52 +0100)]
Don't try to divide by zero.

Fixes a crash in Dolphin when pressing a key so quickly after a url
change that there are no items in the file item model yet.

BUG:287147

14 years agoFix shortcut issue with panels
Peter Penz [Mon, 21 Nov 2011 10:04:45 +0000 (11:04 +0100)]
Fix shortcut issue with panels

The KAction instance of the panels is added to the menu instance
now instead of the QDock-actions. It is assured that the state
between the actions gets synchronized. Now it's possible for
the user to apply custom shortcuts and the shortcuts are also
shown in the menu as expected.

CCMAIL: lueck@hube-lueck.de

14 years agocolumns view was removed, new compact view
Burkhard Lück [Mon, 21 Nov 2011 09:14:50 +0000 (10:14 +0100)]
columns view was removed, new compact view

14 years agoDon't crash when closing Dolphin if the Folders Panel is hidden
Frank Reininghaus [Sun, 20 Nov 2011 22:26:41 +0000 (23:26 +0100)]
Don't crash when closing Dolphin if the Folders Panel is hidden

14 years agoShow panel shortcuts in menu
Peter Penz [Sun, 20 Nov 2011 19:03:22 +0000 (20:03 +0100)]
Show panel shortcuts in menu

14 years agoInitial draft for bringing back the "Folders" panel
Peter Penz [Sun, 20 Nov 2011 18:32:52 +0000 (19:32 +0100)]
Initial draft for bringing back the "Folders" panel

The folders panel has been adjusted to use the new view-engine.
A lot of things don't work yet, but are mostly minor issues that
should be fixable during the next 10 days.

14 years agoSVN_SILENT made messages (.desktop file)
Script Kiddy [Sat, 19 Nov 2011 09:09:17 +0000 (10:09 +0100)]
SVN_SILENT made messages (.desktop file)

14 years agoSimplify creation of drag-pixmap
Peter Penz [Sat, 19 Nov 2011 07:09:09 +0000 (08:09 +0100)]
Simplify creation of drag-pixmap

14 years agoImprove dragging pixmap
Peter Penz [Sat, 19 Nov 2011 06:34:34 +0000 (07:34 +0100)]
Improve dragging pixmap

When dragging multiple files, those files should be shown as part
of the dragging pixmap like in Dolphin 1.7.

BUG: 285031
FIXED-IN: 4.8.0

14 years agoRemove "Rename inline" option
Peter Penz [Sat, 19 Nov 2011 06:04:56 +0000 (07:04 +0100)]
Remove "Rename inline" option

The new view-engine currently does not support inline-renaming
and because of more important pending issues this cannot be
implemented for the 4.8 release of KDE applications.

The plan for 4.9 is to implement inline-renaming again and
to make it "so good" (tm) that it is always turned on (-> there is
no need anymore for an option to disable it ;-)

CCBUG: 286893

14 years agoFix crash when toggling the menu-bar visibility
Peter Penz [Sat, 19 Nov 2011 05:49:32 +0000 (06:49 +0100)]
Fix crash when toggling the menu-bar visibility

Use a queued connection to prevent that the menu
gets hidden during it is still open. Thanks to
Christoph Feck for the hint!

Frank and I could not reproduce the issue in our
environments even when following the steps from
bug 278366, however Christoph's hint sounds sane
and let's hope it works (leaves a bad gut feeling
to "fix" bugs without being able to verify them).

CCBUG: 286822
CCBUG: 278366
FIXED-IN: 4.7.4

14 years agoApply the selected-state to the current item
Peter Penz [Fri, 18 Nov 2011 21:52:07 +0000 (22:52 +0100)]
Apply the selected-state to the current item

This assures that (with the default colors) the indication
of the current item is done in white instead of black.

14 years agoFix wrong position of selection-toggle
Peter Penz [Fri, 18 Nov 2011 21:04:26 +0000 (22:04 +0100)]
Fix wrong position of selection-toggle

When switching between view-modes the selection-toggle sometimes
had a wrong position.

14 years agoFix colors for the selection/hover-area
Peter Penz [Fri, 18 Nov 2011 19:51:47 +0000 (20:51 +0100)]
Fix colors for the selection/hover-area

Thanks to Hugo Pereira Da Costa for pointing this out and
the initial patch!

CCMAIL: hugo@oxygen-icons.org

14 years agoSVN_SILENT made messages (.desktop file)
Script Kiddy [Mon, 14 Nov 2011 08:28:37 +0000 (09:28 +0100)]
SVN_SILENT made messages (.desktop file)

14 years agoFix selection style issues
Peter Penz [Sun, 13 Nov 2011 19:55:51 +0000 (20:55 +0100)]
Fix selection style issues

Don't use a custom drawing code for showing the hover-indication
or selection of the text.
- The default style for items is used.
- Merge icon-rectangle and text-rectangle if possible.
- Fix background and minor focus-issues

14 years agoBring back the selection-markers
Peter Penz [Sun, 13 Nov 2011 15:20:42 +0000 (16:20 +0100)]
Bring back the selection-markers

Still some finetuning is necessary, but lets first bring
back the missing features from Dolphin 1.x to 2.0 before starting
with this.

14 years agoSVN_SILENT made messages (.desktop file)
Script Kiddy [Sun, 13 Nov 2011 07:35:08 +0000 (08:35 +0100)]
SVN_SILENT made messages (.desktop file)

14 years agoSVN_SILENT made messages (.desktop file)
Script Kiddy [Sat, 12 Nov 2011 09:27:10 +0000 (10:27 +0100)]
SVN_SILENT made messages (.desktop file)

14 years agoSVN_SILENT made messages (.desktop file)
Script Kiddy [Thu, 10 Nov 2011 08:44:57 +0000 (09:44 +0100)]
SVN_SILENT made messages (.desktop file)

14 years agoSVN_SILENT made messages (.desktop file)
Script Kiddy [Tue, 8 Nov 2011 14:36:30 +0000 (15:36 +0100)]
SVN_SILENT made messages (.desktop file)

14 years agoFix expansion-level issue
Peter Penz [Sun, 6 Nov 2011 22:09:46 +0000 (23:09 +0100)]
Fix expansion-level issue

When the details-view has been used on / a wrong expansion-level
has been calculated and hence no expansion-toggles have been
visible.

14 years agoShow compact-mode icon also in Konqueror
Peter Penz [Sun, 6 Nov 2011 11:12:35 +0000 (12:12 +0100)]
Show compact-mode icon also in Konqueror

Additionally a broken signal-connection has been fixed.

14 years agoDelete obsolete class DolphinSettings
Peter Penz [Sun, 6 Nov 2011 10:58:48 +0000 (11:58 +0100)]
Delete obsolete class DolphinSettings

14 years agoFix issues with applying wrong view-mode
Peter Penz [Sun, 6 Nov 2011 08:53:03 +0000 (09:53 +0100)]
Fix issues with applying wrong view-mode

- The view properties dialog mixed the details-view with
  the compact-view (#285848).

- The view properties have been reset when applying a
  setting from the "Dolphin Preferences" dialog. The rootcause
  was that the obsolete DolphinSettings class implemented
  the saving in a wrong way because of the recent refactoring
  (will remove this class completely now to prevent such
  issues in future).

BUG: 285848
FIXED-IN: 4.8.0

14 years agoAdd Frank Reininghaus and Sebastian Trüg to the About-dialog
Peter Penz [Sat, 5 Nov 2011 14:16:25 +0000 (15:16 +0100)]
Add Frank Reininghaus and Sebastian Trüg to the About-dialog

14 years agoFix layout-issues when sorting by roles that are changed
Peter Penz [Fri, 4 Nov 2011 22:31:11 +0000 (23:31 +0100)]
Fix layout-issues when sorting by roles that are changed

When sorting is enabled for a role that gets changed e.g. because
a value like the MIME-type is determined asynchronously, then the
layout might get messed up.

slotItemsMoved() has been adjusted to invalidate the sizehint-cache
and to update the group-headers.

BUG: 285542
FIXED-IN: 4.8.0

14 years agoDon't use mixed units in size-column of details-view
Peter Penz [Fri, 4 Nov 2011 20:54:01 +0000 (21:54 +0100)]
Don't use mixed units in size-column of details-view

This makes it tricky to compare the filesizes without adjusting
the sort-order, so now all sizes in the size-column are shown
in KiB or KB (dependent on the KLocale setting).

BUG: 219932
FIXED-IN: 4.8.0

Related fixes:
- Stay consistent with the rounding when using the KiB/KB unit
  in the statusbar.
- Fix sorting-by-size issue for folders
- Show "Unknown" in the size-column when the number of items
  cannot be determined.

14 years agoInternal KFileItemModel optimizations and cleanups
Peter Penz [Mon, 31 Oct 2011 18:32:31 +0000 (19:32 +0100)]
Internal KFileItemModel optimizations and cleanups

- Use merge-sort instead of quick-sort. This assures a sane
  worst-case scenario where quick-sort has a runtime complexity of
  O(n*n) (e.g. when changing the sort-order from ascending to
  descending).

- lessThan()-improvements: Change internal data-structures to
  allow a comparison of any role, not only roles available
  in KFileItem

- Don't synchronously move an item if the value has been changed
  of a role defined as sort-role: This is too expensive in case if
  e.g. the sorting is done by "type" and the type is determined
  step by step.

14 years agoFix sorting-issues when value of a sort-role has been changed
Peter Penz [Sun, 30 Oct 2011 19:57:50 +0000 (20:57 +0100)]
Fix sorting-issues when value of a sort-role has been changed

If the value of a sort-role has been changed, emitting the signal
itemsChanged() is not sufficient as from the KItemModelBase point
of view an item has been moved or deleted/reinserted.

Corresponding to the unit-test KFileItemModel::setData() respects
this case correctly now, however there are some minor visual
animation issues left that (hopefully) should not be tricky to
solve.

14 years agoFix layout issue for groups
Peter Penz [Sun, 30 Oct 2011 09:19:29 +0000 (10:19 +0100)]
Fix layout issue for groups

When enabling a group where the sort-role is retrieved
asynchronously (e.g. group by "type") the group-headers have
stayed invisible.

14 years agoFix grouping-issue with not visible sorting roles
Peter Penz [Sat, 29 Oct 2011 17:50:15 +0000 (19:50 +0200)]
Fix grouping-issue with not visible sorting roles

It must be assured that the data for a sorting role always is
determined even it is not shown as "additional info" in the view.

14 years agoImplement grouping for all roles
Peter Penz [Sat, 29 Oct 2011 16:05:37 +0000 (18:05 +0200)]
Implement grouping for all roles

14 years agoFix minor visual issues in the view-engine
Peter Penz [Thu, 27 Oct 2011 20:34:33 +0000 (22:34 +0200)]
Fix minor visual issues in the view-engine

- Increasing the window-size should not result in increasing the
  size from previously invisible items
- Rename group 'Numerics' to '0 - 9'
- Fix "damaged" icons when changing the view-sizes or changing the
  view-mode

14 years agoGroup header fixes
Peter Penz [Tue, 25 Oct 2011 23:17:57 +0000 (01:17 +0200)]
Group header fixes

- Simplify header for the horizontal scroll direction
- Fix issue that orientation change was not forwarded to the header

14 years agoFix visibility issues of group-headers
Peter Penz [Tue, 25 Oct 2011 22:56:37 +0000 (00:56 +0200)]
Fix visibility issues of group-headers

When expanding/collapsing folders in the tree-view the visibility
of group-headers got unpredictable.

14 years agoFix minor graphical issue in group header and items
Peter Penz [Tue, 25 Oct 2011 20:15:45 +0000 (22:15 +0200)]
Fix minor graphical issue in group header and items

14 years agoMake group-headers less ugly
Peter Penz [Sun, 23 Oct 2011 22:22:03 +0000 (00:22 +0200)]
Make group-headers less ugly

14 years agoImprove group-header layout
Peter Penz [Sun, 23 Oct 2011 19:30:40 +0000 (21:30 +0200)]
Improve group-header layout

- Apply a dynamic width
- Use a height that depends on the style
- Cleanup some interfaces and replace xxxBoundingRect() by
  xxxRect()

14 years agoMousewheel-support: Use smaller scroll-steps
Peter Penz [Sat, 22 Oct 2011 10:33:24 +0000 (12:33 +0200)]
Mousewheel-support: Use smaller scroll-steps

Use only 1/4 of the scrollbar-page-size when the mousewheel
is used.

BUG: 284646
FIXED-IN: 4.8.0

14 years agoFix crash when grouping items
Peter Penz [Sat, 22 Oct 2011 00:14:42 +0000 (02:14 +0200)]
Fix crash when grouping items

Because of a wrong usage of parent() vs. parentItem() a crash
could occur because the parent might be assigned to an already
deleted instance.

14 years agoImplement grouping for names
Peter Penz [Fri, 21 Oct 2011 23:31:02 +0000 (01:31 +0200)]
Implement grouping for names

- Use a custom header for KFileItems
- Cache the groups
- Allow enabling/disabling grouping dynamically

Currently there is a random crash in combination with the
groupheader-recycler, this will be fixed during the next
days.

14 years agoImplement group-header layouting
Peter Penz [Tue, 18 Oct 2011 20:11:22 +0000 (22:11 +0200)]
Implement group-header layouting

The most tricky part for groups - the layouting - basically works
now for all views (grouping was available only in the icons views
for Dolphin 1.x) and is nearly equally fast as without groups.

Still open:
- Group headers are ugly screen rectangles
- Return valid groups in KFileItemModel instead of the currently
  hardcoded testing values
- Dynamically turning on/off groups does not work currently, the
  directory must be reentered

14 years agoSort the items in DolphinView::selectedItems(), part 2
Frank Reininghaus [Sun, 16 Oct 2011 18:45:10 +0000 (20:45 +0200)]
Sort the items in DolphinView::selectedItems(), part 2

I forgot this change in the last commit.
CCBUG:283409

14 years agoSort the items in DolphinView::selectedItems()
Frank Reininghaus [Sun, 16 Oct 2011 18:39:34 +0000 (20:39 +0200)]
Sort the items in DolphinView::selectedItems()

Before this commit, the order of the items in the list returned by
DolphinView::selectedItems() was random. Now the items are sorted like
they are sorted in the view.
BUG: 283409

14 years agoInterface cleanups to prepare the return of "grouped sorting"
Peter Penz [Sat, 15 Oct 2011 20:55:01 +0000 (22:55 +0200)]
Interface cleanups to prepare the return of "grouped sorting"

- Rename setCategorizedSorting() to setGroupedSorting()
- Change the model interface to allow enabling/disabling grouping
  without the need to declare a role (the sort role will be taken).
- Add dummy group role implementation in KFileItemModel

The grouping code itself requires some cleanups and might crash
at the moment or lead to weird layouts.

14 years agoFix regression concerning Control+mouse wheel zooming
Frank Reininghaus [Sat, 15 Oct 2011 18:08:42 +0000 (20:08 +0200)]
Fix regression concerning Control+mouse wheel zooming

Commit 9311f4bc97ec7000be46b8eec242a8 accidentally removed
DolphinView::wheelEvent(), which is responsible for the handling of
Control+mouse wheel events. These should change the zoom level.

14 years agoActivate the DolphinView if the KItemListContainer gets focus
Frank Reininghaus [Fri, 14 Oct 2011 07:21:19 +0000 (09:21 +0200)]
Activate the DolphinView if the KItemListContainer gets focus

This is needed in the case that the view is split to make the
DolphinMainWindow aware of the view which is currently active.

14 years agoRemove workaround to draw the focus indicator manually
Peter Penz [Mon, 10 Oct 2011 21:26:08 +0000 (23:26 +0200)]
Remove workaround to draw the focus indicator manually

In Oxygen the focus-indicator has only been drawn for widget
instances derived from QAbstractItemView and Q3ListView, so it
was not possible in Dolphin to use the style for drawing.

This has been fixed now in Oxygen, so using the style works now.

The custom code for drawing the text background will be removed
and replaced by a style-code later.

CCMAIL: hugo@oxygen-icons.org

14 years agoAllow changing shortcuts for the Panel actions
Peter Penz [Mon, 10 Oct 2011 20:05:32 +0000 (22:05 +0200)]
Allow changing shortcuts for the Panel actions

Until now the shortcuts of the Panel actions could not be changed
as they did not show up in the "Configure shortcuts..." dialog.

The patch is based on the work of "SiegeLord" and Fabian Henze
attached to bug 273050.

BUG: 273050
FIXED-IN: 4.8.0

14 years agoavoid two possible null pointer dereferences
Jaime Torres [Sun, 9 Oct 2011 09:12:22 +0000 (11:12 +0200)]
avoid two possible null pointer dereferences

move the setToolTip lines outside the if(action) inside it.
do not crash if there is no action.

14 years agoDon't let KItemListView decide itself whether to show the header
Peter Penz [Sat, 8 Oct 2011 21:05:03 +0000 (23:05 +0200)]
Don't let KItemListView decide itself whether to show the header

The header should be turned on or off by the user of the
KItemListView classes.

14 years agoDetails-view: Fix column-width issue
Peter Penz [Sat, 8 Oct 2011 20:46:37 +0000 (22:46 +0200)]
Details-view: Fix column-width issue

The column-width must respect the minimum width of the
header-roles.

14 years agoRemember the changed header-roles as part of the directory
Peter Penz [Sat, 8 Oct 2011 19:52:57 +0000 (21:52 +0200)]
Remember the changed header-roles as part of the directory

14 years agoContext menu cleanups
Peter Penz [Sat, 8 Oct 2011 19:40:34 +0000 (21:40 +0200)]
Context menu cleanups

- Open the context menu on the mouse-press event, not on the
  mouse-release event.
- Provide an explicit position-information and don't use
  QCursor::pos(). This fixes the issue that opening a context-menu
  by the keyboard opens below the cursor.
- Provide different signals in the KItemListController for
  the different context-menu types (item vs. view vs. header).
- Implement turning on/off roles by the header-context-menu.

14 years agoAssure that the rubberband is drawn above the items and not below
Peter Penz [Thu, 6 Oct 2011 21:14:04 +0000 (23:14 +0200)]
Assure that the rubberband is drawn above the items and not below

14 years agoProvide alternating background colors for the details-view
Peter Penz [Thu, 6 Oct 2011 21:02:43 +0000 (23:02 +0200)]
Provide alternating background colors for the details-view

14 years agoUse QFontMetrics::height() instead of averageCharWidth()
Peter Penz [Thu, 6 Oct 2011 14:41:29 +0000 (16:41 +0200)]
Use QFontMetrics::height() instead of averageCharWidth()

QFontMetrics::averageCharWidth() is quite slow and does not work
well on fonts with broken characters. In the
usecases required by Dolphin QFontMetrics::height() is a better
and faster alternative to get a font-dependent minimum width.

Thanks go to Christoph Feck for this hint!

14 years agoDon't apply an empty item-size to the layout
Peter Penz [Wed, 5 Oct 2011 15:12:01 +0000 (17:12 +0200)]
Don't apply an empty item-size to the layout

This fixes strange layout-issues when turning on/off previews in the
details-view.

CCBUG: 278899

14 years agoAdd function KItemListSelectionManager::isSelected(int index)
Frank Reininghaus [Mon, 3 Oct 2011 14:42:02 +0000 (16:42 +0200)]
Add function KItemListSelectionManager::isSelected(int index)

This function is used in KItemListView::updateWidgetProperties()
to find out if an item is selected in a more efficient way.
The new function is tested in KItemListSelectionManagerTest.
I've factored out some code from
KItemListSelectionManagerTest::testChangeSelection() to a new
member to simplify the test.

14 years agoRemove TODO-comment which isn't needed anymore
Frank Reininghaus [Mon, 3 Oct 2011 14:22:29 +0000 (16:22 +0200)]
Remove TODO-comment which isn't needed anymore

14 years agoKeep current item and selection when resorting, part 2
Frank Reininghaus [Mon, 3 Oct 2011 14:12:18 +0000 (16:12 +0200)]
Keep current item and selection when resorting, part 2

This commit adds the missing pieces to KItemListView and makes
KFileItemModel::resortAllItems() only emit the itemsMoved() signal.

14 years agoElide the texts if the user shrinks the column-widths
Peter Penz [Sun, 2 Oct 2011 15:33:41 +0000 (17:33 +0200)]
Elide the texts if the user shrinks the column-widths

14 years agoFix layout when the header has been adjusted by the user
Peter Penz [Sun, 2 Oct 2011 14:42:26 +0000 (16:42 +0200)]
Fix layout when the header has been adjusted by the user

14 years agoFix itemsMoved() signal/slot signature: KItemRangeList -> KItemRange
Frank Reininghaus [Fri, 30 Sep 2011 22:50:38 +0000 (00:50 +0200)]
Fix itemsMoved() signal/slot signature: KItemRangeList -> KItemRange

14 years agoImplement smooth-scrolling for horizontal and vertical scrollbars
Peter Penz [Fri, 30 Sep 2011 21:22:56 +0000 (23:22 +0200)]
Implement smooth-scrolling for horizontal and vertical scrollbars

Currently only a smoothscrolling was provided into the
scroll-direction, but not in case of the details-view where a
horizontal scrollbar might be shown too.

Some minor adjustments of the private KItemListSmoothScroller interface
will be done later...