Subversion Repositories Applications.papyrus

Rev

Rev 1688 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1688 Rev 1921
Line 1... Line 1...
1
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
1
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
2
<!--
2
<!--
3
 * FCKeditor - The text editor for internet
3
 * FCKeditor - The text editor for Internet - http://www.fckeditor.net
4
 * Copyright (C) 2003-2006 Frederico Caldeira Knabben
4
 * Copyright (C) 2003-2008 Frederico Caldeira Knabben
-
 
5
 *
-
 
6
 * == BEGIN LICENSE ==
5
 * 
7
 *
6
 * Licensed under the terms of the GNU Lesser General Public License:
8
 * Licensed under the terms of any of the following licenses at your
7
 * 		http://www.opensource.org/licenses/lgpl-license.php
9
 * choice:
8
 * 
10
 *
9
 * For further information visit:
11
 *  - GNU General Public License Version 2 or later (the "GPL")
10
 * 		http://www.fckeditor.net/
12
 *    http://www.gnu.org/licenses/gpl.html
11
 * 
13
 *
12
 * "Support Open Source software. What about a donation today?"
14
 *  - GNU Lesser General Public License Version 2.1 or later (the "LGPL")
-
 
15
 *    http://www.gnu.org/licenses/lgpl.html
13
 * 
16
 *
14
 * File Name: fck_button.html
17
 *  - Mozilla Public License Version 1.1 or later (the "MPL")
15
 * 	Button dialog window.
18
 *    http://www.mozilla.org/MPL/MPL-1.1.html
16
 * 
19
 *
17
 * File Authors:
20
 * == END LICENSE ==
-
 
21
 *
18
 * 		Frederico Caldeira Knabben (fredck@fckeditor.net)
22
 * Button dialog window.
19
-->
23
-->
20
<html xmlns="http://www.w3.org/1999/xhtml">
24
<html xmlns="http://www.w3.org/1999/xhtml">
21
<head>
25
<head>
22
	<title>Button Properties</title>
26
	<title>Button Properties</title>
23
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
27
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
24
	<meta content="noindex, nofollow" name="robots" />
28
	<meta content="noindex, nofollow" name="robots" />
25
	<script src="common/fck_dialog_common.js" type="text/javascript"></script>
29
	<script src="common/fck_dialog_common.js" type="text/javascript"></script>
26
	<script type="text/javascript">
30
	<script type="text/javascript">
Line -... Line 31...
-
 
31
 
27
 
32
var dialog	= window.parent ;
Line 28... Line 33...
28
var oEditor = window.parent.InnerDialogLoaded() ;
33
var oEditor	= dialog.InnerDialogLoaded() ;
29
 
34
 
Line 30... Line 35...
30
// Gets the document DOM
35
// Gets the document DOM
Line 31... Line 36...
31
var oDOM = oEditor.FCK.EditorDocument ;
36
var oDOM = oEditor.FCK.EditorDocument ;
32
 
37
 
33
var oActiveEl = oEditor.FCKSelection.GetSelectedElement() ;
38
var oActiveEl = dialog.Selection.GetSelectedElement() ;
34
 
39
 
Line 40... Line 45...
40
	if ( oActiveEl && oActiveEl.tagName.toUpperCase() == "INPUT" && ( oActiveEl.type == "button" || oActiveEl.type == "submit" || oActiveEl.type == "reset" ) )
45
	if ( oActiveEl && oActiveEl.tagName.toUpperCase() == "INPUT" && ( oActiveEl.type == "button" || oActiveEl.type == "submit" || oActiveEl.type == "reset" ) )
41
	{
46
	{
42
		GetE('txtName').value	= oActiveEl.name ;
47
		GetE('txtName').value	= oActiveEl.name ;
43
		GetE('txtValue').value	= oActiveEl.value ;
48
		GetE('txtValue').value	= oActiveEl.value ;
44
		GetE('txtType').value	= oActiveEl.type ;
49
		GetE('txtType').value	= oActiveEl.type ;
45
 
-
 
46
		GetE('txtType').disabled = true ;
-
 
47
	}
50
	}
48
	else
51
	else
49
		oActiveEl = null ;
52
		oActiveEl = null ;
Line 50... Line 53...
50
 
53
 
-
 
54
	dialog.SetOkButton( true ) ;
-
 
55
	dialog.SetAutoSize( true ) ;
51
	window.parent.SetOkButton( true ) ;
56
	SelectField( 'txtName' ) ;
Line 52... Line 57...
52
}
57
}
53
 
58
 
54
function Ok()
59
function Ok()
55
{
60
{
56
	if ( !oActiveEl )
61
	oEditor.FCKUndo.SaveUndoStep() ;
57
	{
-
 
58
		oActiveEl = oEditor.FCK.EditorDocument.createElement( 'INPUT' ) ;
-
 
59
		oActiveEl.type = GetE('txtType').value ;
-
 
Line 60... Line -...
60
		oActiveEl = oEditor.FCK.InsertElementAndGetIt( oActiveEl ) ;
-
 
61
	}
62
 
Line 62... Line 63...
62
 
63
	oActiveEl = CreateNamedElement( oEditor, oActiveEl, 'INPUT', {name: GetE('txtName').value, type: GetE('txtType').value } ) ;
63
	oActiveEl.name = GetE('txtName').value ;
64