# HG changeset patch # User Sebastien Jodogne # Date 1606499081 -3600 # Node ID ee2b5990dfff29afdc5840528a5f412b4ee88a07 # Parent 432172b49de4b807f7c256fa921fbfe635dffa70 remove annoying alert box in the server demo diff -r 432172b49de4 -r ee2b5990dfff Applications/StoneWebViewer/WebApplication/app.js --- a/Applications/StoneWebViewer/WebApplication/app.js Fri Nov 27 18:26:07 2020 +0100 +++ b/Applications/StoneWebViewer/WebApplication/app.js Fri Nov 27 18:44:41 2020 +0100 @@ -1072,7 +1072,8 @@ window.addEventListener('message', function(e) { - if ('type' in e.data) { + if ('type' in e.data && + (e.data.type == 'show-osirix-annotations')) { var expectedOrigin = app.globalConfiguration['ExpectedMessageOrigin']; if (expectedOrigin === undefined) { @@ -1092,8 +1093,8 @@ app.LoadOsiriXAnnotations(e.data.xml, clear); } - else { - alert('Unknown type of dynamic action in the Stone Web viewer: ' + e.data.type); - } + } + else { + console.log('Unknown type of dynamic action in the Stone Web viewer: ' + e.data.type); } });