| 1 |
/*======================================================================*//** |
|---|
| 2 |
* |
|---|
| 3 |
* �p�u���b�V���v���t�@�C���̏������� |
|---|
| 4 |
* |
|---|
| 5 |
* @author Copyright (c) 2007-2008 taka:nium, supported by Spark project. |
|---|
| 6 |
* @version 1.0.0 |
|---|
| 7 |
* @see http://www.libspark.org/ |
|---|
| 8 |
* |
|---|
| 9 |
* Developed by taka:nium |
|---|
| 10 |
* @see http://nium.jp/ |
|---|
| 11 |
* |
|---|
| 12 |
* Hosted by Spark project |
|---|
| 13 |
* @see http://www.libspark.org/ |
|---|
| 14 |
* |
|---|
| 15 |
* Licensed under the MIT License |
|---|
| 16 |
* |
|---|
| 17 |
* Copyright (c) 2007 taka:nium, supported by Spark project. |
|---|
| 18 |
* |
|---|
| 19 |
* Permission is hereby granted, free of charge, to any person obtaining a copy |
|---|
| 20 |
* of this software and associated documentation files (the "Software"), to deal |
|---|
| 21 |
* in the Software without restriction, including without limitation the rights |
|---|
| 22 |
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell |
|---|
| 23 |
* copies of the Software, and to permit persons to whom the Software is |
|---|
| 24 |
* furnished to do so, subject to the following conditions: |
|---|
| 25 |
* |
|---|
| 26 |
* The above copyright notice and this permission notice shall be included in |
|---|
| 27 |
* all copies or substantial portions of the Software. |
|---|
| 28 |
* |
|---|
| 29 |
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR |
|---|
| 30 |
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, |
|---|
| 31 |
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE |
|---|
| 32 |
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER |
|---|
| 33 |
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, |
|---|
| 34 |
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN |
|---|
| 35 |
* THE SOFTWARE. |
|---|
| 36 |
* |
|---|
| 37 |
*//*=======================================================================*/ |
|---|
| 38 |
|
|---|
| 39 |
/*======================================================================*//** |
|---|
| 40 |
* ���C��������`����*//*=======================================================================*/ |
|---|
| 41 |
( function() { |
|---|
| 42 |
var doc = fl.getDocumentDOM(); |
|---|
| 43 |
|
|---|
| 44 |
if ( !doc ) { return; } |
|---|
| 45 |
|
|---|
| 46 |
var profileURI = fl.configURI + "publish_profile.xml"; |
|---|
| 47 |
|
|---|
| 48 |
doc.exportPublishProfile( profileURI ); |
|---|
| 49 |
|
|---|
| 50 |
FLfile.write( profileURI, ( function() { |
|---|
| 51 |
var src = FLfile.read( profileURI ); |
|---|
| 52 |
var flashFileName = new RegExp( "<flashFileName>.*</flashFileName>", "g" ).exec( src ); |
|---|
| 53 |
return src |
|---|
| 54 |
.split( "<defaultNames>1</defaultNames>" ).join( "<defaultNames>0</defaultNames>" ) |
|---|
| 55 |
.split( "<flashDefaultName>1</flashDefaultName>" ).join( "<flashDefaultName>0</flashDefaultName>" ) |
|---|
| 56 |
.split( flashFileName ).join( "<flashFileName>swf/" + doc.name + "</flashFileName>" ) |
|---|
| 57 |
.split( ".fla" ).join( ".swf" ); |
|---|
| 58 |
} )() ); |
|---|
| 59 |
|
|---|
| 60 |
doc.importPublishProfile( profileURI ); |
|---|
| 61 |
|
|---|
| 62 |
FLfile.remove( profileURI ); |
|---|
| 63 |
} ).apply( this ); |
|---|
| 64 |
|
|---|
| 65 |
|
|---|
| 66 |
|
|---|
| 67 |
|
|---|
| 68 |
|
|---|
| 69 |
|
|---|
| 70 |
|
|---|
| 71 |
|
|---|
| 72 |
|
|---|
| 73 |
|
|---|
| 74 |
|
|---|