Index: trunk/phase3/includes/EditPage.php |
— | — | @@ -55,7 +55,7 @@ |
56 | 56 | */ |
57 | 57 | var $mTitle; |
58 | 58 | private $mContextTitle = null; |
59 | | - var $action; |
| 59 | + var $action = 'submit'; |
60 | 60 | var $isConflict = false; |
61 | 61 | var $isCssJsSubpage = false; |
62 | 62 | var $isCssSubpage = false; |
— | — | @@ -96,15 +96,15 @@ |
97 | 97 | |
98 | 98 | # Placeholders for text injection by hooks (must be HTML) |
99 | 99 | # extensions should take care to _append_ to the present value |
100 | | - public $editFormPageTop; // Before even the preview |
101 | | - public $editFormTextTop; |
102 | | - public $editFormTextBeforeContent; |
103 | | - public $editFormTextAfterWarn; |
104 | | - public $editFormTextAfterTools; |
105 | | - public $editFormTextBottom; |
106 | | - public $editFormTextAfterContent; |
107 | | - public $previewTextAfterContent; |
108 | | - public $mPreloadText; |
| 100 | + public $editFormPageTop = ''; // Before even the preview |
| 101 | + public $editFormTextTop = ''; |
| 102 | + public $editFormTextBeforeContent = ''; |
| 103 | + public $editFormTextAfterWarn = ''; |
| 104 | + public $editFormTextAfterTools = ''; |
| 105 | + public $editFormTextBottom = ''; |
| 106 | + public $editFormTextAfterContent = ''; |
| 107 | + public $previewTextAfterContent = ''; |
| 108 | + public $mPreloadText = ''; |
109 | 109 | |
110 | 110 | /* $didSave should be set to true whenever an article was succesfully altered. */ |
111 | 111 | public $didSave = false; |
— | — | @@ -116,31 +116,27 @@ |
117 | 117 | * @todo document |
118 | 118 | * @param $article Article |
119 | 119 | */ |
120 | | - function __construct( $article ) { |
121 | | - $this->mArticle =& $article; |
| 120 | + public function __construct( $article ) { |
| 121 | + $this->mArticle = $article; |
122 | 122 | $this->mTitle = $article->getTitle(); |
123 | | - $this->action = 'submit'; |
124 | | - |
125 | | - # Placeholders for text injection by hooks (empty per default) |
126 | | - $this->editFormPageTop = |
127 | | - $this->editFormTextTop = |
128 | | - $this->editFormTextBeforeContent = |
129 | | - $this->editFormTextAfterWarn = |
130 | | - $this->editFormTextAfterTools = |
131 | | - $this->editFormTextBottom = |
132 | | - $this->editFormTextAfterContent = |
133 | | - $this->previewTextAfterContent = |
134 | | - $this->mPreloadText = ""; |
135 | 123 | } |
136 | 124 | |
137 | 125 | /** |
138 | 126 | * @return Article |
139 | 127 | */ |
140 | | - function getArticle() { |
| 128 | + public function getArticle() { |
141 | 129 | return $this->mArticle; |
142 | 130 | } |
143 | 131 | |
144 | 132 | /** |
| 133 | + * @since 1.19 |
| 134 | + * @return Title |
| 135 | + */ |
| 136 | + public function getTitle() { |
| 137 | + return $this->mTitle; |
| 138 | + } |
| 139 | + |
| 140 | + /** |
145 | 141 | * Set the context Title object |
146 | 142 | * |
147 | 143 | * @param $title Title object or null |