Before this commit if the text selection was lost while the color palette was used, the color selection was not applied on anything. After this commit if the text selection was lost, it is restored to the last selection known in history before applying (or previewing) the color selection. Also avoid to remember selections that are not part of the editable. task-2599771 closes odoo/odoo#76357 X-original-commit: 0e706d508d6e747cff566c33d34b794a321eef5c Signed-off-by: Antoine Guenet <Zinston@users.noreply.github.com>