Commit 16e4fe38 authored by Robert Lyon's avatar Robert Lyon Committed by Gerrit Code Review
Browse files

Error message fading too fast to read (bug 1246024)

The message was being removed due to the changes in this bug:
https://bugs.launchpad.net/mahara/+bug/1081309



Where the new message was been included in the cleanup of
old messages.

To test: add a creative commons block to page
- then try and add another. you will get the error message at top that
quickly fades away

With patch: the message should stay until you try to add block for
third time and the earlier message fades away

Change-Id: I298ba76d5f9696b3881d15868518f401236ac422
Signed-off-by: Robert Lyon's avatarRobert Lyon <robertl@catalyst.net.nz>
parent c306cc27
......@@ -141,11 +141,11 @@ function displayMessage(message, type, hideprevmsg) {
type = 'info';
}
var oldmessage = getFirstElementByTagAndClassName('div', null, 'messages');
var message = makeMessage(message, type);
appendChildNodes('messages', message);
if (typeof hideprevmsg === 'undefined' || hideprevmsg == true) {
var oldmessage = getFirstElementByTagAndClassName('div', null, 'messages');
if (oldmessage) {
fade(oldmessage, {afterFinish: partial(removeElement, oldmessage)});
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment