In previous version #135 I used fixed height(435px) and width to set initial position of cropbox, which result in a problem that the cropbox contains image cannot be auto centred after other app calling displayImage method (see below).
This new version allows cropbox auto centred based on caller's brower size rather than fixed size but requires caller to pass two new parameters. Here is an example to call the new api:
Note that this changes the API of the images app, I suspect this will cause issues with scripting and possibly with other apps (e.g. PseudoCave implementation)
In previous version #135 I used fixed height(435px) and width to set initial position of cropbox, which result in a problem that the cropbox contains image cannot be auto centred after other app calling displayImage method (see below).
This new version allows cropbox auto centred based on caller's brower size rather than fixed size but requires caller to pass two new parameters. Here is an example to call the new api:
gdo.net.app["Images"].server.displayImage(instanceId, filename, 2, $("iframe")[0].contentWindow.width, $("iframe" [0].contentWindow.height);