janlepper (Jan Lepper)
User

Projects

Today

  • Clear sailing ahead.

Tomorrow

  • Clear sailing ahead.

Saturday

  • Clear sailing ahead.

User Details

User Since
Dec 9 2016, 3:17 PM (23 w, 5 d)
Availability
Available

Recent Activity

Apr 9 2017

janlepper added a comment to T5716: New release: 2.6.0.

Agreed :)

Apr 9 2017, 4:20 PM · Krusader
janlepper added a comment to D5292: Fix for crash when closing currently refreshing panel.

Hmm, I can't update the diff (permissions?)

This is safer:

diff --git a/krusader/Panel/panelfunc.cpp b/krusader/Panel/panelfunc.cpp
index 3f2b184f7..c3dcaff41 100644
--- a/krusader/Panel/panelfunc.cpp
+++ b/krusader/Panel/panelfunc.cpp
@@ -310,11 +310,15 @@ void ListPanelFunc::doRefresh()
 
     // NOTE: this is blocking. Returns false on error or interruption (cancel requested or panel
     // was deleted)
+    QPointer<ListPanel> panelSave = panel;
     const bool refreshed = fileSystemP->refresh(url);
     if (refreshed) {
         // update the history and address bar, as the actual url might differ from the one requested
         history->setCurrentUrl(fileSystemP->currentDirectory());
         panel->setNavigatorUrl(fileSystemP->currentDirectory());
+    } else if (!panelSave) {
+        // panel was deleted while refreshing
+        return;
     }
 
     panel->view->setNameToMakeCurrent(QString());
Apr 9 2017, 3:24 PM · Krusader
janlepper added a comment to D5292: Fix for crash when closing currently refreshing panel.

Hmm, I can't update the diff (permissions?)

Apr 9 2017, 3:12 PM · Krusader
janlepper added a comment to D5292: Fix for crash when closing currently refreshing panel.

Sorry for the even later reaction ;)
Well, the QPointer doesn't hurt, but it doesn't fix the problem in this case.
Actually the ListPanelFunc object is destroyed before the ListPanel, so when you do the check for this->panel, this points to already freed memory.

Apr 9 2017, 2:39 PM · Krusader

Apr 4 2017

janlepper added a comment to D5292: Fix for crash when closing currently refreshing panel.
In D5292#99747, @abika wrote:

There has been code in place to prevent this, but looking at PanelManager::deletePanel(), the panel is now unconditionally deleted.
So a proper fix would be to re-introduce the previous behaviour.

I removed the whole code together with the previous check

