Peter Penz [Sat, 1 Aug 2009 18:33:12 +0000 (18:33 +0000)]
Use QTemporaryFile instead of QFile. This assures an automatic deleting of the file and works reliable on multiuser system. Thanks to André Wöbbeking for the hint!
Peter Penz [Thu, 30 Jul 2009 06:21:35 +0000 (06:21 +0000)]
If the revision states have been changed because of executing a SVN context menu action, the resulting update should be done silently without information messages.
Peter Penz [Wed, 29 Jul 2009 07:38:57 +0000 (07:38 +0000)]
- indicate whether the server provides an updated version of a file
- QProcess::waitForReadyRead() must be invoked until it returns false. BTW: this method is invoked inside a non-GUI-thread and hence does not block Dolphin
Peter Penz [Mon, 27 Jul 2009 05:31:48 +0000 (05:31 +0000)]
Improved Subversion test plugin to allow committing, updating, diffing, adding and removing of files. As soon as the test plugin gets moved to kdesdk, the code should be improved to use the libsvn interface.
Peter Penz [Thu, 23 Jul 2009 06:28:28 +0000 (06:28 +0000)]
The revision control plugin must be aware on which directory the context-menu-actions should get applied. Relying on the directory that has been used in beginRetrieval() does not work when having a treeview.
Peter Penz [Wed, 22 Jul 2009 07:07:43 +0000 (07:07 +0000)]
- Documentation updates.
- Allow the revision plugin to emit a signal which indicates a changed revision state.
- Update the revision state if the state of file items has been changed.
- Check also the content of a file if the size of a local and revisioned file is equal.
Peter Penz [Fri, 17 Jul 2009 19:26:46 +0000 (19:26 +0000)]
The performance of updating the revision state of items depends on the used plugin. To prevent that Dolphin gets blocked by a slow plugin, the updating is delegated to a thread.
Still open issue: Applying the revision control property to the model is a bottleneck in QListView (a detailed description of the reason is in kdelibs/kfile/kfilepreviewgenerator.cpp, class LayoutBlocker). But the approach used in KFilePreviewGenerator destroys the textlayout in this case and is temporary disabled until I could track down the reason.
Improve selection behaviour concerning the new "jump to next/previous
row using right/left arrow" and "jump to next/previous column using
down/up arrow" when using the Icon View's "Rows" and "Columns"
arrangement, respectively, in the following cases:
1. In "Columns" arrangement, if the first item is selected and
Ctrl-Down is pressed repeatedly, don't deselect the first item when
jumping to the next column.
2. In "Rows" arrangement, if the first item in the second row is
active and then Left and finally Shift-Left is pressed, don't
re-select the first item in the second row unexpectedly.
3. If an item in the middle of the second row is selected, make sure
that selection with Shift-Left/Shift-Right is reversible even if the
previous/next row is reached.
Peter Penz [Mon, 13 Jul 2009 20:39:44 +0000 (20:39 +0000)]
The Oxygen team will provide revision control emblems for KDE 4.4. Adjust the code to use icons instead of coloring the text... The icon position at the moment is terrible, an interface extension in KFileItemDelegate is required to get the icon boundaries.
Peter Penz [Sun, 12 Jul 2009 15:15:10 +0000 (15:15 +0000)]
Just change the text color for revisioned files instead of using a completely filled background. I'm unsure whether we should use emblems or not... The problem with emblems is that most people that work with revisioned files use the details view with very small icons. So having an emblem above an icon and additionally the selection indicator does not work. Any ideas?
Peter Penz [Sun, 12 Jul 2009 14:00:45 +0000 (14:00 +0000)]
Enable Dolphin to show the revision states of files that are under revision control systems like SVN, Git, CVS, ... The current code is an early draft and it is planned that all plugins (SVN, Git, CVS, ...) are maintained outside Dolphin. If the API is stable enough, a discussion will be done at kfm-devel@kde.org regarding the location of the plugins (the current implementation of SubversionPlugin is only temporary located in Dolphin for testing purposes).
RevisionControlObserver is implemented in a way that no recognizable slowdown is given for directories that are not under revision control.
David Faure [Sun, 12 Jul 2009 01:00:14 +0000 (01:00 +0000)]
Same change as in r995015, but for usage in konq: Don't connect to KDirLister::itemDeleted(const KFileItem&), but KDirLister::itemsDeleted(const KFileItemList&).
Peter Penz [Sat, 11 Jul 2009 18:56:03 +0000 (18:56 +0000)]
Don't open folders on a single-click in the column view when the mouse settings specify double-click. Originally this was meant as a kind of feature (open files on double-click, but folders still on single-click), but it has been received as bug.
Peter Penz [Sat, 11 Jul 2009 18:10:35 +0000 (18:10 +0000)]
Update the statusbar synchronously when the directory lister has been completed. As no selection is given at this moment, there is no risk that updateStatusBar() is expensive.
Peter Penz [Sat, 11 Jul 2009 17:48:05 +0000 (17:48 +0000)]
Fixed performance issues related to selections and deleting of files:
- Don't connect to KDirLister::itemDeleted(const KFileItem&), but KDirLister::itemsDeleted(const KFileItemList&). Otherwise Dolphin is informed about each single file deletion instead of getting the deleted items as a list. Thanks to David Faure for the hint!
- DolphinViewContainer::updateStatusBar() can be expensive when a lot of files are selected, as the file size must get retrieved. Assure that fast calls for updateStatusBar() don't trigger a synchronous update, do the update after 300 ms where no further update has been triggered.
- Dolphin provides a list of file items when emitting the selectionChanged() signal. Collecting the file items is a quite expensive operation, so use the same approach as when updating the statusbar: only emit the selection changed signal when no change has been done within 300 ms. This improves the performance when doing huge selections a lot.
- Make updateStatusBar() a private method, the main window should not need to take care about updating the statusbar (this is done internally now by DolphinViewContainer).
David Faure [Fri, 10 Jul 2009 11:46:48 +0000 (11:46 +0000)]
Fix regression introduced by an obviously untested "krazy fix" (r973284). Setting a
QVariant to QString() is not the same as calling clear on the QVariant (which makes the variant invalid).
(BUG 194502)
Fixed the annoying bug (for me) that dealt with having a very long folder name. In this case, the name of the tab could be many more times bigger than the tabBar itself.
Now they are ellided, so e.g. "really really long folder name...is" or something.
Few more cases left for me to fix(shortly), but those are not quite close to this section.
Peter Penz [Sun, 5 Jul 2009 22:54:37 +0000 (22:54 +0000)]
The complexity of the class InformationPanel has grown a lot from KDE 4.0 to KDE 4.3. One main reason is that a lot of things are done now asynchronously with timers to prevent a blocking UI and unnecessary expensive operations.
To keep the Information Panel maintainable and prepared for future features a cleanup has been done. The whole user interface handling has been moved into the class InformationPanelContent that offers a straight forward interface: showItem(const KFileItem& item) and showItems(const KFileItemList& items).
The class InformationPanel is responsible for calling those methods in a way that hovering items, changing directories, doing selections, rename and delete operations, ... don't result in calling showItem() 10 times per second.
Peter Penz [Sun, 5 Jul 2009 19:10:20 +0000 (19:10 +0000)]
Improve performance of Dolphin:
- When changing a directory the receiving of the meta data is done now with a short delay. This gives the directory lister the chance to show the directory as fast as possible.
- Prevent that DolphinInformationPanel::reset() is invoked when changing a directory. The method only needs to get invoked if an item has been deleted or renamed.
- Cache an unknown file item. This improves the startup time of Dolphin (-> KFileItem constructor is invoked only once instead of up to 6 times).
Pass the "Yesterday (%B, %Y)" string to modifiedTime.toString(), such
that %B and %Y actually get replaced by month and year. Today seemed
to be a good day to reproduce and fix this :-)
Andrius Štikonas [Tue, 30 Jun 2009 20:09:04 +0000 (20:09 +0000)]
Use KIntSpinBox instead of QSpinBox for better integration with KDE. As a bonus this allows to use plural suffix in spinboxes since KDE 4.3 if necessary.
Swap two lines in DolphinViewContainer::setUrl. Up to now, the "if
(...)" check was more or less equivalent to "if (false)" here ;-) I've
verified that the "Create New..." menu is still enabled correctly when
switching columns in Columns view, which is what the "if" check
was added for in the first place.
Count selected items, not QItemSelectionRanges in
DolphinView::selectedItemsCount(). This fixes the problem that the
"Compare Files" action may be disabled or enabled incorrectly.
Peter Penz [Sun, 21 Jun 2009 08:16:03 +0000 (08:16 +0000)]
Simplify how Nepomuk comments can be edited by the user:
- don't provide any mode for editing, just let the user directly manipulate the comment inside the text widget
- automatically save changes, no explicit confirmation required
Peter Penz [Sat, 20 Jun 2009 18:35:08 +0000 (18:35 +0000)]
Simplify the handling of previews: Create the tooltip as early as possible even if the preview has not been finished yet. Previously an empty area has been shown instead of a default icon, but also in this case the size of the tooltip will change as soon as the preview is received -> just show the default icon as early as possible.
Peter Penz [Sat, 20 Jun 2009 16:49:04 +0000 (16:49 +0000)]
- Don't keep pointers to objects that are obtained and deleted by other objects.
- Simplify the API so that it is assured that no memory leaks are given.
Peter Penz [Sat, 20 Jun 2009 11:45:34 +0000 (11:45 +0000)]
We won't get translated labels for Nepomuk literals in KDE 4.3.0... At least assure that camelcase labels like "fileLocation:" are replaced by "File location:" (thanks to Sebastian Trüg for the code)
Use qAbs() instead of fabs(). The values in question are integers
anyway (so fabs() is not the 'right' function for them), and this
change makes the Sun Studio compiler happy.
Peter Penz [Wed, 10 Jun 2009 10:04:33 +0000 (10:04 +0000)]
fixed resizing issues when having long comments:
* embed the comment label inside a scrollarea
* assure that the "add comment..."/"change comment..." link is always visible
* assure that the maximum width of the meta data widget is set to the panel width (otherwise the panel would be increased in an unlimited way when having a text without spaces)
Peter Penz [Thu, 4 Jun 2009 06:05:45 +0000 (06:05 +0000)]
Only reset the current URL, if the element is shown in the current view.
This fixes the issue that when going back the last visited directory is
not marked.