Review Request 108598: Create the new types enum - Important please review !
Martin Klapetek
martin.klapetek at gmail.com
Tue Jan 29 13:03:51 UTC 2013
> On Jan. 28, 2013, 10:55 a.m., Dan Vrátil wrote:
> > KTp/types.h, line 58
> > <http://git.reviewboard.kde.org/r/108598/diff/1/?file=109299#file109299line58>
> >
> > I know that in my email I was against killing these roles, but back then I didn't realize we can use KTp::Presence instread of Tp::Presence.
> >
> > If we modify KTp::Presence to be QML friendly (being QObject and using Q_PROPERTY), we can kill all the ContactPresence*Roles.
> >
> > However that would mean making KTp::Presence a QObject. And I don't know whether that makes any sense at all...up to you, just an idea.
I think having them as model roles makes the code cleaner, eg
index.data(ContactsModel::ContactPresenceRole).value<KTp::Presence>().presenceMessage();
vs
index.data(ContactsModel::ContactPresenceMessageRole).toString();
- Martin
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/108598/#review26297
-----------------------------------------------------------
On Jan. 26, 2013, 1:33 p.m., David Edmundson wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://git.reviewboard.kde.org/r/108598/
> -----------------------------------------------------------
>
> (Updated Jan. 26, 2013, 1:33 p.m.)
>
>
> Review request for Telepathy.
>
>
> Description
> -------
>
> Create the new types enum.
>
> This is really important. Please please review.
> Give a "ship it!" if you're happy with the enum. I will only push into the model_refactor_3 branch.
>
> Obviously this won't compile, I want to make sure people are happy with this _before_ we start changing all the other code. We can add roles later, but I don't want to be editing or deleting them.
>
> I'm also not sure whether I should namespace the enum so we don't have roles at the top level of the KTp namespace? (i.e namespace KTp { namespace ContactModelRoles { enum ModelRoles{ ..... ) ? Thoughts?
>
> (what's not shown in the diff is that I've also deleted/merged the ktp-metatypes.h file)
>
>
> Diffs
> -----
>
> KTp/CMakeLists.txt 10c17bf1f915db9fed59f2d11421cb73a38cebae
> KTp/Models/accounts-tree-proxy-model.cpp ead34f6a1b019535caeb77e05eb7332e71d82f5c
> KTp/Models/contacts-filter-model.cpp 145dcef38593edc10d1efb3f6dc5e188723ecc8e
> KTp/Models/contacts-list-model.h 876a485a65eacad7fa8663dd7c221f52c1ae7ff1
> KTp/Models/contacts-model.h 2a9cf44736e6e3aea5f92eb09e6840314ba94247
> KTp/ktp-metatypes.h 9488ee5cbe059d831466b1a1115e2ff359457bac
> KTp/types.h PRE-CREATION
>
> Diff: http://git.reviewboard.kde.org/r/108598/diff/
>
>
> Testing
> -------
>
>
> Thanks,
>
> David Edmundson
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-telepathy/attachments/20130129/4de9fb29/attachment.html>
More information about the KDE-Telepathy
mailing list