NextBits_BannerNext - Version 1.0.8

Version Notes

1.0.8
-added feature for background management

1.0.7
-removed unwanted code.
-fixed upload error for Magento Version < 1.5.1.0

1.0.6
-minor text changes

1.0.5
-fixed compilation issue
-added files in base for easy installation
-fixed image sorting and excluding bug

Download this release

Release Info

Developer NextBits Web Solutions Pvt. Ltd.
Extension NextBits_BannerNext
Version 1.0.8
Comparing to
See all releases


Code changes from version 1.0.7 to 1.0.8

Files changed (26) hide show
  1. app/code/local/NextBits/BannerNext/Block/Adminhtml/Bannernext/Edit/Tab/Form.php +1 -1
  2. app/code/local/NextBits/BannerNext/Block/Adminhtml/Bannernext/Edit/Tab/Gallery.php +29 -16
  3. app/code/local/NextBits/BannerNext/Block/Banner.php +37 -3
  4. app/code/local/NextBits/BannerNext/Helper/Data.php +1 -1
  5. app/code/local/NextBits/BannerNext/Model/Config/Source/Page.php +4 -0
  6. app/code/local/NextBits/BannerNext/Model/Config/Source/Position.php +3 -1
  7. app/code/local/NextBits/BannerNext/etc/system.xml +1 -31
  8. app/design/frontend/base/default/layout/bannernext.xml +6 -0
  9. app/design/frontend/base/default/template/bannernext/background.phtml +64 -0
  10. app/design/frontend/default/default/layout/bannernext.xml +6 -0
  11. app/design/frontend/default/default/template/bannernext/background.phtml +64 -0
  12. package.xml +8 -5
  13. skin/frontend/default/default/bannernext/supersized/css/supersized.core.css +23 -0
  14. skin/frontend/default/default/bannernext/supersized/css/supersized.css +30 -0
  15. skin/frontend/default/default/bannernext/supersized/img/bg-black.png +0 -0
  16. skin/frontend/default/default/bannernext/supersized/img/progress.gif +0 -0
  17. skin/frontend/default/default/bannernext/supersized/img/supersized-logo.png +0 -0
  18. skin/frontend/default/default/bannernext/supersized/js/jquery.easing.min.js +71 -0
  19. skin/frontend/default/default/bannernext/supersized/js/supersized.3.2.6.min.js +13 -0
  20. skin/frontend/default/default/bannernext/supersized/js/supersized.3.2.7.js +931 -0
  21. skin/frontend/default/default/bannernext/supersized/js/supersized.3.2.7.min.js +11 -0
  22. skin/frontend/default/default/bannernext/supersized/js/supersized.core.3.2.1.js +304 -0
  23. skin/frontend/default/default/bannernext/supersized/js/supersized.core.3.2.1.min.js +13 -0
  24. skin/frontend/default/default/bannernext/supersized/theme/supersized.shutter.css +74 -0
  25. skin/frontend/default/default/bannernext/supersized/theme/supersized.shutter.js +337 -0
  26. skin/frontend/default/default/bannernext/supersized/theme/supersized.shutter.min.js +14 -0
app/code/local/NextBits/BannerNext/Block/Adminhtml/Bannernext/Edit/Tab/Form.php CHANGED
@@ -33,7 +33,7 @@ class NextBits_BannerNext_Block_Adminhtml_Bannernext_Edit_Tab_Form extends Mage_
33
  'required' => false,
34
  'name' => 'height',
35
  'class' =>'validate-number',
36
- 'note' =>'E.g you want to width 100px then need to only 100 into textbox'
37
  ));
38
 
39
  $fieldset->addField('width', 'text', array(
33
  'required' => false,
34
  'name' => 'height',
35
  'class' =>'validate-number',
36
+ 'note' =>'E.g you want to height 100px then need to only 100 into textbox'
37
  ));
38
 
39
  $fieldset->addField('width', 'text', array(
app/code/local/NextBits/BannerNext/Block/Adminhtml/Bannernext/Edit/Tab/Gallery.php CHANGED
@@ -63,28 +63,41 @@ class NextBits_BannerNext_Block_Adminhtml_Bannernext_Edit_Tab_Gallery extends Ma
63
  );
64
  }
65
 
66
- public function getImagesJson()
67
  {
68
  $model = Mage::registry('bannernext_data');
69
  if(isset($model['content']) && !empty($model['content'])){
70
  return $model->getData('content');
71
  }
72
- return '[]';
73
-
74
-
75
- /* if(is_array($this->getElement()->getValue())) {
76
- $value = $this->getElement()->getValue();
77
- if(count($value['images'])>0) {
78
- foreach ($value['images'] as &$image) {
79
- $image['url'] = Mage::getSingleton('catalog/product_media_config')
80
- ->getMediaUrl($image['file']);
81
- }
82
- return Mage::helper('core')->jsonEncode($value['images']);
83
- }
84
- }
85
- return '[]'; */
 
86
  }
87
-
 
 
 
 
 
 
 
 
 
 
 
 
88
  public function getImagesValuesJson()
89
  {
90
  $values = array();
63
  );
64
  }
65
 
66
+ /* public function getImagesJson()
67
  {
68
  $model = Mage::registry('bannernext_data');
69
  if(isset($model['content']) && !empty($model['content'])){
70
  return $model->getData('content');
71
  }
72
+ return '[]';
73
+ } */
74
+
75
+ public function getImagesJson()
76
+ {
77
+ $model = Mage::registry('bannernext_data');
78
+ if(isset($model['content']) && !empty($model['content'])){
79
+ $content = Mage::helper('core')->jsonDecode($model->getData('content'));
80
+ $this->aasort($content,"position");
81
+ $content = Mage::helper('core')->jsonEncode($content);
82
+ Mage::log($content,'7','77.log');
83
+ return $content;
84
+ //return $model->getData('content');
85
+ }
86
+ return '[]';
87
  }
88
+ function aasort (&$array, $key) {
89
+ $sorter = array();
90
+ $ret = array();
91
+ reset($array);
92
+ foreach ($array as $ii => $va) {
93
+ $sorter[$ii]=$va[$key];
94
+ }
95
+ asort($sorter);
96
+ foreach ($sorter as $ii => $va) {
97
+ $ret[]=$array[$ii];
98
+ }
99
+ $array = $ret;
100
+ }
101
  public function getImagesValuesJson()
102
  {
103
  $values = array();
app/code/local/NextBits/BannerNext/Block/Banner.php CHANGED
@@ -6,6 +6,7 @@ class NextBits_BannerNext_Block_Banner extends Mage_Core_Block_Template
6
  protected $_collection;
7
 
8
  protected function _getCollection($position = null) {
 
9
  $enabled = Mage::getStoreConfig('bannernext/general/active');
10
  if($enabled){
11
  /* if ($this->_collection ){
@@ -18,6 +19,19 @@ class NextBits_BannerNext_Block_Banner extends Mage_Core_Block_Template
18
  $this->_collection->addStoreFilter($storeId);
19
  }
20
 
 
 
 
 
 
 
 
 
 
 
 
 
 
21
  if (Mage::registry('current_category')) {
22
  $_categoryId = Mage::registry('current_category')->getId();
23
  $this->_collection->addCategoryFilter($_categoryId);
@@ -38,9 +52,29 @@ class NextBits_BannerNext_Block_Banner extends Mage_Core_Block_Template
38
  print_R($this->_collection->getData());
39
  echo "</pre>"; */
40
  //Mage::registry('banner_collection',$this->_collection);
41
- return $this->_collection;
42
- }else
43
- {
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
44
  return '';
45
  }
46
  }
6
  protected $_collection;
7
 
8
  protected function _getCollection($position = null) {
9
+ $position = $this->getData('position');
10
  $enabled = Mage::getStoreConfig('bannernext/general/active');
11
  if($enabled){
12
  /* if ($this->_collection ){
19
  $this->_collection->addStoreFilter($storeId);
20
  }
21
 
22
+ $origColl = Mage::getModel('bannernext/bannernext')->getCollection()
23
+ ->addEnableFilter($this->_isActive);
24
+ if (!Mage::app()->isSingleStoreMode()) {
25
+ $origColl->addStoreFilter($storeId);
26
+ }
27
+
28
+ $origColl2 = Mage::getModel('bannernext/bannernext')->getCollection()
29
+ ->addEnableFilter($this->_isActive);
30
+ if (!Mage::app()->isSingleStoreMode()) {
31
+ $origColl2->addStoreFilter($storeId);
32
+ }
33
+
34
+
35
  if (Mage::registry('current_category')) {
36
  $_categoryId = Mage::registry('current_category')->getId();
37
  $this->_collection->addCategoryFilter($_categoryId);
52
  print_R($this->_collection->getData());
53
  echo "</pre>"; */
54
  //Mage::registry('banner_collection',$this->_collection);
55
+
56
+ if($position=='BODY_BACKGROUND'){
57
+
58
+
59
+ if (Mage::registry('current_category')) {
60
+ $_categoryId = Mage::registry('current_category')->getId();
61
+ $origColl->addCategoryFilter($_categoryId);
62
+ } elseif (Mage::app()->getFrontController()->getRequest()->getRouteName() == 'cms') {
63
+ $_pageId = Mage::getBlockSingleton('cms/page')->getPage()->getPageId();
64
+ $origColl->addPageFilter($_pageId);
65
+ }
66
+ $origColl->addPositionFilter('BODY_BACKGROUND');
67
+ $coll = $origColl->getData();
68
+
69
+ if(empty($coll)){
70
+ $origColl2->addPageFilter('9999999');
71
+ return $origColl2;
72
+ }
73
+ return $origColl;
74
+
75
+ }
76
+ return $this->_collection;
77
+ }else{
78
  return '';
79
  }
80
  }
app/code/local/NextBits/BannerNext/Helper/Data.php CHANGED
@@ -68,7 +68,7 @@ class NextBits_BannerNext_Helper_Data extends Mage_Core_Helper_Abstract
68
  return Mage::getStoreConfig(self::XML_CONFIG_PATH . $key, $store = '');
69
  }
70
 
71
- public function resizeImg($fileName,$width,$height='')
72
  {
73
  $baseURL = Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_MEDIA);
74
  $imageURL = $baseURL .'/'.'bannernext'.'/'.$fileName;
68
  return Mage::getStoreConfig(self::XML_CONFIG_PATH . $key, $store = '');
69
  }
70
 
71
+ public function resizeImg($fileName,$width='',$height='')
72
  {
73
  $baseURL = Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_MEDIA);
74
  $imageURL = $baseURL .'/'.'bannernext'.'/'.$fileName;
app/code/local/NextBits/BannerNext/Model/Config/Source/Page.php CHANGED
@@ -14,6 +14,10 @@ class NextBits_BannerNext_Model_Config_Source_Page
14
  'value' =>'',
15
  'label' =>'',
16
  );
 
 
 
 
17
  foreach ($_collection as $item) {
18
  $data = array(
19
  'value' => $item->getData('page_id'),
14
  'value' =>'',
15
  'label' =>'',
16
  );
17
+ $_result[] =array(
18
+ 'value' => '9999999',
19
+ 'label' => 'All Pages => For Background Position only',
20
+ );
21
  foreach ($_collection as $item) {
22
  $data = array(
23
  'value' => $item->getData('page_id'),
app/code/local/NextBits/BannerNext/Model/Config/Source/Position.php CHANGED
@@ -4,6 +4,7 @@ class NextBits_BannerNext_Model_Config_Source_Position
4
  const CONTENT_TOP = 'CONTENT_TOP';
5
  const CONTENT_BOTTOM = 'CONTENT_BOTTOM';
6
  const CONTENT_WIDGET = 'CONTENT_WIDGET';
 
7
 
8
  /**
9
  * Options getter
@@ -15,7 +16,8 @@ class NextBits_BannerNext_Model_Config_Source_Position
15
  return array(
16
  array('value' => self::CONTENT_TOP, 'label'=>Mage::helper('adminhtml')->__('Content Top')),
17
  array('value' => self::CONTENT_BOTTOM, 'label'=>Mage::helper('adminhtml')->__('Content Bottom')),
18
- array('value' => self::CONTENT_WIDGET, 'label'=>Mage::helper('adminhtml')->__('Anywhere by CMS Widget'))
 
19
  );
20
  }
21
  }
4
  const CONTENT_TOP = 'CONTENT_TOP';
5
  const CONTENT_BOTTOM = 'CONTENT_BOTTOM';
6
  const CONTENT_WIDGET = 'CONTENT_WIDGET';
7
+ const BODY_BACKGROUND = 'BODY_BACKGROUND';
8
 
9
  /**
10
  * Options getter
16
  return array(
17
  array('value' => self::CONTENT_TOP, 'label'=>Mage::helper('adminhtml')->__('Content Top')),
18
  array('value' => self::CONTENT_BOTTOM, 'label'=>Mage::helper('adminhtml')->__('Content Bottom')),
19
+ array('value' => self::CONTENT_WIDGET, 'label'=>Mage::helper('adminhtml')->__('Anywhere by CMS Widget')),
20
+ array('value' => self::BODY_BACKGROUND, 'label'=>Mage::helper('adminhtml')->__('Page Background'))
21
  );
22
  }
23
  }
app/code/local/NextBits/BannerNext/etc/system.xml CHANGED
@@ -55,36 +55,6 @@
55
  </fields>
56
  </general>
57
  </groups>
58
- </bannernext>
59
- <!-- <license module="bannernext">
60
- <label>License Manager</label>
61
- <tab>NextBits_Extensions</tab>
62
- <frontend_type>text</frontend_type>
63
- <sort_order>10</sort_order>
64
- <show_in_default>1</show_in_default>
65
- <show_in_website>1</show_in_website>
66
- <show_in_store>1</show_in_store>
67
- <groups>
68
- <bannernext_license translate="label">
69
- <label>Banner Next License</label>
70
- <frontend_type>text</frontend_type>
71
- <sort_order>0</sort_order>
72
- <show_in_default>1</show_in_default>
73
- <show_in_website>1</show_in_website>
74
- <show_in_store>1</show_in_store>
75
- <fields>
76
- <domains translate="label">
77
- <frontend_type>text</frontend_type>
78
- <frontend_model>NextBits_Nbcore_Block_Adminhtml_System_Config_Form_Multiline</frontend_model>
79
- <backend_model>NextBits_Nbcore_Model_System_Config_Backend_License</backend_model>
80
- <sort_order>1</sort_order>
81
- <show_in_default>1</show_in_default>
82
- <show_in_website>0</show_in_website>
83
- <show_in_store>0</show_in_store>
84
- </domains>
85
- </fields>
86
- </bannernext_license>
87
- </groups>
88
- </license> -->
89
  </sections>
90
  </config>
55
  </fields>
56
  </general>
57
  </groups>
58
+ </bannernext>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
59
  </sections>
60
  </config>
app/design/frontend/base/default/layout/bannernext.xml CHANGED
@@ -7,6 +7,12 @@
7
  <block type="bannernext/banner" name="bannernext_content_bottom" template="bannernext/banner.phtml" after="-" >
8
  <action method="setPosition"><name>CONTENT_BOTTOM</name></action>
9
  </block>
 
 
 
 
 
 
10
  </default>
11
  <cms_page>
12
  <reference name="content">
7
  <block type="bannernext/banner" name="bannernext_content_bottom" template="bannernext/banner.phtml" after="-" >
8
  <action method="setPosition"><name>CONTENT_BOTTOM</name></action>
9
  </block>
10
+ <block type="bannernext/banner" name="bannernext_content_background" template="bannernext/background.phtml" after="-" >
11
+ <action method="setPosition"><name>BODY_BACKGROUND</name></action>
12
+ </block>
13
+ <reference name="head">
14
+ <action method="insert" ifconfig="bannernext/general/active"><block>bannernext_content_background</block></action>
15
+ </reference>
16
  </default>
17
  <cms_page>
18
  <reference name="content">
app/design/frontend/base/default/template/bannernext/background.phtml ADDED
@@ -0,0 +1,64 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php $bannerCollection = $this->_getCollection(); ?>
2
+ <?php if(($bannerCollection->count())>0) : ?>
3
+ <?php $imageCollection = $this->_getBannerImageCollection($bannerCollection); ?>
4
+ <?php foreach ($imageCollection as $item) : ?>
5
+ <?php
6
+ $height = $item['height'];
7
+ $width = $item['width'];
8
+ $content = $item['content'];
9
+ $advanced_settings = trim($item['advanced_settings']);
10
+ $images = $this->getSortedImages($content);
11
+ ?>
12
+ <?php if(isset($images) && !empty($images) && count($images)>0) : ?>
13
+ <link rel="stylesheet" href="<?php echo $this->getSkinUrl('bannernext/supersized/css/supersized.css');?>" type="text/css" media="screen" />
14
+ <link rel="stylesheet" href="<?php echo $this->getSkinUrl('bannernext/supersized/theme/supersized.shutter.css');?>" type="text/css" media="screen" />
15
+ <script type="text/javascript" src="<?php echo $this->getSkinUrl('bannernext/supersized/js/jquery.easing.min.js') ?>" ></script>
16
+ <script type="text/javascript" src="<?php echo $this->getSkinUrl('bannernext/supersized/js/supersized.3.2.6.min.js') ?>" ></script>
17
+ <script type="text/javascript" src="<?php echo $this->getSkinUrl('bannernext/supersized/theme/supersized.shutter.min.js') ?>" ></script>
18
+ <script type="text/javascript">
19
+ jQuery(function($){
20
+
21
+ $.supersized({
22
+ // Functionality
23
+ slideshow : 1, // Slideshow on/off
24
+ autoplay : 1, // Slideshow starts playing automatically
25
+ start_slide : 1, // Start slide (0 is random)
26
+ stop_loop : 0, // Pauses slideshow on last slide
27
+ random : 0, // Randomize slide order (Ignores start slide)
28
+ slide_interval : 3000, // Length between transitions
29
+ transition : 6, // 0-None, 1-Fade, 2-Slide Top, 3-Slide Right, 4-Slide Bottom, 5-Slide Left, 6-Carousel Right, 7-Carousel Left
30
+ transition_speed : 1000, // Speed of transition
31
+ new_window : 1, // Image links open in new window/tab
32
+ pause_hover : 0, // Pause slideshow on hover
33
+ keyboard_nav : 1, // Keyboard navigation on/off
34
+ performance : 1, // 0-Normal, 1-Hybrid speed/quality, 2-Optimizes image quality, 3-Optimizes transition speed // (Only works for Firefox/IE, not Webkit)
35
+ image_protect : 1, // Disables image dragging and right click with Javascript
36
+
37
+ // Size & Position
38
+ min_width : 0, // Min width allowed (in pixels)
39
+ min_height : 0, // Min height allowed (in pixels)
40
+ vertical_center : 1, // Vertically center background
41
+ horizontal_center : 1, // Horizontally center background
42
+ fit_always : 0, // Image will never exceed browser width or height (Ignores min. dimensions)
43
+ fit_portrait : 1, // Portrait images will not exceed browser height
44
+ fit_landscape : 0, // Landscape images will not exceed browser width
45
+
46
+ // Components
47
+ slide_links : 'blank', // Individual links for each slide (Options: false, 'number', 'name', 'blank')
48
+ thumb_links : 1, // Individual thumb links for each slide
49
+ thumbnail_navigation : 0, // Thumbnail navigation
50
+ slides :
51
+ [
52
+ <?php $i=1; $total = count($images); foreach($images as $image): ?>
53
+ {image : '<?php echo $this->helper('bannernext')->resizeImg($image['file']);?>', title : 'Image Credit: Maria Kazvan', thumb : '<?php echo $this->helper('bannernext')->resizeImg($image['file'],$width,$height);?>', url : '<?php echo $this->helper('bannernext')->resizeImg($image['file'],$width,$height);?>'}
54
+ <?php if($i!=$total){ echo ',';} $i++; ?>
55
+ <?php endforeach;?>
56
+ ]
57
+ });
58
+ });
59
+
60
+ </script>
61
+
62
+ <?php endif;?>
63
+ <?php endforeach;?>
64
+ <?php endif; ?>
app/design/frontend/default/default/layout/bannernext.xml CHANGED
@@ -7,6 +7,12 @@
7
  <block type="bannernext/banner" name="bannernext_content_bottom" template="bannernext/banner.phtml" after="-" >
8
  <action method="setPosition"><name>CONTENT_BOTTOM</name></action>
9
  </block>
 
 
 
 
 
 
10
  </default>
11
  <cms_page>
12
  <reference name="content">
7
  <block type="bannernext/banner" name="bannernext_content_bottom" template="bannernext/banner.phtml" after="-" >
8
  <action method="setPosition"><name>CONTENT_BOTTOM</name></action>
9
  </block>
10
+ <block type="bannernext/banner" name="bannernext_content_background" template="bannernext/background.phtml" after="-" >
11
+ <action method="setPosition"><name>BODY_BACKGROUND</name></action>
12
+ </block>
13
+ <reference name="head">
14
+ <action method="insert" ifconfig="bannernext/general/active"><block>bannernext_content_background</block></action>
15
+ </reference>
16
  </default>
17
  <cms_page>
18
  <reference name="content">
app/design/frontend/default/default/template/bannernext/background.phtml ADDED
@@ -0,0 +1,64 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php $bannerCollection = $this->_getCollection(); ?>
2
+ <?php if(($bannerCollection->count())>0) : ?>
3
+ <?php $imageCollection = $this->_getBannerImageCollection($bannerCollection); ?>
4
+ <?php foreach ($imageCollection as $item) : ?>
5
+ <?php
6
+ $height = $item['height'];
7
+ $width = $item['width'];
8
+ $content = $item['content'];
9
+ $advanced_settings = trim($item['advanced_settings']);
10
+ $images = $this->getSortedImages($content);
11
+ ?>
12
+ <?php if(isset($images) && !empty($images) && count($images)>0) : ?>
13
+ <link rel="stylesheet" href="<?php echo $this->getSkinUrl('bannernext/supersized/css/supersized.css');?>" type="text/css" media="screen" />
14
+ <link rel="stylesheet" href="<?php echo $this->getSkinUrl('bannernext/supersized/theme/supersized.shutter.css');?>" type="text/css" media="screen" />
15
+ <script type="text/javascript" src="<?php echo $this->getSkinUrl('bannernext/supersized/js/jquery.easing.min.js') ?>" ></script>
16
+ <script type="text/javascript" src="<?php echo $this->getSkinUrl('bannernext/supersized/js/supersized.3.2.6.min.js') ?>" ></script>
17
+ <script type="text/javascript" src="<?php echo $this->getSkinUrl('bannernext/supersized/theme/supersized.shutter.min.js') ?>" ></script>
18
+ <script type="text/javascript">
19
+ jQuery(function($){
20
+
21
+ $.supersized({
22
+ // Functionality
23
+ slideshow : 1, // Slideshow on/off
24
+ autoplay : 1, // Slideshow starts playing automatically
25
+ start_slide : 1, // Start slide (0 is random)
26
+ stop_loop : 0, // Pauses slideshow on last slide
27
+ random : 0, // Randomize slide order (Ignores start slide)
28
+ slide_interval : 3000, // Length between transitions
29
+ transition : 6, // 0-None, 1-Fade, 2-Slide Top, 3-Slide Right, 4-Slide Bottom, 5-Slide Left, 6-Carousel Right, 7-Carousel Left
30
+ transition_speed : 1000, // Speed of transition
31
+ new_window : 1, // Image links open in new window/tab
32
+ pause_hover : 0, // Pause slideshow on hover
33
+ keyboard_nav : 1, // Keyboard navigation on/off
34
+ performance : 1, // 0-Normal, 1-Hybrid speed/quality, 2-Optimizes image quality, 3-Optimizes transition speed // (Only works for Firefox/IE, not Webkit)
35
+ image_protect : 1, // Disables image dragging and right click with Javascript
36
+
37
+ // Size & Position
38
+ min_width : 0, // Min width allowed (in pixels)
39
+ min_height : 0, // Min height allowed (in pixels)
40
+ vertical_center : 1, // Vertically center background
41
+ horizontal_center : 1, // Horizontally center background
42
+ fit_always : 0, // Image will never exceed browser width or height (Ignores min. dimensions)
43
+ fit_portrait : 1, // Portrait images will not exceed browser height
44
+ fit_landscape : 0, // Landscape images will not exceed browser width
45
+
46
+ // Components
47
+ slide_links : 'blank', // Individual links for each slide (Options: false, 'number', 'name', 'blank')
48
+ thumb_links : 1, // Individual thumb links for each slide
49
+ thumbnail_navigation : 0, // Thumbnail navigation
50
+ slides :
51
+ [
52
+ <?php $i=1; $total = count($images); foreach($images as $image): ?>
53
+ {image : '<?php echo $this->helper('bannernext')->resizeImg($image['file']);?>', title : 'Image Credit: Maria Kazvan', thumb : '<?php echo $this->helper('bannernext')->resizeImg($image['file'],$width,$height);?>', url : '<?php echo $this->helper('bannernext')->resizeImg($image['file'],$width,$height);?>'}
54
+ <?php if($i!=$total){ echo ',';} $i++; ?>
55
+ <?php endforeach;?>
56
+ ]
57
+ });
58
+ });
59
+
60
+ </script>
61
+
62
+ <?php endif;?>
63
+ <?php endforeach;?>
64
+ <?php endif; ?>
package.xml CHANGED
@@ -1,14 +1,17 @@
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>NextBits_BannerNext</name>
4
- <version>1.0.7</version>
5
  <stability>stable</stability>
6
  <license uri="http://opensource.org/licenses/osl-3.0.php">Open Software License (OSL)</license>
7
  <channel>community</channel>
8
  <extends/>
9
  <summary>NextBits BannerNext Magento extension for image slider</summary>
10
  <description>NextBits BannerNext Magento extension for image slider</description>
11
- <notes>1.0.7&#xD;
 
 
 
12
  -removed unwanted code.&#xD;
13
  -fixed upload error for Magento Version &lt; 1.5.1.0&#xD;
14
  &#xD;
@@ -20,9 +23,9 @@
20
  -added files in base for easy installation&#xD;
21
  -fixed image sorting and excluding bug</notes>
22
  <authors><author><name>NextBits Web Solutions Pvt. Ltd.</name><user>nextbits</user><email>nextbitswebsolutions@gmail.com</email></author></authors>
23
- <date>2013-08-07</date>
24
- <time>08:40:15</time>
25
- <contents><target name="magelocal"><dir name="NextBits"><dir name="BannerNext"><dir name="Block"><dir name="Adminhtml"><dir name="Bannernext"><dir name="Edit"><file name="Form.php" hash="9763bc5539158fe58850903def6a98c1"/><dir name="Tab"><file name="Category.php" hash="a59198b47f2e2be1bd0e07438ab515df"/><file name="Form.php" hash="ead5fe37c6d0a9159e06636482a6f509"/><file name="Gallery.php" hash="a74000a133b9f4cf81e0a8c6b4e6e344"/><file name="Page.php" hash="419317f71e24be03b0ed7679c1b54b44"/></dir><file name="Tabs.php" hash="f5153f8733262a9451ac7c8a7d918d95"/></dir><file name="Edit.php" hash="031a49e1568256fa85a679bdb73fb913"/><file name="Grid.php" hash="e932163a96996acae0fbda1a18952120"/></dir><file name="Bannernext.php" hash="ab5d95494ed6d690fecaf096478757eb"/></dir><file name="Banner.php" hash="b5cf326ade5841d931bfe7065676903e"/><file name="Widget.php" hash="1a372af5d4aaa02e192413790b4824b9"/></dir><dir name="Helper"><file name="Data.php" hash="c7bc1d6546d2656901f3854758cffbb3"/></dir><dir name="Model"><file name="Availablebanners.php" hash="53038f28b8c515ddf2a24af11f3b5b81"/><file name="Bannernext.php" hash="9e343e39648e68e4a8a4fd2a4f511267"/><dir name="Config"><dir name="Source"><file name="Page.php" hash="607fa1de1fc1a7149b6e960d1469b403"/><file name="Position.php" hash="16f3d9b6ef4a25283ebeb1ee221350e2"/></dir></dir><dir name="Mysql4"><dir name="Bannernext"><file name="Collection.php" hash="eac6374b499da5fd9fbd9dfa9d2e3942"/></dir><file name="Bannernext.php" hash="d705c144162806567657123fa78ddf28"/></dir><file name="Observer.php" hash="5ea4f494b766b291bd3ac8f7ce19884c"/><file name="Status.php" hash="13df58ea078181d6997ea36212ede89a"/></dir><dir name="controllers"><dir name="Adminhtml"><file name="BannernextController.php" hash="7eadd56f1c594d3e7a40a39f1d334137"/></dir></dir><dir name="etc"><file name="config.xml" hash="0f33fcaf1bbeb7051c6664a165449b13"/><file name="system.xml" hash="9c75d62c7c04553bef89f70b71fba964"/><file name="widget.xml" hash="ada7fddb76e7b0d9b5ea5cd231baec28"/></dir><dir name="sql"><dir name="bannernext_setup"><file name="mysql4-install-0.1.0.php" hash="cb466300a00defcbd3425043d052cd92"/></dir></dir></dir></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="bannernext.xml" hash="8a1494f85f7d1f41eb3b1c2407212b3e"/></dir><dir name="template"><dir name="bannernext"><file name="banner.phtml" hash="f78536f489706dcd536a50ba6808bb2b"/><dir name="edit"><dir name="tab"><file name="category.phtml" hash="fd539d50d42bfcb80a21a1257aef2121"/><file name="gallery.phtml" hash="9c2701ec2327a797685e758aaaad7a12"/><file name="image.phtml" hash="6832ef1caacae2b1a8addf424c75d80f"/></dir></dir><file name="uploader.phtml" hash="3d34aef9b5f57f9a8a80c7c225877a84"/></dir></dir></dir></dir></dir><dir name="frontend"><dir name="default"><dir name="default"><dir name="layout"><file name="bannernext.xml" hash="9d69326ccd164591934938bfe248a6a5"/></dir><dir name="template"><dir name="bannernext"><file name="banner.phtml" hash="ae234c7d653081105c6b8bf18ef0d47e"/></dir></dir></dir></dir><dir name="base"><dir name="default"><dir name="layout"><file name="bannernext.xml" hash="9d69326ccd164591934938bfe248a6a5"/></dir><dir name="template"><dir name="bannernext"><file name="banner.phtml" hash="ae234c7d653081105c6b8bf18ef0d47e"/></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="NextBits_BannerNext.xml" hash="b809bfd4b663a71632a77191ce0500eb"/></dir></target><target name="mageskin"><dir name="frontend"><dir name="default"><dir name="default"><dir name="bannernext"><dir name="skitter_slideshow"><dir name="css"><file name="highlight.black.css" hash="788c79331b0b1cd63920861fac19510b"/><file name="highlight.css" hash="9740467c0a8249bce6a00371eebc5c96"/><file name="skitter.styles.css" hash="2c9dac90fd64914d3865ef01a602afcd"/><file name="skitter.styles.responsive.css" hash="1d015f82ea443425948982b5a1068456"/></dir><dir name="images"><file name="ajax-loader.gif" hash="37e24e0370847870c1c43ea9ce19b1f4"/><file name="back-box-label-black.png" hash="b01b0552b61224f13e80b1ec834e33c9"/><file name="background.gif" hash="4e3d49edf41760318255a96712e2e943"/><file name="focus-button.png" hash="c7c65a7e866cfd9eda4df3431c0e58d7"/><file name="next.png" hash="60a367588cbd341acab2216629d41f39"/><file name="pause-button.png" hash="4ade832a2c3cad15e3e3e18db7b8cbd5"/><file name="play-button.png" hash="9fc21ab2e0572a5219e9caa1dc67f2e1"/><file name="prev.png" hash="f1c757b12560aeb70a1aa4898c8c3aad"/></dir><dir name="js"><file name="highlight.js" hash="fa006a4cff74da2811e5e4750d697f46"/><file name="jquery.animate-colors-min.js" hash="b61bdf5245e4d30450e78687faee5fca"/><file name="jquery.easing.1.3.js" hash="a6f75e0c043a2a087837e5c113cc6f7a"/><file name="jquery.skitter.js" hash="628711ead56282025dfe36d47eb4972f"/><file name="jquery.skitter.min.js" hash="4726d85b97e99fabe29aa5c3c4a8cf47"/></dir></dir></dir></dir></dir></dir></target><target name="mage"><dir name="js"><dir name="bannernext"><dir name="jquery"><file name="jquery-1.8.1.min.js" hash="a9a0cc296e96bbeaa0f82498e2da0917"/><file name="jquery.noconflict.js" hash="3179f2255b046d5f2e9a71e365287bef"/></dir></dir></dir></target><target name="magelocale"><dir name="en_US"><file name="NextBits_BannerNext.csv" hash="f645242cea8a69ca09df5d62b4e9ec0d"/></dir></target></contents>
26
  <compatible/>
27
  <dependencies><required><php><min>5.1.0</min><max>6.0.0</max></php></required></dependencies>
28
  </package>
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>NextBits_BannerNext</name>
4
+ <version>1.0.8</version>
5
  <stability>stable</stability>
6
  <license uri="http://opensource.org/licenses/osl-3.0.php">Open Software License (OSL)</license>
7
  <channel>community</channel>
8
  <extends/>
9
  <summary>NextBits BannerNext Magento extension for image slider</summary>
10
  <description>NextBits BannerNext Magento extension for image slider</description>
11
+ <notes>1.0.8&#xD;
12
+ -added feature for background management&#xD;
13
+ &#xD;
14
+ 1.0.7&#xD;
15
  -removed unwanted code.&#xD;
16
  -fixed upload error for Magento Version &lt; 1.5.1.0&#xD;
17
  &#xD;
23
  -added files in base for easy installation&#xD;
24
  -fixed image sorting and excluding bug</notes>
25
  <authors><author><name>NextBits Web Solutions Pvt. Ltd.</name><user>nextbits</user><email>nextbitswebsolutions@gmail.com</email></author></authors>
26
+ <date>2013-10-18</date>
27
+ <time>09:56:44</time>
28
+ <contents><target name="magelocal"><dir name="NextBits"><dir name="BannerNext"><dir name="Block"><dir name="Adminhtml"><dir name="Bannernext"><dir name="Edit"><file name="Form.php" hash="9763bc5539158fe58850903def6a98c1"/><dir name="Tab"><file name="Category.php" hash="a59198b47f2e2be1bd0e07438ab515df"/><file name="Form.php" hash="5dc9db4d134e0c5e77ecb4e2b10ebfb5"/><file name="Gallery.php" hash="788229a015a748357a752553aff3d8b4"/><file name="Page.php" hash="419317f71e24be03b0ed7679c1b54b44"/></dir><file name="Tabs.php" hash="f5153f8733262a9451ac7c8a7d918d95"/></dir><file name="Edit.php" hash="031a49e1568256fa85a679bdb73fb913"/><file name="Grid.php" hash="e932163a96996acae0fbda1a18952120"/></dir><file name="Bannernext.php" hash="ab5d95494ed6d690fecaf096478757eb"/></dir><file name="Banner.php" hash="bf1292a4fc2f37be2763111c6060a746"/><file name="Widget.php" hash="1a372af5d4aaa02e192413790b4824b9"/></dir><dir name="Helper"><file name="Data.php" hash="c42f5a826656ebd94dc6acc224c2f4b3"/></dir><dir name="Model"><file name="Availablebanners.php" hash="53038f28b8c515ddf2a24af11f3b5b81"/><file name="Bannernext.php" hash="9e343e39648e68e4a8a4fd2a4f511267"/><dir name="Config"><dir name="Source"><file name="Page.php" hash="1eb1c62bddf310f966f8567ecad9d119"/><file name="Position.php" hash="383536e0b40cb9ba521c35e2231cac49"/></dir></dir><dir name="Mysql4"><dir name="Bannernext"><file name="Collection.php" hash="eac6374b499da5fd9fbd9dfa9d2e3942"/></dir><file name="Bannernext.php" hash="d705c144162806567657123fa78ddf28"/></dir><file name="Observer.php" hash="5ea4f494b766b291bd3ac8f7ce19884c"/><file name="Status.php" hash="13df58ea078181d6997ea36212ede89a"/></dir><dir name="controllers"><dir name="Adminhtml"><file name="BannernextController.php" hash="7eadd56f1c594d3e7a40a39f1d334137"/></dir></dir><dir name="etc"><file name="config.xml" hash="0f33fcaf1bbeb7051c6664a165449b13"/><file name="system.xml" hash="484d71a108e34e6a65b5919d6ff67b83"/><file name="widget.xml" hash="ada7fddb76e7b0d9b5ea5cd231baec28"/></dir><dir name="sql"><dir name="bannernext_setup"><file name="mysql4-install-0.1.0.php" hash="cb466300a00defcbd3425043d052cd92"/></dir></dir></dir></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="bannernext.xml" hash="8a1494f85f7d1f41eb3b1c2407212b3e"/></dir><dir name="template"><dir name="bannernext"><file name="banner.phtml" hash="f78536f489706dcd536a50ba6808bb2b"/><dir name="edit"><dir name="tab"><file name="category.phtml" hash="fd539d50d42bfcb80a21a1257aef2121"/><file name="gallery.phtml" hash="9c2701ec2327a797685e758aaaad7a12"/><file name="image.phtml" hash="6832ef1caacae2b1a8addf424c75d80f"/></dir></dir><file name="uploader.phtml" hash="3d34aef9b5f57f9a8a80c7c225877a84"/></dir></dir></dir></dir></dir><dir name="frontend"><dir name="default"><dir name="default"><dir name="layout"><file name="bannernext.xml" hash="a84f60f8dcafa3ad56a5173ddb98fa44"/></dir><dir name="template"><dir name="bannernext"><file name="background.phtml" hash="f9b1f9f6b5c0146ce23726fee890daf8"/><file name="banner.phtml" hash="ae234c7d653081105c6b8bf18ef0d47e"/></dir></dir></dir></dir><dir name="base"><dir name="default"><dir name="layout"><file name="bannernext.xml" hash="a84f60f8dcafa3ad56a5173ddb98fa44"/></dir><dir name="template"><dir name="bannernext"><file name="background.phtml" hash="f9b1f9f6b5c0146ce23726fee890daf8"/><file name="banner.phtml" hash="ae234c7d653081105c6b8bf18ef0d47e"/></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="NextBits_BannerNext.xml" hash="b809bfd4b663a71632a77191ce0500eb"/></dir></target><target name="mageskin"><dir name="frontend"><dir name="default"><dir name="default"><dir name="bannernext"><dir name="skitter_slideshow"><dir name="css"><file name="highlight.black.css" hash="788c79331b0b1cd63920861fac19510b"/><file name="highlight.css" hash="9740467c0a8249bce6a00371eebc5c96"/><file name="skitter.styles.css" hash="2c9dac90fd64914d3865ef01a602afcd"/><file name="skitter.styles.responsive.css" hash="1d015f82ea443425948982b5a1068456"/></dir><dir name="images"><file name="ajax-loader.gif" hash="37e24e0370847870c1c43ea9ce19b1f4"/><file name="back-box-label-black.png" hash="b01b0552b61224f13e80b1ec834e33c9"/><file name="background.gif" hash="4e3d49edf41760318255a96712e2e943"/><file name="focus-button.png" hash="c7c65a7e866cfd9eda4df3431c0e58d7"/><file name="next.png" hash="60a367588cbd341acab2216629d41f39"/><file name="pause-button.png" hash="4ade832a2c3cad15e3e3e18db7b8cbd5"/><file name="play-button.png" hash="9fc21ab2e0572a5219e9caa1dc67f2e1"/><file name="prev.png" hash="f1c757b12560aeb70a1aa4898c8c3aad"/></dir><dir name="js"><file name="highlight.js" hash="fa006a4cff74da2811e5e4750d697f46"/><file name="jquery.animate-colors-min.js" hash="b61bdf5245e4d30450e78687faee5fca"/><file name="jquery.easing.1.3.js" hash="a6f75e0c043a2a087837e5c113cc6f7a"/><file name="jquery.skitter.js" hash="628711ead56282025dfe36d47eb4972f"/><file name="jquery.skitter.min.js" hash="4726d85b97e99fabe29aa5c3c4a8cf47"/></dir></dir><dir name="supersized"><dir name="css"><file name="supersized.core.css" hash="4ae85a1e85e2d2ba402df7a6bf8817a2"/><file name="supersized.css" hash="492803b509449dab290cedf6d8146a6f"/></dir><dir name="img"><file name="bg-black.png" hash="77982bd2c8ad9234b1e96bd47ffb6dd3"/><file name="progress.gif" hash="db34c77121e2269e4fc8d35e6883ea53"/><file name="supersized-logo.png" hash="57b441f46bd71b5f6b880a0d477b8e8d"/></dir><dir name="js"><file name="jquery.easing.min.js" hash="0ef28adcb1b067699550e47f41b4caa6"/><file name="supersized.3.2.6.min.js" hash="d785e34cb95f2dceb64f0ff3aec7edde"/><file name="supersized.3.2.7.js" hash="07d97327fb09213bb329da2982ce104a"/><file name="supersized.3.2.7.min.js" hash="f1fbae69fa27aed705c88f3cc76e242e"/><file name="supersized.core.3.2.1.js" hash="b8c9e05de5cf658033fa21ab1ae17809"/><file name="supersized.core.3.2.1.min.js" hash="88d7dea71096ccd6faf98c200920fedc"/></dir><dir name="theme"><file name="supersized.shutter.css" hash="10dfb480a4f856559d21415dbb467920"/><file name="supersized.shutter.js" hash="036389953f0839d8c391e6be13d2f608"/><file name="supersized.shutter.min.js" hash="1fb9cf67f16b645eb26cb29229824169"/></dir></dir></dir></dir></dir></dir></target><target name="mage"><dir name="js"><dir name="bannernext"><dir name="jquery"><file name="jquery-1.8.1.min.js" hash="a9a0cc296e96bbeaa0f82498e2da0917"/><file name="jquery.noconflict.js" hash="3179f2255b046d5f2e9a71e365287bef"/></dir></dir></dir></target><target name="magelocale"><dir name="en_US"><file name="NextBits_BannerNext.csv" hash="f645242cea8a69ca09df5d62b4e9ec0d"/></dir></target></contents>
29
  <compatible/>
30
  <dependencies><required><php><min>5.1.0</min><max>6.0.0</max></php></required></dependencies>
31
  </package>
skin/frontend/default/default/bannernext/supersized/css/supersized.core.css ADDED
@@ -0,0 +1,23 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /*
2
+
3
+ Supersized - Fullscreen Slideshow jQuery Plugin
4
+ Version : Core 3.2.1
5
+
6
+ Site : www.buildinternet.com/project/supersized
7
+ Author : Sam Dunn
8
+ Company : One Mighty Roar (www.onemightyroar.com)
9
+ License : MIT License / GPL License
10
+
11
+ */
12
+
13
+ * { margin:0; padding:0; }
14
+ body { background:#111; height:100%; }
15
+ img{ border:none; }
16
+
17
+ #supersized-loader { position:absolute; top:50%; left:50%; z-index:0; width:60px; height:60px; margin:-30px 0 0 -30px; text-indent:-999em; background:url(../img/progress.gif) no-repeat center center;}
18
+
19
+ #supersized { position:fixed; left:0; top:0; overflow:hidden; z-index:-999; height:100%; width:100%; }
20
+ #supersized img{ width:auto; height:auto; position:relative; outline:none; border:none; }
21
+
22
+ #supersized a { z-index:-30; position:fixed; overflow:hidden; top:0; left:0; width:100%; height:100%; background:#111; display:block; }
23
+ #supersized a.image-loading { background:#111 url(../img/progress.gif) no-repeat center center; width:100%; height:100%; }
skin/frontend/default/default/bannernext/supersized/css/supersized.css ADDED
@@ -0,0 +1,30 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /*
2
+
3
+ Supersized - Fullscreen Slideshow jQuery Plugin
4
+ Version : 3.2.7
5
+ Site : www.buildinternet.com/project/supersized
6
+
7
+ Author : Sam Dunn
8
+ Company : One Mighty Roar (www.onemightyroar.com)
9
+ License : MIT License / GPL License
10
+
11
+ */
12
+
13
+ * { margin:0; padding:0; }
14
+ body { height:100%; }
15
+ img { border:none; }
16
+
17
+ #supersized-loader { position:absolute; top:50%; left:50%; z-index:0; width:60px; height:60px; margin:-30px 0 0 -30px; text-indent:-999em; background:url(../img/progress.gif) no-repeat center center;}
18
+
19
+ #supersized { display:block; position:fixed; left:0; top:0; overflow:hidden; z-index:-999; height:100%; width:100%; }
20
+ #supersized img { width:auto; height:auto; position:relative; display:none; outline:none; border:none; }
21
+ #supersized.speed img { -ms-interpolation-mode:nearest-neighbor; image-rendering: -moz-crisp-edges; } /*Speed*/
22
+ #supersized.quality img { -ms-interpolation-mode:bicubic; image-rendering: optimizeQuality; } /*Quality*/
23
+
24
+ #supersized li { display:block; list-style:none; z-index:-30; position:fixed; overflow:hidden; top:0; left:0; width:100%; height:100%; background:#111; }
25
+ #supersized a { width:100%; height:100%; display:block; }
26
+ #supersized li.prevslide { z-index:-20; }
27
+ #supersized li.activeslide { z-index:-10; }
28
+ #supersized li.image-loading { background:#111 url(../img/progress.gif) no-repeat center center; width:100%; height:100%; }
29
+ #supersized li.image-loading img{ visibility:hidden; }
30
+ #supersized li.prevslide img, #supersized li.activeslide img{ display:inline; }
skin/frontend/default/default/bannernext/supersized/img/bg-black.png ADDED
Binary file
skin/frontend/default/default/bannernext/supersized/img/progress.gif ADDED
Binary file
skin/frontend/default/default/bannernext/supersized/img/supersized-logo.png ADDED
Binary file
skin/frontend/default/default/bannernext/supersized/js/jquery.easing.min.js ADDED
@@ -0,0 +1,71 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /*
2
+ * jQuery Easing v1.3 - http://gsgd.co.uk/sandbox/jquery/easing/
3
+ *
4
+ * Uses the built in easing capabilities added In jQuery 1.1
5
+ * to offer multiple easing options
6
+ *
7
+ * TERMS OF USE - jQuery Easing
8
+ *
9
+ * Open source under the BSD License.
10
+ *
11
+ * Copyright � 2008 George McGinley Smith
12
+ * All rights reserved.
13
+ *
14
+ * Redistribution and use in source and binary forms, with or without modification,
15
+ * are permitted provided that the following conditions are met:
16
+ *
17
+ * Redistributions of source code must retain the above copyright notice, this list of
18
+ * conditions and the following disclaimer.
19
+ * Redistributions in binary form must reproduce the above copyright notice, this list
20
+ * of conditions and the following disclaimer in the documentation and/or other materials
21
+ * provided with the distribution.
22
+ *
23
+ * Neither the name of the author nor the names of contributors may be used to endorse
24
+ * or promote products derived from this software without specific prior written permission.
25
+ *
26
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
27
+ * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
28
+ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
29
+ * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
30
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
31
+ * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
32
+ * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
33
+ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
34
+ * OF THE POSSIBILITY OF SUCH DAMAGE.
35
+ *
36
+ */
37
+
38
+ jQuery.easing.jswing=jQuery.easing.swing;jQuery.extend(jQuery.easing,{def:"easeOutQuad",swing:function(e,f,a,h,g){return jQuery.easing[jQuery.easing.def](e,f,a,h,g)},easeInQuad:function(e,f,a,h,g){return h*(f/=g)*f+a},easeOutQuad:function(e,f,a,h,g){return -h*(f/=g)*(f-2)+a},easeInOutQuad:function(e,f,a,h,g){if((f/=g/2)<1){return h/2*f*f+a}return -h/2*((--f)*(f-2)-1)+a},easeInCubic:function(e,f,a,h,g){return h*(f/=g)*f*f+a},easeOutCubic:function(e,f,a,h,g){return h*((f=f/g-1)*f*f+1)+a},easeInOutCubic:function(e,f,a,h,g){if((f/=g/2)<1){return h/2*f*f*f+a}return h/2*((f-=2)*f*f+2)+a},easeInQuart:function(e,f,a,h,g){return h*(f/=g)*f*f*f+a},easeOutQuart:function(e,f,a,h,g){return -h*((f=f/g-1)*f*f*f-1)+a},easeInOutQuart:function(e,f,a,h,g){if((f/=g/2)<1){return h/2*f*f*f*f+a}return -h/2*((f-=2)*f*f*f-2)+a},easeInQuint:function(e,f,a,h,g){return h*(f/=g)*f*f*f*f+a},easeOutQuint:function(e,f,a,h,g){return h*((f=f/g-1)*f*f*f*f+1)+a},easeInOutQuint:function(e,f,a,h,g){if((f/=g/2)<1){return h/2*f*f*f*f*f+a}return h/2*((f-=2)*f*f*f*f+2)+a},easeInSine:function(e,f,a,h,g){return -h*Math.cos(f/g*(Math.PI/2))+h+a},easeOutSine:function(e,f,a,h,g){return h*Math.sin(f/g*(Math.PI/2))+a},easeInOutSine:function(e,f,a,h,g){return -h/2*(Math.cos(Math.PI*f/g)-1)+a},easeInExpo:function(e,f,a,h,g){return(f==0)?a:h*Math.pow(2,10*(f/g-1))+a},easeOutExpo:function(e,f,a,h,g){return(f==g)?a+h:h*(-Math.pow(2,-10*f/g)+1)+a},easeInOutExpo:function(e,f,a,h,g){if(f==0){return a}if(f==g){return a+h}if((f/=g/2)<1){return h/2*Math.pow(2,10*(f-1))+a}return h/2*(-Math.pow(2,-10*--f)+2)+a},easeInCirc:function(e,f,a,h,g){return -h*(Math.sqrt(1-(f/=g)*f)-1)+a},easeOutCirc:function(e,f,a,h,g){return h*Math.sqrt(1-(f=f/g-1)*f)+a},easeInOutCirc:function(e,f,a,h,g){if((f/=g/2)<1){return -h/2*(Math.sqrt(1-f*f)-1)+a}return h/2*(Math.sqrt(1-(f-=2)*f)+1)+a},easeInElastic:function(f,h,e,l,k){var i=1.70158;var j=0;var g=l;if(h==0){return e}if((h/=k)==1){return e+l}if(!j){j=k*0.3}if(g<Math.abs(l)){g=l;var i=j/4}else{var i=j/(2*Math.PI)*Math.asin(l/g)}return -(g*Math.pow(2,10*(h-=1))*Math.sin((h*k-i)*(2*Math.PI)/j))+e},easeOutElastic:function(f,h,e,l,k){var i=1.70158;var j=0;var g=l;if(h==0){return e}if((h/=k)==1){return e+l}if(!j){j=k*0.3}if(g<Math.abs(l)){g=l;var i=j/4}else{var i=j/(2*Math.PI)*Math.asin(l/g)}return g*Math.pow(2,-10*h)*Math.sin((h*k-i)*(2*Math.PI)/j)+l+e},easeInOutElastic:function(f,h,e,l,k){var i=1.70158;var j=0;var g=l;if(h==0){return e}if((h/=k/2)==2){return e+l}if(!j){j=k*(0.3*1.5)}if(g<Math.abs(l)){g=l;var i=j/4}else{var i=j/(2*Math.PI)*Math.asin(l/g)}if(h<1){return -0.5*(g*Math.pow(2,10*(h-=1))*Math.sin((h*k-i)*(2*Math.PI)/j))+e}return g*Math.pow(2,-10*(h-=1))*Math.sin((h*k-i)*(2*Math.PI)/j)*0.5+l+e},easeInBack:function(e,f,a,i,h,g){if(g==undefined){g=1.70158}return i*(f/=h)*f*((g+1)*f-g)+a},easeOutBack:function(e,f,a,i,h,g){if(g==undefined){g=1.70158}return i*((f=f/h-1)*f*((g+1)*f+g)+1)+a},easeInOutBack:function(e,f,a,i,h,g){if(g==undefined){g=1.70158}if((f/=h/2)<1){return i/2*(f*f*(((g*=(1.525))+1)*f-g))+a}return i/2*((f-=2)*f*(((g*=(1.525))+1)*f+g)+2)+a},easeInBounce:function(e,f,a,h,g){return h-jQuery.easing.easeOutBounce(e,g-f,0,h,g)+a},easeOutBounce:function(e,f,a,h,g){if((f/=g)<(1/2.75)){return h*(7.5625*f*f)+a}else{if(f<(2/2.75)){return h*(7.5625*(f-=(1.5/2.75))*f+0.75)+a}else{if(f<(2.5/2.75)){return h*(7.5625*(f-=(2.25/2.75))*f+0.9375)+a}else{return h*(7.5625*(f-=(2.625/2.75))*f+0.984375)+a}}}},easeInOutBounce:function(e,f,a,h,g){if(f<g/2){return jQuery.easing.easeInBounce(e,f*2,0,h,g)*0.5+a}return jQuery.easing.easeOutBounce(e,f*2-g,0,h,g)*0.5+h*0.5+a}});
39
+
40
+ /*
41
+ *
42
+ * TERMS OF USE - EASING EQUATIONS
43
+ *
44
+ * Open source under the BSD License.
45
+ *
46
+ * Copyright � 2001 Robert Penner
47
+ * All rights reserved.
48
+ *
49
+ * Redistribution and use in source and binary forms, with or without modification,
50
+ * are permitted provided that the following conditions are met:
51
+ *
52
+ * Redistributions of source code must retain the above copyright notice, this list of
53
+ * conditions and the following disclaimer.
54
+ * Redistributions in binary form must reproduce the above copyright notice, this list
55
+ * of conditions and the following disclaimer in the documentation and/or other materials
56
+ * provided with the distribution.
57
+ *
58
+ * Neither the name of the author nor the names of contributors may be used to endorse
59
+ * or promote products derived from this software without specific prior written permission.
60
+ *
61
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
62
+ * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
63
+ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
64
+ * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
65
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
66
+ * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
67
+ * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
68
+ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
69
+ * OF THE POSSIBILITY OF SUCH DAMAGE.
70
+ *
71
+ */
skin/frontend/default/default/bannernext/supersized/js/supersized.3.2.6.min.js ADDED
@@ -0,0 +1,13 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /*
2
+
3
+ Supersized - Fullscreen Slideshow jQuery Plugin
4
+ Version : 3.2.6
5
+ Site : www.buildinternet.com/project/supersized
6
+
7
+ Author : Sam Dunn
8
+ Company : One Mighty Roar (www.onemightyroar.com)
9
+ License : MIT License / GPL License
10
+
11
+ */
12
+
13
+ (function(a){a(document).ready(function(){a("body").append('<div id="supersized-loader"></div><ul id="supersized"></ul>')});a.supersized=function(b){var c="#supersized",d=this;d.$el=a(c);d.el=c;vars=a.supersized.vars;d.$el.data("supersized",d);api=d.$el.data("supersized");d.init=function(){a.supersized.vars=a.extend(a.supersized.vars,a.supersized.themeVars);a.supersized.vars.options=a.extend({},a.supersized.defaultOptions,a.supersized.themeOptions,b);d.options=a.supersized.vars.options;d._build()};d._build=function(){var g=0,e="",j="",h,f="",i;while(g<=d.options.slides.length-1){switch(d.options.slide_links){case"num":h=g;break;case"name":h=d.options.slides[g].title;break;case"blank":h="";break}e=e+'<li class="slide-'+g+'"></li>';if(g==d.options.start_slide-1){if(d.options.slide_links){j=j+'<li class="slide-link-'+g+' current-slide"><a>'+h+"</a></li>"}if(d.options.thumb_links){d.options.slides[g].thumb?i=d.options.slides[g].thumb:i=d.options.slides[g].image;f=f+'<li class="thumb'+g+' current-thumb"><img src="'+i+'"/></li>'}}else{if(d.options.slide_links){j=j+'<li class="slide-link-'+g+'" ><a>'+h+"</a></li>"}if(d.options.thumb_links){d.options.slides[g].thumb?i=d.options.slides[g].thumb:i=d.options.slides[g].image;f=f+'<li class="thumb'+g+'"><img src="'+i+'"/></li>'}}g++}if(d.options.slide_links){a(vars.slide_list).html(j)}if(d.options.thumb_links&&vars.thumb_tray.length){a(vars.thumb_tray).append('<ul id="'+vars.thumb_list.replace("#","")+'">'+f+"</ul>")}a(d.el).append(e);if(d.options.thumbnail_navigation){vars.current_slide-1<0?prevThumb=d.options.slides.length-1:prevThumb=vars.current_slide-1;a(vars.prev_thumb).show().html(a("<img/>").attr("src",d.options.slides[prevThumb].image));vars.current_slide==d.options.slides.length-1?nextThumb=0:nextThumb=vars.current_slide+1;a(vars.next_thumb).show().html(a("<img/>").attr("src",d.options.slides[nextThumb].image))}d._start()};d._start=function(){if(d.options.start_slide){vars.current_slide=d.options.start_slide-1}else{vars.current_slide=Math.floor(Math.random()*d.options.slides.length)}var o=d.options.new_window?' target="_blank"':"";if(d.options.performance==3){d.$el.addClass("speed")}else{if((d.options.performance==1)||(d.options.performance==2)){d.$el.addClass("quality")}}if(d.options.random){arr=d.options.slides;for(var h,m,k=arr.length;k;h=parseInt(Math.random()*k),m=arr[--k],arr[k]=arr[h],arr[h]=m){}d.options.slides=arr}if(d.options.slides.length>1){if(d.options.slides.length>2){vars.current_slide-1<0?loadPrev=d.options.slides.length-1:loadPrev=vars.current_slide-1;var g=(d.options.slides[loadPrev].url)?"href='"+d.options.slides[loadPrev].url+"'":"";var q=a('<img src="'+d.options.slides[loadPrev].image+'"/>');var n=d.el+" li:eq("+loadPrev+")";q.appendTo(n).wrap("<a "+g+o+"></a>").parent().parent().addClass("image-loading prevslide");q.load(function(){a(this).data("origWidth",a(this).width()).data("origHeight",a(this).height());d.resizeNow()})}}else{d.options.slideshow=0}g=(api.getField("url"))?"href='"+api.getField("url")+"'":"";var l=a('<img src="'+api.getField("image")+'"/>');var f=d.el+" li:eq("+vars.current_slide+")";l.appendTo(f).wrap("<a "+g+o+"></a>").parent().parent().addClass("image-loading activeslide");l.load(function(){d._origDim(a(this));d.resizeNow();d.launch();if(typeof theme!="undefined"&&typeof theme._init=="function"){theme._init()}});if(d.options.slides.length>1){vars.current_slide==d.options.slides.length-1?loadNext=0:loadNext=vars.current_slide+1;g=(d.options.slides[loadNext].url)?"href='"+d.options.slides[loadNext].url+"'":"";var e=a('<img src="'+d.options.slides[loadNext].image+'"/>');var p=d.el+" li:eq("+loadNext+")";e.appendTo(p).wrap("<a "+g+o+"></a>").parent().parent().addClass("image-loading");e.load(function(){a(this).data("origWidth",a(this).width()).data("origHeight",a(this).height());d.resizeNow()})}d.$el.css("visibility","hidden");a(".load-item").hide()};d.launch=function(){d.$el.css("visibility","visible");a("#supersized-loader").remove();if(typeof theme!="undefined"&&typeof theme.beforeAnimation=="function"){theme.beforeAnimation("next")}a(".load-item").show();if(d.options.keyboard_nav){a(document.documentElement).keyup(function(e){if(vars.in_animation){return false}if((e.keyCode==37)||(e.keyCode==40)){clearInterval(vars.slideshow_interval);d.prevSlide()}else{if((e.keyCode==39)||(e.keyCode==38)){clearInterval(vars.slideshow_interval);d.nextSlide()}else{if(e.keyCode==32&&!vars.hover_pause){clearInterval(vars.slideshow_interval);d.playToggle()}}}})}if(d.options.slideshow&&d.options.pause_hover){a(d.el).hover(function(){if(vars.in_animation){return false}vars.hover_pause=true;if(!vars.is_paused){vars.hover_pause="resume";d.playToggle()}},function(){if(vars.hover_pause=="resume"){d.playToggle();vars.hover_pause=false}})}if(d.options.slide_links){a(vars.slide_list+"> li").click(function(){index=a(vars.slide_list+"> li").index(this);targetSlide=index+1;d.goTo(targetSlide);return false})}if(d.options.thumb_links){a(vars.thumb_list+"> li").click(function(){index=a(vars.thumb_list+"> li").index(this);targetSlide=index+1;api.goTo(targetSlide);return false})}if(d.options.slideshow&&d.options.slides.length>1){if(d.options.autoplay&&d.options.slides.length>1){vars.slideshow_interval=setInterval(d.nextSlide,d.options.slide_interval)}else{vars.is_paused=true}a(".load-item img").bind("contextmenu mousedown",function(){return false})}a(window).resize(function(){d.resizeNow()})};d.resizeNow=function(){return d.$el.each(function(){a("img",d.el).each(function(){thisSlide=a(this);var f=(thisSlide.data("origHeight")/thisSlide.data("origWidth")).toFixed(2);var e=d.$el.width(),h=d.$el.height(),i;if(d.options.fit_always){if((h/e)>f){g()}else{j()}}else{if((h<=d.options.min_height)&&(e<=d.options.min_width)){if((h/e)>f){d.options.fit_landscape&&f<1?g(true):j(true)}else{d.options.fit_portrait&&f>=1?j(true):g(true)}}else{if(e<=d.options.min_width){if((h/e)>f){d.options.fit_landscape&&f<1?g(true):j()}else{d.options.fit_portrait&&f>=1?j():g(true)}}else{if(h<=d.options.min_height){if((h/e)>f){d.options.fit_landscape&&f<1?g():j(true)}else{d.options.fit_portrait&&f>=1?j(true):g()}}else{if((h/e)>f){d.options.fit_landscape&&f<1?g():j()}else{d.options.fit_portrait&&f>=1?j():g()}}}}}function g(k){if(k){if(thisSlide.width()<e||thisSlide.width()<d.options.min_width){if(thisSlide.width()*f>=d.options.min_height){thisSlide.width(d.options.min_width);thisSlide.height(thisSlide.width()*f)}else{j()}}}else{if(d.options.min_height>=h&&!d.options.fit_landscape){if(e*f>=d.options.min_height||(e*f>=d.options.min_height&&f<=1)){thisSlide.width(e);thisSlide.height(e*f)}else{if(f>1){thisSlide.height(d.options.min_height);thisSlide.width(thisSlide.height()/f)}else{if(thisSlide.width()<e){thisSlide.width(e);thisSlide.height(thisSlide.width()*f)}}}}else{thisSlide.width(e);thisSlide.height(e*f)}}}function j(k){if(k){if(thisSlide.height()<h){if(thisSlide.height()/f>=d.options.min_width){thisSlide.height(d.options.min_height);thisSlide.width(thisSlide.height()/f)}else{g(true)}}}else{if(d.options.min_width>=e){if(h/f>=d.options.min_width||f>1){thisSlide.height(h);thisSlide.width(h/f)}else{if(f<=1){thisSlide.width(d.options.min_width);thisSlide.height(thisSlide.width()*f)}}}else{thisSlide.height(h);thisSlide.width(h/f)}}}if(thisSlide.parents("li").hasClass("image-loading")){a(".image-loading").removeClass("image-loading")}if(d.options.horizontal_center){a(this).css("left",(e-a(this).width())/2)}if(d.options.vertical_center){a(this).css("top",(h-a(this).height())/2)}});if(d.options.image_protect){a("img",d.el).bind("contextmenu mousedown",function(){return false})}return false})};d.nextSlide=function(){if(vars.in_animation||!api.options.slideshow){return false}else{vars.in_animation=true}clearInterval(vars.slideshow_interval);var h=d.options.slides,e=d.$el.find(".activeslide");a(".prevslide").removeClass("prevslide");e.removeClass("activeslide").addClass("prevslide");vars.current_slide+1==d.options.slides.length?vars.current_slide=0:vars.current_slide++;var g=a(d.el+" li:eq("+vars.current_slide+")"),i=d.$el.find(".prevslide");if(d.options.performance==1){d.$el.removeClass("quality").addClass("speed")}loadSlide=false;vars.current_slide==d.options.slides.length-1?loadSlide=0:loadSlide=vars.current_slide+1;var k=d.el+" li:eq("+loadSlide+")";if(!a(k).html()){var j=d.options.new_window?' target="_blank"':"";imageLink=(d.options.slides[loadSlide].url)?"href='"+d.options.slides[loadSlide].url+"'":"";var f=a('<img src="'+d.options.slides[loadSlide].image+'"/>');f.appendTo(k).wrap("<a "+imageLink+j+"></a>").parent().parent().addClass("image-loading").css("visibility","hidden");f.load(function(){d._origDim(a(this));d.resizeNow()})}if(d.options.thumbnail_navigation==1){vars.current_slide-1<0?prevThumb=d.options.slides.length-1:prevThumb=vars.current_slide-1;a(vars.prev_thumb).html(a("<img/>").attr("src",d.options.slides[prevThumb].image));nextThumb=loadSlide;a(vars.next_thumb).html(a("<img/>").attr("src",d.options.slides[nextThumb].image))}if(typeof theme!="undefined"&&typeof theme.beforeAnimation=="function"){theme.beforeAnimation("next")}if(d.options.slide_links){a(".current-slide").removeClass("current-slide");a(vars.slide_list+"> li").eq(vars.current_slide).addClass("current-slide")}g.css("visibility","hidden").addClass("activeslide");switch(d.options.transition){case 0:case"none":g.css("visibility","visible");vars.in_animation=false;break;case 1:case"fade":g.animate({opacity:0},0).css("visibility","visible").animate({opacity:1,avoidTransforms:false},d.options.transition_speed,function(){d.afterAnimation()});break;case 2:case"slideTop":g.animate({top:-d.$el.height()},0).css("visibility","visible").animate({top:0,avoidTransforms:false},d.options.transition_speed,function(){d.afterAnimation()});break;case 3:case"slideRight":g.animate({left:d.$el.width()},0).css("visibility","visible").animate({left:0,avoidTransforms:false},d.options.transition_speed,function(){d.afterAnimation()});break;case 4:case"slideBottom":g.animate({top:d.$el.height()},0).css("visibility","visible").animate({top:0,avoidTransforms:false},d.options.transition_speed,function(){d.afterAnimation()});break;case 5:case"slideLeft":g.animate({left:-d.$el.width()},0).css("visibility","visible").animate({left:0,avoidTransforms:false},d.options.transition_speed,function(){d.afterAnimation()});break;case 6:case"carouselRight":g.animate({left:d.$el.width()},0).css("visibility","visible").animate({left:0,avoidTransforms:false},d.options.transition_speed,function(){d.afterAnimation()});e.animate({left:-d.$el.width(),avoidTransforms:false},d.options.transition_speed);break;case 7:case"carouselLeft":g.animate({left:-d.$el.width()},0).css("visibility","visible").animate({left:0,avoidTransforms:false},d.options.transition_speed,function(){d.afterAnimation()});e.animate({left:d.$el.width(),avoidTransforms:false},d.options.transition_speed);break}return false};d.prevSlide=function(){if(vars.in_animation||!api.options.slideshow){return false}else{vars.in_animation=true}clearInterval(vars.slideshow_interval);var h=d.options.slides,e=d.$el.find(".activeslide");a(".prevslide").removeClass("prevslide");e.removeClass("activeslide").addClass("prevslide");vars.current_slide==0?vars.current_slide=d.options.slides.length-1:vars.current_slide--;var g=a(d.el+" li:eq("+vars.current_slide+")"),i=d.$el.find(".prevslide");if(d.options.performance==1){d.$el.removeClass("quality").addClass("speed")}loadSlide=vars.current_slide;var k=d.el+" li:eq("+loadSlide+")";if(!a(k).html()){var j=d.options.new_window?' target="_blank"':"";imageLink=(d.options.slides[loadSlide].url)?"href='"+d.options.slides[loadSlide].url+"'":"";var f=a('<img src="'+d.options.slides[loadSlide].image+'"/>');f.appendTo(k).wrap("<a "+imageLink+j+"></a>").parent().parent().addClass("image-loading").css("visibility","hidden");f.load(function(){d._origDim(a(this));d.resizeNow()})}if(d.options.thumbnail_navigation==1){prevThumb=loadSlide;a(vars.prev_thumb).html(a("<img/>").attr("src",d.options.slides[prevThumb].image));vars.current_slide==d.options.slides.length-1?nextThumb=0:nextThumb=vars.current_slide+1;a(vars.next_thumb).html(a("<img/>").attr("src",d.options.slides[nextThumb].image))}if(typeof theme!="undefined"&&typeof theme.beforeAnimation=="function"){theme.beforeAnimation("prev")}if(d.options.slide_links){a(".current-slide").removeClass("current-slide");a(vars.slide_list+"> li").eq(vars.current_slide).addClass("current-slide")}g.css("visibility","hidden").addClass("activeslide");switch(d.options.transition){case 0:case"none":g.css("visibility","visible");vars.in_animation=false;d.afterAnimation();break;case 1:case"fade":g.animate({opacity:0},0).css("visibility","visible").animate({opacity:1,avoidTransforms:false},d.options.transition_speed,function(){d.afterAnimation()});break;case 2:case"slideTop":g.animate({top:d.$el.height()},0).css("visibility","visible").animate({top:0,avoidTransforms:false},d.options.transition_speed,function(){d.afterAnimation()});break;case 3:case"slideRight":g.animate({left:-d.$el.width()},0).css("visibility","visible").animate({left:0,avoidTransforms:false},d.options.transition_speed,function(){d.afterAnimation()});break;case 4:case"slideBottom":g.animate({top:-d.$el.height()},0).css("visibility","visible").animate({top:0,avoidTransforms:false},d.options.transition_speed,function(){d.afterAnimation()});break;case 5:case"slideLeft":g.animate({left:d.$el.width()},0).css("visibility","visible").animate({left:0,avoidTransforms:false},d.options.transition_speed,function(){d.afterAnimation()});break;case 6:case"carouselRight":g.animate({left:-d.$el.width()},0).css("visibility","visible").animate({left:0,avoidTransforms:false},d.options.transition_speed,function(){d.afterAnimation()});e.animate({left:0},0).animate({left:d.$el.width(),avoidTransforms:false},d.options.transition_speed);break;case 7:case"carouselLeft":g.animate({left:d.$el.width()},0).css("visibility","visible").animate({left:0,avoidTransforms:false},d.options.transition_speed,function(){d.afterAnimation()});e.animate({left:0},0).animate({left:-d.$el.width(),avoidTransforms:false},d.options.transition_speed);break}return false};d.playToggle=function(){if(vars.in_animation||!api.options.slideshow){return false}if(vars.is_paused){vars.is_paused=false;if(typeof theme!="undefined"&&typeof theme.playToggle=="function"){theme.playToggle("play")}vars.slideshow_interval=setInterval(d.nextSlide,d.options.slide_interval)}else{vars.is_paused=true;if(typeof theme!="undefined"&&typeof theme.playToggle=="function"){theme.playToggle("pause")}clearInterval(vars.slideshow_interval)}return false};d.goTo=function(f){if(vars.in_animation||!api.options.slideshow){return false}var e=d.options.slides.length;if(f<0){f=e}else{if(f>e){f=1}}f=e-f+1;clearInterval(vars.slideshow_interval);if(typeof theme!="undefined"&&typeof theme.goTo=="function"){theme.goTo()}if(vars.current_slide==e-f){if(!(vars.is_paused)){vars.slideshow_interval=setInterval(d.nextSlide,d.options.slide_interval)}return false}if(e-f>vars.current_slide){vars.current_slide=e-f-1;vars.update_images="next";d._placeSlide(vars.update_images)}else{if(e-f<vars.current_slide){vars.current_slide=e-f+1;vars.update_images="prev";d._placeSlide(vars.update_images)}}if(d.options.slide_links){a(vars.slide_list+"> .current-slide").removeClass("current-slide");a(vars.slide_list+"> li").eq((e-f)).addClass("current-slide")}if(d.options.thumb_links){a(vars.thumb_list+"> .current-thumb").removeClass("current-thumb");a(vars.thumb_list+"> li").eq((e-f)).addClass("current-thumb")}};d._placeSlide=function(e){var h=d.options.new_window?' target="_blank"':"";loadSlide=false;if(e=="next"){vars.current_slide==d.options.slides.length-1?loadSlide=0:loadSlide=vars.current_slide+1;var g=d.el+" li:eq("+loadSlide+")";if(!a(g).html()){var h=d.options.new_window?' target="_blank"':"";imageLink=(d.options.slides[loadSlide].url)?"href='"+d.options.slides[loadSlide].url+"'":"";var f=a('<img src="'+d.options.slides[loadSlide].image+'"/>');f.appendTo(g).wrap("<a "+imageLink+h+"></a>").parent().parent().addClass("image-loading").css("visibility","hidden");f.load(function(){d._origDim(a(this));d.resizeNow()})}d.nextSlide()}else{if(e=="prev"){vars.current_slide-1<0?loadSlide=d.options.slides.length-1:loadSlide=vars.current_slide-1;var g=d.el+" li:eq("+loadSlide+")";if(!a(g).html()){var h=d.options.new_window?' target="_blank"':"";imageLink=(d.options.slides[loadSlide].url)?"href='"+d.options.slides[loadSlide].url+"'":"";var f=a('<img src="'+d.options.slides[loadSlide].image+'"/>');f.appendTo(g).wrap("<a "+imageLink+h+"></a>").parent().parent().addClass("image-loading").css("visibility","hidden");f.load(function(){d._origDim(a(this));d.resizeNow()})}d.prevSlide()}}};d._origDim=function(e){e.data("origWidth",e.width()).data("origHeight",e.height())};d.afterAnimation=function(){if(d.options.performance==1){d.$el.removeClass("speed").addClass("quality")}if(vars.update_images){vars.current_slide-1<0?setPrev=d.options.slides.length-1:setPrev=vars.current_slide-1;vars.update_images=false;a(".prevslide").removeClass("prevslide");a(d.el+" li:eq("+setPrev+")").addClass("prevslide")}vars.in_animation=false;if(!vars.is_paused&&d.options.slideshow){vars.slideshow_interval=setInterval(d.nextSlide,d.options.slide_interval);if(d.options.stop_loop&&vars.current_slide==d.options.slides.length-1){d.playToggle()}}if(typeof theme!="undefined"&&typeof theme.afterAnimation=="function"){theme.afterAnimation()}return false};d.getField=function(e){return d.options.slides[vars.current_slide][e]};d.init()};a.supersized.vars={thumb_tray:"#thumb-tray",thumb_list:"#thumb-list",slide_list:"#slide-list",current_slide:0,in_animation:false,is_paused:false,hover_pause:false,slideshow_interval:false,update_images:false,options:{}};a.supersized.defaultOptions={slideshow:1,autoplay:1,start_slide:1,stop_loop:0,random:0,slide_interval:5000,transition:1,transition_speed:750,new_window:1,pause_hover:0,keyboard_nav:1,performance:1,image_protect:1,fit_always:0,fit_landscape:0,fit_portrait:1,min_width:0,min_height:0,horizontal_center:1,vertical_center:1,slide_links:1,thumb_links:1,thumbnail_navigation:0};a.fn.supersized=function(b){return this.each(function(){(new a.supersized(b))})}})(jQuery);
skin/frontend/default/default/bannernext/supersized/js/supersized.3.2.7.js ADDED
@@ -0,0 +1,931 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /*
2
+
3
+ Supersized - Fullscreen Slideshow jQuery Plugin
4
+ Version : 3.2.7
5
+ Site : www.buildinternet.com/project/supersized
6
+
7
+ Author : Sam Dunn
8
+ Company : One Mighty Roar (www.onemightyroar.com)
9
+ License : MIT License / GPL License
10
+
11
+ */
12
+
13
+ (function($){
14
+
15
+ /* Place Supersized Elements
16
+ ----------------------------*/
17
+ $(document).ready(function() {
18
+ $('body').append('<div id="supersized-loader"></div><ul id="supersized"></ul>');
19
+ });
20
+
21
+
22
+ $.supersized = function(options){
23
+
24
+ /* Variables
25
+ ----------------------------*/
26
+ var el = '#supersized',
27
+ base = this;
28
+ // Access to jQuery and DOM versions of element
29
+ base.$el = $(el);
30
+ base.el = el;
31
+ vars = $.supersized.vars;
32
+ // Add a reverse reference to the DOM object
33
+ base.$el.data("supersized", base);
34
+ api = base.$el.data('supersized');
35
+
36
+ base.init = function(){
37
+ // Combine options and vars
38
+ $.supersized.vars = $.extend($.supersized.vars, $.supersized.themeVars);
39
+ $.supersized.vars.options = $.extend({},$.supersized.defaultOptions, $.supersized.themeOptions, options);
40
+ base.options = $.supersized.vars.options;
41
+
42
+ base._build();
43
+ };
44
+
45
+
46
+ /* Build Elements
47
+ ----------------------------*/
48
+ base._build = function(){
49
+ // Add in slide markers
50
+ var thisSlide = 0,
51
+ slideSet = '',
52
+ markers = '',
53
+ markerContent,
54
+ thumbMarkers = '',
55
+ thumbImage;
56
+
57
+ while(thisSlide <= base.options.slides.length-1){
58
+ //Determine slide link content
59
+ switch(base.options.slide_links){
60
+ case 'num':
61
+ markerContent = thisSlide;
62
+ break;
63
+ case 'name':
64
+ markerContent = base.options.slides[thisSlide].title;
65
+ break;
66
+ case 'blank':
67
+ markerContent = '';
68
+ break;
69
+ }
70
+
71
+ slideSet = slideSet+'<li class="slide-'+thisSlide+'"></li>';
72
+
73
+ if(thisSlide == base.options.start_slide-1){
74
+ // Slide links
75
+ if (base.options.slide_links)markers = markers+'<li class="slide-link-'+thisSlide+' current-slide"><a>'+markerContent+'</a></li>';
76
+ // Slide Thumbnail Links
77
+ if (base.options.thumb_links){
78
+ base.options.slides[thisSlide].thumb ? thumbImage = base.options.slides[thisSlide].thumb : thumbImage = base.options.slides[thisSlide].image;
79
+ thumbMarkers = thumbMarkers+'<li class="thumb'+thisSlide+' current-thumb"><img src="'+thumbImage+'"/></li>';
80
+ };
81
+ }else{
82
+ // Slide links
83
+ if (base.options.slide_links) markers = markers+'<li class="slide-link-'+thisSlide+'" ><a>'+markerContent+'</a></li>';
84
+ // Slide Thumbnail Links
85
+ if (base.options.thumb_links){
86
+ base.options.slides[thisSlide].thumb ? thumbImage = base.options.slides[thisSlide].thumb : thumbImage = base.options.slides[thisSlide].image;
87
+ thumbMarkers = thumbMarkers+'<li class="thumb'+thisSlide+'"><img src="'+thumbImage+'"/></li>';
88
+ };
89
+ }
90
+ thisSlide++;
91
+ }
92
+
93
+ if (base.options.slide_links) $(vars.slide_list).html(markers);
94
+ if (base.options.thumb_links && vars.thumb_tray.length){
95
+ $(vars.thumb_tray).append('<ul id="'+vars.thumb_list.replace('#','')+'">'+thumbMarkers+'</ul>');
96
+ }
97
+
98
+ $(base.el).append(slideSet);
99
+
100
+ // Add in thumbnails
101
+ if (base.options.thumbnail_navigation){
102
+ // Load previous thumbnail
103
+ vars.current_slide - 1 < 0 ? prevThumb = base.options.slides.length - 1 : prevThumb = vars.current_slide - 1;
104
+ $(vars.prev_thumb).show().html($("<img/>").attr("src", base.options.slides[prevThumb].image));
105
+
106
+ // Load next thumbnail
107
+ vars.current_slide == base.options.slides.length - 1 ? nextThumb = 0 : nextThumb = vars.current_slide + 1;
108
+ $(vars.next_thumb).show().html($("<img/>").attr("src", base.options.slides[nextThumb].image));
109
+ }
110
+
111
+ base._start(); // Get things started
112
+ };
113
+
114
+
115
+ /* Initialize
116
+ ----------------------------*/
117
+ base._start = function(){
118
+
119
+ // Determine if starting slide random
120
+ if (base.options.start_slide){
121
+ vars.current_slide = base.options.start_slide - 1;
122
+ }else{
123
+ vars.current_slide = Math.floor(Math.random()*base.options.slides.length); // Generate random slide number
124
+ }
125
+
126
+ // If links should open in new window
127
+ var linkTarget = base.options.new_window ? ' target="_blank"' : '';
128
+
129
+ // Set slideshow quality (Supported only in FF and IE, no Webkit)
130
+ if (base.options.performance == 3){
131
+ base.$el.addClass('speed'); // Faster transitions
132
+ } else if ((base.options.performance == 1) || (base.options.performance == 2)){
133
+ base.$el.addClass('quality'); // Higher image quality
134
+ }
135
+
136
+ // Shuffle slide order if needed
137
+ if (base.options.random){
138
+ arr = base.options.slides;
139
+ for(var j, x, i = arr.length; i; j = parseInt(Math.random() * i), x = arr[--i], arr[i] = arr[j], arr[j] = x); // Fisher-Yates shuffle algorithm (jsfromhell.com/array/shuffle)
140
+ base.options.slides = arr;
141
+ }
142
+
143
+ /*-----Load initial set of images-----*/
144
+
145
+ if (base.options.slides.length > 1){
146
+ if(base.options.slides.length > 2){
147
+ // Set previous image
148
+ vars.current_slide - 1 < 0 ? loadPrev = base.options.slides.length - 1 : loadPrev = vars.current_slide - 1; // If slide is 1, load last slide as previous
149
+ var imageLink = (base.options.slides[loadPrev].url) ? "href='" + base.options.slides[loadPrev].url + "'" : "";
150
+
151
+ var imgPrev = $('<img src="'+base.options.slides[loadPrev].image+'"/>');
152
+ var slidePrev = base.el+' li:eq('+loadPrev+')';
153
+ imgPrev.appendTo(slidePrev).wrap('<a ' + imageLink + linkTarget + '></a>').parent().parent().addClass('image-loading prevslide');
154
+
155
+ imgPrev.load(function(){
156
+ $(this).data('origWidth', $(this).width()).data('origHeight', $(this).height());
157
+ base.resizeNow(); // Resize background image
158
+ }); // End Load
159
+ }
160
+ } else {
161
+ // Slideshow turned off if there is only one slide
162
+ base.options.slideshow = 0;
163
+ }
164
+
165
+ // Set current image
166
+ imageLink = (api.getField('url')) ? "href='" + api.getField('url') + "'" : "";
167
+ var img = $('<img src="'+api.getField('image')+'"/>');
168
+
169
+ var slideCurrent= base.el+' li:eq('+vars.current_slide+')';
170
+ img.appendTo(slideCurrent).wrap('<a ' + imageLink + linkTarget + '></a>').parent().parent().addClass('image-loading activeslide');
171
+
172
+ img.load(function(){
173
+ base._origDim($(this));
174
+ base.resizeNow(); // Resize background image
175
+ base.launch();
176
+ if( typeof theme != 'undefined' && typeof theme._init == "function" ) theme._init(); // Load Theme
177
+ });
178
+
179
+ if (base.options.slides.length > 1){
180
+ // Set next image
181
+ vars.current_slide == base.options.slides.length - 1 ? loadNext = 0 : loadNext = vars.current_slide + 1; // If slide is last, load first slide as next
182
+ imageLink = (base.options.slides[loadNext].url) ? "href='" + base.options.slides[loadNext].url + "'" : "";
183
+
184
+ var imgNext = $('<img src="'+base.options.slides[loadNext].image+'"/>');
185
+ var slideNext = base.el+' li:eq('+loadNext+')';
186
+ imgNext.appendTo(slideNext).wrap('<a ' + imageLink + linkTarget + '></a>').parent().parent().addClass('image-loading');
187
+
188
+ imgNext.load(function(){
189
+ $(this).data('origWidth', $(this).width()).data('origHeight', $(this).height());
190
+ base.resizeNow(); // Resize background image
191
+ }); // End Load
192
+ }
193
+ /*-----End load initial images-----*/
194
+
195
+ // Hide elements to be faded in
196
+ base.$el.css('visibility','hidden');
197
+ $('.load-item').hide();
198
+
199
+ };
200
+
201
+
202
+ /* Launch Supersized
203
+ ----------------------------*/
204
+ base.launch = function(){
205
+
206
+ base.$el.css('visibility','visible');
207
+ $('#supersized-loader').remove(); //Hide loading animation
208
+
209
+ // Call theme function for before slide transition
210
+ if( typeof theme != 'undefined' && typeof theme.beforeAnimation == "function" ) theme.beforeAnimation('next');
211
+ $('.load-item').show();
212
+
213
+ // Keyboard Navigation
214
+ if (base.options.keyboard_nav){
215
+ $(document.documentElement).keyup(function (event) {
216
+
217
+ if(vars.in_animation) return false; // Abort if currently animating
218
+ if($(document.activeElement).is("input, textarea")) return false; // Abort if active element is an input or a textarea.
219
+
220
+ // Left Arrow or Down Arrow
221
+ if ((event.keyCode == 37) || (event.keyCode == 40)) {
222
+ clearInterval(vars.slideshow_interval); // Stop slideshow, prevent buildup
223
+ base.prevSlide();
224
+
225
+ // Right Arrow or Up Arrow
226
+ } else if ((event.keyCode == 39) || (event.keyCode == 38)) {
227
+ clearInterval(vars.slideshow_interval); // Stop slideshow, prevent buildup
228
+ base.nextSlide();
229
+
230
+ // Spacebar
231
+ } else if (event.keyCode == 32 && !vars.hover_pause) {
232
+ clearInterval(vars.slideshow_interval); // Stop slideshow, prevent buildup
233
+ base.playToggle();
234
+ }
235
+
236
+ });
237
+ }
238
+
239
+ // Pause when hover on image
240
+ if (base.options.slideshow && base.options.pause_hover){
241
+ $(base.el).hover(function() {
242
+ if(vars.in_animation) return false; // Abort if currently animating
243
+ vars.hover_pause = true; // Mark slideshow paused from hover
244
+ if(!vars.is_paused){
245
+ vars.hover_pause = 'resume'; // It needs to resume afterwards
246
+ base.playToggle();
247
+ }
248
+ }, function() {
249
+ if(vars.hover_pause == 'resume'){
250
+ base.playToggle();
251
+ vars.hover_pause = false;
252
+ }
253
+ });
254
+ }
255
+
256
+ if (base.options.slide_links){
257
+ // Slide marker clicked
258
+ $(vars.slide_list+'> li').click(function(){
259
+
260
+ index = $(vars.slide_list+'> li').index(this);
261
+ targetSlide = index + 1;
262
+
263
+ base.goTo(targetSlide);
264
+ return false;
265
+
266
+ });
267
+ }
268
+
269
+ // Thumb marker clicked
270
+ if (base.options.thumb_links){
271
+ $(vars.thumb_list+'> li').click(function(){
272
+
273
+ index = $(vars.thumb_list+'> li').index(this);
274
+ targetSlide = index + 1;
275
+
276
+ api.goTo(targetSlide);
277
+ return false;
278
+
279
+ });
280
+ }
281
+
282
+ // Start slideshow if enabled
283
+ if (base.options.slideshow && base.options.slides.length > 1){
284
+
285
+ // Start slideshow if autoplay enabled
286
+ if (base.options.autoplay && base.options.slides.length > 1){
287
+ vars.slideshow_interval = setInterval(base.nextSlide, base.options.slide_interval); // Initiate slide interval
288
+ }else{
289
+ vars.is_paused = true; // Mark as paused
290
+ }
291
+
292
+ //Prevent navigation items from being dragged
293
+ $('.load-item img').bind("contextmenu mousedown",function(){
294
+ return false;
295
+ });
296
+
297
+ }
298
+
299
+ // Adjust image when browser is resized
300
+ $(window).resize(function(){
301
+ base.resizeNow();
302
+ });
303
+
304
+ };
305
+
306
+
307
+ /* Resize Images
308
+ ----------------------------*/
309
+ base.resizeNow = function(){
310
+
311
+ return base.$el.each(function() {
312
+ // Resize each image seperately
313
+ $('img', base.el).each(function(){
314
+
315
+ thisSlide = $(this);
316
+ var ratio = (thisSlide.data('origHeight')/thisSlide.data('origWidth')).toFixed(2); // Define image ratio
317
+
318
+ // Gather browser size
319
+ var browserwidth = base.$el.width(),
320
+ browserheight = base.$el.height(),
321
+ offset;
322
+
323
+ /*-----Resize Image-----*/
324
+ if (base.options.fit_always){ // Fit always is enabled
325
+ if ((browserheight/browserwidth) > ratio){
326
+ resizeWidth();
327
+ } else {
328
+ resizeHeight();
329
+ }
330
+ }else{ // Normal Resize
331
+ if ((browserheight <= base.options.min_height) && (browserwidth <= base.options.min_width)){ // If window smaller than minimum width and height
332
+
333
+ if ((browserheight/browserwidth) > ratio){
334
+ base.options.fit_landscape && ratio < 1 ? resizeWidth(true) : resizeHeight(true); // If landscapes are set to fit
335
+ } else {
336
+ base.options.fit_portrait && ratio >= 1 ? resizeHeight(true) : resizeWidth(true); // If portraits are set to fit
337
+ }
338
+
339
+ } else if (browserwidth <= base.options.min_width){ // If window only smaller than minimum width
340
+
341
+ if ((browserheight/browserwidth) > ratio){
342
+ base.options.fit_landscape && ratio < 1 ? resizeWidth(true) : resizeHeight(); // If landscapes are set to fit
343
+ } else {
344
+ base.options.fit_portrait && ratio >= 1 ? resizeHeight() : resizeWidth(true); // If portraits are set to fit
345
+ }
346
+
347
+ } else if (browserheight <= base.options.min_height){ // If window only smaller than minimum height
348
+
349
+ if ((browserheight/browserwidth) > ratio){
350
+ base.options.fit_landscape && ratio < 1 ? resizeWidth() : resizeHeight(true); // If landscapes are set to fit
351
+ } else {
352
+ base.options.fit_portrait && ratio >= 1 ? resizeHeight(true) : resizeWidth(); // If portraits are set to fit
353
+ }
354
+
355
+ } else { // If larger than minimums
356
+
357
+ if ((browserheight/browserwidth) > ratio){
358
+ base.options.fit_landscape && ratio < 1 ? resizeWidth() : resizeHeight(); // If landscapes are set to fit
359
+ } else {
360
+ base.options.fit_portrait && ratio >= 1 ? resizeHeight() : resizeWidth(); // If portraits are set to fit
361
+ }
362
+
363
+ }
364
+ }
365
+ /*-----End Image Resize-----*/
366
+
367
+
368
+ /*-----Resize Functions-----*/
369
+
370
+ function resizeWidth(minimum){
371
+ if (minimum){ // If minimum height needs to be considered
372
+ if(thisSlide.width() < browserwidth || thisSlide.width() < base.options.min_width ){
373
+ if (thisSlide.width() * ratio >= base.options.min_height){
374
+ thisSlide.width(base.options.min_width);
375
+ thisSlide.height(thisSlide.width() * ratio);
376
+ }else{
377
+ resizeHeight();
378
+ }
379
+ }
380
+ }else{
381
+ if (base.options.min_height >= browserheight && !base.options.fit_landscape){ // If minimum height needs to be considered
382
+ if (browserwidth * ratio >= base.options.min_height || (browserwidth * ratio >= base.options.min_height && ratio <= 1)){ // If resizing would push below minimum height or image is a landscape
383
+ thisSlide.width(browserwidth);
384
+ thisSlide.height(browserwidth * ratio);
385
+ } else if (ratio > 1){ // Else the image is portrait
386
+ thisSlide.height(base.options.min_height);
387
+ thisSlide.width(thisSlide.height() / ratio);
388
+ } else if (thisSlide.width() < browserwidth) {
389
+ thisSlide.width(browserwidth);
390
+ thisSlide.height(thisSlide.width() * ratio);
391
+ }
392
+ }else{ // Otherwise, resize as normal
393
+ thisSlide.width(browserwidth);
394
+ thisSlide.height(browserwidth * ratio);
395
+ }
396
+ }
397
+ };
398
+
399
+ function resizeHeight(minimum){
400
+ if (minimum){ // If minimum height needs to be considered
401
+ if(thisSlide.height() < browserheight){
402
+ if (thisSlide.height() / ratio >= base.options.min_width){
403
+ thisSlide.height(base.options.min_height);
404
+ thisSlide.width(thisSlide.height() / ratio);
405
+ }else{
406
+ resizeWidth(true);
407
+ }
408
+ }
409
+ }else{ // Otherwise, resized as normal
410
+ if (base.options.min_width >= browserwidth){ // If minimum width needs to be considered
411
+ if (browserheight / ratio >= base.options.min_width || ratio > 1){ // If resizing would push below minimum width or image is a portrait
412
+ thisSlide.height(browserheight);
413
+ thisSlide.width(browserheight / ratio);
414
+ } else if (ratio <= 1){ // Else the image is landscape
415
+ thisSlide.width(base.options.min_width);
416
+ thisSlide.height(thisSlide.width() * ratio);
417
+ }
418
+ }else{ // Otherwise, resize as normal
419
+ thisSlide.height(browserheight);
420
+ thisSlide.width(browserheight / ratio);
421
+ }
422
+ }
423
+ };
424
+
425
+ /*-----End Resize Functions-----*/
426
+
427
+ if (thisSlide.parents('li').hasClass('image-loading')){
428
+ $('.image-loading').removeClass('image-loading');
429
+ }
430
+
431
+ // Horizontally Center
432
+ if (base.options.horizontal_center){
433
+ $(this).css('left', (browserwidth - $(this).width())/2);
434
+ }
435
+
436
+ // Vertically Center
437
+ if (base.options.vertical_center){
438
+ $(this).css('top', (browserheight - $(this).height())/2);
439
+ }
440
+
441
+ });
442
+
443
+ // Basic image drag and right click protection
444
+ if (base.options.image_protect){
445
+
446
+ $('img', base.el).bind("contextmenu mousedown",function(){
447
+ return false;
448
+ });
449
+
450
+ }
451
+
452
+ return false;
453
+
454
+ });
455
+
456
+ };
457
+
458
+
459
+ /* Next Slide
460
+ ----------------------------*/
461
+ base.nextSlide = function(){
462
+
463
+ if(vars.in_animation || !api.options.slideshow) return false; // Abort if currently animating
464
+ else vars.in_animation = true; // Otherwise set animation marker
465
+
466
+ clearInterval(vars.slideshow_interval); // Stop slideshow
467
+
468
+ var slides = base.options.slides, // Pull in slides array
469
+ liveslide = base.$el.find('.activeslide'); // Find active slide
470
+ $('.prevslide').removeClass('prevslide');
471
+ liveslide.removeClass('activeslide').addClass('prevslide'); // Remove active class & update previous slide
472
+
473
+ // Get the slide number of new slide
474
+ vars.current_slide + 1 == base.options.slides.length ? vars.current_slide = 0 : vars.current_slide++;
475
+
476
+ var nextslide = $(base.el+' li:eq('+vars.current_slide+')'),
477
+ prevslide = base.$el.find('.prevslide');
478
+
479
+ // If hybrid mode is on drop quality for transition
480
+ if (base.options.performance == 1) base.$el.removeClass('quality').addClass('speed');
481
+
482
+
483
+ /*-----Load Image-----*/
484
+
485
+ loadSlide = false;
486
+
487
+ vars.current_slide == base.options.slides.length - 1 ? loadSlide = 0 : loadSlide = vars.current_slide + 1; // Determine next slide
488
+
489
+ var targetList = base.el+' li:eq('+loadSlide+')';
490
+ if (!$(targetList).html()){
491
+
492
+ // If links should open in new window
493
+ var linkTarget = base.options.new_window ? ' target="_blank"' : '';
494
+
495
+ imageLink = (base.options.slides[loadSlide].url) ? "href='" + base.options.slides[loadSlide].url + "'" : ""; // If link exists, build it
496
+ var img = $('<img src="'+base.options.slides[loadSlide].image+'"/>');
497
+
498
+ img.appendTo(targetList).wrap('<a ' + imageLink + linkTarget + '></a>').parent().parent().addClass('image-loading').css('visibility','hidden');
499
+
500
+ img.load(function(){
501
+ base._origDim($(this));
502
+ base.resizeNow();
503
+ }); // End Load
504
+ };
505
+
506
+ // Update thumbnails (if enabled)
507
+ if (base.options.thumbnail_navigation == 1){
508
+
509
+ // Load previous thumbnail
510
+ vars.current_slide - 1 < 0 ? prevThumb = base.options.slides.length - 1 : prevThumb = vars.current_slide - 1;
511
+ $(vars.prev_thumb).html($("<img/>").attr("src", base.options.slides[prevThumb].image));
512
+
513
+ // Load next thumbnail
514
+ nextThumb = loadSlide;
515
+ $(vars.next_thumb).html($("<img/>").attr("src", base.options.slides[nextThumb].image));
516
+
517
+ }
518
+
519
+
520
+
521
+ /*-----End Load Image-----*/
522
+
523
+
524
+ // Call theme function for before slide transition
525
+ if( typeof theme != 'undefined' && typeof theme.beforeAnimation == "function" ) theme.beforeAnimation('next');
526
+
527
+ //Update slide markers
528
+ if (base.options.slide_links){
529
+ $('.current-slide').removeClass('current-slide');
530
+ $(vars.slide_list +'> li' ).eq(vars.current_slide).addClass('current-slide');
531
+ }
532
+
533
+ nextslide.css('visibility','hidden').addClass('activeslide'); // Update active slide
534
+
535
+ switch(base.options.transition){
536
+ case 0: case 'none': // No transition
537
+ nextslide.css('visibility','visible'); vars.in_animation = false; base.afterAnimation();
538
+ break;
539
+ case 1: case 'fade': // Fade
540
+ nextslide.css({opacity : 0, 'visibility': 'visible'}).animate({opacity : 1, avoidTransforms : false}, base.options.transition_speed, function(){ base.afterAnimation(); });
541
+ break;
542
+ case 2: case 'slideTop': // Slide Top
543
+ nextslide.css({top : -base.$el.height(), 'visibility': 'visible'}).animate({ top:0, avoidTransforms : false }, base.options.transition_speed, function(){ base.afterAnimation(); });
544
+ break;
545
+ case 3: case 'slideRight': // Slide Right
546
+ nextslide.css({left : base.$el.width(), 'visibility': 'visible'}).animate({ left:0, avoidTransforms : false }, base.options.transition_speed, function(){ base.afterAnimation(); });
547
+ break;
548
+ case 4: case 'slideBottom': // Slide Bottom
549
+ nextslide.css({top : base.$el.height(), 'visibility': 'visible'}).animate({ top:0, avoidTransforms : false }, base.options.transition_speed, function(){ base.afterAnimation(); });
550
+ break;
551
+ case 5: case 'slideLeft': // Slide Left
552
+ nextslide.css({left : -base.$el.width(), 'visibility': 'visible'}).animate({ left:0, avoidTransforms : false }, base.options.transition_speed, function(){ base.afterAnimation(); });
553
+ break;
554
+ case 6: case 'carouselRight': // Carousel Right
555
+ nextslide.css({left : base.$el.width(), 'visibility': 'visible'}).animate({ left:0, avoidTransforms : false }, base.options.transition_speed, function(){ base.afterAnimation(); });
556
+ liveslide.animate({ left: -base.$el.width(), avoidTransforms : false }, base.options.transition_speed );
557
+ break;
558
+ case 7: case 'carouselLeft': // Carousel Left
559
+ nextslide.css({left : -base.$el.width(), 'visibility': 'visible'}).animate({ left:0, avoidTransforms : false }, base.options.transition_speed, function(){ base.afterAnimation(); });
560
+ liveslide.animate({ left: base.$el.width(), avoidTransforms : false }, base.options.transition_speed );
561
+ break;
562
+ }
563
+ return false;
564
+ };
565
+
566
+
567
+ /* Previous Slide
568
+ ----------------------------*/
569
+ base.prevSlide = function(){
570
+
571
+ if(vars.in_animation || !api.options.slideshow) return false; // Abort if currently animating
572
+ else vars.in_animation = true; // Otherwise set animation marker
573
+
574
+ clearInterval(vars.slideshow_interval); // Stop slideshow
575
+
576
+ var slides = base.options.slides, // Pull in slides array
577
+ liveslide = base.$el.find('.activeslide'); // Find active slide
578
+ $('.prevslide').removeClass('prevslide');
579
+ liveslide.removeClass('activeslide').addClass('prevslide'); // Remove active class & update previous slide
580
+
581
+ // Get current slide number
582
+ vars.current_slide == 0 ? vars.current_slide = base.options.slides.length - 1 : vars.current_slide-- ;
583
+
584
+ var nextslide = $(base.el+' li:eq('+vars.current_slide+')'),
585
+ prevslide = base.$el.find('.prevslide');
586
+
587
+ // If hybrid mode is on drop quality for transition
588
+ if (base.options.performance == 1) base.$el.removeClass('quality').addClass('speed');
589
+
590
+
591
+ /*-----Load Image-----*/
592
+
593
+ loadSlide = vars.current_slide;
594
+
595
+ var targetList = base.el+' li:eq('+loadSlide+')';
596
+ if (!$(targetList).html()){
597
+ // If links should open in new window
598
+ var linkTarget = base.options.new_window ? ' target="_blank"' : '';
599
+ imageLink = (base.options.slides[loadSlide].url) ? "href='" + base.options.slides[loadSlide].url + "'" : ""; // If link exists, build it
600
+ var img = $('<img src="'+base.options.slides[loadSlide].image+'"/>');
601
+
602
+ img.appendTo(targetList).wrap('<a ' + imageLink + linkTarget + '></a>').parent().parent().addClass('image-loading').css('visibility','hidden');
603
+
604
+ img.load(function(){
605
+ base._origDim($(this));
606
+ base.resizeNow();
607
+ }); // End Load
608
+ };
609
+
610
+ // Update thumbnails (if enabled)
611
+ if (base.options.thumbnail_navigation == 1){
612
+
613
+ // Load previous thumbnail
614
+ //prevThumb = loadSlide;
615
+ loadSlide == 0 ? prevThumb = base.options.slides.length - 1 : prevThumb = loadSlide - 1;
616
+ $(vars.prev_thumb).html($("<img/>").attr("src", base.options.slides[prevThumb].image));
617
+
618
+ // Load next thumbnail
619
+ vars.current_slide == base.options.slides.length - 1 ? nextThumb = 0 : nextThumb = vars.current_slide + 1;
620
+ $(vars.next_thumb).html($("<img/>").attr("src", base.options.slides[nextThumb].image));
621
+ }
622
+
623
+ /*-----End Load Image-----*/
624
+
625
+
626
+ // Call theme function for before slide transition
627
+ if( typeof theme != 'undefined' && typeof theme.beforeAnimation == "function" ) theme.beforeAnimation('prev');
628
+
629
+ //Update slide markers
630
+ if (base.options.slide_links){
631
+ $('.current-slide').removeClass('current-slide');
632
+ $(vars.slide_list +'> li' ).eq(vars.current_slide).addClass('current-slide');
633
+ }
634
+
635
+ nextslide.css('visibility','hidden').addClass('activeslide'); // Update active slide
636
+
637
+ switch(base.options.transition){
638
+ case 0: case 'none': // No transition
639
+ nextslide.css('visibility','visible'); vars.in_animation = false; base.afterAnimation();
640
+ break;
641
+ case 1: case 'fade': // Fade
642
+ nextslide.css({opacity : 0, 'visibility': 'visible'}).animate({opacity : 1, avoidTransforms : false}, base.options.transition_speed, function(){ base.afterAnimation(); });
643
+ break;
644
+ case 2: case 'slideTop': // Slide Top (reverse)
645
+ nextslide.css({top : base.$el.height(), 'visibility': 'visible'}).animate({ top:0, avoidTransforms : false }, base.options.transition_speed, function(){ base.afterAnimation(); });
646
+ break;
647
+ case 3: case 'slideRight': // Slide Right (reverse)
648
+ nextslide.css({left : -base.$el.width(), 'visibility': 'visible'}).animate({ left:0, avoidTransforms : false }, base.options.transition_speed, function(){ base.afterAnimation(); });
649
+ break;
650
+ case 4: case 'slideBottom': // Slide Bottom (reverse)
651
+ nextslide.css({top : -base.$el.height(), 'visibility': 'visible'}).animate({ top:0, avoidTransforms : false }, base.options.transition_speed, function(){ base.afterAnimation(); });
652
+ break;
653
+ case 5: case 'slideLeft': // Slide Left (reverse)
654
+ nextslide.css({left : base.$el.width(), 'visibility': 'visible'}).animate({ left:0, avoidTransforms : false }, base.options.transition_speed, function(){ base.afterAnimation(); });
655
+ break;
656
+ case 6: case 'carouselRight': // Carousel Right (reverse)
657
+ nextslide.css({left : -base.$el.width(), 'visibility': 'visible'}).animate({ left:0, avoidTransforms : false }, base.options.transition_speed, function(){ base.afterAnimation(); });
658
+ liveslide.css({left : 0}).animate({ left: base.$el.width(), avoidTransforms : false}, base.options.transition_speed );
659
+ break;
660
+ case 7: case 'carouselLeft': // Carousel Left (reverse)
661
+ nextslide.css({left : base.$el.width(), 'visibility': 'visible'}).animate({ left:0, avoidTransforms : false }, base.options.transition_speed, function(){ base.afterAnimation(); });
662
+ liveslide.css({left : 0}).animate({ left: -base.$el.width(), avoidTransforms : false }, base.options.transition_speed );
663
+ break;
664
+ }
665
+ return false;
666
+ };
667
+
668
+
669
+ /* Play/Pause Toggle
670
+ ----------------------------*/
671
+ base.playToggle = function(){
672
+
673
+ if (vars.in_animation || !api.options.slideshow) return false; // Abort if currently animating
674
+
675
+ if (vars.is_paused){
676
+
677
+ vars.is_paused = false;
678
+
679
+ // Call theme function for play
680
+ if( typeof theme != 'undefined' && typeof theme.playToggle == "function" ) theme.playToggle('play');
681
+
682
+ // Resume slideshow
683
+ vars.slideshow_interval = setInterval(base.nextSlide, base.options.slide_interval);
684
+
685
+ }else{
686
+
687
+ vars.is_paused = true;
688
+
689
+ // Call theme function for pause
690
+ if( typeof theme != 'undefined' && typeof theme.playToggle == "function" ) theme.playToggle('pause');
691
+
692
+ // Stop slideshow
693
+ clearInterval(vars.slideshow_interval);
694
+
695
+ }
696
+
697
+ return false;
698
+
699
+ };
700
+
701
+
702
+ /* Go to specific slide
703
+ ----------------------------*/
704
+ base.goTo = function(targetSlide){
705
+ if (vars.in_animation || !api.options.slideshow) return false; // Abort if currently animating
706
+
707
+ var totalSlides = base.options.slides.length;
708
+
709
+ // If target outside range
710
+ if(targetSlide < 0){
711
+ targetSlide = totalSlides;
712
+ }else if(targetSlide > totalSlides){
713
+ targetSlide = 1;
714
+ }
715
+ targetSlide = totalSlides - targetSlide + 1;
716
+
717
+ clearInterval(vars.slideshow_interval); // Stop slideshow, prevent buildup
718
+
719
+ // Call theme function for goTo trigger
720
+ if (typeof theme != 'undefined' && typeof theme.goTo == "function" ) theme.goTo();
721
+
722
+ if (vars.current_slide == totalSlides - targetSlide){
723
+ if(!(vars.is_paused)){
724
+ vars.slideshow_interval = setInterval(base.nextSlide, base.options.slide_interval);
725
+ }
726
+ return false;
727
+ }
728
+
729
+ // If ahead of current position
730
+ if(totalSlides - targetSlide > vars.current_slide ){
731
+
732
+ // Adjust for new next slide
733
+ vars.current_slide = totalSlides-targetSlide-1;
734
+ vars.update_images = 'next';
735
+ base._placeSlide(vars.update_images);
736
+
737
+ //Otherwise it's before current position
738
+ }else if(totalSlides - targetSlide < vars.current_slide){
739
+
740
+ // Adjust for new prev slide
741
+ vars.current_slide = totalSlides-targetSlide+1;
742
+ vars.update_images = 'prev';
743
+ base._placeSlide(vars.update_images);
744
+
745
+ }
746
+
747
+ // set active markers
748
+ if (base.options.slide_links){
749
+ $(vars.slide_list +'> .current-slide').removeClass('current-slide');
750
+ $(vars.slide_list +'> li').eq((totalSlides-targetSlide)).addClass('current-slide');
751
+ }
752
+
753
+ if (base.options.thumb_links){
754
+ $(vars.thumb_list +'> .current-thumb').removeClass('current-thumb');
755
+ $(vars.thumb_list +'> li').eq((totalSlides-targetSlide)).addClass('current-thumb');
756
+ }
757
+
758
+ };
759
+
760
+
761
+ /* Place Slide
762
+ ----------------------------*/
763
+ base._placeSlide = function(place){
764
+
765
+ // If links should open in new window
766
+ var linkTarget = base.options.new_window ? ' target="_blank"' : '';
767
+
768
+ loadSlide = false;
769
+
770
+ if (place == 'next'){
771
+
772
+ vars.current_slide == base.options.slides.length - 1 ? loadSlide = 0 : loadSlide = vars.current_slide + 1; // Determine next slide
773
+
774
+ var targetList = base.el+' li:eq('+loadSlide+')';
775
+
776
+ if (!$(targetList).html()){
777
+ // If links should open in new window
778
+ var linkTarget = base.options.new_window ? ' target="_blank"' : '';
779
+
780
+ imageLink = (base.options.slides[loadSlide].url) ? "href='" + base.options.slides[loadSlide].url + "'" : ""; // If link exists, build it
781
+ var img = $('<img src="'+base.options.slides[loadSlide].image+'"/>');
782
+
783
+ img.appendTo(targetList).wrap('<a ' + imageLink + linkTarget + '></a>').parent().parent().addClass('image-loading').css('visibility','hidden');
784
+
785
+ img.load(function(){
786
+ base._origDim($(this));
787
+ base.resizeNow();
788
+ }); // End Load
789
+ };
790
+
791
+ base.nextSlide();
792
+
793
+ }else if (place == 'prev'){
794
+
795
+ vars.current_slide - 1 < 0 ? loadSlide = base.options.slides.length - 1 : loadSlide = vars.current_slide - 1; // Determine next slide
796
+
797
+ var targetList = base.el+' li:eq('+loadSlide+')';
798
+
799
+ if (!$(targetList).html()){
800
+ // If links should open in new window
801
+ var linkTarget = base.options.new_window ? ' target="_blank"' : '';
802
+
803
+ imageLink = (base.options.slides[loadSlide].url) ? "href='" + base.options.slides[loadSlide].url + "'" : ""; // If link exists, build it
804
+ var img = $('<img src="'+base.options.slides[loadSlide].image+'"/>');
805
+
806
+ img.appendTo(targetList).wrap('<a ' + imageLink + linkTarget + '></a>').parent().parent().addClass('image-loading').css('visibility','hidden');
807
+
808
+ img.load(function(){
809
+ base._origDim($(this));
810
+ base.resizeNow();
811
+ }); // End Load
812
+ };
813
+ base.prevSlide();
814
+ }
815
+
816
+ };
817
+
818
+
819
+ /* Get Original Dimensions
820
+ ----------------------------*/
821
+ base._origDim = function(targetSlide){
822
+ targetSlide.data('origWidth', targetSlide.width()).data('origHeight', targetSlide.height());
823
+ };
824
+
825
+
826
+ /* After Slide Animation
827
+ ----------------------------*/
828
+ base.afterAnimation = function(){
829
+
830
+ // If hybrid mode is on swap back to higher image quality
831
+ if (base.options.performance == 1){
832
+ base.$el.removeClass('speed').addClass('quality');
833
+ }
834
+
835
+ // Update previous slide
836
+ if (vars.update_images){
837
+ vars.current_slide - 1 < 0 ? setPrev = base.options.slides.length - 1 : setPrev = vars.current_slide-1;
838
+ vars.update_images = false;
839
+ $('.prevslide').removeClass('prevslide');
840
+ $(base.el+' li:eq('+setPrev+')').addClass('prevslide');
841
+ }
842
+
843
+ vars.in_animation = false;
844
+
845
+ // Resume slideshow
846
+ if (!vars.is_paused && base.options.slideshow){
847
+ vars.slideshow_interval = setInterval(base.nextSlide, base.options.slide_interval);
848
+ if (base.options.stop_loop && vars.current_slide == base.options.slides.length - 1 ) base.playToggle();
849
+ }
850
+
851
+ // Call theme function for after slide transition
852
+ if (typeof theme != 'undefined' && typeof theme.afterAnimation == "function" ) theme.afterAnimation();
853
+
854
+ return false;
855
+
856
+ };
857
+
858
+ base.getField = function(field){
859
+ return base.options.slides[vars.current_slide][field];
860
+ };
861
+
862
+ // Make it go!
863
+ base.init();
864
+ };
865
+
866
+
867
+ /* Global Variables
868
+ ----------------------------*/
869
+ $.supersized.vars = {
870
+
871
+ // Elements
872
+ thumb_tray : '#thumb-tray', // Thumbnail tray
873
+ thumb_list : '#thumb-list', // Thumbnail list
874
+ slide_list : '#slide-list', // Slide link list
875
+
876
+ // Internal variables
877
+ current_slide : 0, // Current slide number
878
+ in_animation : false, // Prevents animations from stacking
879
+ is_paused : false, // Tracks paused on/off
880
+ hover_pause : false, // If slideshow is paused from hover
881
+ slideshow_interval : false, // Stores slideshow timer
882
+ update_images : false, // Trigger to update images after slide jump
883
+ options : {} // Stores assembled options list
884
+
885
+ };
886
+
887
+
888
+ /* Default Options
889
+ ----------------------------*/
890
+ $.supersized.defaultOptions = {
891
+
892
+ // Functionality
893
+ slideshow : 1, // Slideshow on/off
894
+ autoplay : 1, // Slideshow starts playing automatically
895
+ start_slide : 1, // Start slide (0 is random)
896
+ stop_loop : 0, // Stops slideshow on last slide
897
+ random : 0, // Randomize slide order (Ignores start slide)
898
+ slide_interval : 5000, // Length between transitions
899
+ transition : 1, // 0-None, 1-Fade, 2-Slide Top, 3-Slide Right, 4-Slide Bottom, 5-Slide Left, 6-Carousel Right, 7-Carousel Left
900
+ transition_speed : 750, // Speed of transition
901
+ new_window : 1, // Image links open in new window/tab
902
+ pause_hover : 0, // Pause slideshow on hover
903
+ keyboard_nav : 1, // Keyboard navigation on/off
904
+ performance : 1, // 0-Normal, 1-Hybrid speed/quality, 2-Optimizes image quality, 3-Optimizes transition speed // (Only works for Firefox/IE, not Webkit)
905
+ image_protect : 1, // Disables image dragging and right click with Javascript
906
+
907
+ // Size & Position
908
+ fit_always : 0, // Image will never exceed browser width or height (Ignores min. dimensions)
909
+ fit_landscape : 0, // Landscape images will not exceed browser width
910
+ fit_portrait : 1, // Portrait images will not exceed browser height
911
+ min_width : 0, // Min width allowed (in pixels)
912
+ min_height : 0, // Min height allowed (in pixels)
913
+ horizontal_center : 1, // Horizontally center background
914
+ vertical_center : 1, // Vertically center background
915
+
916
+
917
+ // Components
918
+ slide_links : 1, // Individual links for each slide (Options: false, 'num', 'name', 'blank')
919
+ thumb_links : 1, // Individual thumb links for each slide
920
+ thumbnail_navigation : 0 // Thumbnail navigation
921
+
922
+ };
923
+
924
+ $.fn.supersized = function(options){
925
+ return this.each(function(){
926
+ (new $.supersized(options));
927
+ });
928
+ };
929
+
930
+ })(jQuery);
931
+
skin/frontend/default/default/bannernext/supersized/js/supersized.3.2.7.min.js ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ /*
2
+
3
+ Supersized - Fullscreen Slideshow jQuery Plugin
4
+ Version : 3.2.7
5
+ Site : www.buildinternet.com/project/supersized
6
+
7
+ Author : Sam Dunn
8
+ Company : One Mighty Roar (www.onemightyroar.com)
9
+ License : MIT License / GPL License
10
+
11
+ */(function(e){e(document).ready(function(){e("body").append('<div id="supersized-loader"></div><ul id="supersized"></ul>')});e.supersized=function(t){var n="#supersized",r=this;r.$el=e(n);r.el=n;vars=e.supersized.vars;r.$el.data("supersized",r);api=r.$el.data("supersized");r.init=function(){e.supersized.vars=e.extend(e.supersized.vars,e.supersized.themeVars);e.supersized.vars.options=e.extend({},e.supersized.defaultOptions,e.supersized.themeOptions,t);r.options=e.supersized.vars.options;r._build()};r._build=function(){var t=0,n="",i="",s,o="",u;while(t<=r.options.slides.length-1){switch(r.options.slide_links){case"num":s=t;break;case"name":s=r.options.slides[t].title;break;case"blank":s=""}n=n+'<li class="slide-'+t+'"></li>';if(t==r.options.start_slide-1){r.options.slide_links&&(i=i+'<li class="slide-link-'+t+' current-slide"><a>'+s+"</a></li>");if(r.options.thumb_links){r.options.slides[t].thumb?u=r.options.slides[t].thumb:u=r.options.slides[t].image;o=o+'<li class="thumb'+t+' current-thumb"><img src="'+u+'"/></li>'}}else{r.options.slide_links&&(i=i+'<li class="slide-link-'+t+'" ><a>'+s+"</a></li>");if(r.options.thumb_links){r.options.slides[t].thumb?u=r.options.slides[t].thumb:u=r.options.slides[t].image;o=o+'<li class="thumb'+t+'"><img src="'+u+'"/></li>'}}t++}r.options.slide_links&&e(vars.slide_list).html(i);r.options.thumb_links&&vars.thumb_tray.length&&e(vars.thumb_tray).append('<ul id="'+vars.thumb_list.replace("#","")+'">'+o+"</ul>");e(r.el).append(n);if(r.options.thumbnail_navigation){vars.current_slide-1<0?prevThumb=r.options.slides.length-1:prevThumb=vars.current_slide-1;e(vars.prev_thumb).show().html(e("<img/>").attr("src",r.options.slides[prevThumb].image));vars.current_slide==r.options.slides.length-1?nextThumb=0:nextThumb=vars.current_slide+1;e(vars.next_thumb).show().html(e("<img/>").attr("src",r.options.slides[nextThumb].image))}r._start()};r._start=function(){r.options.start_slide?vars.current_slide=r.options.start_slide-1:vars.current_slide=Math.floor(Math.random()*r.options.slides.length);var t=r.options.new_window?' target="_blank"':"";r.options.performance==3?r.$el.addClass("speed"):(r.options.performance==1||r.options.performance==2)&&r.$el.addClass("quality");if(r.options.random){arr=r.options.slides;for(var n,i,s=arr.length;s;n=parseInt(Math.random()*s),i=arr[--s],arr[s]=arr[n],arr[n]=i);r.options.slides=arr}if(r.options.slides.length>1){if(r.options.slides.length>2){vars.current_slide-1<0?loadPrev=r.options.slides.length-1:loadPrev=vars.current_slide-1;var o=r.options.slides[loadPrev].url?"href='"+r.options.slides[loadPrev].url+"'":"",u=e('<img src="'+r.options.slides[loadPrev].image+'"/>'),a=r.el+" li:eq("+loadPrev+")";u.appendTo(a).wrap("<a "+o+t+"></a>").parent().parent().addClass("image-loading prevslide");u.load(function(){e(this).data("origWidth",e(this).width()).data("origHeight",e(this).height());r.resizeNow()})}}else r.options.slideshow=0;o=api.getField("url")?"href='"+api.getField("url")+"'":"";var f=e('<img src="'+api.getField("image")+'"/>'),l=r.el+" li:eq("+vars.current_slide+")";f.appendTo(l).wrap("<a "+o+t+"></a>").parent().parent().addClass("image-loading activeslide");f.load(function(){r._origDim(e(this));r.resizeNow();r.launch();typeof theme!="undefined"&&typeof theme._init=="function"&&theme._init()});if(r.options.slides.length>1){vars.current_slide==r.options.slides.length-1?loadNext=0:loadNext=vars.current_slide+1;o=r.options.slides[loadNext].url?"href='"+r.options.slides[loadNext].url+"'":"";var c=e('<img src="'+r.options.slides[loadNext].image+'"/>'),h=r.el+" li:eq("+loadNext+")";c.appendTo(h).wrap("<a "+o+t+"></a>").parent().parent().addClass("image-loading");c.load(function(){e(this).data("origWidth",e(this).width()).data("origHeight",e(this).height());r.resizeNow()})}r.$el.css("visibility","hidden");e(".load-item").hide()};r.launch=function(){r.$el.css("visibility","visible");e("#supersized-loader").remove();typeof theme!="undefined"&&typeof theme.beforeAnimation=="function"&&theme.beforeAnimation("next");e(".load-item").show();r.options.keyboard_nav&&e(document.documentElement).keyup(function(e){if(vars.in_animation)return!1;if(e.keyCode==37||e.keyCode==40){clearInterval(vars.slideshow_interval);r.prevSlide()}else if(e.keyCode==39||e.keyCode==38){clearInterval(vars.slideshow_interval);r.nextSlide()}else if(e.keyCode==32&&!vars.hover_pause){clearInterval(vars.slideshow_interval);r.playToggle()}});r.options.slideshow&&r.options.pause_hover&&e(r.el).hover(function(){if(vars.in_animation)return!1;vars.hover_pause=!0;if(!vars.is_paused){vars.hover_pause="resume";r.playToggle()}},function(){if(vars.hover_pause=="resume"){r.playToggle();vars.hover_pause=!1}});r.options.slide_links&&e(vars.slide_list+"> li").click(function(){index=e(vars.slide_list+"> li").index(this);targetSlide=index+1;r.goTo(targetSlide);return!1});r.options.thumb_links&&e(vars.thumb_list+"> li").click(function(){index=e(vars.thumb_list+"> li").index(this);targetSlide=index+1;api.goTo(targetSlide);return!1});if(r.options.slideshow&&r.options.slides.length>1){r.options.autoplay&&r.options.slides.length>1?vars.slideshow_interval=setInterval(r.nextSlide,r.options.slide_interval):vars.is_paused=!0;e(".load-item img").bind("contextmenu mousedown",function(){return!1})}e(window).resize(function(){r.resizeNow()})};r.resizeNow=function(){return r.$el.each(function(){e("img",r.el).each(function(){function o(e){if(e){if(thisSlide.width()<n||thisSlide.width()<r.options.min_width)if(thisSlide.width()*t>=r.options.min_height){thisSlide.width(r.options.min_width);thisSlide.height(thisSlide.width()*t)}else u()}else if(r.options.min_height>=i&&!r.options.fit_landscape){if(n*t>=r.options.min_height||n*t>=r.options.min_height&&t<=1){thisSlide.width(n);thisSlide.height(n*t)}else if(t>1){thisSlide.height(r.options.min_height);thisSlide.width(thisSlide.height()/t)}else if(thisSlide.width()<n){thisSlide.width(n);thisSlide.height(thisSlide.width()*t)}}else{thisSlide.width(n);thisSlide.height(n*t)}}function u(e){if(e){if(thisSlide.height()<i)if(thisSlide.height()/t>=r.options.min_width){thisSlide.height(r.options.min_height);thisSlide.width(thisSlide.height()/t)}else o(!0)}else if(r.options.min_width>=n){if(i/t>=r.options.min_width||t>1){thisSlide.height(i);thisSlide.width(i/t)}else if(t<=1){thisSlide.width(r.options.min_width);thisSlide.height(thisSlide.width()*t)}}else{thisSlide.height(i);thisSlide.width(i/t)}}thisSlide=e(this);var t=(thisSlide.data("origHeight")/thisSlide.data("origWidth")).toFixed(2),n=r.$el.width(),i=r.$el.height(),s;r.options.fit_always?i/n>t?o():u():i<=r.options.min_height&&n<=r.options.min_width?i/n>t?r.options.fit_landscape&&t<1?o(!0):u(!0):r.options.fit_portrait&&t>=1?u(!0):o(!0):n<=r.options.min_width?i/n>t?r.options.fit_landscape&&t<1?o(!0):u():r.options.fit_portrait&&t>=1?u():o(!0):i<=r.options.min_height?i/n>t?r.options.fit_landscape&&t<1?o():u(!0):r.options.fit_portrait&&t>=1?u(!0):o():i/n>t?r.options.fit_landscape&&t<1?o():u():r.options.fit_portrait&&t>=1?u():o();thisSlide.parents("li").hasClass("image-loading")&&e(".image-loading").removeClass("image-loading");r.options.horizontal_center&&e(this).css("left",(n-e(this).width())/2);r.options.vertical_center&&e(this).css("top",(i-e(this).height())/2)});r.options.image_protect&&e("img",r.el).bind("contextmenu mousedown",function(){return!1});return!1})};r.nextSlide=function(){if(vars.in_animation||!api.options.slideshow)return!1;vars.in_animation=!0;clearInterval(vars.slideshow_interval);var t=r.options.slides,n=r.$el.find(".activeslide");e(".prevslide").removeClass("prevslide");n.removeClass("activeslide").addClass("prevslide");vars.current_slide+1==r.options.slides.length?vars.current_slide=0:vars.current_slide++;var i=e(r.el+" li:eq("+vars.current_slide+")"),s=r.$el.find(".prevslide");r.options.performance==1&&r.$el.removeClass("quality").addClass("speed");loadSlide=!1;vars.current_slide==r.options.slides.length-1?loadSlide=0:loadSlide=vars.current_slide+1;var o=r.el+" li:eq("+loadSlide+")";if(!e(o).html()){var u=r.options.new_window?' target="_blank"':"";imageLink=r.options.slides[loadSlide].url?"href='"+r.options.slides[loadSlide].url+"'":"";var a=e('<img src="'+r.options.slides[loadSlide].image+'"/>');a.appendTo(o).wrap("<a "+imageLink+u+"></a>").parent().parent().addClass("image-loading").css("visibility","hidden");a.load(function(){r._origDim(e(this));r.resizeNow()})}if(r.options.thumbnail_navigation==1){vars.current_slide-1<0?prevThumb=r.options.slides.length-1:prevThumb=vars.current_slide-1;e(vars.prev_thumb).html(e("<img/>").attr("src",r.options.slides[prevThumb].image));nextThumb=loadSlide;e(vars.next_thumb).html(e("<img/>").attr("src",r.options.slides[nextThumb].image))}typeof theme!="undefined"&&typeof theme.beforeAnimation=="function"&&theme.beforeAnimation("next");if(r.options.slide_links){e(".current-slide").removeClass("current-slide");e(vars.slide_list+"> li").eq(vars.current_slide).addClass("current-slide")}i.css("visibility","hidden").addClass("activeslide");switch(r.options.transition){case 0:case"none":i.css("visibility","visible");vars.in_animation=!1;r.afterAnimation();break;case 1:case"fade":i.css({opacity:0,visibility:"visible"}).animate({opacity:1,avoidTransforms:!1},r.options.transition_speed,function(){r.afterAnimation()});break;case 2:case"slideTop":i.css({top:-r.$el.height(),visibility:"visible"}).animate({top:0,avoidTransforms:!1},r.options.transition_speed,function(){r.afterAnimation()});break;case 3:case"slideRight":i.css({left:r.$el.width(),visibility:"visible"}).animate({left:0,avoidTransforms:!1},r.options.transition_speed,function(){r.afterAnimation()});break;case 4:case"slideBottom":i.css({top:r.$el.height(),visibility:"visible"}).animate({top:0,avoidTransforms:!1},r.options.transition_speed,function(){r.afterAnimation()});break;case 5:case"slideLeft":i.css({left:-r.$el.width(),visibility:"visible"}).animate({left:0,avoidTransforms:!1},r.options.transition_speed,function(){r.afterAnimation()});break;case 6:case"carouselRight":i.css({left:r.$el.width(),visibility:"visible"}).animate({left:0,avoidTransforms:!1},r.options.transition_speed,function(){r.afterAnimation()});n.animate({left:-r.$el.width(),avoidTransforms:!1},r.options.transition_speed);break;case 7:case"carouselLeft":i.css({left:-r.$el.width(),visibility:"visible"}).animate({left:0,avoidTransforms:!1},r.options.transition_speed,function(){r.afterAnimation()});n.animate({left:r.$el.width(),avoidTransforms:!1},r.options.transition_speed)}return!1};r.prevSlide=function(){if(vars.in_animation||!api.options.slideshow)return!1;vars.in_animation=!0;clearInterval(vars.slideshow_interval);var t=r.options.slides,n=r.$el.find(".activeslide");e(".prevslide").removeClass("prevslide");n.removeClass("activeslide").addClass("prevslide");vars.current_slide==0?vars.current_slide=r.options.slides.length-1:vars.current_slide--;var i=e(r.el+" li:eq("+vars.current_slide+")"),s=r.$el.find(".prevslide");r.options.performance==1&&r.$el.removeClass("quality").addClass("speed");loadSlide=vars.current_slide;var o=r.el+" li:eq("+loadSlide+")";if(!e(o).html()){var u=r.options.new_window?' target="_blank"':"";imageLink=r.options.slides[loadSlide].url?"href='"+r.options.slides[loadSlide].url+"'":"";var a=e('<img src="'+r.options.slides[loadSlide].image+'"/>');a.appendTo(o).wrap("<a "+imageLink+u+"></a>").parent().parent().addClass("image-loading").css("visibility","hidden");a.load(function(){r._origDim(e(this));r.resizeNow()})}if(r.options.thumbnail_navigation==1){loadSlide==0?prevThumb=r.options.slides.length-1:prevThumb=loadSlide-1;e(vars.prev_thumb).html(e("<img/>").attr("src",r.options.slides[prevThumb].image));vars.current_slide==r.options.slides.length-1?nextThumb=0:nextThumb=vars.current_slide+1;e(vars.next_thumb).html(e("<img/>").attr("src",r.options.slides[nextThumb].image))}typeof theme!="undefined"&&typeof theme.beforeAnimation=="function"&&theme.beforeAnimation("prev");if(r.options.slide_links){e(".current-slide").removeClass("current-slide");e(vars.slide_list+"> li").eq(vars.current_slide).addClass("current-slide")}i.css("visibility","hidden").addClass("activeslide");switch(r.options.transition){case 0:case"none":i.css("visibility","visible");vars.in_animation=!1;r.afterAnimation();break;case 1:case"fade":i.css({opacity:0,visibility:"visible"}).animate({opacity:1,avoidTransforms:!1},r.options.transition_speed,function(){r.afterAnimation()});break;case 2:case"slideTop":i.css({top:r.$el.height(),visibility:"visible"}).animate({top:0,avoidTransforms:!1},r.options.transition_speed,function(){r.afterAnimation()});break;case 3:case"slideRight":i.css({left:-r.$el.width(),visibility:"visible"}).animate({left:0,avoidTransforms:!1},r.options.transition_speed,function(){r.afterAnimation()});break;case 4:case"slideBottom":i.css({top:-r.$el.height(),visibility:"visible"}).animate({top:0,avoidTransforms:!1},r.options.transition_speed,function(){r.afterAnimation()});break;case 5:case"slideLeft":i.css({left:r.$el.width(),visibility:"visible"}).animate({left:0,avoidTransforms:!1},r.options.transition_speed,function(){r.afterAnimation()});break;case 6:case"carouselRight":i.css({left:-r.$el.width(),visibility:"visible"}).animate({left:0,avoidTransforms:!1},r.options.transition_speed,function(){r.afterAnimation()});n.css({left:0}).animate({left:r.$el.width(),avoidTransforms:!1},r.options.transition_speed);break;case 7:case"carouselLeft":i.css({left:r.$el.width(),visibility:"visible"}).animate({left:0,avoidTransforms:!1},r.options.transition_speed,function(){r.afterAnimation()});n.css({left:0}).animate({left:-r.$el.width(),avoidTransforms:!1},r.options.transition_speed)}return!1};r.playToggle=function(){if(vars.in_animation||!api.options.slideshow)return!1;if(vars.is_paused){vars.is_paused=!1;typeof theme!="undefined"&&typeof theme.playToggle=="function"&&theme.playToggle("play");vars.slideshow_interval=setInterval(r.nextSlide,r.options.slide_interval)}else{vars.is_paused=!0;typeof theme!="undefined"&&typeof theme.playToggle=="function"&&theme.playToggle("pause");clearInterval(vars.slideshow_interval)}return!1};r.goTo=function(t){if(vars.in_animation||!api.options.slideshow)return!1;var n=r.options.slides.length;t<0?t=n:t>n&&(t=1);t=n-t+1;clearInterval(vars.slideshow_interval);typeof theme!="undefined"&&typeof theme.goTo=="function"&&theme.goTo();if(vars.current_slide==n-t){vars.is_paused||(vars.slideshow_interval=setInterval(r.nextSlide,r.options.slide_interval));return!1}if(n-t>vars.current_slide){vars.current_slide=n-t-1;vars.update_images="next";r._placeSlide(vars.update_images)}else if(n-t<vars.current_slide){vars.current_slide=n-t+1;vars.update_images="prev";r._placeSlide(vars.update_images)}if(r.options.slide_links){e(vars.slide_list+"> .current-slide").removeClass("current-slide");e(vars.slide_list+"> li").eq(n-t).addClass("current-slide")}if(r.options.thumb_links){e(vars.thumb_list+"> .current-thumb").removeClass("current-thumb");e(vars.thumb_list+"> li").eq(n-t).addClass("current-thumb")}};r._placeSlide=function(t){var n=r.options.new_window?' target="_blank"':"";loadSlide=!1;if(t=="next"){vars.current_slide==r.options.slides.length-1?loadSlide=0:loadSlide=vars.current_slide+1;var i=r.el+" li:eq("+loadSlide+")";if(!e(i).html()){var n=r.options.new_window?' target="_blank"':"";imageLink=r.options.slides[loadSlide].url?"href='"+r.options.slides[loadSlide].url+"'":"";var s=e('<img src="'+r.options.slides[loadSlide].image+'"/>');s.appendTo(i).wrap("<a "+imageLink+n+"></a>").parent().parent().addClass("image-loading").css("visibility","hidden");s.load(function(){r._origDim(e(this));r.resizeNow()})}r.nextSlide()}else if(t=="prev"){vars.current_slide-1<0?loadSlide=r.options.slides.length-1:loadSlide=vars.current_slide-1;var i=r.el+" li:eq("+loadSlide+")";if(!e(i).html()){var n=r.options.new_window?' target="_blank"':"";imageLink=r.options.slides[loadSlide].url?"href='"+r.options.slides[loadSlide].url+"'":"";var s=e('<img src="'+r.options.slides[loadSlide].image+'"/>');s.appendTo(i).wrap("<a "+imageLink+n+"></a>").parent().parent().addClass("image-loading").css("visibility","hidden");s.load(function(){r._origDim(e(this));r.resizeNow()})}r.prevSlide()}};r._origDim=function(e){e.data("origWidth",e.width()).data("origHeight",e.height())};r.afterAnimation=function(){r.options.performance==1&&r.$el.removeClass("speed").addClass("quality");if(vars.update_images){vars.current_slide-1<0?setPrev=r.options.slides.length-1:setPrev=vars.current_slide-1;vars.update_images=!1;e(".prevslide").removeClass("prevslide");e(r.el+" li:eq("+setPrev+")").addClass("prevslide")}vars.in_animation=!1;if(!vars.is_paused&&r.options.slideshow){vars.slideshow_interval=setInterval(r.nextSlide,r.options.slide_interval);r.options.stop_loop&&vars.current_slide==r.options.slides.length-1&&r.playToggle()}typeof theme!="undefined"&&typeof theme.afterAnimation=="function"&&theme.afterAnimation();return!1};r.getField=function(e){return r.options.slides[vars.current_slide][e]};r.init()};e.supersized.vars={thumb_tray:"#thumb-tray",thumb_list:"#thumb-list",slide_list:"#slide-list",current_slide:0,in_animation:!1,is_paused:!1,hover_pause:!1,slideshow_interval:!1,update_images:!1,options:{}};e.supersized.defaultOptions={slideshow:1,autoplay:1,start_slide:1,stop_loop:0,random:0,slide_interval:5e3,transition:1,transition_speed:750,new_window:1,pause_hover:0,keyboard_nav:1,performance:1,image_protect:1,fit_always:0,fit_landscape:0,fit_portrait:1,min_width:0,min_height:0,horizontal_center:1,vertical_center:1,slide_links:1,thumb_links:1,thumbnail_navigation:0};e.fn.supersized=function(t){return this.each(function(){new e.supersized(t)})}})(jQuery);
skin/frontend/default/default/bannernext/supersized/js/supersized.core.3.2.1.js ADDED
@@ -0,0 +1,304 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /*
2
+
3
+ Supersized - Fullscreen Slideshow jQuery Plugin
4
+ Version : Core 3.2.1
5
+ Site : www.buildinternet.com/project/supersized
6
+
7
+ Author : Sam Dunn
8
+ Company : One Mighty Roar (www.onemightyroar.com)
9
+ License : MIT License / GPL License
10
+
11
+ */
12
+
13
+ (function($){
14
+
15
+ /* Place Supersized Elements
16
+ ----------------------------*/
17
+ $(document).ready(function() {
18
+ $('body').append('<div id="supersized-loader"></div><div id="supersized"></div>');
19
+ });
20
+
21
+
22
+ $.supersized = function(options){
23
+
24
+ /* Variables
25
+ ----------------------------*/
26
+ var el = '#supersized',
27
+ base = this;
28
+ // Access to jQuery and DOM versions of element
29
+ base.$el = $(el);
30
+ base.el = el;
31
+ vars = $.supersized.vars;
32
+ // Add a reverse reference to the DOM object
33
+ base.$el.data("supersized", base);
34
+ api = base.$el.data('supersized');
35
+
36
+ base.init = function(){
37
+ // Combine options
38
+ $.supersized.vars.options = $.extend({},$.supersized.defaultOptions, options);
39
+ base.options = $.supersized.vars.options;
40
+
41
+ base._build();
42
+ };
43
+
44
+
45
+ /* Build Elements
46
+ ----------------------------*/
47
+ base._build = function(){
48
+
49
+ base._start(); // Get things started
50
+ };
51
+
52
+
53
+ /* Initialize
54
+ ----------------------------*/
55
+ base._start = function(){
56
+
57
+ // Determine if starting slide random
58
+ if (base.options.start_slide){
59
+ vars.current_slide = base.options.start_slide - 1;
60
+ }else{
61
+ vars.current_slide = Math.floor(Math.random()*base.options.slides.length); // Generate random slide number
62
+ }
63
+
64
+ // If links should open in new window
65
+ var linkTarget = base.options.new_window ? ' target="_blank"' : '';
66
+
67
+ // Set current image
68
+ imageLink = (api.getField('url')) ? "href='" + api.getField('url') + "'" : "";
69
+ var img = $('<img src="'+api.getField('image')+'"/>');
70
+ img.appendTo(base.el).wrap('<a class="image-loading activeslide" ' + imageLink + linkTarget + '></a>').css('visibility','hidden');
71
+
72
+ img.load(function(){
73
+ base._origDim($(this));
74
+ base.resizeNow(); // Resize background image
75
+ base.launch();
76
+ });
77
+
78
+ // Hide elements to be faded in
79
+ base.$el.css('visibility','hidden');
80
+
81
+ };
82
+
83
+
84
+ /* Launch Supersized
85
+ ----------------------------*/
86
+ base.launch = function(){
87
+
88
+ base.$el.css('visibility','visible');
89
+ $('#supersized-loader').hide(); //Hide loading animation
90
+
91
+ // Adjust image when browser is resized
92
+ $(window).resize(function(){
93
+ base.resizeNow();
94
+ });
95
+
96
+ };
97
+
98
+
99
+ /* Resize Images
100
+ ----------------------------*/
101
+ base.resizeNow = function(){
102
+
103
+ return base.$el.each(function() {
104
+ // Resize each image seperately
105
+ $('img', base.el).each(function(){
106
+
107
+ thisSlide = $(this);
108
+ var ratio = (thisSlide.data('origHeight')/thisSlide.data('origWidth')).toFixed(2); // Define image ratio
109
+
110
+ // Gather browser size
111
+ var browserwidth = base.$el.width(),
112
+ browserheight = base.$el.height(),
113
+ offset;
114
+
115
+ /*-----Resize Image-----*/
116
+ if (base.options.fit_always){ // Fit always is enabled
117
+ if ((browserheight/browserwidth) > ratio){
118
+ resizeWidth();
119
+ } else {
120
+ resizeHeight();
121
+ }
122
+ }else{ // Normal Resize
123
+ if ((browserheight <= base.options.min_height) && (browserwidth <= base.options.min_width)){ // If window smaller than minimum width and height
124
+
125
+ if ((browserheight/browserwidth) > ratio){
126
+ base.options.fit_landscape && ratio < 1 ? resizeWidth(true) : resizeHeight(true); // If landscapes are set to fit
127
+ } else {
128
+ base.options.fit_portrait && ratio >= 1 ? resizeHeight(true) : resizeWidth(true); // If portraits are set to fit
129
+ }
130
+
131
+ } else if (browserwidth <= base.options.min_width){ // If window only smaller than minimum width
132
+
133
+ if ((browserheight/browserwidth) > ratio){
134
+ base.options.fit_landscape && ratio < 1 ? resizeWidth(true) : resizeHeight(); // If landscapes are set to fit
135
+ } else {
136
+ base.options.fit_portrait && ratio >= 1 ? resizeHeight() : resizeWidth(true); // If portraits are set to fit
137
+ }
138
+
139
+ } else if (browserheight <= base.options.min_height){ // If window only smaller than minimum height
140
+
141
+ if ((browserheight/browserwidth) > ratio){
142
+ base.options.fit_landscape && ratio < 1 ? resizeWidth() : resizeHeight(true); // If landscapes are set to fit
143
+ } else {
144
+ base.options.fit_portrait && ratio >= 1 ? resizeHeight(true) : resizeWidth(); // If portraits are set to fit
145
+ }
146
+
147
+ } else { // If larger than minimums
148
+
149
+ if ((browserheight/browserwidth) > ratio){
150
+ base.options.fit_landscape && ratio < 1 ? resizeWidth() : resizeHeight(); // If landscapes are set to fit
151
+ } else {
152
+ base.options.fit_portrait && ratio >= 1 ? resizeHeight() : resizeWidth(); // If portraits are set to fit
153
+ }
154
+
155
+ }
156
+ }
157
+ /*-----End Image Resize-----*/
158
+
159
+
160
+ /*-----Resize Functions-----*/
161
+
162
+ function resizeWidth(minimum){
163
+ if (minimum){ // If minimum height needs to be considered
164
+ if(thisSlide.width() < browserwidth || thisSlide.width() < base.options.min_width ){
165
+ if (thisSlide.width() * ratio >= base.options.min_height){
166
+ thisSlide.width(base.options.min_width);
167
+ thisSlide.height(thisSlide.width() * ratio);
168
+ }else{
169
+ resizeHeight();
170
+ }
171
+ }
172
+ }else{
173
+ if (base.options.min_height >= browserheight && !base.options.fit_landscape){ // If minimum height needs to be considered
174
+ if (browserwidth * ratio >= base.options.min_height || (browserwidth * ratio >= base.options.min_height && ratio <= 1)){ // If resizing would push below minimum height or image is a landscape
175
+ thisSlide.width(browserwidth);
176
+ thisSlide.height(browserwidth * ratio);
177
+ } else if (ratio > 1){ // Else the image is portrait
178
+ thisSlide.height(base.options.min_height);
179
+ thisSlide.width(thisSlide.height() / ratio);
180
+ } else if (thisSlide.width() < browserwidth) {
181
+ thisSlide.width(browserwidth);
182
+ thisSlide.height(thisSlide.width() * ratio);
183
+ }
184
+ }else{ // Otherwise, resize as normal
185
+ thisSlide.width(browserwidth);
186
+ thisSlide.height(browserwidth * ratio);
187
+ }
188
+ }
189
+ };
190
+
191
+ function resizeHeight(minimum){
192
+ if (minimum){ // If minimum height needs to be considered
193
+ if(thisSlide.height() < browserheight){
194
+ if (thisSlide.height() / ratio >= base.options.min_width){
195
+ thisSlide.height(base.options.min_height);
196
+ thisSlide.width(thisSlide.height() / ratio);
197
+ }else{
198
+ resizeWidth(true);
199
+ }
200
+ }
201
+ }else{ // Otherwise, resized as normal
202
+ if (base.options.min_width >= browserwidth){ // If minimum width needs to be considered
203
+ if (browserheight / ratio >= base.options.min_width || ratio > 1){ // If resizing would push below minimum width or image is a portrait
204
+ thisSlide.height(browserheight);
205
+ thisSlide.width(browserheight / ratio);
206
+ } else if (ratio <= 1){ // Else the image is landscape
207
+ thisSlide.width(base.options.min_width);
208
+ thisSlide.height(thisSlide.width() * ratio);
209
+ }
210
+ }else{ // Otherwise, resize as normal
211
+ thisSlide.height(browserheight);
212
+ thisSlide.width(browserheight / ratio);
213
+ }
214
+ }
215
+ };
216
+
217
+ /*-----End Resize Functions-----*/
218
+
219
+ if (thisSlide.parent().hasClass('image-loading')){
220
+ $('.image-loading').removeClass('image-loading');
221
+ }
222
+
223
+ // Horizontally Center
224
+ if (base.options.horizontal_center){
225
+ $(this).css('left', (browserwidth - $(this).width())/2);
226
+ }
227
+
228
+ // Vertically Center
229
+ if (base.options.vertical_center){
230
+ $(this).css('top', (browserheight - $(this).height())/2);
231
+ }
232
+
233
+ });
234
+
235
+ // Basic image drag and right click protection
236
+ if (base.options.image_protect){
237
+
238
+ $('img', base.el).bind("contextmenu mousedown",function(){
239
+ return false;
240
+ });
241
+
242
+ }
243
+
244
+ return false;
245
+
246
+ });
247
+
248
+ };
249
+
250
+
251
+ /* Get Original Dimensions
252
+ ----------------------------*/
253
+ base._origDim = function(targetSlide){
254
+ targetSlide.data('origWidth', targetSlide.width()).data('origHeight', targetSlide.height()).css('visibility','visible');
255
+ };
256
+
257
+ base.getField = function(field){
258
+ return base.options.slides[vars.current_slide][field];
259
+ };
260
+
261
+ // Make it go!
262
+ base.init();
263
+ };
264
+
265
+
266
+ /* Global Variables
267
+ ----------------------------*/
268
+ $.supersized.vars = {
269
+
270
+ // Internal variables
271
+ current_slide : 0, // Current slide number
272
+ options : {} // Stores assembled options list
273
+
274
+ };
275
+
276
+
277
+ /* Default Options
278
+ ----------------------------*/
279
+ $.supersized.defaultOptions = {
280
+
281
+ // Functionality
282
+ start_slide : 1, // Start slide (0 is random)
283
+ new_window : 1, // Image links open in new window/tab
284
+ image_protect : 1, // Disables image dragging and right click with Javascript
285
+
286
+ // Size & Position
287
+ min_width : 0, // Min width allowed (in pixels)
288
+ min_height : 0, // Min height allowed (in pixels)
289
+ vertical_center : 1, // Vertically center background
290
+ horizontal_center : 1, // Horizontally center background
291
+ fit_always : 0, // Image will never exceed browser width or height (Ignores min. dimensions)
292
+ fit_portrait : 1, // Portrait images will not exceed browser height
293
+ fit_landscape : 0 // Landscape images will not exceed browser width
294
+
295
+ };
296
+
297
+ $.fn.supersized = function(options){
298
+ return this.each(function(){
299
+ (new $.supersized(options));
300
+ });
301
+ };
302
+
303
+ })(jQuery);
304
+
skin/frontend/default/default/bannernext/supersized/js/supersized.core.3.2.1.min.js ADDED
@@ -0,0 +1,13 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /*
2
+
3
+ Supersized - Fullscreen Slideshow jQuery Plugin
4
+ Version : Core 3.2.1
5
+ Site : www.buildinternet.com/project/supersized
6
+
7
+ Author : Sam Dunn
8
+ Company : One Mighty Roar (www.onemightyroar.com)
9
+ License : MIT License / GPL License
10
+
11
+ */
12
+
13
+ (function(a){a(document).ready(function(){a("body").append('<div id="supersized-loader"></div><div id="supersized"></div>')});a.supersized=function(b){var c="#supersized",d=this;d.$el=a(c);d.el=c;vars=a.supersized.vars;d.$el.data("supersized",d);api=d.$el.data("supersized");d.init=function(){a.supersized.vars.options=a.extend({},a.supersized.defaultOptions,b);d.options=a.supersized.vars.options;d._build()};d._build=function(){d._start()};d._start=function(){if(d.options.start_slide){vars.current_slide=d.options.start_slide-1}else{vars.current_slide=Math.floor(Math.random()*d.options.slides.length)}var f=d.options.new_window?' target="_blank"':"";imageLink=(api.getField("url"))?"href='"+api.getField("url")+"'":"";var e=a('<img src="'+api.getField("image")+'"/>');e.appendTo(d.el).wrap('<a class="image-loading activeslide" '+imageLink+f+"></a>").css("visibility","hidden");e.load(function(){d._origDim(a(this));d.resizeNow();d.launch()});d.$el.css("visibility","hidden")};d.launch=function(){d.$el.css("visibility","visible");a("#supersized-loader").hide();a(window).resize(function(){d.resizeNow()})};d.resizeNow=function(){return d.$el.each(function(){a("img",d.el).each(function(){thisSlide=a(this);var f=(thisSlide.data("origHeight")/thisSlide.data("origWidth")).toFixed(2);var e=d.$el.width(),h=d.$el.height(),i;if(d.options.fit_always){if((h/e)>f){g()}else{j()}}else{if((h<=d.options.min_height)&&(e<=d.options.min_width)){if((h/e)>f){d.options.fit_landscape&&f<1?g(true):j(true)}else{d.options.fit_portrait&&f>=1?j(true):g(true)}}else{if(e<=d.options.min_width){if((h/e)>f){d.options.fit_landscape&&f<1?g(true):j()}else{d.options.fit_portrait&&f>=1?j():g(true)}}else{if(h<=d.options.min_height){if((h/e)>f){d.options.fit_landscape&&f<1?g():j(true)}else{d.options.fit_portrait&&f>=1?j(true):g()}}else{if((h/e)>f){d.options.fit_landscape&&f<1?g():j()}else{d.options.fit_portrait&&f>=1?j():g()}}}}}function g(k){if(k){if(thisSlide.width()<e||thisSlide.width()<d.options.min_width){if(thisSlide.width()*f>=d.options.min_height){thisSlide.width(d.options.min_width);thisSlide.height(thisSlide.width()*f)}else{j()}}}else{if(d.options.min_height>=h&&!d.options.fit_landscape){if(e*f>=d.options.min_height||(e*f>=d.options.min_height&&f<=1)){thisSlide.width(e);thisSlide.height(e*f)}else{if(f>1){thisSlide.height(d.options.min_height);thisSlide.width(thisSlide.height()/f)}else{if(thisSlide.width()<e){thisSlide.width(e);thisSlide.height(thisSlide.width()*f)}}}}else{thisSlide.width(e);thisSlide.height(e*f)}}}function j(k){if(k){if(thisSlide.height()<h){if(thisSlide.height()/f>=d.options.min_width){thisSlide.height(d.options.min_height);thisSlide.width(thisSlide.height()/f)}else{g(true)}}}else{if(d.options.min_width>=e){if(h/f>=d.options.min_width||f>1){thisSlide.height(h);thisSlide.width(h/f)}else{if(f<=1){thisSlide.width(d.options.min_width);thisSlide.height(thisSlide.width()*f)}}}else{thisSlide.height(h);thisSlide.width(h/f)}}}if(thisSlide.parent().hasClass("image-loading")){a(".image-loading").removeClass("image-loading")}if(d.options.horizontal_center){a(this).css("left",(e-a(this).width())/2)}if(d.options.vertical_center){a(this).css("top",(h-a(this).height())/2)}});if(d.options.image_protect){a("img",d.el).bind("contextmenu mousedown",function(){return false})}return false})};d._origDim=function(e){e.data("origWidth",e.width()).data("origHeight",e.height()).css("visibility","visible")};d.getField=function(e){return d.options.slides[vars.current_slide][e]};d.init()};a.supersized.vars={current_slide:0,options:{}};a.supersized.defaultOptions={start_slide:1,new_window:1,image_protect:1,min_width:0,min_height:0,vertical_center:1,horizontal_center:1,fit_always:0,fit_portrait:1,fit_landscape:0};a.fn.supersized=function(b){return this.each(function(){(new a.supersized(b))})}})(jQuery);
skin/frontend/default/default/bannernext/supersized/theme/supersized.shutter.css ADDED
@@ -0,0 +1,74 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /*
2
+
3
+ Supersized - Fullscreen Slideshow jQuery Plugin
4
+ Version : 3.2.7
5
+ Site : www.buildinternet.com/project/supersized
6
+
7
+ Theme : Shutter 1.2
8
+ Author : Sam Dunn
9
+ Company : One Mighty Roar (www.onemightyroar.com)
10
+ License : MIT License / GPL License
11
+
12
+ */
13
+
14
+ /* Controls Bar
15
+ ----------------------------*/
16
+ #controls-wrapper { margin:0 auto; height:42px; width:100%; bottom:0px; left:0; z-index:4; background:url(../img/nav-bg.png) repeat-x; position:fixed; }
17
+ #controls { overflow:hidden; height:100%; position:relative; text-align:left; z-index:5; }
18
+ #slidecounter { float:left; color:#999; font:14px "Helvetica Neue", Helvetica, Arial, sans-serif; text-shadow:#000 0 -1px 0; margin:0px 10px 0 15px; line-height:42px; }
19
+ #slidecaption { overflow:hidden; float:left; color:#FFF; font:400 14px "Helvetica Neue", Helvetica, Arial, sans-serif; text-shadow:#000 1px 1px 2px; margin:0 20px 0 0; line-height:42px; }
20
+
21
+ #navigation { float:right; margin:0px 20px 0 0; }
22
+ #play-button{ float:left; margin-top:1px;border-right:1px solid #333; background:url('../img/bg-hover.png') repeat-x 0 44px; }
23
+ #play-button:hover{ background-position:0 1px; cursor:pointer; }
24
+
25
+ #prevslide, #nextslide{ position:absolute; height:43px; width:43px; top:50%; margin-top:-21px; opacity:0.6; }
26
+ #prevslide{ left:10px; background:url('../img/back.png'); }
27
+ #nextslide{ right:10px; background:url('../img/forward.png'); }
28
+ #prevslide:active, #nextslide:active{ margin-top:-19px; }
29
+ #prevslide:hover, #nextslide:hover{ cursor:pointer; }
30
+
31
+ ul#slide-list{ padding:15px 0; float:left; position:absolute; left:50%; }
32
+ ul#slide-list li{ list-style:none; width:12px; height:12px; float:left; margin:0 5px 0 0; }
33
+ ul#slide-list li.current-slide a, ul#slide-list li.current-slide a:hover{ background-position:0 0px; }
34
+ ul#slide-list li a{ display:block; width:12px; height:12px; background:url('../img/nav-dot.png') no-repeat 0 -24px; }
35
+ ul#slide-list li a:hover{ background-position:0 -12px; cursor:pointer; }
36
+
37
+ #tray-button{ float:right; margin-top:1px; border-left:1px solid #333; background:url('../img/bg-hover.png') repeat-x 0 44px; }
38
+ #tray-button:hover{ background-position:0 1px; cursor:pointer; }
39
+
40
+
41
+ /* Progress Bar
42
+ ----------------------------*/
43
+ #progress-back{ z-index:5; position:fixed; bottom:42px; left:0; height:8px; width:100%; background:url('../img/progress-back.png') repeat-x; }
44
+ #progress-bar{ position:relative; height:8px; width:100%; background:url('../img/progress-bar.png') repeat-x; }
45
+
46
+
47
+ /* Thumbnail Navigation
48
+ ----------------------------*/
49
+ #nextthumb,#prevthumb { z-index:2; display:none; position:fixed; bottom:61px; height:75px; width:100px; overflow:hidden; background:#ddd; border:1px solid #fff; -webkit-box-shadow:0 0 5px #000; }
50
+ #nextthumb { right:12px; }
51
+ #prevthumb { left:12px; }
52
+ #nextthumb img, #prevthumb img { width:150px; height:auto; }
53
+ #nextthumb:active, #prevthumb:active { bottom:59px; }
54
+ #nextthumb:hover, #prevthumb:hover { cursor:pointer; }
55
+
56
+
57
+ /* Thumbnail Tray
58
+ ----------------------------*/
59
+ #thumb-tray{ position:fixed; z-index:3; bottom:0; left:0; background:url(../img/bg-black.png); height:150px; width:100%; overflow:hidden; text-align:center; -moz-box-shadow: 0px 0px 4px #000; -webkit-box-shadow: 0px 0px 4px #000; box-shadow: 0px 0px 4px #000; }
60
+
61
+ #thumb-back, #thumb-forward{ position:absolute; z-index:5; bottom:42px; height:108px; width:40px; }
62
+ #thumb-back{ left:0; background: url('../img/thumb-back.png') no-repeat center center;}
63
+ #thumb-forward{ right:0; background:url('../img/thumb-forward.png') no-repeat center center;}
64
+ #thumb-back:hover, #thumb-forward:hover{ cursor:pointer; background-color:rgba(256,256,256, 0.1); }
65
+ #thumb-back:hover{ border-right:1px solid rgba(256,256,256, 0.2); }
66
+ #thumb-forward:hover{ border-left:1px solid rgba(256,256,256, 0.2); }
67
+
68
+
69
+ ul#thumb-list{ display:inline-block; list-style:none; position:relative; left:0px; padding:0 0px; }
70
+ ul#thumb-list li{ background:#111; list-style:none; display:inline; width:150px; height:108px; overflow:hidden; float:left; margin:0; }
71
+ ul#thumb-list li img { width:200px; height:auto; opacity:0.5; -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=60)"; filter:alpha(opacity=60); -webkit-transition: all 100ms ease-in-out; -moz-transition: all 100ms ease-in-out; -o-transition: all 100ms ease-in-out; -ms-transition: all 100ms ease-in-out; transition: all 100ms ease-in-out; }
72
+ ul#thumb-list li.current-thumb img, ul#thumb-list li:hover img{ opacity:1; -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=100)"; filter:alpha(opacity=100); }
73
+ ul#thumb-list li:hover{ cursor:pointer; }
74
+
skin/frontend/default/default/bannernext/supersized/theme/supersized.shutter.js ADDED
@@ -0,0 +1,337 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /*
2
+
3
+ Supersized - Fullscreen Slideshow jQuery Plugin
4
+ Version : 3.2.7
5
+ Theme : Shutter 1.1
6
+
7
+ Site : www.buildinternet.com/project/supersized
8
+ Author : Sam Dunn
9
+ Company : One Mighty Roar (www.onemightyroar.com)
10
+ License : MIT License / GPL License
11
+
12
+ */
13
+
14
+ (function($){
15
+
16
+ theme = {
17
+
18
+
19
+ /* Initial Placement
20
+ ----------------------------*/
21
+ _init : function(){
22
+
23
+ // Center Slide Links
24
+ if (api.options.slide_links) $(vars.slide_list).css('margin-left', -$(vars.slide_list).width()/2);
25
+
26
+ // Start progressbar if autoplay enabled
27
+ if (api.options.autoplay){
28
+ if (api.options.progress_bar) theme.progressBar();
29
+ }else{
30
+ if ($(vars.play_button).attr('src')) $(vars.play_button).attr("src", vars.image_path + "play.png"); // If pause play button is image, swap src
31
+ if (api.options.progress_bar) $(vars.progress_bar).stop().css({left : -$(window).width()}); // Place progress bar
32
+ }
33
+
34
+
35
+ /* Thumbnail Tray
36
+ ----------------------------*/
37
+ // Hide tray off screen
38
+ $(vars.thumb_tray).css({bottom : -$(vars.thumb_tray).height()});
39
+
40
+ // Thumbnail Tray Toggle
41
+ $(vars.tray_button).toggle(function(){
42
+ $(vars.thumb_tray).stop().animate({bottom : 0, avoidTransforms : true}, 300 );
43
+ if ($(vars.tray_arrow).attr('src')) $(vars.tray_arrow).attr("src", vars.image_path + "button-tray-down.png");
44
+ return false;
45
+ }, function() {
46
+ $(vars.thumb_tray).stop().animate({bottom : -$(vars.thumb_tray).height(), avoidTransforms : true}, 300 );
47
+ if ($(vars.tray_arrow).attr('src')) $(vars.tray_arrow).attr("src", vars.image_path + "button-tray-up.png");
48
+ return false;
49
+ });
50
+
51
+ // Make thumb tray proper size
52
+ $(vars.thumb_list).width($('> li', vars.thumb_list).length * $('> li', vars.thumb_list).outerWidth(true)); //Adjust to true width of thumb markers
53
+
54
+ // Display total slides
55
+ if ($(vars.slide_total).length){
56
+ $(vars.slide_total).html(api.options.slides.length);
57
+ }
58
+
59
+
60
+ /* Thumbnail Tray Navigation
61
+ ----------------------------*/
62
+ if (api.options.thumb_links){
63
+ //Hide thumb arrows if not needed
64
+ if ($(vars.thumb_list).width() <= $(vars.thumb_tray).width()){
65
+ $(vars.thumb_back +','+vars.thumb_forward).fadeOut(0);
66
+ }
67
+
68
+ // Thumb Intervals
69
+ vars.thumb_interval = Math.floor($(vars.thumb_tray).width() / $('> li', vars.thumb_list).outerWidth(true)) * $('> li', vars.thumb_list).outerWidth(true);
70
+ vars.thumb_page = 0;
71
+
72
+ // Cycle thumbs forward
73
+ $(vars.thumb_forward).click(function(){
74
+ if (vars.thumb_page - vars.thumb_interval <= -$(vars.thumb_list).width()){
75
+ vars.thumb_page = 0;
76
+ $(vars.thumb_list).stop().animate({'left': vars.thumb_page}, {duration:500, easing:'easeOutExpo'});
77
+ }else{
78
+ vars.thumb_page = vars.thumb_page - vars.thumb_interval;
79
+ $(vars.thumb_list).stop().animate({'left': vars.thumb_page}, {duration:500, easing:'easeOutExpo'});
80
+ }
81
+ });
82
+
83
+ // Cycle thumbs backwards
84
+ $(vars.thumb_back).click(function(){
85
+ if (vars.thumb_page + vars.thumb_interval > 0){
86
+ vars.thumb_page = Math.floor($(vars.thumb_list).width() / vars.thumb_interval) * -vars.thumb_interval;
87
+ if ($(vars.thumb_list).width() <= -vars.thumb_page) vars.thumb_page = vars.thumb_page + vars.thumb_interval;
88
+ $(vars.thumb_list).stop().animate({'left': vars.thumb_page}, {duration:500, easing:'easeOutExpo'});
89
+ }else{
90
+ vars.thumb_page = vars.thumb_page + vars.thumb_interval;
91
+ $(vars.thumb_list).stop().animate({'left': vars.thumb_page}, {duration:500, easing:'easeOutExpo'});
92
+ }
93
+ });
94
+
95
+ }
96
+
97
+
98
+ /* Navigation Items
99
+ ----------------------------*/
100
+ $(vars.next_slide).click(function() {
101
+ api.nextSlide();
102
+ });
103
+
104
+ $(vars.prev_slide).click(function() {
105
+ api.prevSlide();
106
+ });
107
+
108
+ // Full Opacity on Hover
109
+ if(jQuery.support.opacity){
110
+ $(vars.prev_slide +','+vars.next_slide).mouseover(function() {
111
+ $(this).stop().animate({opacity:1},100);
112
+ }).mouseout(function(){
113
+ $(this).stop().animate({opacity:0.6},100);
114
+ });
115
+ }
116
+
117
+ if (api.options.thumbnail_navigation){
118
+ // Next thumbnail clicked
119
+ $(vars.next_thumb).click(function() {
120
+ api.nextSlide();
121
+ });
122
+ // Previous thumbnail clicked
123
+ $(vars.prev_thumb).click(function() {
124
+ api.prevSlide();
125
+ });
126
+ }
127
+
128
+ $(vars.play_button).click(function() {
129
+ api.playToggle();
130
+ });
131
+
132
+
133
+ /* Thumbnail Mouse Scrub
134
+ ----------------------------*/
135
+ if (api.options.mouse_scrub){
136
+ $(vars.thumb_tray).mousemove(function(e) {
137
+ var containerWidth = $(vars.thumb_tray).width(),
138
+ listWidth = $(vars.thumb_list).width();
139
+ if (listWidth > containerWidth){
140
+ var mousePos = 1,
141
+ diff = e.pageX - mousePos;
142
+ if (diff > 10 || diff < -10) {
143
+ mousePos = e.pageX;
144
+ newX = (containerWidth - listWidth) * (e.pageX/containerWidth);
145
+ diff = parseInt(Math.abs(parseInt($(vars.thumb_list).css('left'))-newX )).toFixed(0);
146
+ $(vars.thumb_list).stop().animate({'left':newX}, {duration:diff*3, easing:'easeOutExpo'});
147
+ }
148
+ }
149
+ });
150
+ }
151
+
152
+
153
+ /* Window Resize
154
+ ----------------------------*/
155
+ $(window).resize(function(){
156
+
157
+ // Delay progress bar on resize
158
+ if (api.options.progress_bar && !vars.in_animation){
159
+ if (vars.slideshow_interval) clearInterval(vars.slideshow_interval);
160
+ if (api.options.slides.length - 1 > 0) clearInterval(vars.slideshow_interval);
161
+
162
+ $(vars.progress_bar).stop().css({left : -$(window).width()});
163
+
164
+ if (!vars.progressDelay && api.options.slideshow){
165
+ // Delay slideshow from resuming so Chrome can refocus images
166
+ vars.progressDelay = setTimeout(function() {
167
+ if (!vars.is_paused){
168
+ theme.progressBar();
169
+ vars.slideshow_interval = setInterval(api.nextSlide, api.options.slide_interval);
170
+ }
171
+ vars.progressDelay = false;
172
+ }, 1000);
173
+ }
174
+ }
175
+
176
+ // Thumb Links
177
+ if (api.options.thumb_links && vars.thumb_tray.length){
178
+ // Update Thumb Interval & Page
179
+ vars.thumb_page = 0;
180
+ vars.thumb_interval = Math.floor($(vars.thumb_tray).width() / $('> li', vars.thumb_list).outerWidth(true)) * $('> li', vars.thumb_list).outerWidth(true);
181
+
182
+ // Adjust thumbnail markers
183
+ if ($(vars.thumb_list).width() > $(vars.thumb_tray).width()){
184
+ $(vars.thumb_back +','+vars.thumb_forward).fadeIn('fast');
185
+ $(vars.thumb_list).stop().animate({'left':0}, 200);
186
+ }else{
187
+ $(vars.thumb_back +','+vars.thumb_forward).fadeOut('fast');
188
+ }
189
+
190
+ }
191
+ });
192
+
193
+
194
+ },
195
+
196
+
197
+ /* Go To Slide
198
+ ----------------------------*/
199
+ goTo : function(){
200
+ if (api.options.progress_bar && !vars.is_paused){
201
+ $(vars.progress_bar).stop().css({left : -$(window).width()});
202
+ theme.progressBar();
203
+ }
204
+ },
205
+
206
+ /* Play & Pause Toggle
207
+ ----------------------------*/
208
+ playToggle : function(state){
209
+
210
+ if (state =='play'){
211
+ // If image, swap to pause
212
+ if ($(vars.play_button).attr('src')) $(vars.play_button).attr("src", vars.image_path + "pause.png");
213
+ if (api.options.progress_bar && !vars.is_paused) theme.progressBar();
214
+ }else if (state == 'pause'){
215
+ // If image, swap to play
216
+ if ($(vars.play_button).attr('src')) $(vars.play_button).attr("src", vars.image_path + "play.png");
217
+ if (api.options.progress_bar && vars.is_paused)$(vars.progress_bar).stop().css({left : -$(window).width()});
218
+ }
219
+
220
+ },
221
+
222
+
223
+ /* Before Slide Transition
224
+ ----------------------------*/
225
+ beforeAnimation : function(direction){
226
+ if (api.options.progress_bar && !vars.is_paused) $(vars.progress_bar).stop().css({left : -$(window).width()});
227
+
228
+ /* Update Fields
229
+ ----------------------------*/
230
+ // Update slide caption
231
+ if ($(vars.slide_caption).length){
232
+ (api.getField('title')) ? $(vars.slide_caption).html(api.getField('title')) : $(vars.slide_caption).html('');
233
+ }
234
+ // Update slide number
235
+ if (vars.slide_current.length){
236
+ $(vars.slide_current).html(vars.current_slide + 1);
237
+ }
238
+
239
+
240
+ // Highlight current thumbnail and adjust row position
241
+ if (api.options.thumb_links){
242
+
243
+ $('.current-thumb').removeClass('current-thumb');
244
+ $('li', vars.thumb_list).eq(vars.current_slide).addClass('current-thumb');
245
+
246
+ // If thumb out of view
247
+ if ($(vars.thumb_list).width() > $(vars.thumb_tray).width()){
248
+ // If next slide direction
249
+ if (direction == 'next'){
250
+ if (vars.current_slide == 0){
251
+ vars.thumb_page = 0;
252
+ $(vars.thumb_list).stop().animate({'left': vars.thumb_page}, {duration:500, easing:'easeOutExpo'});
253
+ } else if ($('.current-thumb').offset().left - $(vars.thumb_tray).offset().left >= vars.thumb_interval){
254
+ vars.thumb_page = vars.thumb_page - vars.thumb_interval;
255
+ $(vars.thumb_list).stop().animate({'left': vars.thumb_page}, {duration:500, easing:'easeOutExpo'});
256
+ }
257
+ // If previous slide direction
258
+ }else if(direction == 'prev'){
259
+ if (vars.current_slide == api.options.slides.length - 1){
260
+ vars.thumb_page = Math.floor($(vars.thumb_list).width() / vars.thumb_interval) * -vars.thumb_interval;
261
+ if ($(vars.thumb_list).width() <= -vars.thumb_page) vars.thumb_page = vars.thumb_page + vars.thumb_interval;
262
+ $(vars.thumb_list).stop().animate({'left': vars.thumb_page}, {duration:500, easing:'easeOutExpo'});
263
+ } else if ($('.current-thumb').offset().left - $(vars.thumb_tray).offset().left < 0){
264
+ if (vars.thumb_page + vars.thumb_interval > 0) return false;
265
+ vars.thumb_page = vars.thumb_page + vars.thumb_interval;
266
+ $(vars.thumb_list).stop().animate({'left': vars.thumb_page}, {duration:500, easing:'easeOutExpo'});
267
+ }
268
+ }
269
+ }
270
+
271
+
272
+ }
273
+
274
+ },
275
+
276
+
277
+ /* After Slide Transition
278
+ ----------------------------*/
279
+ afterAnimation : function(){
280
+ if (api.options.progress_bar && !vars.is_paused) theme.progressBar(); // Start progress bar
281
+ },
282
+
283
+
284
+ /* Progress Bar
285
+ ----------------------------*/
286
+ progressBar : function(){
287
+ $(vars.progress_bar).stop().css({left : -$(window).width()}).animate({ left:0 }, api.options.slide_interval);
288
+ }
289
+
290
+
291
+ };
292
+
293
+
294
+ /* Theme Specific Variables
295
+ ----------------------------*/
296
+ $.supersized.themeVars = {
297
+
298
+ // Internal Variables
299
+ progress_delay : false, // Delay after resize before resuming slideshow
300
+ thumb_page : false, // Thumbnail page
301
+ thumb_interval : false, // Thumbnail interval
302
+ image_path : 'img/', // Default image path
303
+
304
+ // General Elements
305
+ play_button : '#pauseplay', // Play/Pause button
306
+ next_slide : '#nextslide', // Next slide button
307
+ prev_slide : '#prevslide', // Prev slide button
308
+ next_thumb : '#nextthumb', // Next slide thumb button
309
+ prev_thumb : '#prevthumb', // Prev slide thumb button
310
+
311
+ slide_caption : '#slidecaption', // Slide caption
312
+ slide_current : '.slidenumber', // Current slide number
313
+ slide_total : '.totalslides', // Total Slides
314
+ slide_list : '#slide-list', // Slide jump list
315
+
316
+ thumb_tray : '#thumb-tray', // Thumbnail tray
317
+ thumb_list : '#thumb-list', // Thumbnail list
318
+ thumb_forward : '#thumb-forward', // Cycles forward through thumbnail list
319
+ thumb_back : '#thumb-back', // Cycles backwards through thumbnail list
320
+ tray_arrow : '#tray-arrow', // Thumbnail tray button arrow
321
+ tray_button : '#tray-button', // Thumbnail tray button
322
+
323
+ progress_bar : '#progress-bar' // Progress bar
324
+
325
+ };
326
+
327
+ /* Theme Specific Options
328
+ ----------------------------*/
329
+ $.supersized.themeOptions = {
330
+
331
+ progress_bar : 1, // Timer for each slide
332
+ mouse_scrub : 0 // Thumbnails move with mouse
333
+
334
+ };
335
+
336
+
337
+ })(jQuery);
skin/frontend/default/default/bannernext/supersized/theme/supersized.shutter.min.js ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /*
2
+
3
+ Supersized - Fullscreen Slideshow jQuery Plugin
4
+ Version : 3.2.0
5
+ Theme : Shutter
6
+
7
+ Site : www.buildinternet.com/project/supersized
8
+ Author : Sam Dunn
9
+ Company : One Mighty Roar (www.onemightyroar.com)
10
+ License : MIT License / GPL License
11
+
12
+ */
13
+
14
+ (function(a){theme={_init:function(){if(api.options.slide_links){a(vars.slide_list).css("margin-left",-a(vars.slide_list).width()/2)}if(api.options.autoplay){if(api.options.progress_bar){theme.progressBar()}}else{if(a(vars.play_button).attr("src")){a(vars.play_button).attr("src",vars.image_path+"play.png")}if(api.options.progress_bar){a(vars.progress_bar).stop().animate({left:-a(window).width()},0)}}a(vars.thumb_tray).animate({bottom:-a(vars.thumb_tray).height()},0);a(vars.tray_button).toggle(function(){a(vars.thumb_tray).stop().animate({bottom:0,avoidTransforms:true},300);if(a(vars.tray_arrow).attr("src")){a(vars.tray_arrow).attr("src",vars.image_path+"button-tray-down.png")}return false},function(){a(vars.thumb_tray).stop().animate({bottom:-a(vars.thumb_tray).height(),avoidTransforms:true},300);if(a(vars.tray_arrow).attr("src")){a(vars.tray_arrow).attr("src",vars.image_path+"button-tray-up.png")}return false});a(vars.thumb_list).width(a("> li",vars.thumb_list).length*a("> li",vars.thumb_list).outerWidth(true));if(a(vars.slide_total).length){a(vars.slide_total).html(api.options.slides.length)}if(api.options.thumb_links){if(a(vars.thumb_list).width()<=a(vars.thumb_tray).width()){a(vars.thumb_back+","+vars.thumb_forward).fadeOut(0)}vars.thumb_interval=Math.floor(a(vars.thumb_tray).width()/a("> li",vars.thumb_list).outerWidth(true))*a("> li",vars.thumb_list).outerWidth(true);vars.thumb_page=0;a(vars.thumb_forward).click(function(){if(vars.thumb_page-vars.thumb_interval<=-a(vars.thumb_list).width()){vars.thumb_page=0;a(vars.thumb_list).stop().animate({left:vars.thumb_page},{duration:500,easing:"easeOutExpo"})}else{vars.thumb_page=vars.thumb_page-vars.thumb_interval;a(vars.thumb_list).stop().animate({left:vars.thumb_page},{duration:500,easing:"easeOutExpo"})}});a(vars.thumb_back).click(function(){if(vars.thumb_page+vars.thumb_interval>0){vars.thumb_page=Math.floor(a(vars.thumb_list).width()/vars.thumb_interval)*-vars.thumb_interval;if(a(vars.thumb_list).width()<=-vars.thumb_page){vars.thumb_page=vars.thumb_page+vars.thumb_interval}a(vars.thumb_list).stop().animate({left:vars.thumb_page},{duration:500,easing:"easeOutExpo"})}else{vars.thumb_page=vars.thumb_page+vars.thumb_interval;a(vars.thumb_list).stop().animate({left:vars.thumb_page},{duration:500,easing:"easeOutExpo"})}})}a(vars.next_slide).click(function(){api.nextSlide()});a(vars.prev_slide).click(function(){api.prevSlide()});if(jQuery.support.opacity){a(vars.prev_slide+","+vars.next_slide).mouseover(function(){a(this).stop().animate({opacity:1},100)}).mouseout(function(){a(this).stop().animate({opacity:0.6},100)})}if(api.options.thumbnail_navigation){a(vars.next_thumb).click(function(){api.nextSlide()});a(vars.prev_thumb).click(function(){api.prevSlide()})}a(vars.play_button).click(function(){api.playToggle()});if(api.options.mouse_scrub){a(vars.thumb_tray).mousemove(function(f){var c=a(vars.thumb_tray).width(),g=a(vars.thumb_list).width();if(g>c){var b=1,d=f.pageX-b;if(d>10||d<-10){b=f.pageX;newX=(c-g)*(f.pageX/c);d=parseInt(Math.abs(parseInt(a(vars.thumb_list).css("left"))-newX)).toFixed(0);a(vars.thumb_list).stop().animate({left:newX},{duration:d*3,easing:"easeOutExpo"})}}})}a(window).resize(function(){if(api.options.progress_bar&&!vars.in_animation){if(vars.slideshow_interval){clearInterval(vars.slideshow_interval)}if(api.options.slides.length-1>0){clearInterval(vars.slideshow_interval)}a(vars.progress_bar).stop().animate({left:-a(window).width()},0);if(!vars.progressDelay&&api.options.slideshow){vars.progressDelay=setTimeout(function(){if(!vars.is_paused){theme.progressBar();vars.slideshow_interval=setInterval(api.nextSlide,api.options.slide_interval)}vars.progressDelay=false},1000)}}if(api.options.thumb_links&&vars.thumb_tray.length){vars.thumb_page=0;vars.thumb_interval=Math.floor(a(vars.thumb_tray).width()/a("> li",vars.thumb_list).outerWidth(true))*a("> li",vars.thumb_list).outerWidth(true);if(a(vars.thumb_list).width()>a(vars.thumb_tray).width()){a(vars.thumb_back+","+vars.thumb_forward).fadeIn("fast");a(vars.thumb_list).stop().animate({left:0},200)}else{a(vars.thumb_back+","+vars.thumb_forward).fadeOut("fast")}}})},goTo:function(b){if(api.options.progress_bar&&!vars.is_paused){a(vars.progress_bar).stop().animate({left:-a(window).width()},0);theme.progressBar()}},playToggle:function(b){if(b=="play"){if(a(vars.play_button).attr("src")){a(vars.play_button).attr("src",vars.image_path+"pause.png")}if(api.options.progress_bar&&!vars.is_paused){theme.progressBar()}}else{if(b=="pause"){if(a(vars.play_button).attr("src")){a(vars.play_button).attr("src",vars.image_path+"play.png")}if(api.options.progress_bar&&vars.is_paused){a(vars.progress_bar).stop().animate({left:-a(window).width()},0)}}}},beforeAnimation:function(b){if(api.options.progress_bar&&!vars.is_paused){a(vars.progress_bar).stop().animate({left:-a(window).width()},0)}if(a(vars.slide_caption).length){(api.getField("title"))?a(vars.slide_caption).html(api.getField("title")):a(vars.slide_caption).html("")}if(vars.slide_current.length){a(vars.slide_current).html(vars.current_slide+1)}if(api.options.thumb_links){a(".current-thumb").removeClass("current-thumb");a("li",vars.thumb_list).eq(vars.current_slide).addClass("current-thumb");if(a(vars.thumb_list).width()>a(vars.thumb_tray).width()){if(b=="next"){if(vars.current_slide==0){vars.thumb_page=0;a(vars.thumb_list).stop().animate({left:vars.thumb_page},{duration:500,easing:"easeOutExpo"})}else{if(a(".current-thumb").offset().left-a(vars.thumb_tray).offset().left>=vars.thumb_interval){vars.thumb_page=vars.thumb_page-vars.thumb_interval;a(vars.thumb_list).stop().animate({left:vars.thumb_page},{duration:500,easing:"easeOutExpo"})}}}else{if(b=="prev"){if(vars.current_slide==api.options.slides.length-1){vars.thumb_page=Math.floor(a(vars.thumb_list).width()/vars.thumb_interval)*-vars.thumb_interval;if(a(vars.thumb_list).width()<=-vars.thumb_page){vars.thumb_page=vars.thumb_page+vars.thumb_interval}a(vars.thumb_list).stop().animate({left:vars.thumb_page},{duration:500,easing:"easeOutExpo"})}else{if(a(".current-thumb").offset().left-a(vars.thumb_tray).offset().left<0){if(vars.thumb_page+vars.thumb_interval>0){return false}vars.thumb_page=vars.thumb_page+vars.thumb_interval;a(vars.thumb_list).stop().animate({left:vars.thumb_page},{duration:500,easing:"easeOutExpo"})}}}}}}},afterAnimation:function(){if(api.options.progress_bar&&!vars.is_paused){theme.progressBar()}},progressBar:function(){a(vars.progress_bar).stop().animate({left:-a(window).width()},0).animate({left:0},api.options.slide_interval)}};a.supersized.themeVars={progress_delay:false,thumb_page:false,thumb_interval:false,image_path:"img/",play_button:"#pauseplay",next_slide:"#nextslide",prev_slide:"#prevslide",next_thumb:"#nextthumb",prev_thumb:"#prevthumb",slide_caption:"#slidecaption",slide_current:".slidenumber",slide_total:".totalslides",slide_list:"#slide-list",thumb_tray:"#thumb-tray",thumb_list:"#thumb-list",thumb_forward:"#thumb-forward",thumb_back:"#thumb-back",tray_arrow:"#tray-arrow",tray_button:"#tray-button",progress_bar:"#progress-bar"};a.supersized.themeOptions={progress_bar:1,mouse_scrub:0}})(jQuery);