Revision: 43515
Author: aaron
Date: 2008-11-15 01:18:15 +0000 (Sat, 15 Nov 2008)
Log Message:
-----------
Revert r43514 and fix rev detail view. I'm about ready to throw all this
subpage param nonsense out the window...
Modified Paths:
--------------
trunk/extensions/CodeReview/CodeReview.php
trunk/extensions/CodeReview/CodeRevisionView.php
trunk/extensions/CodeReview/SpecialCode.php
Removed Paths:
-------------
trunk/extensions/CodeReview/CodePathRevListView.php
Deleted: trunk/extensions/CodeReview/CodePathRevListView.php
===================================================================
--- trunk/extensions/CodeReview/CodePathRevListView.php 2008-11-15 01:02:20 UTC
(rev 43514)
+++ trunk/extensions/CodeReview/CodePathRevListView.php 2008-11-15 01:18:15 UTC
(rev 43515)
@@ -1,45 +0,0 @@
-<?php
-
-// Special:Code/MediaWiki
-class CodePathRevListView extends CodeRevisionListView {
- function __construct( $repoName ) {
- parent::__construct( $repoName );
- }
-
- function execute() {
- global $wgOut;
- if( !$this->mRepo ) {
- $view = new CodeRepoListView();
- $view->execute();
- return;
- }
- // No path! Use regular lister!
- if( !$this->mPath ) {
- $view = new CodeRevisionListView(
$this->mRepo->getName() );
- $view->execute();
- return;
- }
- $this->showForm();
- // Path should have a bit of length...
- if( strlen($this->mPath) > 3 ) {
- $pager = $this->getPager();
- $wgOut->addHTML(
- $pager->getNavigationBar() .
- $pager->getLimitForm() .
- $pager->getBody() .
- $pager->getNavigationBar()
- );
- }
- }
-
- function getPager() {
- return new SvnPathRevTablePager( $this );
- }
-}
-
-// Pager for CodeRevisionListView
-class SvnPathRevTablePager extends SvnRevTablePager {
- function getTitle() {
- return SpecialPage::getTitleFor( 'Code',
$this->mRepo->getName() . '/path' );
- }
-}
Modified: trunk/extensions/CodeReview/CodeReview.php
===================================================================
--- trunk/extensions/CodeReview/CodeReview.php 2008-11-15 01:02:20 UTC (rev
43514)
+++ trunk/extensions/CodeReview/CodeReview.php 2008-11-15 01:18:15 UTC (rev
43515)
@@ -19,7 +19,7 @@
1) Find out what revisions exist
2) Get id/author/timestamp/notice basics
- 3) base path helps if available
+3) base path helps if available
4) get list of affected files
5) get diffs
@@ -54,7 +54,6 @@
$wgAutoloadClasses['CodeRevisionView'] = $dir . 'CodeRevisionView.php';
$wgAutoloadClasses['CodeAuthorListView'] = $dir . 'CodeAuthorListView.php';
$wgAutoloadClasses['CodeStatusListView'] = $dir . 'CodeStatusListView.php';
-$wgAutoloadClasses['CodePathRevListView'] = $dir . 'CodePathRevListView.php';
$wgAutoloadClasses['CodeTagListView'] = $dir . 'CodeTagListView.php';
$wgAutoloadClasses['CodeCommentsListView'] = $dir . 'CodeCommentsListView.php';
$wgAutoloadClasses['CodeComment'] = $dir . 'CodeComment.php';
Modified: trunk/extensions/CodeReview/CodeRevisionView.php
===================================================================
--- trunk/extensions/CodeReview/CodeRevisionView.php 2008-11-15 01:02:20 UTC
(rev 43514)
+++ trunk/extensions/CodeReview/CodeRevisionView.php 2008-11-15 01:18:15 UTC
(rev 43515)
@@ -10,10 +10,9 @@
$this->mRev = $this->mRepo ? $this->mRepo->getRevision( intval(
$rev ) ) : null;
$this->mPreviewText = false;
# URL params...
- $this->mAddTags = $this->splitTags( $wgRequest->getText(
'wpTag' ) );
- $this->mRemoveTags = $this->splitTags( $wgRequest->getText(
'wpRemoveTag' ) );
- $this->mStatus = $wgRequest->getText('wpStatus') ?
- $wgRequest->getText('wpStatus') :
$this->mRev->getStatus();
+ $this->mAddTags = $wgRequest->getText( 'wpTag' );
+ $this->mRemoveTags =$wgRequest->getText( 'wpRemoveTag' );
+ $this->mStatus = $wgRequest->getText('wpStatus');
$this->jumpToNext = $wgRequest->getCheck('wpSaveAndNext');
$this->mReplyTarget = $replyTarget ?
(int)$replyTarget : $wgRequest->getIntOrNull(
'wpParent' );
@@ -33,6 +32,9 @@
$view->execute();
return;
}
+ $this->mAddTags = $this->splitTags( $this->mAddTags );
+ $this->mRemoveTags = $this->splitTags( $this->mRemoveTags );
+ $this->mStatus = $this->mStatus ? $this->mStatus :
$this->mRev->getStatus();
$redirectOnPost = $this->checkPostings();
if( $redirectOnPost ) {
Modified: trunk/extensions/CodeReview/SpecialCode.php
===================================================================
--- trunk/extensions/CodeReview/SpecialCode.php 2008-11-15 01:02:20 UTC (rev
43514)
+++ trunk/extensions/CodeReview/SpecialCode.php 2008-11-15 01:18:15 UTC (rev
43515)
@@ -40,10 +40,7 @@
} elseif( $params[1] === 'comments' ) {
$view = new CodeCommentsListView(
$params[0] );
break;
- } elseif( $params[1] === 'path' ) {
- $view = new CodePathRevListView(
$params[0] );
- break;
- } else {
+ } else { // revision details
$view = new CodeRevisionView(
$params[0], $params[1] );
break;
}
_______________________________________________
MediaWiki-CVS mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs