forked from joomla/joomla-platform
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fixes and removed Old Combiner classes
- Loading branch information
1 parent
52ca108
commit e8bd348
Showing
6 changed files
with
644 additions
and
782 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,72 +1,72 @@ | ||
<?php | ||
/** | ||
* @package Joomla.Platform | ||
* @subpackage Media | ||
* | ||
* @copyright Copyright (C) 2005 - 2012 Open Source Matters, Inc. All rights reserved. | ||
* @license GNU General Public License version 2 or later; see LICENSE | ||
*/ | ||
|
||
defined('JPATH_PLATFORM') or die; | ||
|
||
/** | ||
* CSS combiner classes. | ||
* | ||
* @package Joomla.Platform | ||
* @subpackage Media | ||
* @since 12.1 | ||
*/ | ||
class JMediaCollectionCss extends JMediaCollection | ||
{ | ||
/** | ||
* Constructor | ||
* | ||
* @param Array $options options | ||
* | ||
* @since 12.1 | ||
*/ | ||
public function __construct($options = array()) | ||
{ | ||
$this->_options = array('COMPRESS' => false, 'FILE_COMMENTS' => true, 'COMPRESS_OPTIONS' => array()); | ||
parent::__construct($options); | ||
} | ||
|
||
/** | ||
* Method to combine a set of files and save to single file. | ||
* | ||
* @return Void | ||
* | ||
* @since 12.1 | ||
*/ | ||
public function combine() | ||
{ | ||
$this->combined = ''; | ||
|
||
foreach ($this->sources as $file) | ||
{ | ||
if ($this->_options['FILE_COMMENTS']) | ||
{ | ||
$this->combined .= '/** File : ' . JFile::getName($file) . ' : Start **/' . "\n\n"; | ||
} | ||
|
||
if ($this->_options['COMPRESS']) | ||
{ | ||
$this->_options['COMPRESS_OPTIONS']['type'] = 'css'; | ||
|
||
$this->combined .= JMediaCompressor::compressString(JFile::read($file), $this->_options['COMPRESS_OPTIONS']) . "\n\n"; | ||
} | ||
else | ||
{ | ||
$this->combined .= JFile::read($file) . "\n\n"; | ||
} | ||
|
||
if ($this->_options['FILE_COMMENTS']) | ||
{ | ||
$this->combined .= '/** File : ' . JFile::getName($file) . ' : End **/' . "\n\n"; | ||
} | ||
} | ||
|
||
$this->combined .= '/** ' . $this->sourceCount . ' css files are combined **/'; | ||
|
||
} | ||
} | ||
<?php | ||
/** | ||
* @package Joomla.Platform | ||
* @subpackage Media | ||
* | ||
* @copyright Copyright (C) 2005 - 2012 Open Source Matters, Inc. All rights reserved. | ||
* @license GNU General Public License version 2 or later; see LICENSE | ||
*/ | ||
|
||
defined('JPATH_PLATFORM') or die; | ||
|
||
/** | ||
* CSS combiner classes. | ||
* | ||
* @package Joomla.Platform | ||
* @subpackage Media | ||
* @since 12.1 | ||
*/ | ||
class JMediaCollectionCss extends JMediaCollection | ||
{ | ||
/** | ||
* Constructor | ||
* | ||
* @param Array $options options | ||
* | ||
* @since 12.1 | ||
*/ | ||
public function __construct($options = array()) | ||
{ | ||
$this->options = array('COMPRESS' => false, 'FILE_COMMENTS' => true, 'COMPRESS_OPTIONS' => array()); | ||
parent::__construct($options); | ||
} | ||
|
||
/** | ||
* Method to combine a set of files and save to single file. | ||
* | ||
* @return Void | ||
* | ||
* @since 12.1 | ||
*/ | ||
public function combine() | ||
{ | ||
$this->combined = ''; | ||
|
||
foreach ($this->sources as $file) | ||
{ | ||
if ($this->options['FILE_COMMENTS']) | ||
{ | ||
$this->combined .= '/** File : ' . JFile::getName($file) . ' : Start **/' . "\n\n"; | ||
} | ||
|
||
if ($this->options['COMPRESS']) | ||
{ | ||
$this->options['COMPRESS_OPTIONS']['type'] = 'css'; | ||
|
||
$this->combined .= JMediaCompressor::compressString(JFile::read($file), $this->options['COMPRESS_OPTIONS']) . "\n\n"; | ||
} | ||
else | ||
{ | ||
$this->combined .= JFile::read($file) . "\n\n"; | ||
} | ||
|
||
if ($this->options['FILE_COMMENTS']) | ||
{ | ||
$this->combined .= '/** File : ' . JFile::getName($file) . ' : End **/' . "\n\n"; | ||
} | ||
} | ||
|
||
$this->combined .= '/** ' . $this->sourceCount . ' css files are combined **/'; | ||
|
||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,72 +1,72 @@ | ||
<?php | ||
/** | ||
* @package Joomla.Platform | ||
* @subpackage Media | ||
* | ||
* @copyright Copyright (C) 2005 - 2012 Open Source Matters, Inc. All rights reserved. | ||
* @license GNU General Public License version 2 or later; see LICENSE | ||
*/ | ||
|
||
defined('JPATH_PLATFORM') or die; | ||
|
||
/** | ||
* Javascript combiner class. | ||
* | ||
* @package Joomla.Platform | ||
* @subpackage Compress | ||
* @since 12.1 | ||
*/ | ||
class JMediaCollectionJs extends JMediaCollection | ||
{ | ||
|
||
/** | ||
* Constructor | ||
* | ||
* @param Array $options options | ||
* | ||
* @since 12.1 | ||
*/ | ||
public function __construct($options = array()) | ||
{ | ||
$this->_options = array('COMPRESS' => false, 'FILE_COMMENTS' => true, 'COMPRESS_OPTIONS' => array()); | ||
parent::__construct($options); | ||
} | ||
|
||
/** | ||
* Method to combine a set of files and save to single file. | ||
* | ||
* @since 12.1 | ||
* | ||
* @return void | ||
*/ | ||
public function combine() | ||
{ | ||
$this->combined = ''; | ||
|
||
foreach ($this->sources as $file) | ||
{ | ||
if ($this->_options['FILE_COMMENTS']) | ||
{ | ||
$this->combined .= '/** File : ' . JFile::getName($file) . ' : Start **/' . "\n\n"; | ||
} | ||
|
||
if ($this->_options['COMPRESS']) | ||
{ | ||
$this->_options['COMPRESS_OPTIONS']['type'] = 'js'; | ||
|
||
$this->combined .= JMediaCompressor::compressString(JFile::read($file), $this->_options['COMPRESS_OPTIONS']) . "\n\n"; | ||
} | ||
else | ||
{ | ||
$this->combined .= JFile::read($file) . "\n\n"; | ||
} | ||
|
||
if ($this->_options['FILE_COMMENTS']) | ||
{ | ||
$this->combined .= '/** File : ' . JFile::getName($file) . ' : End **/' . "\n\n"; | ||
} | ||
} | ||
|
||
$this->combined .= '/** ' . $this->sourceCount . ' js files are combined **/'; | ||
} | ||
} | ||
<?php | ||
/** | ||
* @package Joomla.Platform | ||
* @subpackage Media | ||
* | ||
* @copyright Copyright (C) 2005 - 2012 Open Source Matters, Inc. All rights reserved. | ||
* @license GNU General Public License version 2 or later; see LICENSE | ||
*/ | ||
|
||
defined('JPATH_PLATFORM') or die; | ||
|
||
/** | ||
* Javascript combiner class. | ||
* | ||
* @package Joomla.Platform | ||
* @subpackage Compress | ||
* @since 12.1 | ||
*/ | ||
class JMediaCollectionJs extends JMediaCollection | ||
{ | ||
|
||
/** | ||
* Constructor | ||
* | ||
* @param Array $options options | ||
* | ||
* @since 12.1 | ||
*/ | ||
public function __construct($options = array()) | ||
{ | ||
$this->options = array('COMPRESS' => false, 'FILE_COMMENTS' => true, 'COMPRESS_OPTIONS' => array()); | ||
parent::__construct($options); | ||
} | ||
|
||
/** | ||
* Method to combine a set of files and save to single file. | ||
* | ||
* @since 12.1 | ||
* | ||
* @return void | ||
*/ | ||
public function combine() | ||
{ | ||
$this->combined = ''; | ||
|
||
foreach ($this->sources as $file) | ||
{ | ||
if ($this->options['FILE_COMMENTS']) | ||
{ | ||
$this->combined .= '/** File : ' . JFile::getName($file) . ' : Start **/' . "\n\n"; | ||
} | ||
|
||
if ($this->options['COMPRESS']) | ||
{ | ||
$this->options['COMPRESS_OPTIONS']['type'] = 'js'; | ||
|
||
$this->combined .= JMediaCompressor::compressString(JFile::read($file), $this->options['COMPRESS_OPTIONS']) . "\n\n"; | ||
} | ||
else | ||
{ | ||
$this->combined .= JFile::read($file) . "\n\n"; | ||
} | ||
|
||
if ($this->options['FILE_COMMENTS']) | ||
{ | ||
$this->combined .= '/** File : ' . JFile::getName($file) . ' : End **/' . "\n\n"; | ||
} | ||
} | ||
|
||
$this->combined .= '/** ' . $this->sourceCount . ' js files are combined **/'; | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.