Feature : Color palette : fix spectrum issue

The palette manager UI is redrawn almost everytime the model changes.
This way, UI is always in sync with the model.

However, spectrum instances are spawning everytime a redraw is performed.
They cannot be cleaned before the redraw is performed, because if a
spectrum picker is opened, it should remain like this. This allows the
cuser to keep modifying a color without having to reopen the picker each
time he/she stops on a color.

As a workaround, I keep a reference on all the spectrum containers and
destroy them all when the manager is disposed.

Ideally I'd prefer to have a single spectrum instance that I could move
around depending on which color the user wants to edit. I.e. I want to
mutualize all the picker instances ...  But this will require a bit more
work.

Also added a notification when the user saves a palette.
Updated z-index of user-message container so that it is always above the
rest of the application.
This commit is contained in:
jdescottes
2014-03-30 22:42:28 +02:00
parent 3be4c78883
commit 090443c318
3 changed files with 35 additions and 34 deletions

View File

@@ -206,7 +206,7 @@ body {
border-bottom: 0;
font-weight: bold;
font-size: 13px;
z-index: 10000;
z-index: 30000;
max-width: 300px;
}