Master Slider – Responsive Touch Slider - Version 3.5.0

Version Description

Download this release

Release Info

Developer averta
Plugin Icon 128x128 Master Slider – Responsive Touch Slider
Version 3.5.0
Comparing to
See all releases

Code changes from version 3.4.6 to 3.5.0

README.txt CHANGED
@@ -7,7 +7,7 @@ Tags: slider, image slider, wordpress slider, video slider, best slider plugin,
7
  Requires PHP: 5.3
8
  Requires at least: 4.6
9
  Tested up to: 5.0.0
10
- Stable tag: 3.4.6
11
 
12
  Build SEO friendly sliders fast and easy with Master Slider. The most advanced responsive HTML5 WordPress slider plugin, with touch swipe navigation that works smoothly on desktop and devices.
13
 
@@ -237,9 +237,10 @@ Bugs can be reported in our [support forums](http://wordpress.org/tags/master-sl
237
 
238
  == Changelog ==
239
 
240
- = 3.4.6 =
241
 
242
- = Version 3.4.6/ (29.04.2018) =
 
243
  - [Fix]: An issue with accessing the sample sliders panel fixed.
244
 
245
  = Version 3.4.4/ (18.04.2018) =
@@ -461,5 +462,6 @@ Bugs can be reported in our [support forums](http://wordpress.org/tags/master-sl
461
 
462
  == Upgrade Notice ==
463
 
464
- = Version 3.4.6/ (29.04.2018) =
 
465
  - [Fix]: An issue with accessing the sample sliders panel fixed.
7
  Requires PHP: 5.3
8
  Requires at least: 4.6
9
  Tested up to: 5.0.0
10
+ Stable tag: 3.5.0
11
 
12
  Build SEO friendly sliders fast and easy with Master Slider. The most advanced responsive HTML5 WordPress slider plugin, with touch swipe navigation that works smoothly on desktop and devices.
13
 
237
 
238
  == Changelog ==
239
 
240
+ = 3.5.0 =
241
 
242
+ = Version 3.5.0/ (29.04.2018) =
243
+ - [Fix]: Addressed an issue that prevents calling the slider callbacks.
244
  - [Fix]: An issue with accessing the sample sliders panel fixed.
245
 
246
  = Version 3.4.4/ (18.04.2018) =
462
 
463
  == Upgrade Notice ==
464
 
465
+ = Version 3.5.0/ (29.04.2018) =
466
+ - [Fix]: Addressed an issue that prevents calling the slider callbacks.
467
  - [Fix]: An issue with accessing the sample sliders panel fixed.
admin/assets/css/msp-general.css CHANGED
@@ -614,7 +614,7 @@ tbody .latest-updates {
614
  }
615
 
616
  .master-list #contextual-help-link-wrap{
617
- right: 240px;
618
  }
619
 
620
  #screen-meta-links .screen-meta-toggle {
614
  }
615
 
616
  .master-list #contextual-help-link-wrap{
617
+
618
  }
619
 
620
  #screen-meta-links .screen-meta-toggle {
admin/includes/classes/class-msp-notices.php CHANGED
@@ -118,7 +118,15 @@ class MSP_Notices {
118
  }
119
  }
120
 
121
- msp_set_transient( $transient_id, $info, 3 * HOUR_IN_SECONDS );
 
 
 
 
 
 
 
 
122
 
123
  return $info;
124
  }
@@ -159,11 +167,10 @@ class MSP_Notices {
159
  // info transient id
160
  $transient_id = $this->get_notice_info_transient_id( $notice_id );
161
 
162
- if( false !== ( $result = msp_get_transient( $transient_id ) ) ){
163
- if( isset( $result['enabled'] ) ){
164
- $result['enabled'] = false;
165
- msp_set_transient( $transient_id, $result, 3 * MONTH_IN_SECONDS );
166
- }
167
  }
168
 
169
  return true;
118
  }
119
  }
120
 
121
+ // disable the notice if the revision is not changed since the previous dismiss
122
+ if( false !== $previous_revision = msp_get_option( $transient_id . '-revision', false ) ){
123
+ if( $info['revision'] == $previous_revision ){
124
+ $info["enabled"] = false;
125
+ $info['debug'][] = '2.0';
126
+ }
127
+ }
128
+
129
+ msp_set_transient( $transient_id, $info, 6 * HOUR_IN_SECONDS );
130
 
131
  return $info;
132
  }
167
  // info transient id
168
  $transient_id = $this->get_notice_info_transient_id( $notice_id );
169
 
170
+ if( false !== ( $result = $this->fetch_notice_info( $notice_id ) ) ){
171
+ msp_update_option( $transient_id . '-revision', $result['revision'] );
172
+ $result['enabled'] = false;
173
+ msp_set_transient( $transient_id, $result, 6 * HOUR_IN_SECONDS );
 
174
  }
175
 
176
  return true;
admin/includes/classes/class-msp-parser.php CHANGED
@@ -172,82 +172,83 @@ class MSP_Parser {
172
  'facebook_size' => isset( $setting['imgSize'] ) ? (string) $setting['imgSize'] : 'orginal',
173
  'facebook_thumb_size' => isset( $setting['thumbSize'] ) ? (string) $setting['thumbSize'] : '320',
174
 
175
- 'arrows' => 'false', // display arrows?
176
- 'arrows_autohide' => 'true', // auto hide arrows?
177
- 'arrows_overvideo' => 'true', // visible over slide video while playing?
178
- 'arrows_hideunder' => '',
179
-
180
- 'bullets' => 'false', // display bullets?
181
- 'bullets_autohide' => 'true', // auto hide bullets?
182
- 'bullets_overvideo'=> 'true', // visible over slide video while playing?
183
- 'bullets_align' => 'bottom',
184
- 'bullets_margin' => '',
185
- 'bullets_hideunder'=> '',
186
-
187
- 'thumbs' => 'false', // display thumbnails?
188
- 'thumbs_autohide' => 'true', // auto hide thumbs?
189
- 'thumbs_overvideo' => 'true', // visible over slide video while playing?
190
- 'thumbs_type' => 'thumbs', // thumb or tabs
191
- 'thumbs_speed' => 17, // scrolling speed. It accepts float values between 0 and 100
192
- 'thumbs_inset' => 'true', // insert thumbs inside slider
193
- 'thumbs_align' => 'bottom',
194
- 'thumbs_margin' => 0,
195
- 'thumbs_width' => 100,
196
- 'thumbs_height' => 80,
197
- 'thumbs_space' => 5,
198
- 'thumbs_hideunder' => '',
199
- 'thumbs_arrows' => 'false',
200
- 'thumbs_in_tab' => 'false',
201
- 'thumbs_hoverchange'=> 'false',
202
-
203
- 'scroll' => 'false', // display scrollbar?
204
- 'scroll_autohide' => 'true', // auto hide scroll?
205
- 'scroll_overvideo' => 'true', // visible over slide video while playing?
206
- 'scroll_align' => 'top',
207
- 'scroll_inset' => 'true',
208
- 'scroll_margin' => '',
209
- 'scroll_hideunder' => '',
210
- 'scroll_color' => '#3D3D3D',
211
- 'scroll_width' => '',
212
-
213
-
214
- 'circletimer' => 'false', // display circletimer?
215
- 'circletimer_autohide' => 'true', // auto hide circletimer?
216
- 'circletimer_overvideo'=> 'true', // visible over slide video while playing?
217
- 'circletimer_color' => '#A2A2A2',// color of circle timer
218
- 'circletimer_radius' => 4, // radius of circle timer in pixels
219
- 'circletimer_stroke' => 10, // the stroke of circle timer in pixels
220
- 'circletimer_margin' => '',
221
- 'circletimer_hideunder'=> '',
222
-
223
- 'timebar' => 'false', // display timebar?
224
- 'timebar_autohide' => 'true', // auto hide timebar?
225
- 'timebar_overvideo'=> 'true', // visible over slide video while playing?
226
- 'timebar_align' => 'bottom',
227
- 'timebar_hideunder'=> '',
228
- 'timebar_color' => '#FFFFFF',
229
- 'timebar_width' => '',
230
-
231
-
232
- 'slideinfo' => 'false', // display timebar?
233
- 'slideinfo_autohide' => 'true', // auto hide timebar?
234
- 'slideinfo_overvideo'=> 'true', // visible over slide video while playing?
235
- 'slideinfo_align' => 'bottom',
236
- 'slideinfo_inset' => 'false',
237
- 'slideinfo_margin' => '',
238
- 'slideinfo_hideunder'=> '',
239
- 'slideinfo_width' => '',
240
- 'slideinfo_height' => '',
241
-
242
- 'on_change_start' => '',
243
- 'on_change_end' => '',
244
- 'on_waiting' => '',
245
- 'on_resize' => '',
246
- 'on_video_play' => '',
247
- 'on_video_close' => '',
248
- 'on_swipe_start' => '',
249
- 'on_swipe_move' => '',
250
- 'on_swipe_end' => ''
 
251
  );
252
 
253
 
@@ -506,35 +507,37 @@ class MSP_Parser {
506
  }
507
 
508
 
509
- public function get_callback_params( $callback ) {
510
-
511
- $name = isset( $callback['name'] ) ? (string) $callback['name'] : '';
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
512
 
513
- switch ( $name ) {
514
- case 'CHANGE_START':
515
- return array( 'on_change_start' => isset( $callback['content'] ) ? base64_encode( $callback['content'] ) : '' );
516
- case 'CHANGE_END':
517
- return array( 'on_change_end' => isset( $callback['content'] ) ? base64_encode( $callback['content'] ) : '' );
518
- case 'WAITING':
519
- return array( 'on_waiting' => isset( $callback['content'] ) ? base64_encode( $callback['content'] ) : '' );
520
- case 'RESIZE':
521
- return array( 'on_resize' => isset( $callback['content'] ) ? base64_encode( $callback['content'] ) : '' );
522
- case 'VIDEO_PLAY':
523
- return array( 'on_video_play' => isset( $callback['content'] ) ? base64_encode( $callback['content'] ) : '' );
524
- case 'VIDEO_CLOSE':
525
- return array( 'on_video_close' => isset( $callback['content'] ) ? base64_encode( $callback['content'] ) : '' );
526
- case 'SWIPE_START':
527
- return array( 'on_swipe_start' => isset( $callback['content'] ) ? base64_encode( $callback['content'] ) : '' );
528
- case 'SWIPE_MOVE':
529
- return array( 'on_swipe_move' => isset( $callback['content'] ) ? base64_encode( $callback['content'] ) : '' );
530
- case 'SWIPE_END':
531
- return array( 'on_swipe_end' => isset( $callback['content'] ) ? base64_encode( $callback['content'] ) : '' );
532
- default:
533
- return array();
534
  }
535
 
536
- }
537
-
538
 
539
 
540
 
172
  'facebook_size' => isset( $setting['imgSize'] ) ? (string) $setting['imgSize'] : 'orginal',
173
  'facebook_thumb_size' => isset( $setting['thumbSize'] ) ? (string) $setting['thumbSize'] : '320',
174
 
175
+ 'arrows' => 'false', // display arrows?
176
+ 'arrows_autohide' => 'true', // auto hide arrows?
177
+ 'arrows_overvideo' => 'true', // visible over slide video while playing?
178
+ 'arrows_hideunder' => '',
179
+
180
+ 'bullets' => 'false', // display bullets?
181
+ 'bullets_autohide' => 'true', // auto hide bullets?
182
+ 'bullets_overvideo' => 'true', // visible over slide video while playing?
183
+ 'bullets_align' => 'bottom',
184
+ 'bullets_margin' => '',
185
+ 'bullets_hideunder' => '',
186
+
187
+ 'thumbs' => 'false', // display thumbnails?
188
+ 'thumbs_autohide' => 'true', // auto hide thumbs?
189
+ 'thumbs_overvideo' => 'true', // visible over slide video while playing?
190
+ 'thumbs_type' => 'thumbs', // thumb or tabs
191
+ 'thumbs_speed' => 17, // scrolling speed. It accepts float values between 0 and 100
192
+ 'thumbs_inset' => 'true', // insert thumbs inside slider
193
+ 'thumbs_align' => 'bottom',
194
+ 'thumbs_margin' => 0,
195
+ 'thumbs_width' => 100,
196
+ 'thumbs_height' => 80,
197
+ 'thumbs_space' => 5,
198
+ 'thumbs_hideunder' => '',
199
+ 'thumbs_arrows' => 'false',
200
+ 'thumbs_in_tab' => 'false',
201
+ 'thumbs_hoverchange' => 'false',
202
+
203
+ 'scroll' => 'false', // display scrollbar?
204
+ 'scroll_autohide' => 'true', // auto hide scroll?
205
+ 'scroll_overvideo' => 'true', // visible over slide video while playing?
206
+ 'scroll_align' => 'top',
207
+ 'scroll_inset' => 'true',
208
+ 'scroll_margin' => '',
209
+ 'scroll_hideunder' => '',
210
+ 'scroll_color' => '#3D3D3D',
211
+ 'scroll_width' => '',
212
+
213
+
214
+ 'circletimer' => 'false', // display circletimer?
215
+ 'circletimer_autohide' => 'true', // auto hide circletimer?
216
+ 'circletimer_overvideo' => 'true', // visible over slide video while playing?
217
+ 'circletimer_color' => '#A2A2A2',// color of circle timer
218
+ 'circletimer_radius' => 4, // radius of circle timer in pixels
219
+ 'circletimer_stroke' => 10, // the stroke of circle timer in pixels
220
+ 'circletimer_margin' => '',
221
+ 'circletimer_hideunder' => '',
222
+
223
+ 'timebar' => 'false', // display timebar?
224
+ 'timebar_autohide' => 'true', // auto hide timebar?
225
+ 'timebar_overvideo' => 'true', // visible over slide video while playing?
226
+ 'timebar_align' => 'bottom',
227
+ 'timebar_hideunder' => '',
228
+ 'timebar_color' => '#FFFFFF',
229
+ 'timebar_width' => '',
230
+
231
+
232
+ 'slideinfo' => 'false', // display timebar?
233
+ 'slideinfo_autohide' => 'true', // auto hide timebar?
234
+ 'slideinfo_overvideo' => 'true', // visible over slide video while playing?
235
+ 'slideinfo_align' => 'bottom',
236
+ 'slideinfo_inset' => 'false',
237
+ 'slideinfo_margin' => '',
238
+ 'slideinfo_hideunder' => '',
239
+ 'slideinfo_width' => '',
240
+ 'slideinfo_height' => '',
241
+
242
+ 'on_init' => '',
243
+ 'on_change_start' => '',
244
+ 'on_change_end' => '',
245
+ 'on_waiting' => '',
246
+ 'on_resize' => '',
247
+ 'on_video_play' => '',
248
+ 'on_video_close' => '',
249
+ 'on_swipe_start' => '',
250
+ 'on_swipe_move' => '',
251
+ 'on_swipe_end' => ''
252
  );
253
 
254
 
507
  }
508
 
509
 
