Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- From 95f7f98b42818866972e326ce92cb4c264afab50 Mon Sep 17 00:00:00 2001
- From: sy <sy@example.com>
- Date: Sun, 8 Sep 2013 17:49:14 +0900
- Subject: [PATCH] add ship_num,slotitem_num info
- ---
- chrome/chrome/content/libs.js | 8 ++++++++
- chrome/chrome/content/mainwindow.xul | 13 +++++++++++++
- chrome/chrome/content/sidebar.xul | 13 +++++++++++++
- 3 files changed, 34 insertions(+), 0 deletions(-)
- diff --git a/chrome/chrome/content/libs.js b/chrome/chrome/content/libs.js
- index cfae4bc..4721577 100644
- --- a/chrome/chrome/content/libs.js
- +++ b/chrome/chrome/content/libs.js
- @@ -176,6 +176,14 @@ function KanColleTimerCallback(request,s){
- let kdocks = document.getElementsByClassName("kdock-box");
- f( ndocks, parseInt(d.api_count_ndock) );
- f( kdocks, parseInt(d.api_count_kdock) );
- + }else if( url.match(/kcsapi\/api_get_member\/record/) ){
- + // 艦隊司令部情報
- + if( data.api_result==1){
- + var ship_str = data.api_data.api_ship[0] + "/"+ data.api_data.api_ship[1];
- + $('ship_num').value = ship_str;
- + var slotitem_str = data.api_data.api_slotitem[0] + "/"+ data.api_data.api_slotitem[1];
- + $('slotitem_num').value = slotitem_str;
- + }
- }
- }
- diff --git a/chrome/chrome/content/mainwindow.xul b/chrome/chrome/content/mainwindow.xul
- index a1cfda9..187a35c 100644
- --- a/chrome/chrome/content/mainwindow.xul
- +++ b/chrome/chrome/content/mainwindow.xul
- @@ -168,6 +168,19 @@
- <label id="kdockremain4" class="kdockremain" value=""/>
- </hbox>
- </groupbox>
- + <groupbox>
- + <caption>情報</caption>
- + <vbox>
- + <hbox>
- + <label value="艦娘数"/>
- + <label id="ship_num" value=""/>
- + </hbox>
- + <hbox>
- + <label value="装備アイテム数"/>
- + <label id="slotitem_num" value=""/>
- + </hbox>
- + </vbox>
- + </groupbox>
- <textbox id="log" placeholder="" multiline="true" flex="1" style="max-height:10em;"/>
- </vbox>
- </stack>
- diff --git a/chrome/chrome/content/sidebar.xul b/chrome/chrome/content/sidebar.xul
- index 265f55d..74dcd0b 100644
- --- a/chrome/chrome/content/sidebar.xul
- +++ b/chrome/chrome/content/sidebar.xul
- @@ -153,6 +153,19 @@
- <label id="kdockremain4" class="kdockremain" value=""/>
- </hbox>
- </groupbox>
- + <groupbox>
- + <caption>情報</caption>
- + <vbox>
- + <hbox>
- + <label value="艦娘数"/>
- + <label id="ship_num" value=""/>
- + </hbox>
- + <hbox>
- + <label value="装備アイテム数"/>
- + <label id="slotitem_num" value=""/>
- + </hbox>
- + </vbox>
- + </groupbox>
- <textbox id="log" placeholder="" multiline="true" flex="1" />
- </vbox>
- </stack>
- --
- 1.7.9
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement