Bug 271796 - Return from auto-away should unset away flags on connections in disconnected state
Summary: Return from auto-away should unset away flags on connections in disconnected ...
Status: CONFIRMED
Alias: None
Product: konversation
Classification: Applications
Component: general (show other bugs)
Version: 1.5-rc1
Platform: Compiled Sources Linux
: NOR normal
Target Milestone: ---
Assignee: Konversation Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-04-26 19:22 UTC by Martin Blumenstingl
Modified: 2013-04-15 02:13 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Blumenstingl 2011-04-26 19:22:31 UTC
Version:           Git (using KDE 4.6.2) 
OS:                Linux

Return from auto-away should unset away flags on connections in disconnected state.
Looks like this has never been done right.

Reproducible: Didn't try

Steps to Reproduce:
-you're connected to a network
-you go auto-away
-you get disconnected from the network
-you return
-you connect to the network again

Actual Results:  
upon reconnect konvi marks me as away again

Expected Results:  
Konversation should *NOT* mark me as away when I'm reconnected.

Most of the isConnected() checks in awaymanager.cpp are probably wrong.
Comment 1 Eike Hein 2011-04-26 19:52:06 UTC
Some notes on this:

- Konversation, long since before it ever got auto-away support, tries to carry away state across reconnects. The idea being that if you were marked away before getting disconnected, or even manually disconnecting, chances are you want to be marked away after reconnecting, too. I think that idea is still valid.

- Away Manager, and this is where the error lies, was written to never be active unless it must be, to cut down on timer wakeups. That currently means it only starts doing stuff when an identity with auto-away enabled is actually seeing use in an established connection, and stops doing stuff when the "identity goes offline". This clashes with carrying away-state across reconnects, because it means it won't catch and implement a return event for connections in a disconnected state, which remember they were away when they were last connected, and recreate that after reconnecting. AwayManager will have to move from thinking about "identities which are onlie" to thinkining about "identities which are in use" at least to some degree.