Hi all, for our phone application we try to build a UI based on QML. Therefore I'm implementing an API for different phone properties and states. On of it is the list of current phone calls, and I'm wondering how to do this in the correct - speak: declarative - way.
First I found it a good idea to implement a QAbstractListModel for the current calls and that works nicely with ListView. But now I realized, that these models are tightly bound to the viewer, for instance the sorting is done in the model and there seems to be not many ways to interact with the model directly. What I would need is a kind of a persistent model, independent of any viewers, which for example I can also bind to condition of states. Like the condition "if an item exists with property A set to value X", which could, for instance, be used to trigger the ringer screen, if a ringing call is added to the list. Of course I could add properties to the QALM like "bool ringing" which is set true whenever there is a ringing call in the list. But somehow I have the feeling this is going into the wrong direction, and QALM is not the right choice here. Also I would like to avoid something like a ringing-signal and similar things, because I fear that this takes me away from the declarative concept. So I would like to know by people more experienced than me in the declarative thinking, how I can design such an API in a declarative way, if this is possible at all. Also you may point me to software that solved these kind of issues already. Thanks a lot for your thoughts and best regards, Sven ________________________________ * Join our Partner program: http://www.snom.com/partner<http://www.snom.com/partners> * Subscribe to our snom support RSS Feed<http://wiki.snom.com/wiki/index.php?title=RSS&action=feed&feed=rss> and get first-hand technical news about snom products, e.g. Firmware updates, FAQ updates, troubleshooting hints, etc. Follow us on Facebook<http://www.facebook.com/snom.VoIP.phones>, Twitter<http://twitter.com/snom>, YouTube<http://www.youtube.com/user/snomvoip>, Linkedin<http://www.linkedin.com/groups?gid=1773766> Sitz/Domicile: Charlottenstr. 68-71, 10117 Berlin, Germany Handelsregistereintrag/Register of Corporations entry: Berlin-Charlottenburg HRB 61842 B Vorstand/Executive Board: Dr. Christian Stredicke, Dr. Michael Knieling, Alexander Khan Vorsitzender des Aufsichtsrates/Chairman of the Supervisory Board: Stefan Friese snom technology AG<http://www.snom.com> _______________________________________________ Qt-qml mailing list Qt-qml@qt.nokia.com http://lists.qt.nokia.com/mailman/listinfo/qt-qml