510
+ public function get_callback_params( $callback ) {
511
+
512
+ $name = isset( $callback['name'] ) ? (string) $callback['name'] : '';
513
+
514
+ switch ( $name ) {
515
+ case 'INIT':
516
+ return array( 'on_init' => isset( $callback['content'] ) ? base64_encode( $callback['content'] ) : '' );
517
+ case 'CHANGE_START':
518
+ return array( 'on_change_start' => isset( $callback['content'] ) ? base64_encode( $callback['content'] ) : '' );
519
+ case 'CHANGE_END':
520
+ return array( 'on_change_end' => isset( $callback['content'] ) ? base64_encode( $callback['content'] ) : '' );
521
+ case 'WAITING':
522
+ return array( 'on_waiting' => isset( $callback['content'] ) ? base64_encode( $callback['content'] ) : '' );
523
+ case 'RESIZE':
524
+ return array( 'on_resize' => isset( $callback['content'] ) ? base64_encode( $callback['content'] ) : '' );
525
+ case 'VIDEO_PLAY':
526
+ return array( 'on_video_play' => isset( $callback['content'] ) ? base64_encode( $callback['content'] ) : '' );
527
+ case 'VIDEO_CLOSE':
528
+ return array( 'on_video_close' => isset( $callback['content'] ) ? base64_encode( $callback['content'] ) : '' );
529
+ case 'SWIPE_START':
530
+ return array( 'on_swipe_start' => isset( $callback['content'] ) ? base64_encode( $callback['content'] ) : '' );
531
+ case 'SWIPE_MOVE':
532
+ return array( 'on_swipe_move' => isset( $callback['content'] ) ? base64_encode( $callback['content'] ) : '' );
533
+ case 'SWIPE_END':
534
+ return array( 'on_swipe_end' => isset( $callback['content'] ) ? base64_encode( $callback['content'] ) : '' );
535
+ default:
536
+ return array();
537
+ }
538
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
539
  }
540
 
 
 
541
 
542
 
543
 
admin/includes/msp-admin-functions.php CHANGED
@@ -126,66 +126,6 @@ function msp_remote_post( $url, $args = array() ) {
126
  return false;
127
  }
128
 
129
- /**
130
- * Get the remote item promotion info
131
- *
132
- * @return string
133
- */
134
- function msp_get_ad_info( $force_update = false ){
135
-
136
- $defaults = array(
137
- 'topcorner_image_src' => MSWP_AVERTA_ADMIN_URL.'/assets/images/thirdparty/phlox-badge.png',
138
- 'topcorner_link' => 'http://avt.li/phmsltbtn',
139
-
140
- 'direct_link_admin' => '',
141
- 'direct_revision' => ''
142
- );
143
-
144
- if( isset( $_GET['msafi'] ) ){
145
- msp_delete_transient( 'master-slider-cached-remote-info' );
146
- }
147
-
148
- if( ! $force_update && false !== ( $result = msp_get_transient( 'master-slider-cached-remote-info' ) ) ){
149
- // wp_parse_args to prevent the errors while new args implemented in new versions
150
- return wp_parse_args( $result, $defaults );
151
- }
152
-
153
- $result = $defaults;
154
-
155
- if( false === $info = msp_remote_post( 'http://cdn.averta.net/project/masterslider/free/info/info.json' ) ){
156
- return $result;
157
- } else {
158
- $info = json_decode( $info, true );
159
- }
160
-
161
-
162
- // top right media
163
- if( ! empty( $info["master-slider"]["topCornerBanner"]["media"] ) ){
164
- $result['topcorner_image_src'] = $info["master-slider"]["topCornerBanner"]["media"];
165
- }
166
- if( ! empty( $info["master-slider"]["topCornerBanner"]["link"] ) ){
167
- $result['topcorner_link'] = $info["master-slider"]["topCornerBanner"]["link"];
168
- }
169
-
170
- // direct admin
171
- if( ! empty( $info["master-slider"]["direct"]["link"] ) ){
172
- $result['direct_link_admin'] = $info["master-slider"]["direct"]["link"];
173
- }
174
- if( ! empty( $info["master-slider"]["direct"]["revision"] ) ){
175
- $result['direct_revision'] = (string) $info["master-slider"]["direct"]["revision"];
176
- } else { // if the remote revision is empty dont redirect to masterslider panel
177
- msp_update_option( 'masterslider_apply_admin_direct', 0 );
178
- }
179
- if( ! empty( $result['direct_revision'] ) && is_numeric( $result['direct_revision'] ) && $result['direct_revision'] != msp_get_option( 'master-slider-cached-direct-revision' ) ){
180
- msp_update_option( 'masterslider_apply_admin_direct', 1 );
181
- msp_update_option( 'master-slider-cached-direct-revision', $result['direct_revision'] );
182
- }
183
-
184
- msp_set_transient( 'master-slider-cached-remote-info', $result, DAY_IN_SECONDS );
185
-
186
- return $result;
187
- }
188
-
189
 