if (p && p->func && p->func->files() && !p->func->files()->vfs_canDelete()) {
    connect(p->func->files(), SIGNAL(deleteAllowed()), p, SLOT(deleteLater()));
    p->func->files()->vfs_requestDelete();
    return;

mainly because it doesn't follow the principle of encapsulation in OOP. The panel manager should not have to check the inner state of the filesystem refresh invoked by the panel function object.
This fix is totally fine imo.

Apr 4 2017, 10:12 PM · Krusader
janlepper added a comment to D5292: Fix for crash when closing currently refreshing panel.

I'm sorry for the regression.
I assumed this situation (a panel was destroyed while still refreshing) wouldn't occur.
There has been code in place to prevent this, but looking at PanelManager::deletePanel(), the panel is now unconditionally deleted.
So a proper fix would be to re-introduce the previous behaviour.
Asynchronous refresh of course would also fix that problem.

Apr 4 2017, 10:08 AM · Krusader

Mar 16 2017

janlepper added a comment to T5673: Fix unsafe lambda usage.

That was fast - thanks!

Mar 16 2017, 12:32 PM · Krusader
janlepper created T5673: Fix unsafe lambda usage.
Mar 16 2017, 10:55 AM · Krusader

Mar 7 2017

janlepper added a comment to T5062: Improve search results tab.

Right, I didn't really think this through.
So it's probably the lesser effort to embed Lister into the result view.

Mar 7 2017, 11:24 AM · Krusader

Mar 5 2017

janlepper committed R167:08a15fd64c57: remove obsolete DirHistoryQueue::pushBackRoot() (authored by janlepper).
remove obsolete DirHistoryQueue::pushBackRoot()
Mar 5 2017, 10:27 PM
janlepper closed D4146: ListPanel: don't go back in history if refresh failed by committing R167:184946fb4255: Merge branch 'my-listpanel_refresh_rework'.
Mar 5 2017, 7:41 PM · Krusader
janlepper committed R167:184946fb4255: Merge branch 'my-listpanel_refresh_rework' (authored by janlepper).
Merge branch 'my-listpanel_refresh_rework'
Mar 5 2017, 7:41 PM
janlepper committed R167:4dc3cbf210fe: remove obsolete DirHistoryQueue::_state (authored by janlepper).
remove obsolete DirHistoryQueue::_state
Mar 5 2017, 7:41 PM
janlepper committed R167:01837ea28dce: remove obsolete ListPanelFunc::_ignoreVFSErrors (authored by janlepper).
remove obsolete ListPanelFunc::_ignoreVFSErrors
Mar 5 2017, 7:41 PM
janlepper committed R167:ec93890d69a9: listpanel: don't go back in history when refresh failed (authored by janlepper).
listpanel: don't go back in history when refresh failed
Mar 5 2017, 7:41 PM
janlepper committed R167:8d964edd244a: fix indentation (authored by janlepper).
fix indentation
Mar 5 2017, 7:41 PM
janlepper raised the priority of T5017: Avoid nested event dispatching from "Normal" to "Needs Triage".
Mar 5 2017, 6:39 PM · Krusader
janlepper claimed T5057: Check usage of QDir::setCurrent().
Mar 5 2017, 6:39 PM · Krusader
janlepper added a comment to T5062: Improve search results tab.

Well, you could add
static void KViewer::viewWithLister(QUrl url, QString searchText)

Mar 5 2017, 6:30 PM · Krusader
janlepper updated the diff for D4146: ListPanel: don't go back in history if refresh failed.

rebased

Mar 5 2017, 6:04 PM · Krusader

Mar 3 2017

janlepper removed a reviewer for D4146: ListPanel: don't go back in history if refresh failed: gengisdave.

I assume gengisdave won't comment on this (hasn't been active for a while)

Mar 3 2017, 2:31 PM · Krusader
janlepper added a comment to D4146: ListPanel: don't go back in history if refresh failed.
In D4146#84250, @abika wrote:

I personally prefer the old behavior. After restart going back to the "nearest" parent folder of a deleted path was pretty nice. And if it was a removable device I can mount it and go back to the folder with the history.

But whatever, another user setting for this would be too much. And yes, the while (true) loop wasn't nice.

Mar 3 2017, 2:25 PM · Krusader
janlepper added a comment to D2857: Use KRun for "Open with"->"Other..." dialog.
In D2857#86585, @abika wrote:
In D2857#85422, @asensi wrote:

Is the working directory really important for (any) application?

I don't recall using any, although probably some exist, and if ListPanelFunc::runCommand() works and allows that those application work correctly, probably it would be better for Krusader to use that code.

Fair enough. I reverted it.

BTW: what is the reason for dialog.hideRunInTerminal();?

Mar 3 2017, 2:14 PM

Feb 27 2017

janlepper accepted D4747: Rework of size/space calculation.

Very nice!
As a next step, if I didn't miss anything, calcSpaceFileSystem in AbstractJobThread::countLocalFiles() could be removed.
The packjob should be passed a list of URLs instead of file names which would eliminate the need to determine the URLs.

Feb 27 2017, 8:51 AM

Feb 8 2017

janlepper added a comment to D4146: ListPanel: don't go back in history if refresh failed.
In D4146#84030, @asensi wrote:

Btw: Am I right assuming that having "Krusader" as a blocking reviewer requires all members to accept?

I'm going to accept it, so everybody will see how that works :-)

