Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
K
kityminder-core
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
吴志俊
kityminder-core
Commits
16a32b68
Commit
16a32b68
authored
Feb 20, 2014
by
campaign
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
by zhanyi
parent
afe603ba
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
21 additions
and
3 deletions
+21
-3
combobox.js
src/adapter/combobox.js
+4
-1
node.js
src/adapter/node.js
+9
-1
combobox.js
src/ui/combobox.js
+8
-1
No files found.
src/adapter/combobox.js
View file @
16a32b68
KM
.
registerToolbarUI
(
'layoutstyle fontfamily fontsize'
,
function
(
name
)
{
KM
.
registerToolbarUI
(
'layoutstyle fontfamily fontsize
inserttopic
'
,
function
(
name
)
{
var
me
=
this
,
label
=
me
.
getLang
(
'tooltips.'
+
name
),
...
...
@@ -30,6 +30,9 @@ KM.registerToolbarUI( 'layoutstyle fontfamily fontsize', function ( name ) {
case
'fontsize'
:
options
=
transForFontsize
(
options
);
break
;
case
'inserttopic'
:
optons
}
//实例化
...
...
src/adapter/node.js
View file @
16a32b68
...
...
@@ -33,6 +33,15 @@ KM.registerToolbarUI( 'node', function ( name ) {
if
(
$combox
.
parent
().
length
===
0
)
{
$combox
.
appendTo
(
me
.
$container
.
find
(
'.kmui-dialog-container'
)
);
}
var
combox
=
$combox
.
kmui
();
combox
.
traverseItems
(
function
(
label
,
value
){
if
(
me
.
queryCommandState
(
value
)
==
-
1
){
combox
.
disableItemByLabel
(
label
)
}
else
{
combox
.
enableItemByLabel
(
label
)
}
})
});
return
comboboxWidget
.
button
().
addClass
(
'kmui-combobox'
);
...
...
@@ -51,7 +60,6 @@ KM.registerToolbarUI( 'node', function ( name ) {
}
);
options
.
items
=
tempItems
;
return
options
;
}
...
...
src/ui/combobox.js
View file @
16a32b68
...
...
@@ -189,7 +189,14 @@
getItems
:
function
()
{
return
this
.
data
(
"options"
).
items
;
},
traverseItems
:
function
(
fn
){
var
values
=
this
.
data
(
'options'
).
value
;
var
labels
=
this
.
data
(
'options'
).
items
;
$
.
each
(
labels
,
function
(
i
,
label
){
fn
(
label
,
values
[
i
])
});
return
this
;
},
getItemMapping
:
function
()
{
return
this
.
data
(
"options"
).
itemMapping
;
},
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment