OpenPKG CVS Repository
  http://cvs.openpkg.org/
  ____________________________________________________________________________

  Server: cvs.openpkg.org                  Name:   Ralf S. Engelschall
  Root:   /v/openpkg/cvs                   Email:  r...@openpkg.org
  Module: openpkg-src                      Date:   11-May-2009 22:30:19
  Branch: HEAD                             Handle: 2009051121301900

  Modified files:
    openpkg-src/drupal      drupal.patch

  Log:
    add shadowbox patch

  Summary:
    Revision    Changes     Path
    1.37        +39 -1      openpkg-src/drupal/drupal.patch
  ____________________________________________________________________________

  patch -p0 <<'@@ .'
  Index: openpkg-src/drupal/drupal.patch
  ============================================================================
  $ cvs diff -u -r1.36 -r1.37 drupal.patch
  --- openpkg-src/drupal/drupal.patch   19 Apr 2009 08:14:49 -0000      1.36
  +++ openpkg-src/drupal/drupal.patch   11 May 2009 20:30:19 -0000      1.37
  @@ -318,7 +318,7 @@
   --- /dev/null        2008-05-02 21:08:21 +0200
   +++ sites/all/modules/img_assist/img_assist_popup.js 2008-05-02 21:05:56 
+0200
   @@ -0,0 +1,20 @@
  -+/* $Id: drupal.patch,v 1.36 2009/04/19 08:14:49 rse Exp $ */
  ++/* $Id: drupal.patch,v 1.37 2009/05/11 20:30:19 rse Exp $ */
   +
   +function launch_popup(nid, mw, mh) {
   +    var ox = mw;
  @@ -763,3 +763,41 @@
      $channel['title'] = variable_get('site_name', 'Drupal') .' blogs';
      $channel['link'] = url('blog', array('absolute' => TRUE));
    
  +-----------------------------------------------------------------------------
  +
  +No need in SWF player if no according media selected.
  +http://drupal.org/node/437618http://drupal.org/node/437618
  +
  +Index: sites/all/modules/shadowbox/shadowbox.module
  +--- sites/all/modules/shadowbox/shadowbox.module.orig        2009-02-10 
18:08:54 +0100
  ++++ sites/all/modules/shadowbox/shadowbox.module     2009-05-11 22:23:03 
+0200
  +@@ -450,6 +450,7 @@
  +  * Validate admin settings form inputs.
  +  */
  + function shadowbox_global_settings_validate($form, &$form_state) {
  ++  $flv_formats = 
array_values($form_state['values']['shadowbox_supported_flv']);
  +   $flv_player = $form_state['values']['shadowbox_flv_player'];
  +   $color = $form_state['values']['shadowbox_overlay_color'];
  +   $opacity = $form_state['values']['shadowbox_overlay_opacity'];
  +@@ -462,13 +463,15 @@
  +   $initial_width = $form_state['values']['shadowbox_initial_width'];
  +   $counter_limit = $form_state['values']['shadowbox_counter_limit'];
  + 
  +-  if (!preg_match('!^([a-z0-9_\-\.]+/)*[a-z0-9_\-]+\.swf$!i', $flv_player)) 
{
  +-    form_set_error('shadowbox_flv_player', t('You must enter a valid path 
to an SWF Flash Player in the form <code>flvplayer.swf</code>.'));
  ++  if( sizeof(array_intersect($flv_formats, shadowbox_get_types('flv'))) != 
0){
  ++    if (!preg_match('!^([a-z0-9_\-\.]+/)*[a-z0-9_\-]+\.swf$!i', 
$flv_player)) {
  ++      form_set_error('shadowbox_flv_player', t('You must enter a valid path 
to an SWF Flash Player in the form <code>flvplayer.swf</code>.'));
  ++    }
  ++    elseif (!file_exists($flv_player)) {
  ++      form_set_error('shadowbox_flv_player', t('The FLV player does not 
exist.'));
  ++    }
  +   }
  +-  elseif (!file_exists($flv_player)) {
  +-    form_set_error('shadowbox_flv_player', t('The FLV player does not 
exist.'));
  +-  }
  +-
  ++  
  +   if (!is_numeric($resize_duration) || $resize_duration < 0 || 
$resize_duration > 10) {
  +     form_set_error('shadowbox_resize_duration', t('You must enter a number 
between 0 and 10.'));
  +   }
  @@ .
______________________________________________________________________
OpenPKG                                             http://openpkg.org
CVS Repository Commit List                     openpkg-cvs@openpkg.org

Reply via email to