190
  /**
191
  * Display a notice for running the setup wizard
@@ -202,45 +142,6 @@ function msp_custom_admin_notice(){
202
  add_action( 'admin_notices', 'msp_custom_admin_notice' );
203
 
204
 
205
-
206
- /**
207
- * Conditional admin redirect
208
- *
209
- * @return void
210
- */
211
- function msp_maybe_admin_redirect(){
212
-
213
- if( ! current_user_can( 'administrator' ) ){
214
- return;
215
- }
216
-
217
- // dont redirect if the current page is master slider dashboard
218
- if( ! empty( $_GET['page'] ) && MSWP_SLUG === $_GET['page'] ){
219
- return;
220
- }
221
-
222
- if( 1 == msp_get_option( 'masterslider_apply_admin_direct' ) || isset( $_GET['msrd'] ) ) {
223
- msp_update_option( 'masterslider_apply_admin_direct', 0 );
224
-
225
-
226
- $info = msp_get_ad_info();
227
- if( empty( $info['direct_link_admin'] ) ){
228
- return;
229
- }
230
-
231
- // validate the link
232
- $location = self_admin_url( $info['direct_link_admin'] );
233
- if( ! wp_validate_redirect( $location) ){
234
- return;
235
- }
236
-
237
- $js = sprintf( 'jQuery(document).ready(function(){ window.location = "%s"; });', $location );
238
- wp_add_inline_script( 'jquery-core', $js, 'after' );
239
- }
240
- }
241
- add_action( 'admin_print_scripts', 'msp_maybe_admin_redirect' );
242
-
243
-
244
  /**
245
  * Get total number of downloads by item slug
246
  *
126
  return false;
127
  }
128
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
129
 
130
  /**
131
  * Display a notice for running the setup wizard
142
  add_action( 'admin_notices', 'msp_custom_admin_notice' );
143
 
144
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
145
  /**
146
  * Get total number of downloads by item slug
147
  *
admin/includes/msp-admin-templates.php CHANGED
@@ -1,21 +1,12 @@
1
  <?php
2
 
3
  function msp_get_panel_header(){
4
-
5
- $info = msp_get_ad_info();
6
-
7
  ?>
8
  <div id="msp-header">
9
  <div class="msp-logo">
10
  <a href="<?php echo admin_url( 'admin.php?page='.MSWP_SLUG ); ?>">
11
  <img src="<?php echo MSWP_AVERTA_ADMIN_URL; ?>/views/slider-panel/images/masterslider.gif" />
12
  </a>
13
-
14
- <div class="msp-phlox-badge">
15
- <a href="<?php echo esc_url( $info['topcorner_link'] ); ?>" target="_blank">
16
- <img src="<?php echo esc_url( $info['topcorner_image_src'] ); ?>" />
17
- </a>
18
- </div>
19
  </div>
20
  <?php if( isset( $_GET['action'] ) && 'edit' == $_GET['action'] ) { ?>
21
  <a class="upgrade-pro" href="http://avt.li/mslpan" title="<?php _e( "Upgrade to PRO version to unlock more features. Click to see the list of features." ); ?>" target="_blank"><?php _e( "Upgrade to PRO Version", 'master-slider' ); ?></a>
1
  <?php
2
 
3
  function msp_get_panel_header(){
 
 
 
4
  ?>
5
  <div id="msp-header">
6
  <div class="msp-logo">
7
  <a href="<?php echo admin_url( 'admin.php?page='.MSWP_SLUG ); ?>">
8
  <img src="<?php echo MSWP_AVERTA_ADMIN_URL; ?>/views/slider-panel/images/masterslider.gif" />
9
  </a>
 
 
 
 
 
 
10
  </div>
11
  <?php if( isset( $_GET['action'] ) && 'edit' == $_GET['action'] ) { ?>
12
  <a class="upgrade-pro" href="http://avt.li/mslpan" title="<?php _e( "Upgrade to PRO version to unlock more features. Click to see the list of features." ); ?>" target="_blank"><?php _e( "Upgrade to PRO Version", 'master-slider' ); ?></a>
includes/init/define.php CHANGED
@@ -5,7 +5,7 @@ if ( ! defined('ABSPATH') ) {
5
  die();
6
  }
7
 
8
- define( 'MSWP_AVERTA_VERSION' , '3.4.6' );
9
 
10
  define( 'MSWP_SLUG' , 'master-slider' );
11
  define( 'MSWP_TEXT_DOMAIN' , 'masterslider' );
5
  die();
6
  }
7
 
8
+ define( 'MSWP_AVERTA_VERSION' , '3.5.0' );
9
 
10
  define( 'MSWP_SLUG' , 'master-slider' );
11
  define( 'MSWP_TEXT_DOMAIN' , 'masterslider' );
includes/msp-shortcodes.php CHANGED
@@ -230,15 +230,16 @@ function msp_masterslider_wrapper_shortcode( $atts, $content = null ) {
230
  'slideinfo_width' => '',
231
  'slideinfo_height' => '',
232
 
233
- 'on_change_start' => '',
234
- 'on_change_end' => '',
235
- 'on_waiting' => '',
236
- 'on_resize' => '',
237
- 'on_video_play' => '',
238
- 'on_video_close' => '',
239
- 'on_swipe_start' => '',
240
- 'on_swipe_move' => '',
241
- 'on_swipe_end' => ''
 
242
  )
243
  , $atts , 'ms_slider'
244
  );
@@ -551,6 +552,8 @@ function msp_masterslider_wrapper_shortcode( $atts, $content = null ) {
551
  });
552
 
553
  <?php
 
 
554
 
555
  if( ! empty( $on_change_start ) )
556
  printf( "$instance_name.api.addEventListener(MSSliderEvent.CHANGE_START, %s );\n" , msp_maybe_base64_decode( $on_change_start ) ) ;
@@ -572,22 +575,22 @@ function msp_masterslider_wrapper_shortcode( $atts, $content = null ) {
572
 
573
  if( $on_swipe_start || $on_swipe_move || $on_swipe_end ){
574
 
575
- echo "\t\t\t\t$instance_name.api.addEventListener(MSSliderEvent.INIT, function(){\n";
576
 
577
- if( ! empty( $on_swipe_start ) ){
578
- printf( "\t\t\t\t\t$instance_name.api.view.addEventListener(MSSliderEvent.SWIPE_START, %s );\n" , msp_maybe_base64_decode( $on_swipe_start ) ) ;
579
- }
580
 
581
- if( ! empty( $on_swipe_move ) ){
582
- printf( "\t\t\t\t\t$instance_name.api.view.addEventListener(MSSliderEvent.SWIPE_MOVE, %s );\n" , msp_maybe_base64_decode( $on_swipe_move ) ) ;
583
- }
584
 
585
- if( ! empty( $on_swipe_end ) ){
586
- printf( "\t\t\t\t\t$instance_name.api.view.addEventListener(MSSliderEvent.SWIPE_END, %s );\n" , msp_maybe_base64_decode( $on_swipe_end ) ) ;
587
- }
588
 
589
- echo "\t\t\t\t});\n";
590
- }
591
 
592
  if ( 'image-gallery' == $template ) {
593
  printf( "new MSGallery( '%s' , %s).setup();", $puid, $instance_name );
230
  'slideinfo_width' => '',
231
  'slideinfo_height' => '',
232
 
233
+ 'on_init' => '',
234
+ 'on_change_start' => '',
235
+ 'on_change_end' => '',
236
+ 'on_waiting' => '',
237
+ 'on_resize' => '',
238
+ 'on_video_play' => '',
239
+ 'on_video_close' => '',
240
+ 'on_swipe_start' => '',
241
+ 'on_swipe_move' => '',
242
+ 'on_swipe_end' => ''
243
  )
244
  , $atts , 'ms_slider'
245
  );
552
  });
553
 
554
  <?php
555
+ if( ! empty( $on_init ) )
556
+ printf( "$instance_name.api.addEventListener(MSSliderEvent.INIT, %s );\n" , msp_maybe_base64_decode( $on_init ) ) ;
557
 
558
  if( ! empty( $on_change_start ) )
559
  printf( "$instance_name.api.addEventListener(MSSliderEvent.CHANGE_START, %s );\n" , msp_maybe_base64_decode( $on_change_start ) ) ;
575
 
576
  if( $on_swipe_start || $on_swipe_move || $on_swipe_end ){
577
 
578
+ echo "\t\t\t$instance_name.api.addEventListener(MSSliderEvent.INIT, function(){\n";
579
 
580
+ if( ! empty( $on_swipe_start ) ){
581
+ printf( "\t\t\t\t$instance_name.api.view.addEventListener(MSViewEvents.SWIPE_START, %s );\n" , msp_maybe_base64_decode( $on_swipe_start ) ) ;
582
+ }
583
 
584
+ if( ! empty( $on_swipe_move ) ){
585
+ printf( "\t\t\t\t$instance_name.api.view.addEventListener(MSViewEvents.SWIPE_MOVE, %s );\n" , msp_maybe_base64_decode( $on_swipe_move ) ) ;
586
+ }
587
 
588
+ if( ! empty( $on_swipe_end ) ){
589
+ printf( "\t\t\t\t$instance_name.api.view.addEventListener(MSViewEvents.SWIPE_END, %s );\n" , msp_maybe_base64_decode( $on_swipe_end ) ) ;
590
+ }
591
 
592
+ echo "\t\t\t});\n";
593
+ }
594
 
595
  if ( 'image-gallery' == $template ) {
596
  printf( "new MSGallery( '%s' , %s).setup();", $puid, $instance_name );
master-slider.php CHANGED
@@ -11,7 +11,7 @@
11
  * Plugin Name: Master Slider
12
  * Plugin URI: https://wordpress.org/plugins/master-slider/
13
  * Description: Master Slider is the most advanced responsive HTML5 WordPress slider plugin with touch swipe navigation that works smoothly on devices too.
14
- * Version: 3.4.6
15
  * Author: averta
16
  * Author URI: http://averta.net
17
  * Text Domain: master-slider
11
  * Plugin Name: Master Slider
12
  * Plugin URI: https://wordpress.org/plugins/master-slider/
13
  * Description: Master Slider is the most advanced responsive HTML5 WordPress slider plugin with touch swipe navigation that works smoothly on devices too.
14
+ * Version: 3.5.0
15
  * Author: averta
16
  * Author URI: http://averta.net
17
  * Text Domain: master-slider