Closed
Bug 455240
Opened 14 years ago
Closed 14 years ago
Address book card preview pane doesn't update for card changes via external interfaces (where notifications exist, e.g. OS X)
Categories
(MailNews Core :: Address Book, defect)
MailNews Core
Address Book
Tracking
(Not tracked)
RESOLVED
FIXED
Thunderbird 3.0a3
People
(Reporter: standard8, Assigned: standard8)
References
Details
Attachments
(1 file, 2 obsolete files)
10.14 KB,
patch
|
neil
:
review+
Bienvenu
:
superreview+
|
Details | Diff | Splinter Review |
1) Select a card in Thunderbird's Address Book which is in an OS X address book. 2) Go into the OS X address book and update the card. 3) Notice that the card preview pane doesn't update. The problem is the way we're doing the notifications. Should be very simple to fix. At the moment when we call the edit card or edit list dialogs, they are called with a callback which equates to UpdateCardView, which is why this works internally. We have proper methods for doing this, in particular we already have a listener in addressbook.js which listens for some events. We should just drop the edit card/list callbacks and update the card view in the listener in addressbook.js if the card matches the selected card.
Assignee | ||
Comment 1•14 years ago
|
||
This patch means we update the card view pane whenever the changed card matches the one selected, hence we can drop the "manual" callbacks that are used to update the cards.
Attachment #338550 -
Flags: superreview?(bienvenu)
Attachment #338550 -
Flags: review?(neil)
Comment 2•14 years ago
|
||
I'm tempted to suggest that this should be done in nsAbView - it already has to update its internal state for card edits and it should be trivial to check that the card it updated was the single selection and if so poke the UI.
Assignee | ||
Comment 3•14 years ago
|
||
(In reply to comment #2) > I'm tempted to suggest that this should be done in nsAbView - it already has to > update its internal state for card edits and it should be trivial to check that > the card it updated was the single selection and if so poke the UI. How would you be thinking of poking the UI? Not everything that uses nsAbView needs an update, so the only way I can think of is to use a listener/callback combination which is what I'm effectively doing here anyway.
Comment 4•14 years ago
|
||
We already have an nsIAbViewListener. For instance, when you change the first/last name pref then the nsAbView calls its onSelectionChanged method.
Assignee | ||
Comment 5•14 years ago
|
||
Better patch, based on Neil's comments, this patch simply notifies the nsIAbViewListener of a selection changed update (when OnItemPropertyChanged is called) and that refreshes the display.
Attachment #338550 -
Attachment is obsolete: true
Attachment #339059 -
Flags: superreview?(bienvenu)
Attachment #339059 -
Flags: review?(neil)
Attachment #338550 -
Flags: superreview?(bienvenu)
Attachment #338550 -
Flags: review?(neil)
Assignee | ||
Comment 6•14 years ago
|
||
Limit updates to only when the card was/is selected.
Attachment #339059 -
Attachment is obsolete: true
Attachment #339063 -
Flags: superreview?(bienvenu)
Attachment #339063 -
Flags: review?(neil)
Attachment #339059 -
Flags: superreview?(bienvenu)
Attachment #339059 -
Flags: review?(neil)
Comment 7•14 years ago
|
||
Comment on attachment 339063 [details] [diff] [review] The fix v3 This also works when editing the contact from the address book sidebar of course :-)
Attachment #339063 -
Flags: review?(neil) → review+
Updated•14 years ago
|
Attachment #339063 -
Flags: superreview?(bienvenu) → superreview+
Assignee | ||
Comment 8•14 years ago
|
||
Checked in, changeset id: 360:6fb2a576f786
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•