Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
qq_14980201
ueditor
提交
0b56d0f9
U
ueditor
项目概览
qq_14980201
/
ueditor
与 Fork 源项目一致
从无法访问的项目Fork
通知
3
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
U
ueditor
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
0b56d0f9
编写于
4月 26, 2013
作者:
H
hancong03
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
解决多实例编辑器下UI相互影响的BUG
Signed-off-by:
N
hancong03
<
121371790@qq.com
>
上级
1d5db78e
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
20 addition
and
9 deletion
+20
-9
_src/ui/autotypesetbutton.js
_src/ui/autotypesetbutton.js
+11
-3
_src/ui/autotypesetpicker.js
_src/ui/autotypesetpicker.js
+9
-6
未找到文件。
_src/ui/autotypesetbutton.js
浏览文件 @
0b56d0f9
...
...
@@ -15,13 +15,19 @@
function
getPara
(
me
){
var
opt
=
me
.
editor
.
options
.
autotypeset
,
cont
=
me
.
getDom
(),
editorId
=
me
.
editor
.
uid
,
inputType
=
null
,
attrName
=
null
,
ipts
=
domUtils
.
getElementsByTagName
(
cont
,
"
input
"
);
for
(
var
i
=
ipts
.
length
-
1
,
ipt
;
ipt
=
ipts
[
i
--
];){
if
(
ipt
.
getAttribute
(
"
type
"
)
==
"
checkbox
"
){
var
attrName
=
ipt
.
getAttribute
(
"
name
"
);
inputType
=
ipt
.
getAttribute
(
"
type
"
);
if
(
inputType
==
"
checkbox
"
){
attrName
=
ipt
.
getAttribute
(
"
name
"
);
opt
[
attrName
]
&&
delete
opt
[
attrName
];
if
(
ipt
.
checked
){
var
attrValue
=
document
.
getElementById
(
attrName
+
"
Value
"
);
var
attrValue
=
document
.
getElementById
(
attrName
+
"
Value
"
+
editorId
);
if
(
attrValue
){
if
(
/input/ig
.
test
(
attrValue
.
tagName
)){
opt
[
attrName
]
=
attrValue
.
value
;
...
...
@@ -45,6 +51,7 @@
var
attr
=
si
.
getAttribute
(
'
name
'
);
opt
[
attr
]
=
opt
[
attr
]
?
si
.
value
:
''
;
}
me
.
editor
.
options
.
autotypeset
=
opt
;
}
AutoTypeSetButton
.
prototype
=
{
...
...
@@ -70,6 +77,7 @@
if
(
flag
)
return
;
var
cont
=
this
.
getDom
(),
btn
=
cont
.
getElementsByTagName
(
'
button
'
)[
0
];
btn
.
onclick
=
function
(){
getPara
(
popupUI
);
me
.
editor
.
execCommand
(
'
autotypeset
'
);
...
...
_src/ui/autotypesetpicker.js
浏览文件 @
0b56d0f9
...
...
@@ -17,18 +17,21 @@
opt
=
me
.
options
.
autotypeset
,
lang
=
me
.
getLang
(
"
autoTypeSet
"
);
var
textAlignInputName
=
'
textAlignValue
'
+
me
.
uid
,
imageBlockInputName
=
'
imageBlockLineValue
'
+
me
.
uid
;
return
'
<div id="##" class="edui-autotypesetpicker %%">
'
+
'
<div class="edui-autotypesetpicker-body">
'
+
'
<table >
'
+
'
<tr><td nowrap colspan="2"><input type="checkbox" name="mergeEmptyline"
'
+
(
opt
[
"
mergeEmptyline
"
]
?
"
checked
"
:
""
)
+
'
>
'
+
lang
.
mergeLine
+
'
</td><td colspan="2"><input type="checkbox" name="removeEmptyline"
'
+
(
opt
[
"
removeEmptyline
"
]
?
"
checked
"
:
""
)
+
'
>
'
+
lang
.
delLine
+
'
</td></tr>
'
+
'
<tr><td nowrap colspan="2"><input type="checkbox" name="removeClass"
'
+
(
opt
[
"
removeClass
"
]
?
"
checked
"
:
""
)
+
'
>
'
+
lang
.
removeFormat
+
'
</td><td colspan="2"><input type="checkbox" name="indent"
'
+
(
opt
[
"
indent
"
]
?
"
checked
"
:
""
)
+
'
>
'
+
lang
.
indent
+
'
</td></tr>
'
+
'
<tr><td nowrap colspan="2"><input type="checkbox" name="textAlign"
'
+
(
opt
[
"
textAlign
"
]
?
"
checked
"
:
""
)
+
'
>
'
+
lang
.
alignment
+
'
</td><td colspan="2" id="
textAlignValue"><input type="radio" name="textAlignValue" value="left"
'
+
((
opt
[
"
textAlign
"
]
&&
opt
[
"
textAlign
"
]
==
"
left
"
)
?
"
checked
"
:
""
)
+
'
>
'
+
me
.
getLang
(
"
justifyleft
"
)
+
'
<input type="radio" name="textAlignValue" value="center"
'
+
((
opt
[
"
textAlign
"
]
&&
opt
[
"
textAlign
"
]
==
"
center
"
)
?
"
checked
"
:
""
)
+
'
>
'
+
me
.
getLang
(
"
justifycenter
"
)
+
'
<input type="radio" name="textAlignValue
" value="right"
'
+
((
opt
[
"
textAlign
"
]
&&
opt
[
"
textAlign
"
]
==
"
right
"
)
?
"
checked
"
:
""
)
+
'
>
'
+
me
.
getLang
(
"
justifyright
"
)
+
'
</tr>
'
+
'
<tr><td nowrap colspan="2"><input type="checkbox" name="textAlign"
'
+
(
opt
[
"
textAlign
"
]
?
"
checked
"
:
""
)
+
'
>
'
+
lang
.
alignment
+
'
</td><td colspan="2" id="
'
+
textAlignInputName
+
'
"><input type="radio" name="
'
+
textAlignInputName
+
'
" value="left"
'
+
((
opt
[
"
textAlign
"
]
&&
opt
[
"
textAlign
"
]
==
"
left
"
)
?
"
checked
"
:
""
)
+
'
>
'
+
me
.
getLang
(
"
justifyleft
"
)
+
'
<input type="radio" name="
'
+
textAlignInputName
+
'
" value="center"
'
+
((
opt
[
"
textAlign
"
]
&&
opt
[
"
textAlign
"
]
==
"
center
"
)
?
"
checked
"
:
""
)
+
'
>
'
+
me
.
getLang
(
"
justifycenter
"
)
+
'
<input type="radio" name="
'
+
textAlignInputName
+
'
" value="right"
'
+
((
opt
[
"
textAlign
"
]
&&
opt
[
"
textAlign
"
]
==
"
right
"
)
?
"
checked
"
:
""
)
+
'
>
'
+
me
.
getLang
(
"
justifyright
"
)
+
'
</tr>
'
+
'
<tr><td nowrap colspan="2"><input type="checkbox" name="imageBlockLine"
'
+
(
opt
[
"
imageBlockLine
"
]
?
"
checked
"
:
""
)
+
'
>
'
+
lang
.
imageFloat
+
'
</td>
'
+
'
<td nowrap colspan="2" id="
imageBlockLineValue
">
'
+
'
<input type="radio" name="
imageBlockLineValue
" value="none"
'
+
((
opt
[
"
imageBlockLine
"
]
&&
opt
[
"
imageBlockLine
"
]
==
"
none
"
)
?
"
checked
"
:
""
)
+
'
>
'
+
me
.
getLang
(
"
default
"
)
+
'
<input type="radio" name="
imageBlockLineValue
" value="left"
'
+
((
opt
[
"
imageBlockLine
"
]
&&
opt
[
"
imageBlockLine
"
]
==
"
left
"
)
?
"
checked
"
:
""
)
+
'
>
'
+
me
.
getLang
(
"
justifyleft
"
)
+
'
<input type="radio" name="
imageBlockLineValue
" value="center"
'
+
((
opt
[
"
imageBlockLine
"
]
&&
opt
[
"
imageBlockLine
"
]
==
"
center
"
)
?
"
checked
"
:
""
)
+
'
>
'
+
me
.
getLang
(
"
justifycenter
"
)
+
'
<input type="radio" name="
imageBlockLineValue
" value="right"
'
+
((
opt
[
"
imageBlockLine
"
]
&&
opt
[
"
imageBlockLine
"
]
==
"
right
"
)
?
"
checked
"
:
""
)
+
'
>
'
+
me
.
getLang
(
"
justifyright
"
)
+
'
</tr>
'
+
'
<td nowrap colspan="2" id="
'
+
imageBlockInputName
+
'
">
'
+
'
<input type="radio" name="
'
+
imageBlockInputName
+
'
" value="none"
'
+
((
opt
[
"
imageBlockLine
"
]
&&
opt
[
"
imageBlockLine
"
]
==
"
none
"
)
?
"
checked
"
:
""
)
+
'
>
'
+
me
.
getLang
(
"
default
"
)
+
'
<input type="radio" name="
'
+
imageBlockInputName
+
'
" value="left"
'
+
((
opt
[
"
imageBlockLine
"
]
&&
opt
[
"
imageBlockLine
"
]
==
"
left
"
)
?
"
checked
"
:
""
)
+
'
>
'
+
me
.
getLang
(
"
justifyleft
"
)
+
'
<input type="radio" name="
'
+
imageBlockInputName
+
'
" value="center"
'
+
((
opt
[
"
imageBlockLine
"
]
&&
opt
[
"
imageBlockLine
"
]
==
"
center
"
)
?
"
checked
"
:
""
)
+
'
>
'
+
me
.
getLang
(
"
justifycenter
"
)
+
'
<input type="radio" name="
'
+
imageBlockInputName
+
'
" value="right"
'
+
((
opt
[
"
imageBlockLine
"
]
&&
opt
[
"
imageBlockLine
"
]
==
"
right
"
)
?
"
checked
"
:
""
)
+
'
>
'
+
me
.
getLang
(
"
justifyright
"
)
+
'
</tr>
'
+
'
<tr><td nowrap colspan="2"><input type="checkbox" name="clearFontSize"
'
+
(
opt
[
"
clearFontSize
"
]
?
"
checked
"
:
""
)
+
'
>
'
+
lang
.
removeFontsize
+
'
</td><td colspan="2"><input type="checkbox" name="clearFontFamily"
'
+
(
opt
[
"
clearFontFamily
"
]
?
"
checked
"
:
""
)
+
'
>
'
+
lang
.
removeFontFamily
+
'
</td></tr>
'
+
'
<tr><td nowrap colspan="4"><input type="checkbox" name="removeEmptyNode"
'
+
(
opt
[
"
removeEmptyNode
"
]
?
"
checked
"
:
""
)
+
'
>
'
+
lang
.
removeHtml
+
'
</td></tr>
'
+
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录