[P2-php-svn] [886] expack:

Back to archive index

svnno****@sourc***** svnno****@sourc*****
2010年 8月 17日 (火) 16:37:40 JST


Revision: 886
          http://sourceforge.jp/projects/p2-php/svn/view?view=rev&revision=886
Author:   rsk
Date:     2010-08-17 16:37:40 +0900 (Tue, 17 Aug 2010)

Log Message:
-----------
expack:
- typoを修正。
- 新着まとめ読みツールバーの上方向移動先を「前のスレッドのフッタ」から
  「現在のスレッドのヘッダ」に変更。

Modified Paths:
--------------
    p2ex/trunk/js/iphone.js
    p2ex/trunk/read_new_k.php
    p2ex/trunk/spm_k.php


-------------- next part --------------
Modified: p2ex/trunk/js/iphone.js
===================================================================
--- p2ex/trunk/js/iphone.js	2010-08-16 23:11:02 UTC (rev 885)
+++ p2ex/trunk/js/iphone.js	2010-08-17 07:37:40 UTC (rev 886)
@@ -725,7 +725,13 @@
 	id = url.slice(offset + 1);
 	target = document.getElementById(id);
 	if (target) {
-		window.scrollTo(0, target.offsetTop + 1);
+		offset = target.offsetTop;
+		// 1‚‚¾‚¯ŠO‘¤‚Ì—v‘f‚àl—¶‚·‚é
+		if (target.offsetParent) {
+			offset += target.offsetParent.offsetTop;
+		}
+		// +1 ‚̓{[ƒ_[•
+		window.scrollTo(0, offset + 1);
 	}
 
 	return false;
@@ -1407,17 +1413,6 @@
 	} else if (!window.location.hash.length && iutil.getScrollY() < 1) {
 		window.scrollTo(0, 1);
 	}
-
-	// location.hash‚Ì‘ã‚í‚è‚Ép2s2=id‚ŃWƒƒƒ“ƒv‚·‚é
-	// p2s2 ‚Í re[p2] [s]croll[To] ‚Ì—ª
-	// ‚Ç‚¤‚µ‚Ä‚àƒXƒNƒ[ƒ‹‚³‚¹‚½‚¢ê‡‚¾‚¯Žg‚¤
-	var m = window.location.href.match(/[&?]p2s2=([\w\-].+)/);
-	if (m) {
-		var t = document.getElementById(m[1]);
-		if (t) {
-			window.setTimeout(window.scrollTo, 100, 0, t.offsetTop + 1);
-		}
-	}
 }, false);
 
 // }}}

Modified: p2ex/trunk/read_new_k.php
===================================================================
--- p2ex/trunk/read_new_k.php	2010-08-16 23:11:02 UTC (rev 885)
+++ p2ex/trunk/read_new_k.php	2010-08-17 07:37:40 UTC (rev 886)
@@ -458,7 +458,7 @@
 <h2 class="ttitle">{$aThread->ttitle_hd} {$read_header_itaj_ht}</h2>
 EOP;
         $read_header_ht .= '<div class="mover">';
-        $read_header_ht .= toolbar_i_standard_button('img/gp2-down.png', '', "#ntt_btt{$newthre_num}");
+        $read_header_ht .= toolbar_i_standard_button('img/gp2-down.png', '', sprintf('#ntt%d', $newthre_num + 1));
         $read_header_ht .= '</div>';
 
         $info_ht = P2Util::getInfoHtml();
@@ -534,7 +534,7 @@
         // ƒ^ƒCƒgƒ‹“™
         $read_footer_ht .= <<<EOP
 </tr></tbody></table>
-<div class="ttitle" id="ntt_btt{$newthre_num}"><a href="{$_conf['read_php']}?{$host_bbs_key_q}&amp;offline=1&amp;rescount={$aThread->rescount}{$_conf['k_at_a']}" target="_blank">{$aThread->ttitle_hd}</a> {$toolbar_itaj_ht}</div>
+<div class="ttitle"><a href="{$_conf['read_php']}?{$host_bbs_key_q}&amp;offline=1&amp;rescount={$aThread->rescount}{$_conf['k_at_a']}" target="_blank">{$aThread->ttitle_hd}</a> {$toolbar_itaj_ht}</div>
 <div class="mover">
 EOP;
         $read_footer_ht .= toolbar_i_standard_button('img/gp1-up.png', '', "#ntt{$newthre_num}");
@@ -613,7 +613,7 @@
         echo '<p class="empty">V’…ƒŒƒX‚Í‚È‚¢‚Û</p>';
     }
 
-    echo '<div class="ntoolbar" id="footer"><table><tbody><tr>';
+    echo "<div class=\"ntoolbar\" id=\"footer\"><table id=\"ntt{$newthre_num}\"><tbody><tr>";
 
     // ƒgƒbƒv‚É–ß‚é
     echo '<td>';

Modified: p2ex/trunk/spm_k.php
===================================================================
--- p2ex/trunk/spm_k.php	2010-08-16 23:11:02 UTC (rev 885)
+++ p2ex/trunk/spm_k.php	2010-08-17 07:37:40 UTC (rev 886)
@@ -16,7 +16,7 @@
     $base_dir_s = P2_BASE_DIR . DIRECTORY_SEPARATOR;
     switch ($_GET['ktool_name']) {
         case 'goto':
-            $_REQUEST['ls'] = $_GET['ls'] = spirntf('%d-%d', $ktv, $ktv + $_conf['mobile.rnum_range']);
+            $_REQUEST['ls'] = $_GET['ls'] = sprintf('%d-%d', $ktv, $ktv + $_conf['mobile.rnum_range']);
             include $base_dir_s . 'read.php';
             exit;
         case 'rref':



P2-php-svn メーリングリストの案内
Back to archive index