Ignore:
Timestamp:
Jan 6, 2014, 4:41:55 PM (11 years ago)
Author:
mistic100
Message:

Update for Piwigo 2.6
TODO: button on Admin Tools bar

Location:
extensions/gvideo/include
Files:
1 deleted
1 moved

Legend:

Unmodified
Added
Removed
  • extensions/gvideo/include/events.inc.php

    r24342 r26470  
    11<?php
    2 if (!defined('GVIDEO_PATH')) die('Hacking attempt!');
     2defined('GVIDEO_PATH') or die('Hacking attempt!');
    33
    44/**
     
    1111    // remove default parser
    1212    remove_event_handler('render_element_content', 'default_picture_content', EVENT_HANDLER_PRIORITY_NEUTRAL);
    13  
    14     // remove autosize
    15     global $pwg_loaded_plugins, $autosize_ctrl;
    1613   
    17     if ( isset($pwg_loaded_plugins['Autosize']) and isset($autosize_ctrl) )
    18     {
    19       remove_event_handler('render_element_content', array(&$autosize_ctrl, 'autosize_calcContent'), EVENT_HANDLER_PRIORITY_NEUTRAL-11, 2);
    20       remove_event_handler('render_element_content', array(&$autosize_ctrl, 'init_1'), EVENT_HANDLER_PRIORITY_NEUTRAL-9, 2);
    21       remove_event_handler('render_element_content', array(&$autosize_ctrl, 'init'), EVENT_HANDLER_PRIORITY_NEUTRAL-1, 2);
    22       remove_event_handler('render_element_content', array(&$autosize_ctrl, 'init2'), EVENT_HANDLER_PRIORITY_NEUTRAL+1, 2);
    23       remove_event_handler('loc_after_page_header', array(&$autosize_ctrl, 'cl_autosize_script_1'));
    24       remove_event_handler('loc_after_page_header', array(&$autosize_ctrl, 'cl_autosize_script_2'));
    25       remove_event_handler('loc_after_page_header', array(&$autosize_ctrl, 'cl_autosize_script_3'));
    26       remove_event_handler('loc_after_page_header', array(&$autosize_ctrl, 'cl_autosize_affiche'), EVENT_HANDLER_PRIORITY_NEUTRAL+21);
    27     }
     14    // add custom parser
     15    add_event_handler('render_element_content', 'gvideo_element_content', EVENT_HANDLER_PRIORITY_NEUTRAL-10, 2);
    2816  }
    2917 
     
    4230 
    4331  global $page, $picture, $template, $conf;
    44  
    45   if (is_string($conf['gvideo']))
    46   {
    47     $conf['gvideo'] = unserialize($conf['gvideo']);
    48   }
    4932 
    5033  // remove some actions
     
    8972 
    9073  global $user;
     74  // hide stripped overlay preventing to click on video object
    9175  if (strpos('stripped', $user['theme']) !== false)
    9276  {
    93     $template->append('head_elements', '<style type="text/css">.hideTabs{display:none !important;}</style>');
     77    $template->block_html_style(null, '.hideTabs{ display:none !important; }');
    9478  }
    9579
     
    10993  pwg_query($query);
    11094}
    111 
    112 ?>
Note: See TracChangeset for help on using the changeset viewer.