Bug 234000 - [PATCH] Status -> Online only works if all accounts are offline
Summary: [PATCH] Status -> Online only works if all accounts are offline
Status: RESOLVED FIXED
Alias: None
Product: kopete
Classification: Unclassified
Component: general (show other bugs)
Version: unspecified
Platform: Ubuntu Packages Unspecified
: NOR wishlist (vote)
Target Milestone: ---
Assignee: Kopete Developers
URL:
Keywords:
: 140391 (view as bug list)
Depends on:
Blocks:
 
Reported: 2010-04-11 03:35 UTC by Christian Muehlhaeuser
Modified: 2011-03-18 00:04 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In: 4.6.1


Attachments
Proposed patch to fix this bug (3.52 KB, patch)
2010-05-11 04:26 UTC, Christian Muehlhaeuser
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Christian Muehlhaeuser 2010-04-11 03:35:56 UTC
Version:            (using KDE 4.4.2)
Installed from:    Ubuntu Packages

If one of my accounts goes offline, I can't bring it back online by using the Status button in the toolbar. That only works if all accounts are offline.

Expected behaviour: When i click Status -> Online, make sure that all offline accounts start connecting.
Comment 1 Christian Muehlhaeuser 2010-05-11 04:26:25 UTC
Created attachment 43448 [details]
Proposed patch to fix this bug

Proposed patch to fix this issue.

This patch anticipates that the status change request was made by the user and forces the status change on all accounts by calling AccountManager::setOnlineStatus() with a special force parameter.

All other setOnlineStatus() calls won't be affected and keep working as previously.
Comment 2 Christian Muehlhaeuser 2010-05-11 07:24:10 UTC
Additional chat / info about the patch (which might not be final yet):

[07:15] <Tm_T> muesli: #234000 patch, if I disconnect one account, it will reconnect if I change global status online, right?
[07:16] <muesli> yes
[07:16] <Tm_T> deliberately disconnected account shouldn't be reconnected by it IMHO
[07:16] <muesli> if it's triggered via the status menu or context-menu
[07:16] <muesli> in both cases the user actively chooses their status to be online
[07:16] <muesli> and i think all accounts should respect that
[07:17] <muesli> if there are other means of changing the status, they shouldn't be affected
[07:17] <Tm_T> heh, we agree to disagree then, I'd recommend to mail to kopete-devel mailing list (:
[07:17] <Tm_T> I guess I'm not qualified to decide anyway
[07:17] <muesli> me neither
[07:17] <muesli> but so often i rely on status->online
[07:18] <muesli> just to figure out sometime later that it didn't actually bother to connect at all because one account remained online all the time
[07:18] <muesli> and there's no visual clue or feedback or anything to the usr
[07:18] <Tm_T> muesli: agreed, it's a bit mess at times
[07:19] <Tm_T> muesli: second report makes sense to me, though the code I don't understand very well
[07:19] <muesli> yeah, the second one is a no brainer
[07:19] <muesli> it was miscalculating the widget's height all the time and it was easy to fix by getting the row height from the qlistview
[07:20] <muesli> Tm_T: so thing is: if kopete goes auto away, all deliberately offline accounts will remain offline, of course
[07:20] <muesli> just if you pick a new status via the menu it applies to all accounts
[07:20] <muesli> the real argument for me is:
[07:20] <muesli> Online and Offline should apply to all accounts
[07:21] <muesli> Away, Invisible changes should only apply to accounts already online (my patch fails to respect that atm, but it's easy to fix)
[07:21] <muesli> the entire problem starts by not differentiating between Available and Online
[07:21] <muesli> online shouldn't be a status
[07:22] <muesli> online should be an action and the result should be a status change from Offline to Available
[07:22] <muesli> (one could argue offline isn't a status either)
Comment 3 Lamarque V. Souza 2011-02-09 06:13:08 UTC
SVN commit 1219501 by lvsouza:

Applying patch from  Christian Muehlhaeuser to force all accounts to
go online if the Status -> Online menu is clicked. Thanks for the patch.

BUG: 234000


 M  +6 -1      kopete/kopetewindow.cpp  
 M  +1 -1      kopete/kopetewindow.h  
 M  +2 -2      libkopete/kopeteaccountmanager.cpp  
 M  +4 -1      libkopete/kopeteaccountmanager.h  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1219501
Comment 4 Lamarque V. Souza 2011-02-09 06:14:21 UTC
SVN commit 1219502 by lvsouza:

Backport r1219501 by lvsouza from trunk to the 4.6 branch:

Applying patch from  Christian Muehlhaeuser to force all accounts to
go online if the Status -> Online menu is clicked. Thanks for the patch.

CCBUG: 234000


 M  +6 -1      kopete/kopetewindow.cpp  
 M  +1 -1      kopete/kopetewindow.h  
 M  +2 -2      libkopete/kopeteaccountmanager.cpp  
 M  +4 -1      libkopete/kopeteaccountmanager.h  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1219502
Comment 5 Lamarque V. Souza 2011-03-18 00:04:48 UTC
*** Bug 140391 has been marked as a duplicate of this bug. ***