Ignore:
Timestamp:
Nov 30, 2013 7:30:44 PM (10 years ago)
Author:
anonymous
Message:

added public and private keywords to all properties and methods, changed old classname constructor function to construct, removed more ?> closing tags

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/eli_branch/lib/ImageThumb.inc.php

    r438 r439  
    4343   
    4444    // General object parameters.
    45     var $_params = array(
     45    private $_params = array(
    4646        // The location for images to create thumbnails from.
    4747        'source_dir' => null,
     
    7272   
    7373    // Default image size specs.
    74     var $_default_image_specs = array(
     74    private $_default_image_specs = array(
    7575        // The destination for an image thumbnail size.
    7676        // Use initial / to specify absolute paths, leave off to specify a path relative to source_dir (eg: ../thumbs).
     
    108108
    109109    // Final specifications for image sizes, set with setSpec().
    110     var $_image_specs = array();
     110    private $_image_specs = array();
    111111
    112112    /**
     
    116116     * @param  array    $params     Array of parameters (key => val pairs).
    117117     */
    118     function setParam($params)
     118    public function setParam($params)
    119119    {
    120120        $app =& App::getInstance();
     
    160160     * @return mixed               Configured parameter value.
    161161     */
    162     function getParam($param)
     162    public function getParam($param)
    163163    {
    164164        $app =& App::getInstance();
     
    180180     *                          Use to overwrite existing spec array values.
    181181     */
    182     function setSpec($spec, $index=null)
     182    public function setSpec($spec, $index=null)
    183183    {
    184184        $app =& App::getInstance();
     
    259259    * @since    08 May 2007 15:26:39
    260260    */
    261     function getSpec($key, $index=null)
     261    public function getSpec($key, $index=null)
    262262    {
    263263        $index = isset($index) ? $index : 0;
     
    271271     * @return  bool true on success, false on failure.
    272272     */
    273     function processAll($runtime_specs=null)
     273    public function processAll($runtime_specs=null)
    274274    {
    275275        $app =& App::getInstance();
     
    313313     * @return  bool true on success, false on failure.
    314314     */
    315     function processFile($file_name, $runtime_specs=null)
     315    public function processFile($file_name, $runtime_specs=null)
    316316    {
    317317        $app =& App::getInstance();
     
    452452    * @since    19 May 2006 13:55:46
    453453    */
    454     function _resizeWithNetpbm($source_file, $dest_file, $spec)
     454    private function _resizeWithNetpbm($source_file, $dest_file, $spec)
    455455    {
    456456        $app =& App::getInstance();
     
    521521    * @since    19 May 2006 15:46:02
    522522    */
    523     function _resizeWithGD($source_file, $dest_file, $spec)
     523    private function _resizeWithGD($source_file, $dest_file, $spec)
    524524    {
    525525        $app =& App::getInstance();
     
    662662     * @return  bool true on success, false on failure.
    663663     */
    664     function deleteThumbs($file_name, $use_glob=false)
     664    public function deleteThumbs($file_name, $use_glob=false)
    665665    {
    666666        $app =& App::getInstance();
     
    700700     * @return  bool true on success, false on failure.
    701701     */
    702     function deleteOriginal($file_name)
     702    public function deleteOriginal($file_name)
    703703    {
    704704        $app =& App::getInstance();
     
    733733     * @return  bool true on success, false on failure.
    734734     */
    735     function exists($file_name)
     735    public function exists($file_name)
    736736    {
    737737        $app =& App::getInstance();
     
    754754     * @return  bool    True on success, false on failure.
    755755     */
    756     function _validFileExtension($file_name)
     756    private function _validFileExtension($file_name)
    757757    {
    758758        preg_match('/.*?\.(\w+)$/i', $file_name, $ext);
     
    766766     * @return  bool true on success, false on failure.
    767767     */
    768     function _createDestDirs($filename=null)
     768    private function _createDestDirs($filename=null)
    769769    {
    770770        $app =& App::getInstance();
     
    844844     * @param string $line    __LINE__.
    845845     */
    846     function _raiseMsg($message, $type, $file, $line)
     846    private function _raiseMsg($message, $type, $file, $line)
    847847    {
    848848        $app =& App::getInstance();
     
    864864     * @since   15 Nov 2005 20:55:22
    865865     */
    866     function _glob($pattern, $directory)
     866    private function _glob($pattern, $directory)
    867867    {
    868868        $file_list = glob(sprintf('%s/%s', $directory, $pattern));
Note: See TracChangeset for help on using the changeset viewer.