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
d66cec03
Commit
d66cec03
authored
May 16, 2014
by
Akikonata
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixed icon bug
parent
eb7518f8
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
33 additions
and
27 deletions
+33
-27
markers.js
dialogs/markers/markers.js
+33
-27
No files found.
dialogs/markers/markers.js
View file @
d66cec03
(
function
(
utils
)
{
(
function
(
utils
)
{
KM
.
registerWidget
(
'markers'
,
{
KM
.
registerWidget
(
'markers'
,
{
tpl
:
"<style>"
+
tpl
:
"<style>"
+
".kmui-dialog-<%= container %> .priority .icon{background:url(dialogs/markers/images/iconpriority.png) 0 0}"
+
".kmui-dialog-<%= container %> .priority .icon{background:url(dialogs/markers/images/iconpriority.png) 0 0}"
+
".kmui-dialog-<%= container %> .progress .icon{background:url(dialogs/markers/images/iconprogress.png) 0 0}"
+
".kmui-dialog-<%= container %> .progress .icon{background:url(dialogs/markers/images/iconprogress.png) 0 0}"
+
...
@@ -22,37 +22,43 @@
...
@@ -22,37 +22,43 @@
"<li value='4' type='progress'><span class='icon p4'></span><span><%= progress.threequartersdone %></span></li>"
+
"<li value='4' type='progress'><span class='icon p4'></span><span><%= progress.threequartersdone %></span></li>"
+
"<li value='5' type='progress'><span class='icon p5'></span><span><%= progress.done %></span></li>"
+
"<li value='5' type='progress'><span class='icon p5'></span><span><%= progress.done %></span></li>"
+
"</ul>"
,
"</ul>"
,
initContent
:
function
(
km
,
$w
)
{
initContent
:
function
(
km
,
$w
)
{
var
lang
=
km
.
getLang
(
'dialogs.markers'
);
var
lang
=
km
.
getLang
(
'dialogs.markers'
);
if
(
lang
)
{
if
(
lang
)
{
var
html
=
$
.
parseTmpl
(
this
.
tpl
,
utils
.
extend
(
{
var
html
=
$
.
parseTmpl
(
this
.
tpl
,
utils
.
extend
(
{
'container'
:
'markers'
'container'
:
'markers'
},
lang
)
);
},
lang
)
);
}
}
this
.
root
().
html
(
html
);
this
.
root
().
html
(
html
);
var
valPri
=
km
.
queryCommandValue
(
"priority"
);
var
valPro
=
km
.
queryCommandValue
(
"progress"
);
$w
.
find
(
"li[type='priority']"
).
removeClass
(
"active"
);
$w
.
find
(
"li[type='priority'][value='"
+
valPri
+
"']"
).
addClass
(
"active"
);
$w
.
find
(
"li[type='progress']"
).
removeClass
(
"active"
);
$w
.
find
(
"li[type='progress'][value='"
+
valPro
+
"']"
).
addClass
(
"active"
);
},
},
initEvent
:
function
(
km
,
$w
)
{
initEvent
:
function
(
km
,
$w
)
{
$w
.
on
(
"click"
,
"li"
,
function
()
{
$w
.
on
(
"click"
,
"li"
,
function
()
{
var
$this
=
$
(
this
);
var
$this
=
$
(
this
);
$this
.
siblings
().
removeClass
(
"active"
);
$this
.
siblings
().
removeClass
(
"active"
);
$this
.
toggleClass
(
"active"
);
$this
.
toggleClass
(
"active"
);
var
val
=
$this
.
val
();
var
val
=
$this
.
val
();
if
(
!
$this
.
hasClass
(
"active"
)
)
{
if
(
!
$this
.
hasClass
(
"active"
)
)
{
val
=
null
;
val
=
null
;
}
}
var
type
=
$this
.
attr
(
"type"
);
var
type
=
$this
.
attr
(
"type"
);
km
.
execCommand
(
type
,
val
);
km
.
execCommand
(
type
,
val
);
}
);
});
km
.
on
(
'interactchange'
,
function
(
e
)
{
km
.
on
(
'interactchange'
,
function
(
e
)
{
var
valPri
=
this
.
queryCommandValue
(
"priority"
);
var
valPri
=
this
.
queryCommandValue
(
"priority"
);
var
valPro
=
this
.
queryCommandValue
(
"progress"
);
var
valPro
=
this
.
queryCommandValue
(
"progress"
);
$w
.
find
(
"li[type='priority']"
).
removeClass
(
"active"
);
$w
.
find
(
"li[type='priority']"
).
removeClass
(
"active"
);
$w
.
find
(
"li[type='priority'][value='"
+
valPri
+
"']"
).
addClass
(
"active"
);
$w
.
find
(
"li[type='priority'][value='"
+
valPri
+
"']"
).
addClass
(
"active"
);
$w
.
find
(
"li[type='progress']"
).
removeClass
(
"active"
);
$w
.
find
(
"li[type='progress']"
).
removeClass
(
"active"
);
$w
.
find
(
"li[type='progress'][value='"
+
valPro
+
"']"
).
addClass
(
"active"
);
$w
.
find
(
"li[type='progress'][value='"
+
valPro
+
"']"
).
addClass
(
"active"
);
}
);
});
},
},
width
:
200
width
:
200
}
)
})
}
)(
KM
.
Utils
);
})(
KM
.
Utils
);
\ No newline at end of file
\ No newline at end of file
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