Thread View: alt.pl.programy.flash-5
1 messages
1 total messages
Started by plex
Tue, 11 Mar 2008 13:26
component window - i combobox
Author: plex
Date: Tue, 11 Mar 2008 13:26
Date: Tue, 11 Mar 2008 13:26
48 lines
1957 bytes
1957 bytes
witam
mam taki problem
mam strone na w ktorej wywoluje component window
do niego wciagam plik swf ktory pobiera dane z pliku xml i umieszcza to
w comboboxie ktory steruje flvplayerem
problem...
sam plik z playerem dziala idealnie ale jak go wciagam do innego pliku
do komponentu window nie ma nic w comboboxie
-----------------------------------------
plik - video.fla
--
kod dla combobox:
on (change) {
this._parent.flvp.stop();
this._parent.flvp.contentPath = "videos/" + this.getValue();
this._parent.flvp.play();
trace (this.getValue());
}
--
kod dla calego pliku:
thisXML = new XML();
thisXML.ignoreWhite = true;
thisXML.onLoad = LoadCombo;
thisXML.load("videos.xml");
this.flvp.contentPath = "videos/1.flv";
function LoadCombo(success) {
if (success) {
var BaseNode=thisXML.childNodes[0];
var ComboVideos = new Array();
var ComboURLs = new Array();
var ThisNode;
for (i=0; i < BaseNode.childNodes.length; i++) {
ThisNode = BaseNode.childNodes[i];
ComboVideos[i] = ThisNode.attributes["videoOpis"];
ComboURLs[i] = ThisNode.attributes["videoLink"];
listaVideo.addItem(ComboVideos[i],ComboURLs[i]);
}
}
}
stop();
---------------------------
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads