Load Flash in Window

  1. #1

    Load Flash in Window



    I would you like if is possible open the flash(.swf) in <ext:Window>?
    The example attached.

    Thanks for attention!
  2. #2

    RE: Load Flash in Window

    Hi flaviodamaia,

    Can you add the flash object to the <Body> of the Window?


    Geoffrey McGill
    Founder
  3. #3

    RE: Load Flash in Window

    Hi,
    you can use a flash viewer control (FlashControl) to view your flash files. They have a professional edition which you have to purchase or use the free edition with minor limitations and works great, here is there website: http://www.flash-control.net/download.htm
    hope it helps.

    p.s.: this is not an ad or something, it's only for the sake of helping people.
  4. #4

    RE: Load Flash in Window



    Yes, I can. I found out the Ext.ux.FlashPlugin to use the the Flash on the window, but it doesn't work.

    - Ext.ux.FlashPlugin

    
    Ext.ux.FlashPlugin = function() {
        this.init = function(ct) {
            ct.flashTemplate = new Ext.XTemplate(
                '',
                '<object id="flash-{id}" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/s...ersion=6,0,0,0" width="{swfWidth}" height="{swfHeight}">',
                '<param name="movie" value="{swf}" />',
                '<param name="quality" value="high" />',
                '<param name="wmode" value="transparent" />',
                '<param name="flashvars" value="{computedflashvars}" />',
                '<param name="allowScriptAccess" value="domain" />',
                '<param name="align" value="t" />',
                '<param name="salign" value="TL" />',
                '<param name="swliveconnect" value="true" />',
                '<param name="scale" value="noscale" />',
                '<embed name="flash-{id}" src="{swf}" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" flashvars="{computedflashvars}" type="application/x-shockwave-flash" width="{swfWidth}" height="{swfHeight}" wmode="transparent" allowScriptAccess="always" swliveconnect="true" align="t" salign="TL" scale="noscale"></embed>',
                '</object>',
                '
    '
            );
            ct.flashTemplate.compile();
            ct.renderFlash = function() {
                if (this.flashvars &amp;&amp; (typeof this.flashvars == 'object')) {
                    var tempflashvars = Ext.apply({}, this.flashvars);
                    for (var key in tempflashvars) {
                        if (typeof tempflashvars[key] == 'function') {
                            tempflashvars[key] = tempflashvars[key].call(this, true);
                        } 
                    };
                    this.computedflashvars = Ext.urlEncode(tempflashvars);
                }
                this.swfHeight = this.body.getSize().height -2;
                this.swfWidth = this.body.getSize().width -2;
                if (this.body.first()) this.flashTemplate.overwrite(this.body.first(),this);
                else this.flashTemplate.insertFirst(this.body,this);
            };
            ct.loadFlash = function(config) {
                Ext.apply(this,config);
                this.renderFlash();
            };
            ct.on('afterlayout',ct.renderFlash, ct);
        };
    };
    Thanks for attention!
  5. #5

    RE: Load Flash in Window



    Yes, I can. I found out the Ext.ux.FlashPlugin to use the the Flash on the window, but it doesn't work.

    - Ext.ux.FlashPlugin

    
    Ext.ux.FlashPlugin = function() {
        this.init = function(ct) {
            ct.flashTemplate = new Ext.XTemplate(
                '',
                '<object id="flash-{id}" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/s...ersion=6,0,0,0" width="{swfWidth}" height="{swfHeight}">',
                '<param name="movie" value="{swf}" />',
                '<param name="quality" value="high" />',
                '<param name="wmode" value="transparent" />',
                '<param name="flashvars" value="{computedflashvars}" />',
                '<param name="allowScriptAccess" value="domain" />',
                '<param name="align" value="t" />',
                '<param name="salign" value="TL" />',
                '<param name="swliveconnect" value="true" />',
                '<param name="scale" value="noscale" />',
                '<embed name="flash-{id}" src="{swf}" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" flashvars="{computedflashvars}" type="application/x-shockwave-flash" width="{swfWidth}" height="{swfHeight}" wmode="transparent" allowScriptAccess="always" swliveconnect="true" align="t" salign="TL" scale="noscale"></embed>',
                '</object>',
                '
    '
            );
            ct.flashTemplate.compile();
            ct.renderFlash = function() {
                if (this.flashvars &amp;&amp; (typeof this.flashvars == 'object')) {
                    var tempflashvars = Ext.apply({}, this.flashvars);
                    for (var key in tempflashvars) {
                        if (typeof tempflashvars[key] == 'function') {
                            tempflashvars[key] = tempflashvars[key].call(this, true);
                        } 
                    };
                    this.computedflashvars = Ext.urlEncode(tempflashvars);
                }
                this.swfHeight = this.body.getSize().height -2;
                this.swfWidth = this.body.getSize().width -2;
                if (this.body.first()) this.flashTemplate.overwrite(this.body.first(),this);
                else this.flashTemplate.insertFirst(this.body,this);
            };
            ct.loadFlash = function(config) {
                Ext.apply(this,config);
                this.renderFlash();
            };
            ct.on('afterlayout',ct.renderFlash, ct);
        };
    };
    Thanks for attention!

Similar Threads

  1. Replies: 2
    Last Post: Oct 11, 2011, 1:15 PM
  2. Replies: 0
    Last Post: Oct 01, 2011, 3:51 PM
  3. [CLOSED] [1.0] Rendering Chart/Flash behind Model Window
    By ljankowski in forum 1.x Legacy Premium Help
    Replies: 7
    Last Post: Nov 08, 2010, 7:24 PM
  4. [CLOSED] [1.0] Load htmlEditor in window - autosize to fit in window
    By Patrick in forum 1.x Legacy Premium Help
    Replies: 0
    Last Post: Apr 23, 2010, 7:20 AM
  5. Load flash in the ext:Window
    By flaviodamaia in forum 1.x Help
    Replies: 1
    Last Post: Jun 01, 2009, 1:15 PM

Posting Permissions