Bug 410095

Summary: Messaging app appears to be loading forever if the number of messages in the complete conversation do not fill the initial view
Product: [Applications] kdeconnect Reporter: Simon Redman <simon>
Component: messaging-applicationAssignee: Simon Redman <simon>
Status: RESOLVED FIXED    
Severity: normal Flags: simon: Usability+
Priority: NOR    
Version First Reported In: unspecified   
Target Milestone: ---   
Platform: Compiled Sources   
OS: All   
Latest Commit: Version Fixed/Implemented In: 2e04adf99ce6bf6b6c50376497115b4e0efec4e4
Sentry Crash Report:

Description Simon Redman 2019-07-22 07:13:27 UTC
SUMMARY
Messaging app appears to be loading forever if the number of messages in the complete conversation do not fill the initial view

The basic issue is that there is no response from the daemon if the phone sends back an empty list of messages, so there is no way to know that "that's it"

The damage is minimal since we are still able to send messages while loading (so we can still see all messages in the conversation and interact with it). It is just a confusing UI.

STEPS TO REPRODUCE
1. Open a short conversation in the messaging app (for example, one message)
2. See loading indicator forever

OBSERVED RESULT
Messages still appear to be loading even though none are there

EXPECTED RESULT
Remove the loading indicator to indicate that all messages have been loaded

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: Fedora 29
KDE Plasma Version: 5.14.5
KDE Frameworks Version: 5.58.0
Qt Version: 5.11.3

ADDITIONAL INFORMATION
Consider the two problem cases: A conversation with only one message (so asking the phone for more results in an empty list) and a conversation with only a few messages (so asking the daemon for 10 messages gives back fewer than 10)

Probably the correct answer to this situation is to move the handling of `isInitalized` from the QML view to the C++ model so that it's possible to connect the reply from the daemon to the logic controlling the view