Thursday, July 21, 2011

Sencha - loading an image

- set an ID of Panel (e.g., PreviewPaneAI)
- set an ID of a sub-panel for an image (e.g., assetImageContainerAI),
and set a height properly.
- Send an image properly to a client from Phython,

- Use the following code for AIuserProject.js.
updatePreview: function(node) {
        var str='<img src="{img}" style="float: right;" height="100%" />';
        str = str.replace("{img}",node.attributes.thumbnailURL);
        panel = Ext.getCmp('assetImageContainerAI');
        panel.body.update(str);
}

No comments:

Post a Comment