Index: trunk/extensions/FlaggedRevs/FlaggedArticleView.php |
— | — | @@ -897,11 +897,11 @@ |
898 | 898 | return true; // simple custom levels set for action=protect |
899 | 899 | } |
900 | 900 | $title = $this->article->getTitle()->getSubjectPage(); |
901 | | - if ( !FlaggedRevs::isPageReviewable( $title ) ) { |
| 901 | + if( !FlaggedRevs::isPageReviewable( $title ) ) { |
902 | 902 | return true; // Only reviewable pages need these tabs |
903 | 903 | } |
904 | 904 | // Check if we should show a stabilization tab |
905 | | - if ( |
| 905 | + if( |
906 | 906 | !$skin->mTitle->isTalkPage() && |
907 | 907 | is_array( $actions ) && |
908 | 908 | !isset( $actions['protect'] ) && |
— | — | @@ -934,7 +934,7 @@ |
935 | 935 | $fa = FlaggedArticle::getTitleInstance( $title ); |
936 | 936 | |
937 | 937 | $action = $wgRequest->getVal( 'action', 'view' ); |
938 | | - if ( !$fa->isReviewable() || $fa->limitedUI() ) { |
| 938 | + if( !$fa->isReviewable() || $fa->limitedUI() ) { |
939 | 939 | return true; // Not a reviewable page or the UI is hidden |
940 | 940 | } |
941 | 941 | $flags = ($action == 'rollback') ? FR_MASTER : 0; |
— | — | @@ -944,25 +944,25 @@ |
945 | 945 | } |
946 | 946 | $synced = FlaggedRevs::stableVersionIsSynced( $srev, $fa ); |
947 | 947 | // Set draft tab as needed... |
948 | | - if ( !$skin->mTitle->isTalkPage() && !$synced ) { |
949 | | - if ( isset( $views['edit'] ) ) { |
950 | | - if ( $fa->showStableByDefault() ) { |
| 948 | + if( !$skin->mTitle->isTalkPage() && !$synced ) { |
| 949 | + if( isset( $views['edit'] ) ) { |
| 950 | + if( $fa->showStableByDefault() ) { |
951 | 951 | $views['edit']['text'] = wfMsg('revreview-edit'); |
952 | 952 | } |
953 | | - if ( $this->pageOverride() ) { |
| 953 | + if( $this->pageOverride() ) { |
954 | 954 | $views['edit']['href'] = $title->getLocalUrl( 'action=edit' ); |
955 | 955 | } |
956 | 956 | } |
957 | | - if ( isset( $views['viewsource'] ) ) { |
958 | | - if ( $fa->showStableByDefault() ) { |
| 957 | + if( isset( $views['viewsource'] ) ) { |
| 958 | + if( $fa->showStableByDefault() ) { |
959 | 959 | $views['viewsource']['text'] = wfMsg('revreview-source'); |
960 | 960 | } |
961 | | - if ( $this->pageOverride() ) { |
| 961 | + if( $this->pageOverride() ) { |
962 | 962 | $views['viewsource']['href'] = $title->getLocalUrl( 'action=edit' ); |
963 | 963 | } |
964 | 964 | } |
965 | 965 | } |
966 | | - if ( !FlaggedRevs::showVersionTabs() || $synced ) { |
| 966 | + if( !FlaggedRevs::showVersionTabs() || $synced ) { |
967 | 967 | // Exit, since either the stable/draft tabs should not be shown |
968 | 968 | // or the page is already the most current revision |
969 | 969 | return true; |
— | — | @@ -979,10 +979,10 @@ |
980 | 980 | 'class' => '' |
981 | 981 | ), |
982 | 982 | ); |
983 | | - if ( $this->pageOverride() || $wgRequest->getVal( 'stableid' ) ) { |
| 983 | + if( $this->pageOverride() || $wgRequest->getVal( 'stableid' ) ) { |
984 | 984 | // We are looking a the stable version |
985 | 985 | $tabs['stable']['class'] = 'selected'; |
986 | | - } elseif ( |
| 986 | + } elseif( |
987 | 987 | ( self::isViewAction( $action ) || $action == 'edit' ) && |
988 | 988 | !$skin->mTitle->isTalkPage() |
989 | 989 | ) { |