Feb 8 2017, 1:27 PM · Krusader
janlepper edited reviewers for D4146: ListPanel: don't go back in history if refresh failed, added: abika, gengisdave, yurchor; removed: Krusader.
Feb 8 2017, 1:25 PM · Krusader
janlepper added a comment to T5062: Improve search results tab.

Another option: Use Lister and add the necessary methods.

Feb 8 2017, 1:07 PM · Krusader

Feb 6 2017

janlepper added a comment to T5062: Improve search results tab.

True, that would be easier and also do the job.
KParts::TextExtension should come in handy here.

Feb 6 2017, 8:39 AM · Krusader
janlepper added a comment to D4146: ListPanel: don't go back in history if refresh failed.

Before I go forward I would like some more opinions ;)

Feb 6 2017, 8:28 AM · Krusader
janlepper removed a reviewer for D4146: ListPanel: don't go back in history if refresh failed: martinkostolny.
Feb 6 2017, 8:27 AM · Krusader

Jan 18 2017

janlepper requested changes to D2857: Use KRun for "Open with"->"Other..." dialog.
Jan 18 2017, 4:38 AM

Jan 15 2017

janlepper updated D4146: ListPanel: don't go back in history if refresh failed.
Jan 15 2017, 8:46 PM · Krusader
janlepper added a task to D4146: ListPanel: don't go back in history if refresh failed: T5017: Avoid nested event dispatching.
Jan 15 2017, 8:32 PM · Krusader
janlepper added a revision to T5017: Avoid nested event dispatching: D4146: ListPanel: don't go back in history if refresh failed.
Jan 15 2017, 8:32 PM · Krusader
janlepper added a reviewer for D4146: ListPanel: don't go back in history if refresh failed: Krusader.
Jan 15 2017, 7:53 PM · Krusader
janlepper updated D4146: ListPanel: don't go back in history if refresh failed.
Jan 15 2017, 7:52 PM · Krusader
janlepper retitled D4146: ListPanel: don't go back in history if refresh failed from to ListPanel: don't go back in history if refresh failed.
Jan 15 2017, 7:21 PM · Krusader

Jan 13 2017

janlepper reopened D2857: Use KRun for "Open with"->"Other..." dialog.

I intentionally went via ListPanelFunc::runCommand() so that the panel's path is set as working directory for the command.
With KRun::displayOpenWithDialog() there is no guarantee for that.

Jan 13 2017, 4:40 PM

Jan 12 2017

janlepper added a comment to T5062: Improve search results tab.

How about that?

Jan 12 2017, 1:43 PM · Krusader
janlepper added a comment to T5062: Improve search results tab.

I'm sorry - it's just a mockup ;)
I don't think I'll be working on this in the near future - just wanted to collect some ideas.
The mc-like result list will probably require a lot of work - in KrView there is a 1:1 relationship between view item and a file, but this would require multiple items per file.

Jan 12 2017, 1:27 PM · Krusader
janlepper edited the description of T5062: Improve search results tab.
Jan 12 2017, 1:16 PM · Krusader

Jan 11 2017

janlepper edited the description of T5062: Improve search results tab.
Jan 11 2017, 4:56 PM · Krusader
janlepper edited the description of T5062: Improve search results tab.
Jan 11 2017, 4:40 PM · Krusader
janlepper created T5062: Improve search results tab.
Jan 11 2017, 4:37 PM · Krusader
janlepper added a comment to D3994: add asynchronous vfs refresh.

Unfortunately I don't have this area studied enough yet to consult the direction. But I certainly can test your code and report issues:). So far I found some regarding refreshing:

  • external changes aren't reflected (I have to manual refresh Ctrl+R to see them)
  • undo action will not refresh view after it is done

    But I understand it is a work in progress, so please say if it is too soon to test these "corner" cases. Anyway, thanks for Your work!
Jan 11 2017, 9:59 AM · Krusader

Jan 10 2017

janlepper added a comment to T5057: Check usage of QDir::setCurrent().

The invocation In ListPanelFunc::doRefresh() seems to rely on the panel being the active one (which was true historically - when refreshing a panel would activate itself first).
Nowadays a panel might refresh while being inactive - breaking code which relies on the workdir matching the active panel.

