My proposed fix to bug 34987: gender not working in many special pages.
[lhc/web/wiklou.git] / includes / Message.php
index 3c5d5d7..73914d7 100644 (file)
@@ -90,8 +90,7 @@
  *         ->plain();
  * @endcode
  *
- * @note You cannot parse the text except in the content or interface
- * @note languages
+ * @note You can parse the text only in the content or interface languages
  *
  * @section message_compare_old Comparison with old wfMsg* functions:
  *
@@ -341,6 +340,18 @@ class Message {
                return $this;
        }
 
+       /**
+        * Allows manipulating the interface message flag directly.
+        * Can be used to restore the flag after setting a language.
+        * @param $value bool
+        * @return Message: $this
+        * @since 1.20
+        */
+       public function setInterfaceMessageFlag( $value ) {
+               $this->interface = (bool) $value;
+               return $this;
+       }
+
        /**
         * Enable or disable database use.
         * @param $value Boolean