Re: [qtMoko] How Contact selection UI is filled
On Wednesday 25 January 2012 17:05:40 Guilhem Bonnefille wrote: I still not know precisely what code is running when I select recipients of a SMS. But I found many codes doing similar things, but differently. QContactSelector (in src/libraries/qtopiapim/qcontactview.cpp) allow to select a single contact (I think) but return a QContact reference. The caller is then responsible of picking the right info and requesting a new selection from the user if the selected contact has many possible info (see src/server/phone/dialer/touch/dialer.cpp). This seems quite a good design. I also found AddressSelectorWidget (in src/libraries/qtopiamail/addressselectorwidget.cpp). It allows to select many recipients. But, by design, it does not allow to select the phone number of a contact when this contact has many phone numbers. The info used are only the defaultPhone or defaultEmail. This selector is interesting as it allow to select many contacts and offers a Find feature. What's the right way to fix the issue? I imagine the best one is to merge these selectors. But I'm really too new to qtMoko's hacking to decide the way to merge these codes. Any suggestion is welcome. Hmm the stuff around mail is quite complicated and IMO overengineered, but it's working quite good. I am afraid that big changes can break it. I think the multiple selection was supposed to work like this: - If contact has one phone number it's always used - If contact has two or more numbers you can edit the contact and set default phone number. This number is then used without asking. QContact has defaultPhoneNumber property [1] - it think it was for this purpose. But i cant see a place where it is used in code and where you can set it up from ui... You could get better overview how it works if you compile qtmoko with debug (i think it's -debug configure switch) and then use gdb on your phone on the qtmail application. I might want to take a look at it too, but i am currently a bit busy. Regards Radek [1] http://radekp.github.com/qtmoko/api/qcontact.html#defaultPhoneNumber ___ Openmoko community mailing list community@lists.openmoko.org http://lists.openmoko.org/mailman/listinfo/community
Re: [qtMoko] How Contact selection UI is filled
I still not know precisely what code is running when I select recipients of a SMS. But I found many codes doing similar things, but differently. QContactSelector (in src/libraries/qtopiapim/qcontactview.cpp) allow to select a single contact (I think) but return a QContact reference. The caller is then responsible of picking the right info and requesting a new selection from the user if the selected contact has many possible info (see src/server/phone/dialer/touch/dialer.cpp). This seems quite a good design. I also found AddressSelectorWidget (in src/libraries/qtopiamail/addressselectorwidget.cpp). It allows to select many recipients. But, by design, it does not allow to select the phone number of a contact when this contact has many phone numbers. The info used are only the defaultPhone or defaultEmail. This selector is interesting as it allow to select many contacts and offers a Find feature. What's the right way to fix the issue? I imagine the best one is to merge these selectors. But I'm really too new to qtMoko's hacking to decide the way to merge these codes. Any suggestion is welcome. 2012/1/22 Guilhem Bonnefille guilhem.bonnefi...@gmail.com: Hi, When writing a message (SMS), the recipient dialog show me a list of contact (with checkboxes). But when I select some contact, with many phone numbers, the wrong phone number is picked and I do not have ability to select the right one. I do not know what's wrong: - is there any filtering on phone number? - is it missing a dialog to select between the different phone numbers of a contact? Can someone point me the source code responsible of this dialog? I tried to look at it, but qtMoko is quite complex and hard to start with (specially for occasional hacking). Thanks in advance. -- Guilhem BONNEFILLE -=- JID: gu...@im.apinc.org MSN: guilhem_bonnefi...@hotmail.com -=- mailto:guilhem.bonnefi...@gmail.com -=- http://nathguil.free.fr/ -- Guilhem BONNEFILLE -=- JID: gu...@im.apinc.org MSN: guilhem_bonnefi...@hotmail.com -=- mailto:guilhem.bonnefi...@gmail.com -=- http://nathguil.free.fr/ ___ Openmoko community mailing list community@lists.openmoko.org http://lists.openmoko.org/mailman/listinfo/community
Re: [qtMoko] How Contact selection UI is filled
On Wed, 25 Jan 2012 17:05:40 +0100 Guilhem Bonnefille guilhem.bonnefi...@gmail.com wrote: I still not know precisely what code is running when I select recipients of a SMS. But I found many codes doing similar things, but differently. To check which code is responsible for the functionality you can insert qDebug(__PRETTY_FUNCTION__); in the code you suspect. Build/install QtMoko. switch on logging in QtMoko. SSH to the FreeRunner. tail -f /var/log/messages Push buttons i the phone user interface looking at the tail output. ___ Openmoko community mailing list community@lists.openmoko.org http://lists.openmoko.org/mailman/listinfo/community
[qtMoko] How Contact selection UI is filled
Hi, When writing a message (SMS), the recipient dialog show me a list of contact (with checkboxes). But when I select some contact, with many phone numbers, the wrong phone number is picked and I do not have ability to select the right one. I do not know what's wrong: - is there any filtering on phone number? - is it missing a dialog to select between the different phone numbers of a contact? Can someone point me the source code responsible of this dialog? I tried to look at it, but qtMoko is quite complex and hard to start with (specially for occasional hacking). Thanks in advance. -- Guilhem BONNEFILLE -=- JID: gu...@im.apinc.org MSN: guilhem_bonnefi...@hotmail.com -=- mailto:guilhem.bonnefi...@gmail.com -=- http://nathguil.free.fr/ ___ Openmoko community mailing list community@lists.openmoko.org http://lists.openmoko.org/mailman/listinfo/community