1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-12-26 15:30:58 +01:00
phorge-phorge/webroot/rsrc/js/application/conpherence
Bob Trahan 6c049d06ce Conpherence - change message rendering logic to eradicate possibility of duplicates
Summary:
Fixes T6713. Before this diff, we would update the DOM when various requests came back, but the logic to erase race conditions proved too tricky for me to get right. Instead, change the algorithm up and keep a set of transaction ids around per thread. When its time to update the transactions, sort the list of ids and just render the whole darn set again.

To make this work, this ends up adding transacton ids to fake transactons like "show older" and date markers. This is able to work by using a float sort and giving these transactions ids that are .5 from being an integer and in the right place numerically.

Test Plan: for durable column, clicked show older and it worked. sent a message and it worked. for main view, clicked show older and it worked. sent a message and it worked.

Reviewers: epriestley

Reviewed By: epriestley

Subscribers: Korvin, epriestley

Maniphest Tasks: T6713

Differential Revision: https://secure.phabricator.com/D12819
2015-05-13 11:06:54 -07:00
..
behavior-drag-and-drop-photo.js Conpherence - add back in custom images 2015-05-04 13:52:22 -07:00
behavior-durable-column.js Conpherence - change message rendering logic to eradicate possibility of duplicates 2015-05-13 11:06:54 -07:00
behavior-menu.js Conpherence - change message rendering logic to eradicate possibility of duplicates 2015-05-13 11:06:54 -07:00
behavior-pontificate.js Conpherence - introduce ConpherenceThreadManager 2015-03-10 12:20:29 -07:00
behavior-quicksand-blacklist.js Generalize URI pattern blacklist for Quicksand 2015-03-10 15:32:15 -07:00
behavior-widget-pane.js Conpherence - get #anchor links to messages working 2015-04-13 15:24:48 -07:00
ConpherenceThreadManager.js Conpherence - change message rendering logic to eradicate possibility of duplicates 2015-05-13 11:06:54 -07:00