Bug 175715 - Download % on title bar not correctly updated
Summary: Download % on title bar not correctly updated
Status: RESOLVED FIXED
Alias: None
Product: kget
Classification: Applications
Component: Core (show other bugs)
Version: unspecified
Platform: Compiled Sources Linux
: NOR normal
Target Milestone: ---
Assignee: KGet authors
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-11-20 23:20 UTC by FiNeX
Modified: 2008-12-23 22:51 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
Update the mainwindow window title when a transfer is removed or stopped (1.97 KB, patch)
2008-11-21 15:16 UTC, Javier goday
Details

Note You need to log in before you can comment on or make changes to this bug.
Description FiNeX 2008-11-20 23:20:34 UTC
Two problems in current trunk:

- when you've only a file transfer and, while the download is active, you click on "delete selected", the transfer list is emptied, but the title bar still has the last % value.

- when you have 2 file transfer and you stop the first and, after a while, you stop the second one, the % on the title is related to the last stopped transfer. Instead if you stop them togheter the % is calculated from both.

bye
Comment 1 Javier goday 2008-11-21 15:16:53 UTC
Created attachment 28727 [details]
Update the mainwindow window title when a transfer is removed or stopped

Attach a patch to solve this problems:

1- Update the kget window title when a transfer is removed too (MainWindowGroupObserver::removedTransferEvent)

2- We only show the percent of the active transfers (Call to updateTitle when a transfer status is changed)
Comment 2 FiNeX 2008-11-21 15:37:30 UTC
@Javier: I've tested the patch and it works perfectly. You can commit it :-)

Thanks!
Comment 3 Lukas Appelhans 2008-11-21 18:53:58 UTC
No, it's wrong actually...
If a Transfer's status changes the group status does not automatically change... ;)
We should better go with a clean sollution, probably update the title from GenericTransferObserver?

Lukas
Comment 4 Javier goday 2008-12-08 17:13:35 UTC
Why not tell the TransferGroup about the transfer changes using the 
GenericTransferObserver::transferChangedEvent ?

something like transfer->group()->setGroupChange([Some conversion between the transfer and the group changeFlags], true);
Comment 5 Lukas Appelhans 2008-12-08 19:10:10 UTC
It's a change of the Transfer, not of the Group actually...

Lukas
Comment 6 Javier goday 2008-12-23 22:51:01 UTC
SVN commit 900895 by jgoday:

BUG: 175715
Add a transferObserver to the mainWindow to upload the titleBar


 M  +23 -4     mainwindow.cpp  
 M  +20 -2     mainwindow.h  


WebSVN link: http://websvn.kde.org/?view=rev&revision=900895