• R/O
  • HTTP
  • SSH
  • HTTPS

提交

標籤
無標籤

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

Commit MetaInfo

修訂bd6ce0d85d62e9a35d4db48039018cc2f047a29e (tree)
時間2012-09-12 20:56:04
作者angeart <angeart@git....>
Commiterangeart

Log Message

モデルリスト復活

Change Summary

差異

--- /dev/null
+++ b/client/bin/cards/modellist/main.js
@@ -0,0 +1,39 @@
1+
2+/***MetaData***
3+
4+{
5+ "name": "モデルリスト",
6+ "icon": "icon.png",
7+ "api_version": 1
8+}
9+
10+***MetaData***/
11+
12+var list;
13+list = new UI.List({
14+ docking: UI.DOCKING_TOP | UI.DOCKING_LEFT | UI.DOCKING_RIGHT | UI.DOCKING_BOTTOM
15+});
16+
17+var even_line = false;
18+var model_names = Model.all();
19+for (var i = 0; i < model_names.length; i++) {
20+ if ((/char:/).test(model_names[i])) {
21+ (function(model_name){
22+ list.addItem(
23+ new UI.Label({
24+ docking: UI.DOCKING_TOP | UI.DOCKING_LEFT | UI.DOCKING_RIGHT,
25+ text: model_name,
26+ bgcolor: ((even_line = !even_line) ? "#EEAFEECC" : "#FFFFFFCC"),
27+ onclick: function() {
28+ Account.updateModelName(model_name)
29+ }
30+ })
31+ );
32+ })(model_names[i])
33+ }
34+}
35+
36+Card.board.width = 240;
37+Card.board.height = 120;
38+Card.board.docking = UI.DOCKING_BOTTOM | UI.DOCKING_RIGHT
39+Card.board.addChild(list);
\ No newline at end of file