Jan 10 2017, 7:03 PM · Krusader
janlepper created T5057: Check usage of QDir::setCurrent().
Jan 10 2017, 6:58 PM · Krusader
janlepper removed a dependent revision for D3994: add asynchronous vfs refresh: Unknown Object (Differential Revision).
Jan 10 2017, 2:37 AM · Krusader
janlepper set the repository for D3994: add asynchronous vfs refresh to R167 Krusader.
Jan 10 2017, 2:23 AM · Krusader
janlepper updated the diff for D3994: add asynchronous vfs refresh.
Jan 10 2017, 2:23 AM · Krusader
janlepper added a dependent revision for D3994: add asynchronous vfs refresh: Unknown Object (Differential Revision).
Jan 10 2017, 12:38 AM · Krusader

Jan 9 2017

janlepper changed the visibility for D3994: add asynchronous vfs refresh.
Jan 9 2017, 9:11 PM · Krusader

Jan 8 2017

janlepper added a reviewer for D3994: add asynchronous vfs refresh: Krusader.
Jan 8 2017, 5:11 PM · Krusader

Jan 6 2017

janlepper edited the description of T5017: Avoid nested event dispatching.
Jan 6 2017, 4:58 PM · Krusader
janlepper added a task to D3994: add asynchronous vfs refresh: T5017: Avoid nested event dispatching.
Jan 6 2017, 4:57 PM · Krusader
janlepper added a revision to T5017: Avoid nested event dispatching: D3994: add asynchronous vfs refresh.
Jan 6 2017, 4:57 PM · Krusader
janlepper retitled D3994: add asynchronous vfs refresh from to add asynchronous vfs refresh.
Jan 6 2017, 4:57 PM · Krusader

Jan 4 2017

janlepper added a comment to T3419: Rework of VFS.

Just so we don't duplicate our efforts: T5017

Jan 4 2017, 10:31 AM · Krusader
janlepper edited the description of T5017: Avoid nested event dispatching.
Jan 4 2017, 10:31 AM · Krusader
janlepper edited the description of T5017: Avoid nested event dispatching.
Jan 4 2017, 10:21 AM · Krusader

Jan 3 2017

janlepper edited the description of T5017: Avoid nested event dispatching.
Jan 3 2017, 12:11 AM · Krusader

Jan 2 2017

janlepper created T5017: Avoid nested event dispatching.
Jan 2 2017, 11:37 PM · Krusader
janlepper added a comment to T3419: Rework of VFS.
In T3419#70758, @abika wrote:

I'm still unsure if we should split the vfs class (in e.g. FileLister and FileOperations). Currently there is only one method that is used without vfs: copyFiles().

It's problybly not that important.

Thinking about it, a more beneficial thing would be moving to a non-blocking
refresh refresh like in KDirLister.

Then there is vfs::calcSpace() which also blocks.
From there I stumbled on vfs::calcSpaceKIO and "TODO called from another thread, creating KIO jobs does not work here".
I recall that KIO jobs move themselves to the main (or gui?) thread, or is my memory wrong here?

Jan 2 2017, 11:12 PM · Krusader

Dec 14 2016

janlepper added a comment to T3419: Rework of VFS.
In T3419#70758, @abika wrote:

I'm still unsure if we should split the vfs class (in e.g. FileLister and FileOperations). Currently there is only one method that is used without vfs: copyFiles().

Dec 14 2016, 4:32 AM · Krusader

Dec 9 2016

janlepper added a member for Krusader: janlepper.
Dec 9 2016, 3:40 PM
janlepper added a comment to T3419: Rework of VFS.

If I didn't overlook something this vfs instance is never deleted:
https://cgit.kde.org/krusader.git/tree/krusader/VFS/krvfshandler.cpp?id=2f50bd46ebcc643bd99f88afef45561f4fb5d08e#n54

Dec 9 2016, 3:22 PM · Krusader
janlepper added a watcher for Krusader: janlepper.
Dec 9 2016, 3:18 PM