protected $mHideBadImages;
/**
- * @var Parser Registered parser object for output callbacks
+ * @var Parser|false Registered parser object for output callbacks
*/
public $mParser;
/**
- * @var Title Contextual title, used when images are being screened against
+ * @var Title|null Contextual title, used when images are being screened against
* the bad image list
*/
- protected $contextTitle = false;
+ protected $contextTitle = null;
/** @var array */
protected $mAttribs = [];
- /** @var bool */
- private static $modeMapping = false;
+ /** @var int */
+ protected $mPerRow;
+
+ /** @var int */
+ protected $mWidths;
+
+ /** @var int */
+ protected $mHeights;
+
+ /** @var array */
+ private static $modeMapping;
/**
* Get a new image gallery. This is the method other callers
}
private static function loadModes() {
- if ( self::$modeMapping === false ) {
+ if ( self::$modeMapping === null ) {
self::$modeMapping = [
'traditional' => TraditionalImageGallery::class,
'nolines' => NolinesImageGallery::class,
/**
* Set the contextual title
*
- * @param Title $title Contextual title
+ * @param Title|null $title Contextual title
*/
public function setContextTitle( $title ) {
$this->contextTitle = $title;
/**
* Get the contextual title, if applicable
*
- * @return Title|bool Title or false
+ * @return Title|null
*/
public function getContextTitle() {
- return is_object( $this->contextTitle ) && $this->contextTitle instanceof Title
- ? $this->contextTitle
- : false;
+ return $this->contextTitle;
}
/**