projects
/
mkws-moved-to-github.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Remove duplicate
[mkws-moved-to-github.git]
/
src
/
mkws-team.js
diff --git
a/src/mkws-team.js
b/src/mkws-team.js
index
1ea6a63
..
0ddc962
100644
(file)
--- a/
src/mkws-team.js
+++ b/
src/mkws-team.js
@@
-744,7
+744,7
@@
function team($, teamName) {
that.addWidget = function(w) {
if (!m_widgets[w.type]) {
that.addWidget = function(w) {
if (!m_widgets[w.type]) {
- m_widgets[w.type] = widget;
+ m_widgets[w.type] = w;
log("Registered '" + w.type + "' widget in team '" + m_teamName + "'");
} else if (typeof(m_widgets[w.type]) !== 'number') {
m_widgets[w.type] = 2;
log("Registered '" + w.type + "' widget in team '" + m_teamName + "'");
} else if (typeof(m_widgets[w.type]) !== 'number') {
m_widgets[w.type] = 2;
@@
-755,7
+755,13
@@
function team($, teamName) {
}
}
}
}
- that.widget =function(type) {
+ that.widgetTypes = function() {
+ var keys = [];
+ for (var k in m_widgets) keys.push(k);
+ return keys.sort();
+ }
+
+ that.widget = function(type) {
return m_widgets[type];
}
return m_widgets[type];
}