BuddyPress - Version 1.2.9

Version Description

Compatibility with WordPress 3.2

Download this release

Release Info

Developer johnjamesjacoby
Plugin Icon 128x128 BuddyPress
Version 1.2.9
Comparing to
See all releases

Code changes from version 1.2.7 to 1.2.9

Files changed (68) hide show
  1. bp-activity.php +10 -9
  2. bp-activity/bp-activity-classes.php +9 -3
  3. bp-activity/bp-activity-templatetags.php +1 -1
  4. bp-blogs.php +1 -1
  5. bp-core.php +7 -3
  6. bp-core/bp-core-admin.php +9 -9
  7. bp-core/bp-core-adminbar.php +37 -13
  8. bp-core/bp-core-avatars.php +2 -2
  9. bp-core/bp-core-filters.php +34 -0
  10. bp-core/bp-core-templatetags.php +36 -11
  11. bp-core/bp-core-wpabstraction.php +13 -0
  12. bp-core/images/admin_menu_icon.png +0 -0
  13. bp-forums.php +1 -1
  14. bp-forums/bbpress/bb-admin/admin-base.php +5 -1
  15. bp-forums/bbpress/bb-admin/admin.php +9 -1
  16. bp-forums/bbpress/bb-admin/includes/class.bb-install.php +3 -0
  17. bp-forums/bbpress/bb-admin/includes/defaults.bb-schema.php +43 -27
  18. bp-forums/bbpress/bb-admin/includes/functions.bb-admin.php +21 -2
  19. bp-forums/bbpress/bb-admin/includes/functions.bb-recount.php +262 -0
  20. bp-forums/bbpress/bb-admin/includes/functions.bb-upgrade.php +20 -7
  21. bp-forums/bbpress/bb-admin/index.php +22 -18
  22. bp-forums/bbpress/bb-admin/options-permalinks.php +188 -188
  23. bp-forums/bbpress/bb-admin/tools-recount.php +27 -132
  24. bp-forums/bbpress/bb-cron.php +11 -14
  25. bp-forums/bbpress/bb-includes/backpress/functions.formatting.php +6 -4
  26. bp-forums/bbpress/bb-includes/backpress/functions.kses.php +705 -64
  27. bp-forums/bbpress/bb-includes/class.bp-options.php +0 -3
  28. bp-forums/bbpress/bb-includes/functions.bb-core.php +66 -31
  29. bp-forums/bbpress/bb-includes/functions.bb-deprecated.php +5 -2
  30. bp-forums/bbpress/bb-includes/functions.bb-pluggable.php +15 -14
  31. bp-forums/bbpress/bb-includes/functions.bb-posts.php +1 -0
  32. bp-forums/bbpress/bb-includes/functions.bb-template.php +8 -9
  33. bp-forums/bbpress/bb-includes/functions.bb-users.php +78 -40
  34. bp-forums/bbpress/bb-includes/js/jquery/interface.js +12 -11
  35. bp-forums/bbpress/bb-login.php +104 -60
  36. bp-forums/bbpress/bb-templates/kakumei-blue/style.css +2 -0
  37. bp-forums/bbpress/bb-templates/kakumei/favorites.php +1 -1
  38. bp-forums/bbpress/bb-templates/kakumei/forum.php +2 -2
  39. bp-forums/bbpress/bb-templates/kakumei/front-page.php +2 -2
  40. bp-forums/bbpress/bb-templates/kakumei/post-form.php +2 -2
  41. bp-forums/bbpress/bb-templates/kakumei/style.css +16 -1
  42. bp-forums/bbpress/bb-templates/kakumei/tag-single.php +1 -1
  43. bp-forums/bbpress/bb-templates/kakumei/view.php +2 -2
  44. bp-forums/bbpress/rss.php +1 -1
  45. bp-forums/bp-forums-admin.php +8 -7
  46. bp-forums/bp-forums-bbpress.php +1 -1
  47. bp-friends.php +1 -1
  48. bp-groups.php +14 -3
  49. bp-languages/buddypress.pot +60 -62
  50. bp-loader.php +2 -3
  51. bp-messages.php +1 -1
  52. bp-messages/js/autocomplete/jquery.bgiframe.min.js +4 -8
  53. bp-messages/js/autocomplete/license.bgiframe.txt +20 -0
  54. bp-themes/bp-default/_inc/global.js +20 -18
  55. bp-themes/bp-default/style.css +1 -1
  56. bp-xprofile.php +1 -1
  57. bp-xprofile/bp-xprofile-cssjs.php +13 -4
  58. bp-xprofile/bp-xprofile-filters.php +3 -0
  59. bp-xprofile/bp-xprofile-templatetags.php +3 -3
  60. license.txt +281 -280
  61. readme.txt +11 -8
  62. screenshot-1.gif +0 -0
  63. screenshot-2.gif +0 -0
  64. screenshot-3.gif +0 -0
  65. screenshot-4.gif +0 -0
  66. screenshot-5.gif +0 -0
  67. screenshot-6.gif +0 -0
  68. screenshot-7.gif +0 -0
bp-activity.php CHANGED
@@ -98,7 +98,7 @@ function bp_activity_check_installed() {
98
  if ( get_site_option( 'bp-activity-db-version' ) < BP_ACTIVITY_DB_VERSION )
99
  bp_activity_install();
100
  }
101
- add_action( 'admin_menu', 'bp_activity_check_installed' );
102
 
103
  function bp_activity_setup_root_component() {
104
  /* Register 'activity' as a root component (for RSS feed use) */
@@ -610,18 +610,19 @@ function bp_activity_get( $args = '' ) {
610
 
611
  function bp_activity_get_specific( $args = '' ) {
612
  $defaults = array(
613
- 'activity_ids' => false, // A single activity_id or array of IDs.
614
- 'page' => 1, // page 1 without a per_page will result in no pagination.
615
- 'per_page' => false, // results per page
616
- 'max' => false, // Maximum number of results to return
617
- 'sort' => 'DESC', // sort ASC or DESC
618
- 'display_comments' => false // true or false to display threaded comments for these specific activity items
 
619
  );
620
 
621
  $r = wp_parse_args( $args, $defaults );
622
  extract( $r, EXTR_SKIP );
623
 
624
- return apply_filters( 'bp_activity_get_specific', BP_Activity_Activity::get_specific( $activity_ids, $max, $page, $per_page, $sort, $display_comments ) );
625
  }
626
 
627
  function bp_activity_add( $args = '' ) {
@@ -994,7 +995,7 @@ function bp_activity_get_action( $component_id, $key ) {
994
 
995
  function bp_activity_get_user_favorites( $user_id ) {
996
  $my_favs = maybe_unserialize( get_user_meta( $user_id, 'bp_favorite_activities', true ) );
997
- $existing_favs = bp_activity_get_specific( array( 'activity_ids' => $my_favs ) );
998
 
999
  foreach( (array)$existing_favs['activities'] as $fav )
1000
  $new_favs[] = $fav->id;
98
  if ( get_site_option( 'bp-activity-db-version' ) < BP_ACTIVITY_DB_VERSION )
99
  bp_activity_install();
100
  }
101
+ add_action( is_multisite() ? 'network_admin_menu' : 'admin_menu', 'bp_activity_check_installed' );
102
 
103
  function bp_activity_setup_root_component() {
104
  /* Register 'activity' as a root component (for RSS feed use) */
610
 
611
  function bp_activity_get_specific( $args = '' ) {
612
  $defaults = array(
613
+ 'activity_ids' => false, // A single activity_id or array of IDs.
614
+ 'page' => 1, // page 1 without a per_page will result in no pagination.
615
+ 'per_page' => false, // results per page
616
+ 'max' => false, // Maximum number of results to return
617
+ 'sort' => 'DESC', // sort ASC or DESC
618
+ 'display_comments' => false, // true or false to display threaded comments for these specific activity items
619
+ 'show_hidden' => false
620
  );
621
 
622
  $r = wp_parse_args( $args, $defaults );
623
  extract( $r, EXTR_SKIP );
624
 
625
+ return apply_filters( 'bp_activity_get_specific', BP_Activity_Activity::get_specific( $activity_ids, $max, $page, $per_page, $sort, $display_comments, $show_hidden ) );
626
  }
627
 
628
  function bp_activity_add( $args = '' ) {
995
 
996
  function bp_activity_get_user_favorites( $user_id ) {
997
  $my_favs = maybe_unserialize( get_user_meta( $user_id, 'bp_favorite_activities', true ) );
998
+ $existing_favs = bp_activity_get_specific( array( 'activity_ids' => $my_favs, 'show_hidden' => true ) );
999
 
1000
  foreach( (array)$existing_favs['activities'] as $fav )
1001
  $new_favs[] = $fav->id;
bp-activity/bp-activity-classes.php CHANGED
@@ -166,7 +166,7 @@ Class BP_Activity_Activity {
166
  return array( 'activities' => $activities, 'total' => (int)$total_activities );
167
  }
168
 
169
- function get_specific( $activity_ids, $max = false, $page = 1, $per_page = 25, $sort = 'DESC', $display_comments = false ) {
170
  global $wpdb, $bp;
171
 
172
  if ( is_array( $activity_ids ) )
@@ -183,8 +183,14 @@ Class BP_Activity_Activity {
183
  if ( $sort != 'ASC' && $sort != 'DESC' )
184
  $sort = 'DESC';
185
 
186
- $activities = $wpdb->get_results( $wpdb->prepare( "SELECT * FROM {$bp->activity->table_name} WHERE id IN ({$activity_ids}) ORDER BY date_recorded {$sort} $pag_sql" ) );
187
- $total_activities = $wpdb->get_var( $wpdb->prepare( "SELECT count(id) FROM {$bp->activity->table_name} WHERE id IN ({$activity_ids})" ) );
 
 
 
 
 
 
188
 
189
  if ( $display_comments )
190
  $activities = BP_Activity_Activity::append_comments( $activities );
166
  return array( 'activities' => $activities, 'total' => (int)$total_activities );
167
  }
168
 
169
+ function get_specific( $activity_ids, $max = false, $page = 1, $per_page = 25, $sort = 'DESC', $display_comments = false, $show_hidden = false ) {
170
  global $wpdb, $bp;
171
 
172
  if ( is_array( $activity_ids ) )
183
  if ( $sort != 'ASC' && $sort != 'DESC' )
184
  $sort = 'DESC';
185
 
186
+ // Hide Hidden Items?
187
+ if ( !$show_hidden )
188
+ $hidden_sql = "AND hide_sitewide = 0";
189
+ else
190
+ $hidden_sql = '';
191
+
192
+ $activities = $wpdb->get_results( $wpdb->prepare( "SELECT * FROM {$bp->activity->table_name} WHERE id IN ({$activity_ids}) {$hidden_sql} ORDER BY date_recorded {$sort} {$pag_sql}" ) );
193
+ $total_activities = $wpdb->get_var( $wpdb->prepare( "SELECT count(id) FROM {$bp->activity->table_name} WHERE id IN ({$activity_ids}) {$hidden_sql}" ) );
194
 
195
  if ( $display_comments )
196
  $activities = BP_Activity_Activity::append_comments( $activities );
bp-activity/bp-activity-templatetags.php CHANGED
@@ -29,7 +29,7 @@ class BP_Activity_Template {
29
 
30
  // Fetch specific activity items based on ID's
31
  if ( !empty( $include ) )
32
- $this->activities = bp_activity_get_specific( array( 'activity_ids' => explode( ',', $include ), 'max' => $max, 'page' => $this->pag_page, 'per_page' => $this->pag_num, 'sort' => $sort, 'display_comments' => $display_comments ) );
33
  // Fetch all activity items
34
  else
35
  $this->activities = bp_activity_get( array( 'display_comments' => $display_comments, 'max' => $max, 'per_page' => $this->pag_num, 'page' => $this->pag_page, 'sort' => $sort, 'search_terms' => $search_terms, 'filter' => $filter, 'show_hidden' => $show_hidden ) );
29
 
30
  // Fetch specific activity items based on ID's
31
  if ( !empty( $include ) )
32
+ $this->activities = bp_activity_get_specific( array( 'activity_ids' => explode( ',', $include ), 'max' => $max, 'page' => $this->pag_page, 'per_page' => $this->pag_num, 'sort' => $sort, 'display_comments' => $display_comments, 'show_hidden' => $show_hidden ) );
33
  // Fetch all activity items
34
  else
35
  $this->activities = bp_activity_get( array( 'display_comments' => $display_comments, 'max' => $max, 'per_page' => $this->pag_num, 'page' => $this->pag_page, 'sort' => $sort, 'search_terms' => $search_terms, 'filter' => $filter, 'show_hidden' => $show_hidden ) );
bp-blogs.php CHANGED
@@ -60,7 +60,7 @@ function bp_blogs_check_installed() {
60
  bp_blogs_install();
61
  }
62
  }
63
- add_action( 'admin_menu', 'bp_blogs_check_installed' );
64
 
65
  function bp_blogs_setup_globals() {
66
  global $bp, $wpdb;
60
  bp_blogs_install();
61
  }
62
  }
63
+ add_action( is_multisite() ? 'network_admin_menu' : 'admin_menu', 'bp_blogs_check_installed' );
64
 
65
  function bp_blogs_setup_globals() {
66
  global $bp, $wpdb;
bp-core.php CHANGED
@@ -284,7 +284,7 @@ function bp_core_check_installed() {
284
  if ( get_site_option( 'bp-core-db-version' ) < BP_CORE_DB_VERSION )
285
  bp_core_install();
286
  }
287
- add_action( 'admin_menu', 'bp_core_check_installed' );
288
 
289
  /**
290
  * bp_core_add_admin_menu()
@@ -300,7 +300,11 @@ function bp_core_add_admin_menu() {
300
  if ( !is_super_admin() )
301
  return false;
302
 
303
- /* Add the administration tab under the "Site Admin" tab for site administrators */
 
 
 
 
304
  bp_core_add_admin_menu_page( array(
305
  'menu_title' => __( 'BuddyPress', 'buddypress' ),
306
  'page_title' => __( 'BuddyPress', 'buddypress' ),
@@ -312,7 +316,7 @@ function bp_core_add_admin_menu() {
312
  add_submenu_page( 'bp-general-settings', __( 'General Settings', 'buddypress'), __( 'General Settings', 'buddypress' ), 'manage_options', 'bp-general-settings', 'bp_core_admin_settings' );
313
  add_submenu_page( 'bp-general-settings', __( 'Component Setup', 'buddypress'), __( 'Component Setup', 'buddypress' ), 'manage_options', 'bp-component-setup', 'bp_core_admin_component_setup' );
314
  }
315
- add_action( 'admin_menu', 'bp_core_add_admin_menu' );
316
 
317
  /**
318
  * bp_core_is_root_component()
284
  if ( get_site_option( 'bp-core-db-version' ) < BP_CORE_DB_VERSION )
285
  bp_core_install();
286
  }
287
+ add_action( is_multisite() ? 'network_admin_menu' : 'admin_menu', 'bp_core_check_installed' );
288
 
289
  /**
290
  * bp_core_add_admin_menu()
300
  if ( !is_super_admin() )
301
  return false;
302
 
303
+ // If this is WP 3.1+ and multisite is enabled, only load on the Network Admin
304
+ if ( is_multisite() && function_exists( 'is_network_admin' ) && ! is_network_admin() )
305
+ return false;
306
+
307
+ // Add the administration tab under the "Site Admin" tab for site administrators
308
  bp_core_add_admin_menu_page( array(
309
  'menu_title' => __( 'BuddyPress', 'buddypress' ),
310
  'page_title' => __( 'BuddyPress', 'buddypress' ),
316
  add_submenu_page( 'bp-general-settings', __( 'General Settings', 'buddypress'), __( 'General Settings', 'buddypress' ), 'manage_options', 'bp-general-settings', 'bp_core_admin_settings' );
317
  add_submenu_page( 'bp-general-settings', __( 'Component Setup', 'buddypress'), __( 'Component Setup', 'buddypress' ), 'manage_options', 'bp-component-setup', 'bp_core_admin_component_setup' );
318
  }
319
+ add_action( is_multisite() ? 'network_admin_menu' : 'admin_menu', 'bp_core_add_admin_menu' );
320
 
321
  /**
322
  * bp_core_is_root_component()
bp-core/bp-core-admin.php CHANGED
@@ -43,19 +43,19 @@ function bp_core_admin_settings() {
43
  <tbody>
44
  <?php if ( function_exists( 'xprofile_install' ) ) :?>
45
  <tr>
46
- <th scope="row"><?php _e( 'Base profile group name', 'buddypress' ) ?>:</th>
47
  <td>
48
  <input name="bp-admin[bp-xprofile-base-group-name]" id="bp-xprofile-base-group-name" value="<?php echo get_site_option('bp-xprofile-base-group-name') ?>" />
49
  </td>
50
  </tr>
51
  <tr>
52
- <th scope="row"><?php _e( 'Full Name field name', 'buddypress' ) ?>:</th>
53
  <td>
54
  <input name="bp-admin[bp-xprofile-fullname-field-name]" id="bp-xprofile-fullname-field-name" value="<?php echo get_site_option('bp-xprofile-fullname-field-name') ?>" />
55
  </td>
56
  </tr>
57
  <tr>
58
- <th scope="row"><?php _e( 'Disable BuddyPress to WordPress profile syncing?', 'buddypress' ) ?>:</th>
59
  <td>
60
  <input type="radio" name="bp-admin[bp-disable-profile-sync]"<?php if ( (int)get_site_option( 'bp-disable-profile-sync' ) ) : ?> checked="checked"<?php endif; ?> id="bp-disable-profile-sync" value="1" /> <?php _e( 'Yes', 'buddypress' ) ?> &nbsp;
61
  <input type="radio" name="bp-admin[bp-disable-profile-sync]"<?php if ( !(int)get_site_option( 'bp-disable-profile-sync' ) || '' == get_site_option( 'bp-disable-profile-sync' ) ) : ?> checked="checked"<?php endif; ?> id="bp-disable-profile-sync" value="0" /> <?php _e( 'No', 'buddypress' ) ?>
@@ -63,21 +63,21 @@ function bp_core_admin_settings() {
63
  </tr>
64
  <?php endif; ?>
65
  <tr>
66
- <th scope="row"><?php _e( 'Hide admin bar for logged out users?', 'buddypress' ) ?>:</th>
67
  <td>
68
  <input type="radio" name="bp-admin[hide-loggedout-adminbar]"<?php if ( (int)get_site_option( 'hide-loggedout-adminbar' ) ) : ?> checked="checked"<?php endif; ?> id="bp-admin-hide-loggedout-adminbar-yes" value="1" /> <?php _e( 'Yes', 'buddypress' ) ?> &nbsp;
69
  <input type="radio" name="bp-admin[hide-loggedout-adminbar]"<?php if ( !(int)get_site_option( 'hide-loggedout-adminbar' ) ) : ?> checked="checked"<?php endif; ?> id="bp-admin-hide-loggedout-adminbar-no" value="0" /> <?php _e( 'No', 'buddypress' ) ?>
70
  </td>
71
  </tr>
72
  <tr>
73
- <th scope="row"><?php _e( 'Disable avatar uploads? (Gravatars will still work)', 'buddypress' ) ?>:</th>
74
  <td>
75
  <input type="radio" name="bp-admin[bp-disable-avatar-uploads]"<?php if ( (int)get_site_option( 'bp-disable-avatar-uploads' ) ) : ?> checked="checked"<?php endif; ?> id="bp-admin-disable-avatar-uploads-yes" value="1" /> <?php _e( 'Yes', 'buddypress' ) ?> &nbsp;
76
  <input type="radio" name="bp-admin[bp-disable-avatar-uploads]"<?php if ( !(int)get_site_option( 'bp-disable-avatar-uploads' ) ) : ?> checked="checked"<?php endif; ?> id="bp-admin-disable-avatar-uploads-no" value="0" /> <?php _e( 'No', 'buddypress' ) ?>
77
  </td>
78
  </tr>
79
  <tr>
80
- <th scope="row"><?php _e( 'Disable user account deletion?', 'buddypress' ) ?>:</th>
81
  <td>
82
  <input type="radio" name="bp-admin[bp-disable-account-deletion]"<?php if ( (int)get_site_option( 'bp-disable-account-deletion' ) ) : ?> checked="checked"<?php endif; ?> id="bp-disable-account-deletion" value="1" /> <?php _e( 'Yes', 'buddypress' ) ?> &nbsp;
83
  <input type="radio" name="bp-admin[bp-disable-account-deletion]"<?php if ( !(int)get_site_option( 'bp-disable-account-deletion' ) ) : ?> checked="checked"<?php endif; ?> id="bp-disable-account-deletion" value="0" /> <?php _e( 'No', 'buddypress' ) ?>
@@ -85,7 +85,7 @@ function bp_core_admin_settings() {
85
  </tr>
86
  <?php if ( function_exists( 'bp_forums_setup') ) : ?>
87
  <tr>
88
- <th scope="row"><?php _e( 'Disable global forum directory?', 'buddypress' ) ?>:</th>
89
  <td>
90
  <input type="radio" name="bp-admin[bp-disable-forum-directory]"<?php if ( (int)get_site_option( 'bp-disable-forum-directory' ) ) : ?> checked="checked"<?php endif; ?> id="bp-disable-forum-directory" value="1" /> <?php _e( 'Yes', 'buddypress' ) ?> &nbsp;
91
  <input type="radio" name="bp-admin[bp-disable-forum-directory]"<?php if ( !(int)get_site_option( 'bp-disable-forum-directory' ) ) : ?> checked="checked"<?php endif; ?> id="bp-disable-forum-directory" value="0" /> <?php _e( 'No', 'buddypress' ) ?>
@@ -94,7 +94,7 @@ function bp_core_admin_settings() {
94
  <?php endif; ?>
95
  <?php if ( function_exists( 'bp_activity_install') ) : ?>
96
  <tr>
97
- <th scope="row"><?php _e( 'Disable activity stream commenting on blog and forum posts?', 'buddypress' ) ?>:</th>
98
  <td>
99
  <input type="radio" name="bp-admin[bp-disable-blogforum-comments]"<?php if ( (int)get_site_option( 'bp-disable-blogforum-comments' ) || false === get_site_option( 'bp-disable-blogforum-comments' ) ) : ?> checked="checked"<?php endif; ?> id="bp-disable-blogforum-comments" value="1" /> <?php _e( 'Yes', 'buddypress' ) ?> &nbsp;
100
  <input type="radio" name="bp-admin[bp-disable-blogforum-comments]"<?php if ( !(int)get_site_option( 'bp-disable-blogforum-comments' ) ) : ?> checked="checked"<?php endif; ?> id="bp-disable-blogforum-comments" value="0" /> <?php _e( 'No', 'buddypress' ) ?>
@@ -103,7 +103,7 @@ function bp_core_admin_settings() {
103
  <?php endif; ?>
104
 
105
  <tr>
106
- <th scope="row"><?php _e( 'Default User Avatar', 'buddypress' ) ?></th>
107
  <td>
108
  <p><?php _e( 'For users without a custom avatar of their own, you can either display a generic logo or a generated one based on their email address', 'buddypress' ) ?></p>
109
 
43
  <tbody>
44
  <?php if ( function_exists( 'xprofile_install' ) ) :?>
45
  <tr>
46
+ <th scope="row"><p><?php _e( 'Base profile group name', 'buddypress' ) ?>:</p></th>
47
  <td>
48
  <input name="bp-admin[bp-xprofile-base-group-name]" id="bp-xprofile-base-group-name" value="<?php echo get_site_option('bp-xprofile-base-group-name') ?>" />
49
  </td>
50
  </tr>
51
  <tr>
52
+ <th scope="row"><p><?php _e( 'Full Name field name', 'buddypress' ) ?>:</p></th>
53
  <td>
54
  <input name="bp-admin[bp-xprofile-fullname-field-name]" id="bp-xprofile-fullname-field-name" value="<?php echo get_site_option('bp-xprofile-fullname-field-name') ?>" />
55
  </td>
56
  </tr>
57
  <tr>
58
+ <th scope="row"><p><?php _e( 'Disable BuddyPress to WordPress profile syncing?', 'buddypress' ) ?>:</p></th>
59
  <td>
60
  <input type="radio" name="bp-admin[bp-disable-profile-sync]"<?php if ( (int)get_site_option( 'bp-disable-profile-sync' ) ) : ?> checked="checked"<?php endif; ?> id="bp-disable-profile-sync" value="1" /> <?php _e( 'Yes', 'buddypress' ) ?> &nbsp;
61
  <input type="radio" name="bp-admin[bp-disable-profile-sync]"<?php if ( !(int)get_site_option( 'bp-disable-profile-sync' ) || '' == get_site_option( 'bp-disable-profile-sync' ) ) : ?> checked="checked"<?php endif; ?> id="bp-disable-profile-sync" value="0" /> <?php _e( 'No', 'buddypress' ) ?>
63
  </tr>
64
  <?php endif; ?>
65
  <tr>
66
+ <th scope="row"><p><?php _e( 'Hide admin bar for logged out users?', 'buddypress' ) ?>:</p></th>
67
  <td>
68
  <input type="radio" name="bp-admin[hide-loggedout-adminbar]"<?php if ( (int)get_site_option( 'hide-loggedout-adminbar' ) ) : ?> checked="checked"<?php endif; ?> id="bp-admin-hide-loggedout-adminbar-yes" value="1" /> <?php _e( 'Yes', 'buddypress' ) ?> &nbsp;
69
  <input type="radio" name="bp-admin[hide-loggedout-adminbar]"<?php if ( !(int)get_site_option( 'hide-loggedout-adminbar' ) ) : ?> checked="checked"<?php endif; ?> id="bp-admin-hide-loggedout-adminbar-no" value="0" /> <?php _e( 'No', 'buddypress' ) ?>
70
  </td>
71
  </tr>
72
  <tr>
73
+ <th scope="row"><p><?php _e( 'Disable avatar uploads? (Gravatars will still work)', 'buddypress' ) ?>:</p></th>
74
  <td>
75
  <input type="radio" name="bp-admin[bp-disable-avatar-uploads]"<?php if ( (int)get_site_option( 'bp-disable-avatar-uploads' ) ) : ?> checked="checked"<?php endif; ?> id="bp-admin-disable-avatar-uploads-yes" value="1" /> <?php _e( 'Yes', 'buddypress' ) ?> &nbsp;
76
  <input type="radio" name="bp-admin[bp-disable-avatar-uploads]"<?php if ( !(int)get_site_option( 'bp-disable-avatar-uploads' ) ) : ?> checked="checked"<?php endif; ?> id="bp-admin-disable-avatar-uploads-no" value="0" /> <?php _e( 'No', 'buddypress' ) ?>
77
  </td>
78
  </tr>
79
  <tr>
80
+ <th scope="row"><p><?php _e( 'Disable user account deletion?', 'buddypress' ) ?>:</p></th>
81
  <td>
82
  <input type="radio" name="bp-admin[bp-disable-account-deletion]"<?php if ( (int)get_site_option( 'bp-disable-account-deletion' ) ) : ?> checked="checked"<?php endif; ?> id="bp-disable-account-deletion" value="1" /> <?php _e( 'Yes', 'buddypress' ) ?> &nbsp;
83
  <input type="radio" name="bp-admin[bp-disable-account-deletion]"<?php if ( !(int)get_site_option( 'bp-disable-account-deletion' ) ) : ?> checked="checked"<?php endif; ?> id="bp-disable-account-deletion" value="0" /> <?php _e( 'No', 'buddypress' ) ?>
85
  </tr>
86
  <?php if ( function_exists( 'bp_forums_setup') ) : ?>
87
  <tr>
88
+ <th scope="row"><p><?php _e( 'Disable global forum directory?', 'buddypress' ) ?>:</p></th>
89
  <td>
90
  <input type="radio" name="bp-admin[bp-disable-forum-directory]"<?php if ( (int)get_site_option( 'bp-disable-forum-directory' ) ) : ?> checked="checked"<?php endif; ?> id="bp-disable-forum-directory" value="1" /> <?php _e( 'Yes', 'buddypress' ) ?> &nbsp;
91
  <input type="radio" name="bp-admin[bp-disable-forum-directory]"<?php if ( !(int)get_site_option( 'bp-disable-forum-directory' ) ) : ?> checked="checked"<?php endif; ?> id="bp-disable-forum-directory" value="0" /> <?php _e( 'No', 'buddypress' ) ?>
94
  <?php endif; ?>
95
  <?php if ( function_exists( 'bp_activity_install') ) : ?>
96
  <tr>
97
+ <th scope="row"><p><?php _e( 'Disable activity stream commenting on blog and forum posts?', 'buddypress' ) ?>:</p></th>
98
  <td>
99
  <input type="radio" name="bp-admin[bp-disable-blogforum-comments]"<?php if ( (int)get_site_option( 'bp-disable-blogforum-comments' ) || false === get_site_option( 'bp-disable-blogforum-comments' ) ) : ?> checked="checked"<?php endif; ?> id="bp-disable-blogforum-comments" value="1" /> <?php _e( 'Yes', 'buddypress' ) ?> &nbsp;
100
  <input type="radio" name="bp-admin[bp-disable-blogforum-comments]"<?php if ( !(int)get_site_option( 'bp-disable-blogforum-comments' ) ) : ?> checked="checked"<?php endif; ?> id="bp-disable-blogforum-comments" value="0" /> <?php _e( 'No', 'buddypress' ) ?>
103
  <?php endif; ?>
104
 
105
  <tr>
106
+ <th scope="row"><p><?php _e( 'Default User Avatar', 'buddypress' ) ?></p></th>
107
  <td>
108
  <p><?php _e( 'For users without a custom avatar of their own, you can either display a generic logo or a generated one based on their email address', 'buddypress' ) ?></p>
109
 
bp-core/bp-core-adminbar.php CHANGED
@@ -273,18 +273,42 @@ function bp_adminbar_random_menu() {
273
  <?php
274
  }
275
 
276
- // Actions used to build the admin bar
277
- add_action( 'bp_adminbar_logo', 'bp_adminbar_logo' );
278
- add_action( 'bp_adminbar_menus', 'bp_adminbar_login_menu', 2 );
279
- add_action( 'bp_adminbar_menus', 'bp_adminbar_account_menu', 4 );
280
- add_action( 'bp_adminbar_menus', 'bp_adminbar_blogs_menu', 6 );
281
- add_action( 'bp_adminbar_menus', 'bp_adminbar_thisblog_menu', 6 );
282
- add_action( 'bp_adminbar_menus', 'bp_adminbar_notifications_menu', 8 );
283
- add_action( 'bp_adminbar_menus', 'bp_adminbar_authors_menu', 12 );
284
- add_action( 'bp_adminbar_menus', 'bp_adminbar_random_menu', 100 );
285
-
286
- // Actions used to append admin bar to footer
287
- add_action( 'wp_footer', 'bp_core_admin_bar', 8 );
288
- add_action( 'admin_footer', 'bp_core_admin_bar' );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
289
 
290
  ?>
273
  <?php
274
  }
275
 
276
+ /**
277
+ * Provides fallback support for the WordPress 3.1 admin bar
278
+ *
279
+ * By default, this function turns off the WP 3.1 admin bar in favor of the classic BP BuddyBar.
280
+ * To turn off the BP BuddyBar in favor of WP's admin bar, place the following in wp-config.php:
281
+ * define( 'BP_USE_WP_ADMIN_BAR', true );
282
+ *
283
+ * @package BuddyPress Core
284
+ * @since 1.2.8
285
+ */
286
+ function bp_core_load_admin_bar() {
287
+ global $wp_version;
288
+
289
+ if ( defined( 'BP_USE_WP_ADMIN_BAR' ) && BP_USE_WP_ADMIN_BAR && version_compare( $wp_version, 3.1, '>=' ) ) {
290
+ // TODO: Add BP support to WP admin bar
291
+ return;
292
+ } elseif ( !defined( 'BP_DISABLE_ADMIN_BAR' ) || !BP_DISABLE_ADMIN_BAR ) {
293
+ // Keep the WP admin bar from loading
294
+ if ( function_exists( 'show_admin_bar' ) )
295
+ show_admin_bar( false );
296
+
297
+ // Actions used to build the BP admin bar
298
+ add_action( 'bp_adminbar_logo', 'bp_adminbar_logo' );
299
+ add_action( 'bp_adminbar_menus', 'bp_adminbar_login_menu', 2 );
300
+ add_action( 'bp_adminbar_menus', 'bp_adminbar_account_menu', 4 );
301
+ add_action( 'bp_adminbar_menus', 'bp_adminbar_blogs_menu', 6 );
302
+ add_action( 'bp_adminbar_menus', 'bp_adminbar_thisblog_menu', 6 );
303
+ add_action( 'bp_adminbar_menus', 'bp_adminbar_notifications_menu', 8 );
304
+ add_action( 'bp_adminbar_menus', 'bp_adminbar_authors_menu', 12 );
305
+ add_action( 'bp_adminbar_menus', 'bp_adminbar_random_menu', 100 );
306
+
307
+ // Actions used to append BP admin bar to footer
308
+ add_action( 'wp_footer', 'bp_core_admin_bar', 8 );
309
+ add_action( 'admin_footer', 'bp_core_admin_bar' );
310
+ }
311
+ }
312
+ add_action( 'bp_loaded', 'bp_core_load_admin_bar' );
313
 
314
  ?>
bp-core/bp-core-avatars.php CHANGED
@@ -522,7 +522,7 @@ function bp_core_check_avatar_size($file) {
522
  }
523
 
524
  function bp_core_check_avatar_type($file) {
525
- if ( ( strlen($file['file']['type']) && !preg_match('/(jpe?g|gif|png)$/', $file['file']['type'] ) ) && !preg_match( '/(jpe?g|gif|png)$/', $file['file']['name'] ) )
526
  return false;
527
 
528
  return true;
@@ -567,7 +567,7 @@ function bp_core_avatar_url() {
567
 
568
  // If multisite, and current blog does not match root blog, make adjustments
569
  if ( bp_core_is_multisite() && BP_ROOT_BLOG != $current_blog->blog_id )
570
- $upload_dir['baseurl'] = str_replace( get_blog_option( $current_blog->blog_id, 'home' ) , get_blog_option( BP_ROOT_BLOG, 'home' ), $upload_dir['baseurl'] );
571
 
572
  return apply_filters( 'bp_core_avatar_url', $upload_dir['baseurl'] );
573
  }
522
  }
523
 
524
  function bp_core_check_avatar_type($file) {
525
+ if ( ( !empty( $file['file']['type'] ) && !preg_match('/(jpe?g|gif|png)$/', $file['file']['type'] ) ) || !preg_match( '/(jpe?g|gif|png)$/', $file['file']['name'] ) )
526
  return false;
527
 
528
  return true;
567
 
568
  // If multisite, and current blog does not match root blog, make adjustments
569
  if ( bp_core_is_multisite() && BP_ROOT_BLOG != $current_blog->blog_id )
570
+ $upload_dir['baseurl'] = trailingslashit( get_blog_option( BP_ROOT_BLOG, 'home' ) ) . get_blog_option( BP_ROOT_BLOG, 'upload_path' );
571
 
572
  return apply_filters( 'bp_core_avatar_url', $upload_dir['baseurl'] );
573
  }
bp-core/bp-core-filters.php CHANGED
@@ -1,5 +1,39 @@
1
  <?php
2
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3
  /**
4
  * bp_core_email_from_name_filter()
5
  *
1
  <?php
2
 
3
+ /**
4
+ * Load additional sign-up sanitization filters on bp_loaded. These are used
5
+ * to prevent XSS in the BuddyPress sign-up process. You can unhook these to
6
+ * allow for customization of your registration fields, however it is highly
7
+ * recommended that you leave these in place for the safety of your network.
8
+ *
9
+ * @since BuddyPress (r4079)
10
+ * @uses add_filter()
11
+ */
12
+ function bp_core_signup_sanitization() {
13
+
14
+ // Filters on sign-up fields
15
+ $fields = array (
16
+ 'bp_get_signup_username_value',
17
+ 'bp_get_signup_email_value',
18
+ 'bp_get_signup_with_blog_value',
19
+ 'bp_get_signup_blog_url_value',
20
+ 'bp_get_signup_blog_title_value',
21
+ 'bp_get_signup_blog_privacy_value',
22
+ 'bp_get_signup_avatar_dir_value',
23
+ );
24
+
25
+ // Add the 'strip_tags' filter to each field
26
+ foreach( $fields as $filter ) {
27
+ add_filter( $filter, 'esc_html', 1 );
28
+ add_filter( $filter, 'wp_filter_kses', 2 );
29
+ add_filter( $filter, 'stripslashes', 3 );
30
+ }
31
+
32
+ // Sanitize email
33
+ add_filter( 'bp_get_signup_email_value', 'sanitize_email' );
34
+ }
35
+ add_action( 'bp_loaded', 'bp_core_signup_sanitization' );
36
+
37
  /**
38
  * bp_core_email_from_name_filter()
39
  *
bp-core/bp-core-templatetags.php CHANGED
@@ -1189,6 +1189,18 @@ function bp_signup_avatar_dir_value() {
1189
  function bp_get_signup_avatar_dir_value() {
1190
  global $bp;
1191
 
 
 
 
 
 
 
 
 
 
 
 
 
1192
  return apply_filters( 'bp_get_signup_avatar_dir_value', $bp->signup->avatar_dir );
1193
  }
1194
 
@@ -1216,24 +1228,37 @@ function bp_signup_avatar( $args = '' ) {
1216
  $r = wp_parse_args( $args, $defaults );
1217
  extract( $r, EXTR_SKIP );
1218
 
1219
- $signup_avatar_dir = ( !empty( $_POST['signup_avatar_dir'] ) ) ? $_POST['signup_avatar_dir'] : $bp->signup->avatar_dir;
 
 
 
 
 
 
 
 
 
 
 
1220
 
1221
- if ( empty( $signup_avatar_dir ) ) {
1222
- if ( empty( $bp->grav_default->user ) ) {
 
 
 
1223
  $default_grav = 'wavatar';
1224
- } else if ( 'mystery' == $bp->grav_default->user ) {
1225
  $default_grav = BP_PLUGIN_URL . '/bp-core/images/mystery-man.jpg';
1226
- } else {
1227
  $default_grav = $bp->grav_default->user;
1228
- }
1229
 
1230
- $gravatar_url = apply_filters( 'bp_gravatar_url', 'http://www.gravatar.com/avatar/' );
1231
- $gravatar_img = '<img src="' . $gravatar_url . md5( strtolower( $_POST['signup_email'] ) ) . '?d=' . $default_grav . '&amp;s=' . $size . '" width="' . $size . '" height="' . $size . '" alt="' . $alt . '" class="' . $class . '" />';
1232
- } else {
1233
- $gravatar_img = bp_core_fetch_avatar( array( 'item_id' => $signup_avatar_dir, 'object' => 'signup', 'avatar_dir' => 'avatars/signups', 'type' => 'full', 'width' => $size, 'height' => $size, 'alt' => $alt, 'class' => $class ) );
1234
  }
1235
 
1236
- return apply_filters( 'bp_get_signup_avatar', $gravatar_img );
1237
  }
1238
 
1239
  function bp_signup_allowed() {
1189
  function bp_get_signup_avatar_dir_value() {
1190
  global $bp;
1191
 
1192
+ // Check if signup_avatar_dir is passed
1193
+ if ( !empty( $_POST['signup_avatar_dir'] ) )
1194
+ $signup_avatar_dir = $_POST['signup_avatar_dir'];
1195
+
1196
+ // If not, check if global is set
1197
+ elseif ( !empty( $bp->signup->avatar_dir ) )
1198
+ $signup_avatar_dir = $bp->signup->avatar_dir;
1199
+
1200
+ // If not, set false
1201
+ else
1202
+ $signup_avatar_dir = false;
1203
+
1204
  return apply_filters( 'bp_get_signup_avatar_dir_value', $bp->signup->avatar_dir );
1205
  }
1206
 
1228
  $r = wp_parse_args( $args, $defaults );
1229
  extract( $r, EXTR_SKIP );
1230
 
1231
+ // Avatar DIR is found
1232
+ if ( $signup_avatar_dir = bp_get_signup_avatar_dir_value() ) {
1233
+ $gravatar_img = bp_core_fetch_avatar( array(
1234
+ 'item_id' => $signup_avatar_dir,
1235
+ 'object' => 'signup',
1236
+ 'avatar_dir' => 'avatars/signups',
1237
+ 'type' => 'full',
1238
+ 'width' => $size,
1239
+ 'height' => $size,
1240
+ 'alt' => $alt,
1241
+ 'class' => $class
1242
+ ) );
1243
 
1244
+ // No avatar DIR was found
1245
+ } else {
1246
+
1247
+ // Set default gravatar type
1248
+ if ( empty( $bp->grav_default->user ) )
1249
  $default_grav = 'wavatar';
1250
+ else if ( 'mystery' == $bp->grav_default->user )
1251
  $default_grav = BP_PLUGIN_URL . '/bp-core/images/mystery-man.jpg';
1252
+ else
1253
  $default_grav = $bp->grav_default->user;
 
1254
 
1255
+ // Create
1256
+ $gravatar_url = apply_filters( 'bp_gravatar_url', 'http://www.gravatar.com/avatar/' );
1257
+ $md5_lcase_email = md5( strtolower( bp_get_signup_email_value() ) );
1258
+ $gravatar_img = '<img src="' . $gravatar_url . $md5_lcase_email . '?d=' . $default_grav . '&amp;s=' . $size . '" width="' . $size . '" height="' . $size . '" alt="' . $alt . '" class="' . $class . '" />';
1259
  }
1260
 
1261
+ return apply_filters( 'bp_get_signup_avatar', $gravatar_img, $args );
1262
  }
1263
 
1264
  function bp_signup_allowed() {
bp-core/bp-core-wpabstraction.php CHANGED
@@ -112,4 +112,17 @@ if ( !function_exists( 'is_site_admin' ) ) {
112
  }
113
  }
114
 
 
 
 
 
 
 
 
 
 
 
 
 
 
115
  ?>
112
  }
113
  }
114
 
115
+ // Added for WordPress 3.1 support
116
+ if ( !function_exists( 'get_dashboard_url' ) ) {
117
+
118
+ /**
119
+ * Make sure the 'network_admin_menu' hook (which is new to 3.1) fires
120
+ * on our reliable friend 'admin_menu'
121
+ */
122
+ function bp_network_admin_menu() {
123
+ do_action( 'network_admin_menu' );
124
+ }
125
+ add_action( 'admin_menu', 'bp_network_admin_menu' );
126
+ }
127
+
128
  ?>
bp-core/images/admin_menu_icon.png CHANGED
Binary file
bp-forums.php CHANGED
@@ -102,7 +102,7 @@ function bp_forums_add_admin_menu() {
102
  /* Add the administration tab under the "Site Admin" tab for site administrators */
103
  add_submenu_page( 'bp-general-settings', __( 'Forums Setup', 'buddypress' ), __( 'Forums Setup', 'buddypress' ), 'manage_options', 'bb-forums-setup', "bp_forums_bbpress_admin" );
104
  }
105
- add_action( 'admin_menu', 'bp_forums_add_admin_menu' );
106
 
107
  /* Forum Functions */
108
 
102
  /* Add the administration tab under the "Site Admin" tab for site administrators */
103
  add_submenu_page( 'bp-general-settings', __( 'Forums Setup', 'buddypress' ), __( 'Forums Setup', 'buddypress' ), 'manage_options', 'bb-forums-setup', "bp_forums_bbpress_admin" );
104
  }
105
+ add_action( is_multisite() ? 'network_admin_menu' : 'admin_menu', 'bp_forums_add_admin_menu' );
106
 
107
  /* Forum Functions */
108
 
bp-forums/bbpress/bb-admin/admin-base.php CHANGED
@@ -10,7 +10,11 @@ bb_get_admin_header();
10
 
11
  <?php if ( is_callable($bb_admin_page) ) : call_user_func( $bb_admin_page ); else : ?>
12
 
13
- <p><?php _e('Nothing to see here.'); ?><p>
 
 
 
 
14
 
15
  <?php endif; ?>
16
 
10
 
11
  <?php if ( is_callable($bb_admin_page) ) : call_user_func( $bb_admin_page ); else : ?>
12
 
13
+ <h2><?php _e( 'Page not found' ); ?></h2>
14
+ <?php
15
+ bb_admin_notice( __( 'There is no administration page at the requested address. Please check the address you entered and try again.' ), 'error' );
16
+ do_action( 'bb_admin_notices' );
17
+ ?>
18
 
19
  <?php endif; ?>
20
 
bp-forums/bbpress/bb-admin/admin.php CHANGED
@@ -16,8 +16,10 @@ require_once( BB_PATH . 'bb-admin/includes/functions.bb-admin.php' );
16
 
17
  $bb_admin_page = bb_find_filename( $_SERVER['PHP_SELF'] );
18
 
 
19
  if ( $bb_admin_page == 'admin-base.php' ) {
20
- $bb_admin_page = $_GET['plugin'];
 
21
  }
22
 
23
  wp_enqueue_script( 'common' );
@@ -34,4 +36,10 @@ if ( isset( $_GET['foldmenu'] ) ) {
34
  }
35
  bb_admin_menu_generator();
36
  bb_get_current_admin_menu();
 
 
 
 
 
 
37
  ?>
16
 
17
  $bb_admin_page = bb_find_filename( $_SERVER['PHP_SELF'] );
18
 
19
+ $_check_callback = false;
20
  if ( $bb_admin_page == 'admin-base.php' ) {
21
+ $bb_admin_page = (string) @$_GET['plugin'];
22
+ $_check_callback = true;
23
  }
24
 
25
  wp_enqueue_script( 'common' );
36
  }
37
  bb_admin_menu_generator();
38
  bb_get_current_admin_menu();
39
+
40
+ if ( $_check_callback ) {
41
+ if ( empty( $bb_registered_plugin_callbacks ) || empty( $bb_admin_page ) || !in_array( $bb_admin_page, $bb_registered_plugin_callbacks ) ) {
42
+ unset( $bb_admin_page );
43
+ }
44
+ }
45
  ?>
bp-forums/bbpress/bb-admin/includes/class.bb-install.php CHANGED
@@ -309,6 +309,9 @@ class BB_Install
309
  function get_languages()
310
  {
311
  foreach ( bb_glob( BB_LANG_DIR . '*.mo' ) as $language ) {
 
 
 
312
  $language = str_replace( '.mo', '', basename( $language ) );
313
  $this->languages[$language] = $language;
314
  }
309
  function get_languages()
310
  {
311
  foreach ( bb_glob( BB_LANG_DIR . '*.mo' ) as $language ) {
312
+ if ( substr( $language, 0, 18 ) === 'continents-cities-' ) {
313
+ continue;
314
+ }
315
  $language = str_replace( '.mo', '', basename( $language ) );
316
  $this->languages[$language] = $language;
317
  }
bp-forums/bbpress/bb-admin/includes/defaults.bb-schema.php CHANGED
@@ -113,33 +113,37 @@ $bb_queries['topics'] = "CREATE TABLE IF NOT EXISTS `$bbdb->topics` (
113
  KEY `stickies` (`topic_status`, `topic_sticky`, `topic_time`)
114
  );";
115
 
116
- // users - 'user_login', 'user_nicename' and 'user_registered' indices are inconsistent with WordPress
117
- $bb_queries['users'] = "CREATE TABLE IF NOT EXISTS `$bbdb->users` (
118
- `ID` bigint(20) unsigned NOT NULL auto_increment,
119
- `user_login` varchar(60) NOT NULL default '',
120
- `user_pass` varchar(64) NOT NULL default '',
121
- `user_nicename` varchar(50) NOT NULL default '',
122
- `user_email` varchar(100) NOT NULL default '',
123
- `user_url` varchar(100) NOT NULL default '',
124
- `user_registered` datetime NOT NULL default '0000-00-00 00:00:00',
125
- `user_status` int(11) NOT NULL default 0,
126
- `display_name` varchar(250) NOT NULL default '',
127
- PRIMARY KEY (`ID`),
128
- UNIQUE KEY `user_login` (`user_login`),
129
- UNIQUE KEY `user_nicename` (`user_nicename`),
130
- KEY `user_registered` (`user_registered`)
131
- );";
132
-
133
- // usermeta
134
- $bb_queries['usermeta'] = "CREATE TABLE IF NOT EXISTS `$bbdb->usermeta` (
135
- `umeta_id` bigint(20) NOT NULL auto_increment,
136
- `user_id` bigint(20) NOT NULL default 0,
137
- `meta_key` varchar(255),
138
- `meta_value` longtext,
139
- PRIMARY KEY (`umeta_id`),
140
- KEY `user_id` (`user_id`),
141
- KEY `meta_key` (`meta_key`)
142
- );";
 
 
 
 
143
 
144
  $bb_queries = apply_filters( 'bb_schema_pre_charset', $bb_queries );
145
 
@@ -212,6 +216,18 @@ if ( bb_get_option('wp_table_prefix') || ( defined( 'BB_SCHEMA_IGNORE_WP_USERS_K
212
  $bb_schema_ignore = false;
213
  }
214
 
 
 
 
 
 
 
 
 
 
 
 
 
215
  $bb_schema_ignore = apply_filters( 'bb_schema_ignore', $bb_schema_ignore );
216
 
217
  do_action( 'bb_schema_defined' );
113
  KEY `stickies` (`topic_status`, `topic_sticky`, `topic_time`)
114
  );";
115
 
116
+ if ( bb_get_option( 'wp_table_prefix' ) || ( defined( 'BB_SCHEMA_IGNORE_WP_USERS_TABLES' ) && BB_SCHEMA_IGNORE_WP_USERS_TABLES ) ) {
117
+ // Don't add user tables
118
+ } else {
119
+ // users - 'user_login', 'user_nicename' and 'user_registered' indices are inconsistent with WordPress
120
+ $bb_queries['users'] = "CREATE TABLE IF NOT EXISTS `$bbdb->users` (
121
+ `ID` bigint(20) unsigned NOT NULL auto_increment,
122
+ `user_login` varchar(60) NOT NULL default '',
123
+ `user_pass` varchar(64) NOT NULL default '',
124
+ `user_nicename` varchar(50) NOT NULL default '',
125
+ `user_email` varchar(100) NOT NULL default '',
126
+ `user_url` varchar(100) NOT NULL default '',
127
+ `user_registered` datetime NOT NULL default '0000-00-00 00:00:00',
128
+ `user_status` int(11) NOT NULL default 0,
129
+ `display_name` varchar(250) NOT NULL default '',
130
+ PRIMARY KEY (`ID`),
131
+ UNIQUE KEY `user_login` (`user_login`),
132
+ UNIQUE KEY `user_nicename` (`user_nicename`),
133
+ KEY `user_registered` (`user_registered`)
134
+ );";
135
+
136
+ // usermeta
137
+ $bb_queries['usermeta'] = "CREATE TABLE IF NOT EXISTS `$bbdb->usermeta` (
138
+ `umeta_id` bigint(20) NOT NULL auto_increment,
139
+ `user_id` bigint(20) NOT NULL default 0,
140
+ `meta_key` varchar(255),
141
+ `meta_value` longtext,
142
+ PRIMARY KEY (`umeta_id`),
143
+ KEY `user_id` (`user_id`),
144
+ KEY `meta_key` (`meta_key`)
145
+ );";
146
+ }
147
 
148
  $bb_queries = apply_filters( 'bb_schema_pre_charset', $bb_queries );
149
 
216
  $bb_schema_ignore = false;
217
  }
218
 
219
+ if ( bb_get_option('wp_table_prefix') || ( defined( 'BB_SCHEMA_IGNORE_WP_USERS_TABLES' ) && BB_SCHEMA_IGNORE_WP_USERS_TABLES ) ) {
220
+ if ( $bb_schema_ignore ) {
221
+ $bb_schema_ignore['tables'] = array( $bbdb->users, $bbdb->usermeta );
222
+ } else {
223
+ $bb_schema_ignore = array(
224
+ 'tables' => array( $bbdb->users, $bbdb->usermeta ),
225
+ 'columns' => array(),
226
+ 'indices' => array()
227
+ );
228
+ }
229
+ }
230
+
231
  $bb_schema_ignore = apply_filters( 'bb_schema_ignore', $bb_schema_ignore );
232
 
233
  do_action( 'bb_schema_defined' );
bp-forums/bbpress/bb-admin/includes/functions.bb-admin.php CHANGED
@@ -117,6 +117,10 @@ function bb_admin_menu_generator()
117
  function bb_admin_add_menu( $display_name, $capability, $file_name, $menu_position = false, $class = '', $id = '' )
118
  {
119
  global $bb_menu;
 
 
 
 
120
 
121
  if ( $display_name && $capability && $file_name ) {
122
  // Get an array of the keys
@@ -164,6 +168,10 @@ function bb_admin_add_menu( $display_name, $capability, $file_name, $menu_positi
164
  $plugin_menu_next++;
165
  }
166
 
 
 
 
 
167
  // Add the menu item at the given key
168
  $bb_menu[$plugin_menu_next] = array( $display_name, $capability, $file_name, $class, $id );
169
 
@@ -178,7 +186,15 @@ function bb_admin_add_menu( $display_name, $capability, $file_name, $menu_positi
178
  function bb_admin_add_submenu( $display_name, $capability, $file_name, $parent = 'plugins.php' )
179
  {
180
  global $bb_submenu;
 
 
 
 
 
181
  if ( $display_name && $capability && $file_name ) {
 
 
 
182
  $bb_submenu[$parent][] = array( $display_name, $capability, $file_name );
183
  ksort( $bb_submenu );
184
  }
@@ -397,10 +413,13 @@ function bb_get_ids_by_role( $role = 'moderator', $sort = 0, $page = 1, $limit =
397
 
398
  function bb_user_row( $user, $role = '', $email = false ) {
399
  $actions = "<a href='" . esc_attr( get_user_profile_link( $user->ID ) ) . "'>" . __('View') . "</a>";
400
- if ( bb_current_user_can( 'edit_user', $user_id ) )
 
401
  $actions .= " | <a href='" . esc_attr( get_profile_tab_link( $user->ID, 'edit' ) ) . "'>" . __('Edit') . "</a>";
 
 
402
  $r = "\t<tr id='user-$user->ID'" . get_alt_class("user-$role") . ">\n";
403
- $r .= "\t\t<td class=\"user\">" . bb_get_avatar( $user->ID, 32 ) . "<span class=\"row-title\"><a href='" . get_user_profile_link( $user->ID ) . "'>" . get_user_name( $user->ID ) . "</a></span><div><span class=\"row-actions\">$actions</span>&nbsp;</div></td>\n";
404
  $r .= "\t\t<td><a href='" . get_user_profile_link( $user->ID ) . "'>" . get_user_display_name( $user->ID ) . "</a></td>\n";
405
  if ( $email ) {
406
  $email = bb_get_user_email( $user->ID );
117
  function bb_admin_add_menu( $display_name, $capability, $file_name, $menu_position = false, $class = '', $id = '' )
118
  {
119
  global $bb_menu;
120
+ global $bb_registered_plugin_callbacks;
121
+ if ( empty( $bb_registered_plugin_callbacks ) ) {
122
+ $bb_registered_plugin_callbacks = array();
123
+ }
124
 
125
  if ( $display_name && $capability && $file_name ) {
126
  // Get an array of the keys
168
  $plugin_menu_next++;
169
  }
170
 
171
+ if ( strpos( $file_name, '.php' ) === false ) {
172
+ $bb_registered_plugin_callbacks[] = $file_name;
173
+ }
174
+
175
  // Add the menu item at the given key
176
  $bb_menu[$plugin_menu_next] = array( $display_name, $capability, $file_name, $class, $id );
177
 
186
  function bb_admin_add_submenu( $display_name, $capability, $file_name, $parent = 'plugins.php' )
187
  {
188
  global $bb_submenu;
189
+ global $bb_registered_plugin_callbacks;
190
+ if ( empty( $bb_registered_plugin_callbacks ) ) {
191
+ $bb_registered_plugin_callbacks = array();
192
+ }
193
+
194
  if ( $display_name && $capability && $file_name ) {
195
+ if ( strpos( $file_name, '.php' ) === false ) {
196
+ $bb_registered_plugin_callbacks[] = $file_name;
197
+ }
198
  $bb_submenu[$parent][] = array( $display_name, $capability, $file_name );
199
  ksort( $bb_submenu );
200
  }
413
 
414
  function bb_user_row( $user, $role = '', $email = false ) {
415
  $actions = "<a href='" . esc_attr( get_user_profile_link( $user->ID ) ) . "'>" . __('View') . "</a>";
416
+ $title = '';
417
+ if ( bb_current_user_can( 'edit_user', $user_id ) ) {
418
  $actions .= " | <a href='" . esc_attr( get_profile_tab_link( $user->ID, 'edit' ) ) . "'>" . __('Edit') . "</a>";
419
+ $title = " title='" . esc_attr( sprintf( __( 'User ID: %d' ), $user->ID ) ) . "'";
420
+ }
421
  $r = "\t<tr id='user-$user->ID'" . get_alt_class("user-$role") . ">\n";
422
+ $r .= "\t\t<td class=\"user\">" . bb_get_avatar( $user->ID, 32 ) . "<span class=\"row-title\"><a href='" . get_user_profile_link( $user->ID ) . "'" . $title . ">" . get_user_name( $user->ID ) . "</a></span><div><span class=\"row-actions\">$actions</span>&nbsp;</div></td>\n";
423
  $r .= "\t\t<td><a href='" . get_user_profile_link( $user->ID ) . "'>" . get_user_display_name( $user->ID ) . "</a></td>\n";
424
  if ( $email ) {
425
  $email = bb_get_user_email( $user->ID );
bp-forums/bbpress/bb-admin/includes/functions.bb-recount.php ADDED
@@ -0,0 +1,262 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ function bb_recount_topic_posts()
4
+ {
5
+ global $bbdb;
6
+
7
+ $statement = __( 'Counting the number of posts in each topic&hellip; %s' );
8
+ $result = __( 'Failed!' );
9
+
10
+ $sql = "INSERT INTO `$bbdb->topics` (`topic_id`, `topic_posts`) (SELECT `topic_id`, COUNT(`post_status`) as `topic_posts` FROM `$bbdb->posts` WHERE `post_status` = '0' GROUP BY `topic_id`) ON DUPLICATE KEY UPDATE `topic_posts` = VALUES(`topic_posts`);";
11
+ if ( is_wp_error( $bbdb->query( $sql ) ) ) {
12
+ return sprintf( $statement, $result );
13
+ }
14
+
15
+ $result = __( 'Complete!' );
16
+ return sprintf( $statement, $result );
17
+ }
18
+
19
+ function bb_recount_topic_voices()
20
+ {
21
+ global $bbdb;
22
+
23
+ $statement = __( 'Counting the number of voices in each topic&hellip; %s' );
24
+ $result = __( 'Failed!' );
25
+
26
+ $sql_delete = "DELETE FROM `$bbdb->meta` WHERE `object_type` = 'bb_topic' AND `meta_key` = 'voices_count';";
27
+ if ( is_wp_error( $bbdb->query( $sql_delete ) ) ) {
28
+ return sprintf( $statement, $result );
29
+ }
30
+
31
+ $sql = "INSERT INTO `$bbdb->meta` (`object_type`, `object_id`, `meta_key`, `meta_value`) (SELECT 'bb_topic', `topic_id`, 'voices_count', COUNT(DISTINCT `poster_id`) as `meta_value` FROM `$bbdb->posts` WHERE `post_status` = '0' GROUP BY `topic_id`);";
32
+ if ( is_wp_error( $bbdb->query( $sql ) ) ) {
33
+ return sprintf( $statement, $result );
34
+ }
35
+
36
+ $result = __( 'Complete!' );
37
+ return sprintf( $statement, $result );
38
+ }
39
+
40
+ function bb_recount_topic_deleted_posts()
41
+ {
42
+ global $bbdb;
43
+
44
+ $statement = __( 'Counting the number of deleted posts in each topic&hellip; %s' );
45
+ $result = __( 'Failed!' );
46
+
47
+ $sql_delete = "DELETE FROM `$bbdb->meta` WHERE `object_type` = 'bb_topic' AND `meta_key` = 'deleted_posts';";
48
+ if ( is_wp_error( $bbdb->query( $sql_delete ) ) ) {
49
+ return sprintf( $statement, $result );
50
+ }
51
+
52
+ $sql = "INSERT INTO `$bbdb->meta` (`object_type`, `object_id`, `meta_key`, `meta_value`) (SELECT 'bb_topic', `topic_id`, 'deleted_posts', COUNT(`post_status`) as `meta_value` FROM `$bbdb->posts` WHERE `post_status` != '0' GROUP BY `topic_id`);";
53
+ if ( is_wp_error( $bbdb->query( $sql ) ) ) {
54
+ return sprintf( $statement, $result );
55
+ }
56
+
57
+ $result = __( 'Complete!' );
58
+ return sprintf( $statement, $result );
59
+ }
60
+
61
+ function bb_recount_forum_topics()
62
+ {
63
+ global $bbdb;
64
+
65
+ $statement = __( 'Counting the number of topics in each forum&hellip; %s' );
66
+ $result = __( 'Failed!' );
67
+
68
+ $sql = "INSERT INTO `$bbdb->forums` (`forum_id`, `topics`) (SELECT `forum_id`, COUNT(`topic_status`) as `topics` FROM `$bbdb->topics` WHERE `topic_status` = '0' GROUP BY `forum_id`) ON DUPLICATE KEY UPDATE `topics` = VALUES(`topics`);";
69
+ if ( is_wp_error( $bbdb->query( $sql ) ) ) {
70
+ return sprintf( $statement, $result );
71
+ }
72
+
73
+ $result = __( 'Complete!' );
74
+ return sprintf( $statement, $result );
75
+ }
76
+
77
+ function bb_recount_forum_posts()
78
+ {
79
+ global $bbdb;
80
+
81
+ $statement = __( 'Counting the number of posts in each forum&hellip; %s' );
82
+ $result = __( 'Failed!' );
83
+
84
+ $sql = "INSERT INTO `$bbdb->forums` (`forum_id`, `posts`) (SELECT `forum_id`, COUNT(`post_status`) as `posts` FROM `$bbdb->posts` WHERE `post_status` = '0' GROUP BY `forum_id`) ON DUPLICATE KEY UPDATE `posts` = VALUES(`posts`);";
85
+ if ( is_wp_error( $bbdb->query( $sql ) ) ) {
86
+ return sprintf( $statement, $result );
87
+ }
88
+
89
+ $result = __( 'Complete!' );
90
+ return sprintf( $statement, $result );
91
+ }
92
+
93
+ function bb_recount_user_topics_replied()
94
+ {
95
+ global $bbdb;
96
+
97
+ $statement = __( 'Counting the number of topics to which each user has replied&hellip; %s' );
98
+ $result = __( 'Failed!' );
99
+
100
+ $sql_select = "SELECT `poster_id`, COUNT(DISTINCT `topic_id`) as `_count` FROM `$bbdb->posts` WHERE `post_status` = '0' GROUP BY `poster_id`;";
101
+ $insert_rows = $bbdb->get_results( $sql_select );
102
+
103
+ if ( is_wp_error( $insert_rows ) ) {
104
+ return sprintf( $statement, $result );
105
+ }
106
+
107
+ $meta_key = $bbdb->prefix . 'topics_replied';
108
+
109
+ $insert_values = array();
110
+ foreach ( $insert_rows as $insert_row ) {
111
+ $insert_values[] = "('$insert_row->poster_id', '$meta_key', '$insert_row->_count')";
112
+ }
113
+
114
+ if ( !count( $insert_values ) ) {
115
+ return sprintf( $statement, $result );
116
+ }
117
+
118
+ $sql_delete = "DELETE FROM `$bbdb->usermeta` WHERE `meta_key` = '$meta_key';";
119
+ if ( is_wp_error( $bbdb->query( $sql_delete ) ) ) {
120
+ return sprintf( $statement, $result );
121
+ }
122
+
123
+ $insert_values = array_chunk( $insert_values, 10000 );
124
+ foreach ( $insert_values as $chunk ) {
125
+ $chunk = "\n" . join( ",\n", $chunk );
126
+ $sql_insert = "INSERT INTO `$bbdb->usermeta` (`user_id`, `meta_key`, `meta_value`) VALUES $chunk;";
127
+
128
+ if ( is_wp_error( $bbdb->query( $sql_insert ) ) ) {
129
+ return sprintf( $statement, $result );
130
+ }
131
+ }
132
+
133
+ $result = __( 'Complete!' );
134
+ return sprintf( $statement, $result );
135
+ }
136
+
137
+ // TODO - make fast - see #1146
138
+ function bb_recount_topic_tags()
139
+ {
140
+ // Reset tag count to zero
141
+ $bbdb->query( "UPDATE $bbdb->topics SET tag_count = 0" );
142
+
143
+ // Get all tags
144
+ $terms = $wp_taxonomy_object->get_terms( 'bb_topic_tag' );
145
+
146
+ if ( !is_wp_error( $terms ) && is_array( $terms ) ) {
147
+ $message = __('Counted topic tags');
148
+ foreach ( $terms as $term ) {
149
+ $topic_ids = bb_get_tagged_topic_ids( $term->term_id );
150
+ if ( !is_wp_error( $topic_ids ) && is_array( $topic_ids ) ) {
151
+ $bbdb->query(
152
+ "UPDATE $bbdb->topics SET tag_count = tag_count + 1 WHERE topic_id IN (" . join( ',', $topic_ids ) . ")"
153
+ );
154
+ }
155
+ unset( $topic_ids );
156
+ }
157
+ }
158
+ unset( $terms, $term );
159
+
160
+ return $message;
161
+ }
162
+
163
+ // TODO - make fast - see #1146
164
+ function bb_recount_tag_topics()
165
+ {
166
+ // Get all tags
167
+ $terms = $wp_taxonomy_object->get_terms( 'bb_topic_tag', array( 'hide_empty' => false ) );
168
+
169
+ if ( !is_wp_error( $terms ) && is_array( $terms ) ) {
170
+ $message = __('Counted tagged topics');
171
+ $_terms = array();
172
+ foreach ( $terms as $term ) {
173
+ $_terms[] = $term->term_id;
174
+ }
175
+ if ( count( $_terms ) ) {
176
+ $wp_taxonomy_object->update_term_count( $_terms, 'bb_topic_tag' );
177
+ }
178
+ }
179
+ unset( $term, $_terms );
180
+
181
+ return $message;
182
+ }
183
+
184
+ // TODO - make fast - see #1146
185
+ function bb_recount_tag_delete_empty()
186
+ {
187
+ // Get all tags
188
+ if ( !isset( $terms ) ) {
189
+ $terms = $wp_taxonomy_object->get_terms( 'bb_topic_tag', array( 'hide_empty' => false ) );
190
+ }
191
+
192
+ if ( !is_wp_error( $terms ) && is_array( $terms ) ) {
193
+ $message = __('Deleted tags with no topics');
194
+ foreach ( $terms as $term ) {
195
+ $topic_ids = bb_get_tagged_topic_ids( $term->term_id );
196
+ if ( !is_wp_error( $topic_ids ) && is_array( $topic_ids ) ) {
197
+ if ( false === $topic_ids || ( is_array( $topic_ids ) && !count( $topic_ids ) ) ) {
198
+ bb_destroy_tag( $term->term_taxonomy_id );
199
+ }
200
+ }
201
+ unset( $topic_ids );
202
+ }
203
+ }
204
+ unset( $terms, $term );
205
+
206
+ return $message;
207
+ }
208
+
209
+ function bb_recount_clean_favorites()
210
+ {
211
+ global $bbdb;
212
+
213
+ $statement = __( 'Removing deleted topics from user favorites&hellip; %s' );
214
+ $result = __( 'Failed!' );
215
+
216
+ $meta_key = $bbdb->prefix . 'favorites';
217
+
218
+ $users = $bbdb->get_results( "SELECT `user_id`, `meta_value` AS `favorites` FROM `$bbdb->usermeta` WHERE `meta_key` = '$meta_key';" );
219
+ if ( is_wp_error( $users ) ) {
220
+ return sprintf( $statement, $result );
221
+ }
222
+
223
+ $topics = $bbdb->get_col( "SELECT `topic_id` FROM `$bbdb->topics` WHERE `topic_status` = '0';" );
224
+
225
+ if ( is_wp_error( $topics ) ) {
226
+ return sprintf( $statement, $result );
227
+ }
228
+
229
+ $values = array();
230
+ foreach ( $users as $user ) {
231
+ if ( empty( $user->favorites ) || !is_string( $user->favorites ) ) {
232
+ continue;
233
+ }
234
+ $favorites = explode( ',', $user->favorites );
235
+ if ( empty( $favorites ) || !is_array( $favorites ) ) {
236
+ continue;
237
+ }
238
+ $favorites = join( ',', array_intersect( $topics, $favorites ) );
239
+ $values[] = "('$user->user_id', '$meta_key', '$favorites')";
240
+ }
241
+
242
+ if ( !count( $values ) ) {
243
+ return sprintf( $statement, $result );
244
+ }
245
+
246
+ $sql_delete = "DELETE FROM `$bbdb->usermeta` WHERE `meta_key` = '$meta_key';";
247
+ if ( is_wp_error( $bbdb->query( $sql_delete ) ) ) {
248
+ return sprintf( $statement, $result );
249
+ }
250
+
251
+ $values = array_chunk( $values, 10000 );
252
+ foreach ( $values as $chunk ) {
253
+ $chunk = "\n" . join( ",\n", $chunk );
254
+ $sql_insert = "INSERT INTO `$bbdb->usermeta` (`user_id`, `meta_key`, `meta_value`) VALUES $chunk;";
255
+ if ( is_wp_error( $bbdb->query( $sql_insert ) ) ) {
256
+ return sprintf( $statement, $result );
257
+ }
258
+ }
259
+
260
+ $result = __( 'Complete!' );
261
+ return sprintf( $statement, $result );
262
+ }
bp-forums/bbpress/bb-admin/includes/functions.bb-upgrade.php CHANGED
@@ -9,16 +9,25 @@ function bb_install() {
9
  return array_filter($alterations);
10
  }
11
 
12
- function bb_upgrade_all() {
13
- if ( !ini_get('safe_mode') )
 
14
  set_time_limit(600);
 
 
 
 
 
 
15
 
16
  $bb_upgrade = array();
17
 
18
  // Pre DB Delta
19
- $bb_upgrade['messages'][] = bb_upgrade_160(); // Break blocked users
20
- $bb_upgrade['messages'][] = bb_upgrade_170(); // Escaping in usermeta
21
- $bb_upgrade['messages'][] = bb_upgrade_180(); // Delete users for real
 
 
22
  $bb_upgrade['messages'][] = bb_upgrade_190(); // Move topic_resolved to topicmeta
23
  $bb_upgrade['messages'][] = bb_upgrade_200(); // Indices
24
  $bb_upgrade['messages'][] = bb_upgrade_210(); // Convert text slugs to varchar slugs
@@ -37,13 +46,17 @@ function bb_upgrade_all() {
37
  // Post DB Delta
38
  $bb_upgrade['messages'][] = bb_upgrade_1000(); // Make forum and topic slugs
39
  $bb_upgrade['messages'][] = bb_upgrade_1010(); // Make sure all forums have a valid parent
40
- $bb_upgrade['messages'][] = bb_upgrade_1020(); // Add a user_nicename to existing users
 
 
41
  $bb_upgrade['messages'][] = bb_upgrade_1030(); // Move admin_email option to from_email
42
  $bb_upgrade['messages'][] = bb_upgrade_1040(); // Activate Akismet and bozo plugins and convert active plugins to new convention on upgrade only
43
  $bb_upgrade['messages'][] = bb_upgrade_1050(); // Update active theme if present
44
  $bb_upgrade['messages'][] = bb_upgrade_1070(); // trim whitespace from raw_tag
45
  $bb_upgrade['messages'][] = bb_upgrade_1080(); // Convert tags to taxonomy
46
- $bb_upgrade['messages'][] = bb_upgrade_1090(); // Add display names
 
 
47
  $bb_upgrade['messages'][] = bb_upgrade_1100(); // Replace forum_stickies index with stickies (#876)
48
  $bb_upgrade['messages'][] = bb_upgrade_1110(); // Create plugin directory (#1083)
49
  $bb_upgrade['messages'][] = bb_upgrade_1120(); // Create theme directory (#1083)
9
  return array_filter($alterations);
10
  }
11
 
12
+ function bb_upgrade_all()
13
+ {
14
+ if ( !ini_get( 'safe_mode' ) ) {
15
  set_time_limit(600);
16
+ }
17
+
18
+ $_do_user_operations = true;
19
+ if ( bb_get_option( 'wp_table_prefix' ) || ( defined( 'BB_SCHEMA_IGNORE_WP_USERS_TABLES' ) && BB_SCHEMA_IGNORE_WP_USERS_TABLES ) ) {
20
+ $_do_user_operations = false;
21
+ }
22
 
23
  $bb_upgrade = array();
24
 
25
  // Pre DB Delta
26
+ if ( $_do_user_operations ) {
27
+ $bb_upgrade['messages'][] = bb_upgrade_160(); // Break blocked users
28
+ $bb_upgrade['messages'][] = bb_upgrade_170(); // Escaping in usermeta
29
+ $bb_upgrade['messages'][] = bb_upgrade_180(); // Delete users for real
30
+ }
31
  $bb_upgrade['messages'][] = bb_upgrade_190(); // Move topic_resolved to topicmeta
32
  $bb_upgrade['messages'][] = bb_upgrade_200(); // Indices
33
  $bb_upgrade['messages'][] = bb_upgrade_210(); // Convert text slugs to varchar slugs
46
  // Post DB Delta
47
  $bb_upgrade['messages'][] = bb_upgrade_1000(); // Make forum and topic slugs
48
  $bb_upgrade['messages'][] = bb_upgrade_1010(); // Make sure all forums have a valid parent
49
+ if ( $_do_user_operations ) {
50
+ $bb_upgrade['messages'][] = bb_upgrade_1020(); // Add a user_nicename to existing users
51
+ }
52
  $bb_upgrade['messages'][] = bb_upgrade_1030(); // Move admin_email option to from_email
53
  $bb_upgrade['messages'][] = bb_upgrade_1040(); // Activate Akismet and bozo plugins and convert active plugins to new convention on upgrade only
54
  $bb_upgrade['messages'][] = bb_upgrade_1050(); // Update active theme if present
55
  $bb_upgrade['messages'][] = bb_upgrade_1070(); // trim whitespace from raw_tag
56
  $bb_upgrade['messages'][] = bb_upgrade_1080(); // Convert tags to taxonomy
57
+ if ( $_do_user_operations ) {
58
+ $bb_upgrade['messages'][] = bb_upgrade_1090(); // Add display names
59
+ }
60
  $bb_upgrade['messages'][] = bb_upgrade_1100(); // Replace forum_stickies index with stickies (#876)
61
  $bb_upgrade['messages'][] = bb_upgrade_1110(); // Create plugin directory (#1083)
62
  $bb_upgrade['messages'][] = bb_upgrade_1120(); // Create theme directory (#1083)
bp-forums/bbpress/bb-admin/index.php CHANGED
@@ -29,6 +29,14 @@ $rn_users_average = sprintf(__ngettext('<span>%d</span> user', '<span>%d</span>
29
  $rn_topic_tags_average = bb_get_topic_tags_per_day();
30
  $rn_topic_tags_average = sprintf(__ngettext('<span>%d</span> tag', '<span>%d</span> tags', $rn_topic_tags_average), $rn_topic_tags_average);
31
 
 
 
 
 
 
 
 
 
32
  $bb_admin_body_class = ' bb-admin-dashboard';
33
 
34
  bb_get_admin_header();
@@ -48,28 +56,24 @@ bb_get_admin_header();
48
  <th><?php _e( 'Per Day' ); ?></th>
49
  </tr>
50
  </thead>
 
 
 
51
  <tbody>
 
 
 
52
  <tr>
53
- <td><?php echo $rn_forums; ?></td>
54
- <td>-</td>
55
- </tr>
56
- <tr>
57
- <td><?php echo $rn_topics; ?></td>
58
- <td><?php echo $rn_topics_average; ?></td>
59
- </tr>
60
- <tr>
61
- <td><?php echo $rn_posts; ?></td>
62
- <td><?php echo $rn_posts_average; ?></td>
63
- </tr>
64
- <tr>
65
- <td><?php echo $rn_topic_tags; ?></td>
66
- <td><?php echo $rn_topic_tags_average; ?></td>
67
- </tr>
68
- <tr>
69
- <td><?php echo $rn_users; ?></td>
70
- <td><?php echo $rn_users_average; ?></td>
71
  </tr>
 
 
 
72
  </tbody>
 
 
 
73
  </table>
74
  </div>
75
 
29
  $rn_topic_tags_average = bb_get_topic_tags_per_day();
30
  $rn_topic_tags_average = sprintf(__ngettext('<span>%d</span> tag', '<span>%d</span> tags', $rn_topic_tags_average), $rn_topic_tags_average);
31
 
32
+ $rn = apply_filters( 'bb_admin_right_now', array(
33
+ 'forums' => array( $rn_forums, '-' ),
34
+ 'topics' => array( $rn_topics, $rn_topics_average ),
35
+ 'posts' => array( $rn_posts, $rn_posts_average ),
36
+ 'topic_tags' => array( $rn_topic_tags, $rn_topic_tags_average ),
37
+ 'users' => array( $rn_users, $rn_users_average )
38
+ ) );
39
+
40
  $bb_admin_body_class = ' bb-admin-dashboard';
41
 
42
  bb_get_admin_header();
56
  <th><?php _e( 'Per Day' ); ?></th>
57
  </tr>
58
  </thead>
59
+ <?php
60
+ if ( !empty( $rn ) && is_array( $rn ) ) {
61
+ ?>
62
  <tbody>
63
+ <?php
64
+ foreach ( $rn as $rn_row ) {
65
+ ?>
66
  <tr>
67
+ <td><?php echo $rn_row[0]; ?></td>
68
+ <td><?php echo $rn_row[1]; ?></td>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
69
  </tr>
70
+ <?php
71
+ }
72
+ ?>
73
  </tbody>
74
+ <?php
75
+ }
76
+ ?>
77
  </table>
78
  </div>
79
 
bp-forums/bbpress/bb-admin/options-permalinks.php CHANGED
@@ -1,188 +1,188 @@
1
- <?php
2
-
3
- require_once('admin.php');
4
-
5
- $file_source = BB_PATH . 'bb-admin/includes/defaults.bb-htaccess.php';
6
- $file_target = BB_PATH . '.htaccess';
7
- include( $file_source );
8
- $file_source_rules = $_rules; // This is a string
9
-
10
- if ( 'post' == strtolower( $_SERVER['REQUEST_METHOD'] ) && $_POST['action'] == 'update') {
11
-
12
- bb_check_admin_referer( 'options-permalinks-update' );
13
-
14
- foreach ( (array) $_POST as $option => $value ) {
15
- if ( !in_array( $option, array('_wpnonce', '_wp_http_referer', 'action', 'submit') ) ) {
16
- $option = trim( $option );
17
- $value = is_array( $value ) ? $value : trim( $value );
18
- $value = stripslashes_deep( $value );
19
- if ( $value ) {
20
- bb_update_option( $option, $value );
21
- } else {
22
- bb_delete_option( $option );
23
- }
24
- }
25
- }
26
-
27
- $mod_rewrite = (string) bb_get_option( 'mod_rewrite' );
28
-
29
- $goback = remove_query_arg( array( 'updated', 'notapache', 'notmodrewrite' ), wp_get_referer() );
30
-
31
- // Make sure mod_rewrite is possible on the server
32
- if ( !$is_apache ) {
33
- bb_delete_option( 'mod_rewrite_writable' );
34
- $goback = add_query_arg( 'notapache', 'true', $goback );
35
- bb_safe_redirect( $goback );
36
- exit;
37
- } elseif ( '0' !== $mod_rewrite && !apache_mod_loaded( 'mod_rewrite', true ) ) {
38
- bb_delete_option( 'mod_rewrite_writable' );
39
- bb_update_option( 'mod_rewrite', '0' );
40
- $goback = add_query_arg( 'notmodrewrite', 'true', $goback );
41
- bb_safe_redirect( $goback );
42
- exit;
43
- }
44
-
45
- $file_target_rules = array();
46
-
47
- $file_target_exists = false;
48
- $file_target_writable = true;
49
- if ( file_exists( $file_target ) ) {
50
- if ( is_readable( $file_target ) ) {
51
- $file_target_rules = explode( "\n", implode( '', file( $file_target ) ) );
52
- }
53
- $file_target_exists = true;
54
- if ( !is_writable( $file_target ) ) {
55
- $file_target_writable = false;
56
- }
57
- } else {
58
- $file_target_dir = dirname( $file_target );
59
- if ( file_exists( $file_target_dir ) ) {
60
- if ( !is_writable( $file_target_dir ) || !is_dir( $file_target_dir ) ) {
61
- $file_target_writable = false;
62
- }
63
- } else {
64
- $file_target_writable = false;
65
- }
66
- }
67
-
68
- // Strip out existing bbPress rules
69
- $_keep_rule = true;
70
- $_kept_rules = array();
71
- foreach ( $file_target_rules as $_rule ) {
72
- if ( false !== strpos( $_rule, '# BEGIN bbPress' ) ) {
73
- $_keep_rule = false;
74
- continue;
75
- } elseif ( false !== strpos( $_rule, '# END bbPress' ) ) {
76
- $_keep_rule = true;
77
- continue;
78
- }
79
- if ( $_keep_rule ) {
80
- $_kept_rules[] = $_rule;
81
- }
82
- }
83
-
84
- $file_target_rules = join( "\n", $_kept_rules ) . "\n" . $file_source_rules;
85
-
86
- $file_target_written = 0;
87
- if ( $file_target_writable ) {
88
- // Open the file for writing - rewrites the whole file
89
- if ( $file_target_handle = fopen( $file_target, 'w' ) ) {
90
- if ( fwrite( $file_target_handle, $file_target_rules ) ) {
91
- $file_target_written = 1;
92
- }
93
- // Close the file
94
- fclose( $file_target_handle );
95
- @chmod( $file_target, 0666 );
96
- }
97
- }
98
-
99
- bb_update_option( 'mod_rewrite_writable', $file_target_writable );
100
- $goback = add_query_arg( 'updated', 'true', $goback );
101
- bb_safe_redirect( $goback );
102
- exit;
103
- }
104
-
105
- if ( $is_apache && bb_get_option( 'mod_rewrite' ) && !bb_get_option( 'mod_rewrite_writable' ) ) {
106
- $manual_instructions = true;
107
- }
108
-
109
- if ( !empty( $_GET['notmodrewrite'] ) ) {
110
- $manual_instructions = false;
111
- bb_admin_notice( __( '<strong>It appears that your server does not support custom permalink structures.</strong>' ), 'error' );
112
- }
113
-
114
- if ( !empty( $_GET['notapache'] ) ) {
115
- $manual_instructions = false;
116
- bb_admin_notice( __( '<strong>Rewriting on webservers other than Apache using mod_rewrite is currently unsupported, but we won&#8217;t stop you from trying.</strong>' ), 'error' );
117
- }
118
-
119
- if ( !empty( $_GET['updated'] ) ) {
120
- if ( $manual_instructions ) {
121
- bb_admin_notice( __( '<strong>You should update your .htaccess now.</strong>' ) );
122
- } else {
123
- bb_admin_notice( __( '<strong>Permalink structure updated.</strong>' ) );
124
- }
125
- }
126
-
127
- $permalink_options = array(
128
- 'mod_rewrite' => array(
129
- 'title' => __( 'Permalink type' ),
130
- 'type' => 'radio',
131
- 'options' => array(
132
- '0' => sprintf( __( '<span>None</span> <code>%s</code>' ), bb_get_uri( 'forums.php', array( 'id' => 1 ), BB_URI_CONTEXT_TEXT ) ),
133
- '1' => sprintf( __( '<span>Numeric</span> <code>%s</code>' ), bb_get_uri( 'forums/1', null, BB_URI_CONTEXT_TEXT ) ),
134
- 'slugs' => sprintf( __( '<span>Name based</span> <code>%s</code>' ), bb_get_uri( '/forums/first-forum', null, BB_URI_CONTEXT_TEXT ) )
135
- )
136
- )
137
- );
138
-
139
- $bb_admin_body_class = ' bb-admin-settings';
140
-
141
- bb_get_admin_header();
142
-
143
- ?>
144
-
145
- <div class="wrap">
146
-
147
- <h2><?php _e( 'Permalink Settings' ); ?></h2>
148
- <?php do_action( 'bb_admin_notices' ); ?>
149
-
150
- <form class="settings" method="post" action="<?php bb_uri( 'bb-admin/options-permalinks.php', null, BB_URI_CONTEXT_FORM_ACTION + BB_URI_CONTEXT_BB_ADMIN ); ?>">
151
- <fieldset>
152
- <p>
153
- <?php _e( 'By default bbPress uses web URLs which have question marks and lots of numbers in them, however bbPress offers you the ability to choose an alternative URL structure for your permalinks. This can improve the aesthetics, usability, and forward-compatibility of your links.' ); ?>
154
- </p>
155
- <?php
156
- foreach ( $permalink_options as $option => $args ) {
157
- bb_option_form_element( $option, $args );
158
- }
159
- ?>
160
- </fieldset>
161
- <fieldset class="submit">
162
- <?php bb_nonce_field( 'options-permalinks-update' ); ?>
163
- <input type="hidden" name="action" value="update" />
164
- <input class="submit" type="submit" name="submit" value="<?php _e('Save Changes') ?>" />
165
- </fieldset>
166
- </form>
167
-
168
- <?php
169
- if ( $manual_instructions ) {
170
- ?>
171
- <form class="settings" method="post" action="<?php bb_uri( 'bb-admin/options-permalinks.php', null, BB_URI_CONTEXT_FORM_ACTION + BB_URI_CONTEXT_BB_ADMIN ); ?>">
172
- <fieldset>
173
- <p>
174
- <?php _e( 'If your <code>.htaccess</code> file were <a href="http://codex.wordpress.org/Changing_File_Permissions">writable</a>, we could do this automatically, but it isn&#8217;t so these are the mod_rewrite rules you should have in your <code>.htaccess</code> file. Click in the field and press <kbd>CTRL + a</kbd> to select all.' ); ?>
175
- </p>
176
- <textarea dir="ltr" id="rewrite-rules" class="readonly" readonly="readonly" rows="6"><?php echo esc_html( trim( $file_source_rules ) ); ?></textarea>
177
- </fieldset>
178
- </form>
179
-
180
- <?php
181
- }
182
- ?>
183
-
184
- </div>
185
-
186
- <?php
187
-
188
- bb_get_admin_footer();
1
+ <?php
2
+
3
+ require_once('admin.php');
4
+
5
+ $file_source = BB_PATH . 'bb-admin/includes/defaults.bb-htaccess.php';
6
+ $file_target = BB_PATH . '.htaccess';
7
+ include( $file_source );
8
+ $file_source_rules = $_rules; // This is a string
9
+
10
+ if ( 'post' == strtolower( $_SERVER['REQUEST_METHOD'] ) && $_POST['action'] == 'update') {
11
+
12
+ bb_check_admin_referer( 'options-permalinks-update' );
13
+
14
+ foreach ( (array) $_POST as $option => $value ) {
15
+ if ( !in_array( $option, array('_wpnonce', '_wp_http_referer', 'action', 'submit') ) ) {
16
+ $option = trim( $option );
17
+ $value = is_array( $value ) ? $value : trim( $value );
18
+ $value = stripslashes_deep( $value );
19
+ if ( $value ) {
20
+ bb_update_option( $option, $value );
21
+ } else {
22
+ bb_delete_option( $option );
23
+ }
24
+ }
25
+ }
26
+
27
+ $mod_rewrite = (string) bb_get_option( 'mod_rewrite' );
28
+
29
+ $goback = remove_query_arg( array( 'updated', 'notapache', 'notmodrewrite' ), wp_get_referer() );
30
+
31
+ // Make sure mod_rewrite is possible on the server
32
+ if ( !$is_apache ) {
33
+ bb_delete_option( 'mod_rewrite_writable' );
34
+ $goback = add_query_arg( 'notapache', 'true', $goback );
35
+ bb_safe_redirect( $goback );
36
+ exit;
37
+ } elseif ( '0' !== $mod_rewrite && !apache_mod_loaded( 'mod_rewrite', true ) ) {
38
+ bb_delete_option( 'mod_rewrite_writable' );
39
+ bb_update_option( 'mod_rewrite', '0' );
40
+ $goback = add_query_arg( 'notmodrewrite', 'true', $goback );
41
+ bb_safe_redirect( $goback );
42
+ exit;
43
+ }
44
+
45
+ $file_target_rules = array();
46
+
47
+ $file_target_exists = false;
48
+ $file_target_writable = true;
49
+ if ( file_exists( $file_target ) ) {
50
+ if ( is_readable( $file_target ) ) {
51
+ $file_target_rules = explode( "\n", implode( '', file( $file_target ) ) );
52
+ }
53
+ $file_target_exists = true;
54
+ if ( !is_writable( $file_target ) ) {
55
+ $file_target_writable = false;
56
+ }
57
+ } else {
58
+ $file_target_dir = dirname( $file_target );
59
+ if ( file_exists( $file_target_dir ) ) {
60
+ if ( !is_writable( $file_target_dir ) || !is_dir( $file_target_dir ) ) {
61
+ $file_target_writable = false;
62
+ }
63
+ } else {
64
+ $file_target_writable = false;
65
+ }
66
+ }
67
+
68
+ // Strip out existing bbPress rules
69
+ $_keep_rule = true;
70
+ $_kept_rules = array();
71
+ foreach ( $file_target_rules as $_rule ) {
72
+ if ( false !== strpos( $_rule, '# BEGIN bbPress' ) ) {
73
+ $_keep_rule = false;
74
+ continue;
75
+ } elseif ( false !== strpos( $_rule, '# END bbPress' ) ) {
76
+ $_keep_rule = true;
77
+ continue;
78
+ }
79
+ if ( $_keep_rule ) {
80
+ $_kept_rules[] = $_rule;
81
+ }
82
+ }
83
+
84
+ $file_target_rules = join( "\n", $_kept_rules ) . "\n" . $file_source_rules;
85
+
86
+ $file_target_written = 0;
87
+ if ( $file_target_writable ) {
88
+ // Open the file for writing - rewrites the whole file
89
+ if ( $file_target_handle = fopen( $file_target, 'w' ) ) {
90
+ if ( fwrite( $file_target_handle, $file_target_rules ) ) {
91
+ $file_target_written = 1;
92
+ }
93
+ // Close the file
94
+ fclose( $file_target_handle );
95
+ @chmod( $file_target, 0666 );
96
+ }
97
+ }
98
+
99
+ bb_update_option( 'mod_rewrite_writable', $file_target_writable );
100
+ $goback = add_query_arg( 'updated', 'true', $goback );
101
+ bb_safe_redirect( $goback );
102
+ exit;
103
+ }
104
+
105
+ if ( $is_apache && bb_get_option( 'mod_rewrite' ) && !bb_get_option( 'mod_rewrite_writable' ) ) {
106
+ $manual_instructions = true;
107
+ }
108
+
109
+ if ( !empty( $_GET['notmodrewrite'] ) ) {
110
+ $manual_instructions = false;
111
+ bb_admin_notice( __( '<strong>It appears that your server does not support custom permalink structures.</strong>' ), 'error' );
112
+ }
113
+
114
+ if ( !empty( $_GET['notapache'] ) ) {
115
+ $manual_instructions = false;
116
+ bb_admin_notice( __( '<strong>Rewriting on webservers other than Apache using mod_rewrite is currently unsupported, but we won&#8217;t stop you from trying.</strong>' ), 'error' );
117
+ }
118
+
119
+ if ( !empty( $_GET['updated'] ) ) {
120
+ if ( $manual_instructions ) {
121
+ bb_admin_notice( __( '<strong>You should update your .htaccess now.</strong>' ) );
122
+ } else {
123
+ bb_admin_notice( __( '<strong>Permalink structure updated.</strong>' ) );
124
+ }
125
+ }
126
+
127
+ $permalink_options = array(
128
+ 'mod_rewrite' => array(
129
+ 'title' => __( 'Permalink type' ),
130
+ 'type' => 'radio',
131
+ 'options' => array(
132
+ '0' => sprintf( __( '<span>None</span> <code>%s</code>' ), bb_get_uri( 'forums.php', array( 'id' => 1 ), BB_URI_CONTEXT_TEXT ) ),
133
+ '1' => sprintf( __( '<span>Numeric</span> <code>%s</code>' ), bb_get_uri( 'forums/1', null, BB_URI_CONTEXT_TEXT ) ),
134
+ 'slugs' => sprintf( __( '<span>Name based</span> <code>%s</code>' ), bb_get_uri( '/forums/first-forum', null, BB_URI_CONTEXT_TEXT ) )
135
+ )
136
+ )
137
+ );
138
+
139
+ $bb_admin_body_class = ' bb-admin-settings';
140
+
141
+ bb_get_admin_header();
142
+
143
+ ?>
144
+
145
+ <div class="wrap">
146
+
147
+ <h2><?php _e( 'Permalink Settings' ); ?></h2>
148
+ <?php do_action( 'bb_admin_notices' ); ?>
149
+
150
+ <form class="settings" method="post" action="<?php bb_uri( 'bb-admin/options-permalinks.php', null, BB_URI_CONTEXT_FORM_ACTION + BB_URI_CONTEXT_BB_ADMIN ); ?>">
151
+ <fieldset>
152
+ <p>
153
+ <?php _e( 'By default bbPress uses web URLs which have question marks and lots of numbers in them, however bbPress offers you the ability to choose an alternative URL structure for your permalinks. This can improve the aesthetics, usability, and forward-compatibility of your links.' ); ?>
154
+ </p>
155
+ <?php
156
+ foreach ( $permalink_options as $option => $args ) {
157
+ bb_option_form_element( $option, $args );
158
+ }
159
+ ?>
160
+ </fieldset>
161
+ <fieldset class="submit">
162
+ <?php bb_nonce_field( 'options-permalinks-update' ); ?>
163
+ <input type="hidden" name="action" value="update" />
164
+ <input class="submit" type="submit" name="submit" value="<?php _e('Save Changes') ?>" />
165
+ </fieldset>
166
+ </form>
167
+
168
+ <?php
169
+ if ( $manual_instructions ) {
170
+ ?>
171
+ <form class="settings" method="post" action="<?php bb_uri( 'bb-admin/options-permalinks.php', null, BB_URI_CONTEXT_FORM_ACTION + BB_URI_CONTEXT_BB_ADMIN ); ?>">
172
+ <fieldset>
173
+ <p>
174
+ <?php _e( 'If your <code>.htaccess</code> file were <a href="http://codex.wordpress.org/Changing_File_Permissions">writable</a>, we could do this automatically, but it isn&#8217;t so these are the mod_rewrite rules you should have in your <code>.htaccess</code> file. Click in the field and press <kbd>CTRL + a</kbd> to select all.' ); ?>
175
+ </p>
176
+ <textarea dir="ltr" id="rewrite-rules" class="readonly" readonly="readonly" rows="6"><?php echo esc_html( trim( $file_source_rules ) ); ?></textarea>
177
+ </fieldset>
178
+ </form>
179
+
180
+ <?php
181
+ }
182
+ ?>
183
+
184
+ </div>
185
+
186
+ <?php
187
+
188
+ bb_get_admin_footer();
bp-forums/bbpress/bb-admin/tools-recount.php CHANGED
@@ -1,164 +1,59 @@
1
  <?php
2
- require_once('admin.php');
 
3
 
4
  if ( 'post' == strtolower( $_SERVER['REQUEST_METHOD'] ) ) {
5
  bb_check_admin_referer( 'do-counts' );
6
 
 
7
  $messages = array();
8
- if ( isset($_POST['topic-posts']) && 1 == $_POST['topic-posts'] ) {
9
- if ( $topics = (array) $bbdb->get_results("SELECT topic_id, COUNT(post_id) AS count FROM $bbdb->posts WHERE post_status = '0' GROUP BY topic_id") ) {
10
- $messages[] = __('Counted posts');
11
- foreach ($topics as $topic) {
12
- $topic_id = (int) $topic->topic_id;
13
- $bbdb->query( $bbdb->prepare( "UPDATE $bbdb->topics SET topic_posts = %s WHERE topic_id = %s" ), $topic->count, $topic_id );
14
- }
15
- unset($topics, $topic, $topic_id);
16
- }
17
- }
18
 
19
- if ( isset($_POST['topic-voices']) && 1 == $_POST['topic-voices'] ) {
20
- if ( $topics = (array) $bbdb->get_results("SELECT topic_id FROM $bbdb->topics ORDER BY topic_id") ) {
21
- $messages[] = __('Counted voices');
22
- foreach ($topics as $topic) {
23
- $topic_id = (int) $topic->topic_id;
24
- if ( $voices = $bbdb->get_col( $bbdb->prepare( "SELECT DISTINCT poster_id FROM $bbdb->posts WHERE topic_id = %s AND post_status = '0';", $topic_id ) ) ) {
25
- $voices = count( $voices );
26
- bb_update_topicmeta( $topic_id, 'voices_count', $voices );
27
- }
28
- }
29
- unset($topics, $topic, $topic_id);
30
- }
31
  }
32
 
33
- if ( isset($_POST['topic-deleted-posts']) && 1 == $_POST['topic-deleted-posts'] ) {
34
- $old = (array) $bbdb->get_col("SELECT object_id FROM $bbdb->meta WHERE object_type = 'bb_topics' AND meta_key = 'deleted_posts'");
35
- $old = array_flip($old);
36
- if ( $topics = (array) $bbdb->get_results("SELECT topic_id, COUNT(post_id) AS count FROM $bbdb->posts WHERE post_status != '0' GROUP BY topic_id") ) {
37
- $messages[] = __('Counting deleted posts&#8230;');
38
- foreach ( $topics as $topic ) {
39
- bb_update_topicmeta( $topic->topic_id, 'deleted_posts', $topic->count );
40
- unset($old[$topic->topic_id]);
41
- }
42
- unset($topics, $topic);
43
- }
44
- if ( $old ) {
45
- $old = join(',', array_flip($old));
46
- $bbdb->query("DELETE FROM $bbdb->meta WHERE object_type = 'bb_topic' AND object_id IN ($old) AND meta_key = 'deleted_posts'");
47
- $messages[] = __('&#8230;counted deleted posts');
48
- } else {
49
- $messages[] = __('&#8230;no deleted posts to count');
50
- }
51
  }
52
 
53
- if ( isset($_POST['forums']) && 1 == $_POST['forums'] ) {
54
- if ( $all_forums = (array) $bbdb->get_col("SELECT forum_id FROM $bbdb->forums") ) {
55
- $messages[] = __('Counted forum topics and posts');
56
- $all_forums = array_flip( $all_forums );
57
- $forums = $bbdb->get_results("SELECT forum_id, COUNT(topic_id) AS topic_count, SUM(topic_posts) AS post_count FROM $bbdb->topics WHERE topic_status = 0 GROUP BY forum_id");
58
- foreach ( (array) $forums as $forum ) {
59
- $bbdb->query("UPDATE $bbdb->forums SET topics = '$forum->topic_count', posts = '$forum->post_count' WHERE forum_id = '$forum->forum_id'");
60
- unset($all_forums[$forum->forum_id]);
61
- }
62
- if ( $all_forums ) {
63
- $all_forums = implode(',', array_flip( $all_forums ) );
64
- $bbdb->query("UPDATE $bbdb->forums SET topics = 0, posts = 0 WHERE forum_id IN ($all_forums)");
65
- }
66
- unset($all_forums, $forums, $forum);
67
- }
68
  }
69
 
70
- if ( isset($_POST['topics-replied']) && 1 == $_POST['topics-replied'] ) {
71
- if ( $users = (array) $bbdb->get_col("SELECT ID FROM $bbdb->users") ) {
72
- $messages[] = __('Counted topics to which each user has replied');
73
- foreach ( $users as $user )
74
- bb_update_topics_replied( $user );
75
- unset($users, $user);
76
- }
77
  }
78
 
79
- if ( isset($_POST['topic-tag-count']) && 1 == $_POST['topic-tag-count'] ) {
80
- // Reset tag count to zero
81
- $bbdb->query( "UPDATE $bbdb->topics SET tag_count = 0" );
82
-
83
- // Get all tags
84
- $terms = $wp_taxonomy_object->get_terms( 'bb_topic_tag' );
85
-
86
- if ( !is_wp_error( $terms ) && is_array( $terms ) ) {
87
- $messages[] = __('Counted topic tags');
88
- foreach ( $terms as $term ) {
89
- $topic_ids = bb_get_tagged_topic_ids( $term->term_id );
90
- if ( !is_wp_error( $topic_ids ) && is_array( $topic_ids ) ) {
91
- $bbdb->query(
92
- "UPDATE $bbdb->topics SET tag_count = tag_count + 1 WHERE topic_id IN (" . join( ',', $topic_ids ) . ")"
93
- );
94
- }
95
- unset( $topic_ids );
96
- }
97
- }
98
- unset( $terms, $term );
99
  }
100
 
101
- if ( isset($_POST['tags-tag-count']) && 1 == $_POST['tags-tag-count'] ) {
102
- // Get all tags
103
- $terms = $wp_taxonomy_object->get_terms( 'bb_topic_tag', array( 'hide_empty' => false ) );
104
-
105
- if ( !is_wp_error( $terms ) && is_array( $terms ) ) {
106
- $messages[] = __('Counted tagged topics');
107
- $_terms = array();
108
- foreach ( $terms as $term ) {
109
- $_terms[] = $term->term_id;
110
- }
111
- if ( count( $_terms ) ) {
112
- $wp_taxonomy_object->update_term_count( $_terms, 'bb_topic_tag' );
113
- }
114
- }
115
- unset( $term, $_terms );
116
  }
117
 
118
- if ( isset($_POST['tags-delete-empty']) && 1 == $_POST['tags-delete-empty'] ) {
119
- // Get all tags
120
- if ( !isset( $terms ) ) {
121
- $terms = $wp_taxonomy_object->get_terms( 'bb_topic_tag', array( 'hide_empty' => false ) );
122
- }
123
 
124
- if ( !is_wp_error( $terms ) && is_array( $terms ) ) {
125
- $messages[] = __('Deleted tags with no topics');
126
- foreach ( $terms as $term ) {
127
- $topic_ids = bb_get_tagged_topic_ids( $term->term_id );
128
- if ( !is_wp_error( $topic_ids ) && is_array( $topic_ids ) ) {
129
- if ( false === $topic_ids || ( is_array( $topic_ids ) && !count( $topic_ids ) ) ) {
130
- bb_destroy_tag( $term->term_taxonomy_id );
131
- }
132
- }
133
- unset( $topic_ids );
134
- }
135
- }
136
- unset( $terms, $term );
137
  }
138
 
139
- if ( isset($_POST['clean-favorites']) && 1 == $_POST['clean-favorites'] ) {
140
- $favorites_key = $bbdb->prefix . 'favorites';
141
- if ( $users = $bbdb->get_results("SELECT user_id AS id, meta_value AS favorites FROM $bbdb->usermeta WHERE meta_key = '" . $favorites_key . "'") ) {
142
- $messages[] = __('Removed deleted topics from users\' favorites');
143
- $topics = $bbdb->get_col("SELECT topic_id FROM $bbdb->topics WHERE topic_status = '0'");
144
- foreach ( $users as $user ) {
145
- foreach ( explode(',', $user->favorites) as $favorite ) {
146
- if ( !in_array($favorite, $topics) ) {
147
- bb_remove_user_favorite( $user->id, $favorite );
148
- }
149
- }
150
- }
151
- unset($topics, $users, $user, $favorite);
152
- }
153
  }
154
 
155
  bb_recount_list();
156
  foreach ( (array) $recount_list as $item ) {
157
  if ( isset($item[2]) && isset($_POST[$item[0]]) && 1 == $_POST[$item[0]] && is_callable($item[2]) ) {
158
- call_user_func( $item[2] );
159
  }
160
  }
161
-
 
 
162
  if ( count( $messages ) ) {
163
  $messages = join( '</p>' . "\n" . '<p>', $messages );
164
  bb_admin_notice( $messages );
1
  <?php
2
+ require_once( 'admin.php' );
3
+ require_once( 'includes/functions.bb-recount.php' );
4
 
5
  if ( 'post' == strtolower( $_SERVER['REQUEST_METHOD'] ) ) {
6
  bb_check_admin_referer( 'do-counts' );
7
 
8
+ // Stores messages
9
  $messages = array();
 
 
 
 
 
 
 
 
 
 
10
 
11
+ if ( !empty( $_POST['topic-posts'] ) ) {
12
+ $messages[] = bb_recount_topic_posts();
 
 
 
 
 
 
 
 
 
 
13
  }
14
 
15
+ if ( !empty( $_POST['topic-voices'] ) ) {
16
+ $messages[] = bb_recount_topic_voices();
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
17
  }
18
 
19
+ if ( !empty( $_POST['topic-deleted-posts'] ) ) {
20
+ $messages[] = bb_recount_topic_deleted_posts();
 
 
 
 
 
 
 
 
 
 
 
 
 
21
  }
22
 
23
+ if ( !empty( $_POST['forums'] ) ) {
24
+ $messages[] = bb_recount_forum_topics();
25
+ $messages[] = bb_recount_forum_posts();
 
 
 
 
26
  }
27
 
28
+ if ( !empty( $_POST['topics-replied'] ) ) {
29
+ $messages[] = bb_recount_user_topics_replied();
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
30
  }
31
 
32
+ if ( !empty( $_POST['topic-tag-count'] ) ) {
33
+ $messages[] = bb_recount_topic_tags();
 
 
 
 
 
 
 
 
 
 
 
 
 
34
  }
35
 
36
+ if ( !empty( $_POST['tags-tag-count'] ) ) {
37
+ $messages[] = bb_recount_tag_topics();
38
+ }
 
 
39
 
40
+ if ( !empty( $_POST['tags-delete-empty'] ) ) {
41
+ $messages[] = bb_recount_tag_delete_empty();
 
 
 
 
 
 
 
 
 
 
 
42
  }
43
 
44
+ if ( !empty( $_POST['clean-favorites'] ) ) {
45
+ $messages[] = bb_recount_clean_favorites();
 
 
 
 
 
 
 
 
 
 
 
 
46
  }
47
 
48
  bb_recount_list();
49
  foreach ( (array) $recount_list as $item ) {
50
  if ( isset($item[2]) && isset($_POST[$item[0]]) && 1 == $_POST[$item[0]] && is_callable($item[2]) ) {
51
+ $messages[] = call_user_func( $item[2] );
52
  }
53
  }
54
+
55
+ wp_cache_flush();
56
+
57
  if ( count( $messages ) ) {
58
  $messages = join( '</p>' . "\n" . '<p>', $messages );
59
  bb_admin_notice( $messages );
bp-forums/bbpress/bb-cron.php CHANGED
@@ -11,6 +11,10 @@
11
 
12
  ignore_user_abort( true );
13
 
 
 
 
 
14
  /**
15
  * Tell bbPress we are doing the CRON task.
16
  *
@@ -21,24 +25,19 @@ define( 'DOING_CRON', true );
21
  /** Setup bbPress environment */
22
  require_once( './bb-load.php' );
23
 
24
- if ( $_GET['check'] != backpress_get_option( 'cron_check' ) ) {
25
- exit;
26
- }
27
-
28
- if ( bb_get_option( 'doing_cron' ) > time() ) {
29
- exit;
30
  }
31
 
32
- bb_update_option( 'doing_cron', time() + 30 );
33
-
34
- $crons = _get_cron_array();
35
  $keys = array_keys( $crons );
36
- if ( !is_array( $crons ) || $keys[0] > time() ) {
37
- return;
 
 
38
  }
39
 
40
  foreach ( $crons as $timestamp => $cronhooks ) {
41
- if ( $timestamp > time() ) {
42
  break;
43
  }
44
  foreach ( $cronhooks as $hook => $keys ) {
@@ -53,5 +52,3 @@ foreach ( $crons as $timestamp => $cronhooks ) {
53
  }
54
  }
55
  }
56
-
57
- bb_update_option( 'doing_cron', 0 );
11
 
12
  ignore_user_abort( true );
13
 
14
+ if ( !empty( $_POST ) || defined( 'DOING_AJAX' ) || defined( 'DOING_CRON' ) ) {
15
+ die();
16
+ }
17
+
18
  /**
19
  * Tell bbPress we are doing the CRON task.
20
  *
25
  /** Setup bbPress environment */
26
  require_once( './bb-load.php' );
27
 
28
+ if ( false === $crons = _get_cron_array() ) {
29
+ die();
 
 
 
 
30
  }
31
 
 
 
 
32
  $keys = array_keys( $crons );
33
+ $local_time = time();
34
+
35
+ if ( !is_array( $crons ) || ( isset($keys[0]) && $keys[0] > $local_time ) ) {
36
+ die();
37
  }
38
 
39
  foreach ( $crons as $timestamp => $cronhooks ) {
40
+ if ( $timestamp > $local_time ) {
41
  break;
42
  }
43
  foreach ( $cronhooks as $hook => $keys ) {
52
  }
53
  }
54
  }
 
 
bp-forums/bbpress/bb-includes/backpress/functions.formatting.php CHANGED
@@ -1489,14 +1489,15 @@ if ( !function_exists('clean_url') ) :
1489
  *
1490
  * @param string $url The URL to be cleaned.
1491
  * @param array $protocols Optional. An array of acceptable protocols.
1492
- * Defaults to 'http', 'https', 'ftp', 'ftps', 'mailto', 'news', 'irc', 'gopher', 'nntp', 'feed', 'telnet' if not set.
1493
  * @param string $context Optional. How the URL will be used. Default is 'display'.
1494
  * @return string The cleaned $url after the 'cleaned_url' filter is applied.
1495
  */
1496
  function clean_url( $url, $protocols = null, $context = 'display' ) {
1497
  $original_url = $url;
1498
 
1499
- if ('' == $url) return $url;
 
1500
  $url = preg_replace('|[^a-z0-9-~+_.?#=!&;,/:%@$\|*\'()\\x80-\\xff]|i', '', $url);
1501
  $strip = array('%0d', '%0a', '%0D', '%0A');
1502
  $url = _deep_replace($strip, $url);
@@ -1511,12 +1512,13 @@ function clean_url( $url, $protocols = null, $context = 'display' ) {
1511
 
1512
  // Replace ampersands and single quotes only when displaying.
1513
  if ( 'display' == $context ) {
1514
- $url = preg_replace('/&([^#])(?![a-z]{2,8};)/', '&#038;$1', $url);
 
1515
  $url = str_replace( "'", '&#039;', $url );
1516
  }
1517
 
1518
  if ( !is_array($protocols) )
1519
- $protocols = array('http', 'https', 'ftp', 'ftps', 'mailto', 'news', 'irc', 'gopher', 'nntp', 'feed', 'telnet');
1520
  if ( wp_kses_bad_protocol( $url, $protocols ) != $url )
1521
  return '';
1522
 
1489
  *
1490
  * @param string $url The URL to be cleaned.
1491
  * @param array $protocols Optional. An array of acceptable protocols.
1492
+ * Defaults to 'http', 'https', 'ftp', 'ftps', 'mailto', 'news', 'irc', 'gopher', 'nntp', 'feed', 'telnet', 'mms', 'rtsp', 'svn' if not set.
1493
  * @param string $context Optional. How the URL will be used. Default is 'display'.
1494
  * @return string The cleaned $url after the 'cleaned_url' filter is applied.
1495
  */
1496
  function clean_url( $url, $protocols = null, $context = 'display' ) {
1497
  $original_url = $url;
1498
 
1499
+ if ( '' == $url )
1500
+ return $url;
1501
  $url = preg_replace('|[^a-z0-9-~+_.?#=!&;,/:%@$\|*\'()\\x80-\\xff]|i', '', $url);
1502
  $strip = array('%0d', '%0a', '%0D', '%0A');
1503
  $url = _deep_replace($strip, $url);
1512
 
1513
  // Replace ampersands and single quotes only when displaying.
1514
  if ( 'display' == $context ) {
1515
+ $url = wp_kses_normalize_entities( $url );
1516
+ $url = str_replace( '&amp;', '&#038;', $url );
1517
  $url = str_replace( "'", '&#039;', $url );
1518
  }
1519
 
1520
  if ( !is_array($protocols) )
1521
+ $protocols = array ('http', 'https', 'ftp', 'ftps', 'mailto', 'news', 'irc', 'gopher', 'nntp', 'feed', 'telnet', 'mms', 'rtsp', 'svn');
1522
  if ( wp_kses_bad_protocol( $url, $protocols ) != $url )
1523
  return '';
1524
 
bp-forums/bbpress/bb-includes/backpress/functions.kses.php CHANGED
@@ -1,30 +1,485 @@
1
  <?php
2
- // Last sync [WP11537]
3
 
4
  /**
5
- * HTML/XHTML filter that only allows some elements and attributes
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
6
  *
7
  * Added wp_ prefix to avoid conflicts with existing kses users
8
  *
9
  * @version 0.2.2
10
  * @copyright (C) 2002, 2003, 2005
11
- * @author Ulf Harnhammar <metaur@users.sourceforge.net>
12
  *
13
  * @package External
14
  * @subpackage KSES
15
  *
16
- * @internal
17
- * *** CONTACT INFORMATION ***
18
- * E-mail: metaur at users dot sourceforge dot net
19
- * Web page: http://sourceforge.net/projects/kses
20
- * Paper mail: Ulf Harnhammar
21
- * Ymergatan 17 C
22
- * 753 25 Uppsala
23
- * SWEDEN
24
- *
25
- * [kses strips evil scripts!]
26
  */
27
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
28
 
29
  /**
30
  * Filters content and keeps only allowable HTML elements.
@@ -35,9 +490,9 @@
35
  * call this function.
36
  *
37
  * The default allowed protocols are 'http', 'https', 'ftp', 'mailto', 'news',
38
- * 'irc', 'gopher', 'nntp', 'feed', and finally 'telnet. This covers all common
39
- * link protocols, except for 'javascript' which should not be allowed for
40
- * untrusted users.
41
  *
42
  * @since 1.0.0
43
  *
@@ -46,7 +501,8 @@
46
  * @param array $allowed_protocols Optional. Allowed protocol in links.
47
  * @return string Filtered content with only allowed HTML elements
48
  */
49
- function wp_kses($string, $allowed_html, $allowed_protocols = array ('http', 'https', 'ftp', 'ftps', 'mailto', 'news', 'irc', 'gopher', 'nntp', 'feed', 'telnet')) {
 
50
  $string = wp_kses_no_null($string);
51
  $string = wp_kses_js_entities($string);
52
  $string = wp_kses_normalize_entities($string);
@@ -100,8 +556,18 @@ function wp_kses_split($string, $allowed_html, $allowed_protocols) {
100
  global $pass_allowed_html, $pass_allowed_protocols;
101
  $pass_allowed_html = $allowed_html;
102
  $pass_allowed_protocols = $allowed_protocols;
103
- return preg_replace_callback('%((<!--.*?(-->|$))|(<[^>]*(>|$)|>))%',
104
- create_function('$match', 'global $pass_allowed_html, $pass_allowed_protocols; return wp_kses_split2($match[1], $pass_allowed_html, $pass_allowed_protocols);'), $string);
 
 
 
 
 
 
 
 
 
 
105
  }
106
 
107
  /**
@@ -186,7 +652,7 @@ function wp_kses_attr($element, $attr, $allowed_html, $allowed_protocols) {
186
  # Is there a closing XHTML slash at the end of the attributes?
187
 
188
  $xhtml_slash = '';
189
- if (preg_match('%\s/\s*$%', $attr))
190
  $xhtml_slash = ' /';
191
 
192
  # Are any attributes allowed at all for this element?
@@ -224,6 +690,19 @@ function wp_kses_attr($element, $attr, $allowed_html, $allowed_protocols) {
224
  break;
225
  }
226
 
 
 
 
 
 
 
 
 
 
 
 
 
 
227
  if ($ok)
228
  $attr2 .= ' '.$arreach['whole']; # it passed them
229
  } # if !is_array($current)
@@ -299,11 +778,11 @@ function wp_kses_hair($attr, $allowed_protocols) {
299
 
300
  case 2 : # attribute value, a URL after href= for instance
301
 
302
- if (preg_match('/^"([^"]*)"(\s+|$)/', $attr, $match))
303
  # "value"
304
  {
305
  $thisval = $match[1];
306
- if ( in_array($attrname, $uris) )
307
  $thisval = wp_kses_bad_protocol($thisval, $allowed_protocols);
308
 
309
  if(FALSE === array_key_exists($attrname, $attrarr)) {
@@ -315,11 +794,11 @@ function wp_kses_hair($attr, $allowed_protocols) {
315
  break;
316
  }
317
 
318
- if (preg_match("/^'([^']*)'(\s+|$)/", $attr, $match))
319
  # 'value'
320
  {
321
  $thisval = $match[1];
322
- if ( in_array($attrname, $uris) )
323
  $thisval = wp_kses_bad_protocol($thisval, $allowed_protocols);
324
 
325
  if(FALSE === array_key_exists($attrname, $attrarr)) {
@@ -331,11 +810,11 @@ function wp_kses_hair($attr, $allowed_protocols) {
331
  break;
332
  }
333
 
334
- if (preg_match("%^([^\s\"']+)(\s+|$)%", $attr, $match))
335
  # value
336
  {
337
  $thisval = $match[1];
338
- if ( in_array($attrname, $uris) )
339
  $thisval = wp_kses_bad_protocol($thisval, $allowed_protocols);
340
 
341
  if(FALSE === array_key_exists($attrname, $attrarr)) {
@@ -374,10 +853,10 @@ function wp_kses_hair($attr, $allowed_protocols) {
374
  * @since 1.0.0
375
  *
376
  * @param string $value Attribute value
377
- * @param string $vless Whether the value is valueless or not. Use 'y' or 'n'
378
  * @param string $checkname What $checkvalue is checking for.
379
  * @param mixed $checkvalue What constraint the value should pass
380
- * @return bool Whether check passes (true) or not (false)
381
  */
382
  function wp_kses_check_attr_val($value, $vless, $checkname, $checkvalue) {
383
  $ok = true;
@@ -453,7 +932,6 @@ function wp_kses_check_attr_val($value, $vless, $checkname, $checkvalue) {
453
  */
454
  function wp_kses_bad_protocol($string, $allowed_protocols) {
455
  $string = wp_kses_no_null($string);
456
- $string = preg_replace('/\xad+/', '', $string); # deals with Opera "feature"
457
  $string2 = $string.'a';
458
 
459
  while ($string != $string2) {
@@ -559,14 +1037,9 @@ function wp_kses_html_error($string) {
559
  * @return string Sanitized content
560
  */
561
  function wp_kses_bad_protocol_once($string, $allowed_protocols) {
562
- global $_kses_allowed_protocols;
563
- $_kses_allowed_protocols = $allowed_protocols;
564
-
565
- $string2 = preg_split('/:|&#58;|&#x3a;/i', $string, 2);
566
- if ( isset($string2[1]) && !preg_match('%/\?%', $string2[0]) )
567
- $string = wp_kses_bad_protocol_once2($string2[0]) . trim($string2[1]);
568
- else
569
- $string = preg_replace_callback('/^((&[^;]*;|[\sA-Za-z0-9])*)'.'(:|&#58;|&#[Xx]3[Aa];)\s*/', 'wp_kses_bad_protocol_once2', $string);
570
 
571
  return $string;
572
  }
@@ -580,31 +1053,19 @@ function wp_kses_bad_protocol_once($string, $allowed_protocols) {
580
  * @access private
581
  * @since 1.0.0
582
  *
583
- * @param mixed $matches string or preg_replace_callback() matches array to check for bad protocols
 
584
  * @return string Sanitized content
585
  */
586
- function wp_kses_bad_protocol_once2($matches) {
587
- global $_kses_allowed_protocols;
588
-
589
- if ( is_array($matches) ) {
590
- if ( ! isset($matches[1]) || empty($matches[1]) )
591
- return '';
592
-
593
- $string = $matches[1];
594
- } else {
595
- $string = $matches;
596
- }
597
-
598
  $string2 = wp_kses_decode_entities($string);
599
  $string2 = preg_replace('/\s/', '', $string2);
600
  $string2 = wp_kses_no_null($string2);
601
- $string2 = preg_replace('/\xad+/', '', $string2);
602
- # deals with Opera "feature"
603
  $string2 = strtolower($string2);
604
 
605
  $allowed = false;
606
- foreach ( (array) $_kses_allowed_protocols as $one_protocol)
607
- if (strtolower($one_protocol) == $string2) {
608
  $allowed = true;
609
  break;
610
  }
@@ -633,13 +1094,34 @@ function wp_kses_normalize_entities($string) {
633
 
634
  # Change back the allowed entities in our entity whitelist
635
 
636
- $string = preg_replace('/&amp;([A-Za-z][A-Za-z0-9]{0,19});/', '&\\1;', $string);
637
- $string = preg_replace_callback('/&amp;#0*([0-9]{1,5});/', 'wp_kses_normalize_entities2', $string);
638
- $string = preg_replace_callback('/&amp;#([Xx])0*(([0-9A-Fa-f]{2}){1,2});/', 'wp_kses_normalize_entities3', $string);
639
 
640
  return $string;
641
  }
642
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
643
  /**
644
  * Callback for wp_kses_normalize_entities() regular expression.
645
  *
@@ -653,11 +1135,18 @@ function wp_kses_normalize_entities($string) {
653
  * @return string Correctly encoded entity
654
  */
655
  function wp_kses_normalize_entities2($matches) {
656
- if ( ! isset($matches[1]) || empty($matches[1]) )
657
  return '';
658
 
659
  $i = $matches[1];
660
- return ( ( ! valid_unicode($i) ) || ($i > 65535) ? "&amp;#$i;" : "&#$i;" );
 
 
 
 
 
 
 
661
  }
662
 
663
  /**
@@ -672,11 +1161,11 @@ function wp_kses_normalize_entities2($matches) {
672
  * @return string Correctly encoded entity
673
  */
674
  function wp_kses_normalize_entities3($matches) {
675
- if ( ! isset($matches[2]) || empty($matches[2]) )
676
  return '';
677
 
678
- $hexchars = $matches[2];
679
- return ( ( ! valid_unicode(hexdec($hexchars)) ) ? "&amp;#x$hexchars;" : "&#x$hexchars;" );
680
  }
681
 
682
  /**
@@ -705,8 +1194,160 @@ function valid_unicode($i) {
705
  * @return string Content after decoded entities
706
  */
707
  function wp_kses_decode_entities($string) {
708
- $string = preg_replace_callback('/&#([0-9]+);/', create_function('$match', 'return chr($match[1]);'), $string);
709
- $string = preg_replace_callback('/&#[Xx]([0-9A-Fa-f]+);/', create_function('$match', 'return chr(hexdec($match[1]));'), $string);
710
 
711
  return $string;
712
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  <?php
2
+ // Last sync [WP17185]
3
 
4
  /**
5
+ * kses 0.2.2 - HTML/XHTML filter that only allows some elements and attributes
6
+ * Copyright (C) 2002, 2003, 2005 Ulf Harnhammar
7
+ *
8
+ * This program is free software and open source software; you can redistribute
9
+ * it and/or modify it under the terms of the GNU General Public License as
10
+ * published by the Free Software Foundation; either version 2 of the License,
11
+ * or (at your option) any later version.
12
+ *
13
+ * This program is distributed in the hope that it will be useful, but WITHOUT
14
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
15
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
16
+ * more details.
17
+ *
18
+ * You should have received a copy of the GNU General Public License along
19
+ * with this program; if not, write to the Free Software Foundation, Inc.,
20
+ * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA or visit
21
+ * http://www.gnu.org/licenses/gpl.html
22
+ *
23
+ * [kses strips evil scripts!]
24
  *
25
  * Added wp_ prefix to avoid conflicts with existing kses users
26
  *
27
  * @version 0.2.2
28
  * @copyright (C) 2002, 2003, 2005
29
+ * @author Ulf Harnhammar <http://advogato.org/person/metaur/>
30
  *
31
  * @package External
32
  * @subpackage KSES
33
  *
 
 
 
 
 
 
 
 
 
 
34
  */
35
 
36
+ /**
37
+ * You can override this in a plugin.
38
+ *
39
+ * @since 1.2.0
40
+ */
41
+ if ( ! defined( 'BP_CUSTOM_TAGS' ) )
42
+ define( 'BP_CUSTOM_TAGS', false );
43
+
44
+ if ( ! BP_CUSTOM_TAGS ) {
45
+ /**
46
+ * Kses global for default allowable HTML tags.
47
+ *
48
+ * Can be override by using CUSTOM_TAGS constant.
49
+ *
50
+ * @global array $allowedposttags
51
+ * @since 2.0.0
52
+ */
53
+ $allowedposttags = array(
54
+ 'address' => array(),
55
+ 'a' => array(
56
+ 'class' => array (),
57
+ 'href' => array (),
58
+ 'id' => array (),
59
+ 'title' => array (),
60
+ 'rel' => array (),
61
+ 'rev' => array (),
62
+ 'name' => array (),
63
+ 'target' => array()),
64
+ 'abbr' => array(
65
+ 'class' => array (),
66
+ 'title' => array ()),
67
+ 'acronym' => array(
68
+ 'title' => array ()),
69
+ 'article' => array(
70
+ 'align' => array (),
71
+ 'class' => array (),
72
+ 'dir' => array (),
73
+ 'lang' => array(),
74
+ 'style' => array (),
75
+ 'xml:lang' => array(),
76
+ ),
77
+ 'aside' => array(
78
+ 'align' => array (),
79
+ 'class' => array (),
80
+ 'dir' => array (),
81
+ 'lang' => array(),
82
+ 'style' => array (),
83
+ 'xml:lang' => array(),
84
+ ),
85
+ 'b' => array(),
86
+ 'big' => array(),
87
+ 'blockquote' => array(
88
+ 'id' => array (),
89
+ 'cite' => array (),
90
+ 'class' => array(),
91
+ 'lang' => array(),
92
+ 'xml:lang' => array()),
93
+ 'br' => array (
94
+ 'class' => array ()),
95
+ 'button' => array(
96
+ 'disabled' => array (),
97
+ 'name' => array (),
98
+ 'type' => array (),
99
+ 'value' => array ()),
100
+ 'caption' => array(
101
+ 'align' => array (),
102
+ 'class' => array ()),
103
+ 'cite' => array (
104
+ 'class' => array(),
105
+ 'dir' => array(),
106
+ 'lang' => array(),
107
+ 'title' => array ()),
108
+ 'code' => array (
109
+ 'style' => array()),
110
+ 'col' => array(
111
+ 'align' => array (),
112
+ 'char' => array (),
113
+ 'charoff' => array (),
114
+ 'span' => array (),
115
+ 'dir' => array(),
116
+ 'style' => array (),
117
+ 'valign' => array (),
118
+ 'width' => array ()),
119
+ 'del' => array(
120
+ 'datetime' => array ()),
121
+ 'dd' => array(),
122
+ 'details' => array(
123
+ 'align' => array (),
124
+ 'class' => array (),
125
+ 'dir' => array (),
126
+ 'lang' => array(),
127
+ 'open' => array (),
128
+ 'style' => array (),
129
+ 'xml:lang' => array(),
130
+ ),
131
+ 'div' => array(
132
+ 'align' => array (),
133
+ 'class' => array (),
134
+ 'dir' => array (),
135
+ 'lang' => array(),
136
+ 'style' => array (),
137
+ 'xml:lang' => array()),
138
+ 'dl' => array(),
139
+ 'dt' => array(),
140
+ 'em' => array(),
141
+ 'fieldset' => array(),
142
+ 'figure' => array(
143
+ 'align' => array (),
144
+ 'class' => array (),
145
+ 'dir' => array (),
146
+ 'lang' => array(),
147
+ 'style' => array (),
148
+ 'xml:lang' => array(),
149
+ ),
150
+ 'figcaption' => array(
151
+ 'align' => array (),
152
+ 'class' => array (),
153
+ 'dir' => array (),
154
+ 'lang' => array(),
155
+ 'style' => array (),
156
+ 'xml:lang' => array(),
157
+ ),
158
+ 'font' => array(
159
+ 'color' => array (),
160
+ 'face' => array (),
161
+ 'size' => array ()),
162
+ 'footer' => array(
163
+ 'align' => array (),
164
+ 'class' => array (),
165
+ 'dir' => array (),
166
+ 'lang' => array(),
167
+ 'style' => array (),
168
+ 'xml:lang' => array(),
169
+ ),
170
+ 'form' => array(
171
+ 'action' => array (),
172
+ 'accept' => array (),
173
+ 'accept-charset' => array (),
174
+ 'enctype' => array (),
175
+ 'method' => array (),
176
+ 'name' => array (),
177
+ 'target' => array ()),
178
+ 'h1' => array(
179
+ 'align' => array (),
180
+ 'class' => array (),
181
+ 'id' => array (),
182
+ 'style' => array ()),
183
+ 'h2' => array (
184
+ 'align' => array (),
185
+ 'class' => array (),
186
+ 'id' => array (),
187
+ 'style' => array ()),
188
+ 'h3' => array (
189
+ 'align' => array (),
190
+ 'class' => array (),
191
+ 'id' => array (),
192
+ 'style' => array ()),
193
+ 'h4' => array (
194
+ 'align' => array (),
195
+ 'class' => array (),
196
+ 'id' => array (),
197
+ 'style' => array ()),
198
+ 'h5' => array (
199
+ 'align' => array (),
200
+ 'class' => array (),
201
+ 'id' => array (),
202
+ 'style' => array ()),
203
+ 'h6' => array (
204
+ 'align' => array (),
205
+ 'class' => array (),
206
+ 'id' => array (),
207
+ 'style' => array ()),
208
+ 'header' => array(
209
+ 'align' => array (),
210
+ 'class' => array (),
211
+ 'dir' => array (),
212
+ 'lang' => array(),
213
+ 'style' => array (),
214
+ 'xml:lang' => array(),
215
+ ),
216
+ 'hgroup' => array(
217
+ 'align' => array (),
218
+ 'class' => array (),
219
+ 'dir' => array (),
220
+ 'lang' => array(),
221
+ 'style' => array (),
222
+ 'xml:lang' => array(),
223
+ ),
224
+ 'hr' => array (
225
+ 'align' => array (),
226
+ 'class' => array (),
227
+ 'noshade' => array (),
228
+ 'size' => array (),
229
+ 'width' => array ()),
230
+ 'i' => array(),
231
+ 'img' => array(
232
+ 'alt' => array (),
233
+ 'align' => array (),
234
+ 'border' => array (),
235
+ 'class' => array (),
236
+ 'height' => array (),
237
+ 'hspace' => array (),
238
+ 'longdesc' => array (),
239
+ 'vspace' => array (),
240
+ 'src' => array (),
241
+ 'style' => array (),
242
+ 'width' => array ()),
243
+ 'ins' => array(
244
+ 'datetime' => array (),
245
+ 'cite' => array ()),
246
+ 'kbd' => array(),
247
+ 'label' => array(
248
+ 'for' => array ()),
249
+ 'legend' => array(
250
+ 'align' => array ()),
251
+ 'li' => array (
252
+ 'align' => array (),
253
+ 'class' => array ()),
254
+ 'menu' => array (
255
+ 'class' => array (),
256
+ 'style' => array (),
257
+ 'type' => array ()),
258
+ 'nav' => array(
259
+ 'align' => array (),
260
+ 'class' => array (),
261
+ 'dir' => array (),
262
+ 'lang' => array(),
263
+ 'style' => array (),
264
+ 'xml:lang' => array(),
265
+ ),
266
+ 'p' => array(
267
+ 'class' => array (),
268
+ 'align' => array (),
269
+ 'dir' => array(),
270
+ 'lang' => array(),
271
+ 'style' => array (),
272
+ 'xml:lang' => array()),
273
+ 'pre' => array(
274
+ 'style' => array(),
275
+ 'width' => array ()),
276
+ 'q' => array(
277
+ 'cite' => array ()),
278
+ 's' => array(),
279
+ 'span' => array (
280
+ 'class' => array (),
281
+ 'dir' => array (),
282
+ 'align' => array (),
283
+ 'lang' => array (),
284
+ 'style' => array (),
285
+ 'title' => array (),
286
+ 'xml:lang' => array()),
287
+ 'section' => array(
288
+ 'align' => array (),
289
+ 'class' => array (),
290
+ 'dir' => array (),
291
+ 'lang' => array(),
292
+ 'style' => array (),
293
+ 'xml:lang' => array(),
294
+ ),
295
+ 'strike' => array(),
296
+ 'strong' => array(),
297
+ 'sub' => array(),
298
+ 'summary' => array(
299
+ 'align' => array (),
300
+ 'class' => array (),
301
+ 'dir' => array (),
302
+ 'lang' => array(),
303
+ 'style' => array (),
304
+ 'xml:lang' => array(),
305
+ ),
306
+ 'sup' => array(),
307
+ 'table' => array(
308
+ 'align' => array (),
309
+ 'bgcolor' => array (),
310
+ 'border' => array (),
311
+ 'cellpadding' => array (),
312
+ 'cellspacing' => array (),
313
+ 'class' => array (),
314
+ 'dir' => array(),
315
+ 'id' => array(),
316
+ 'rules' => array (),
317
+ 'style' => array (),
318
+ 'summary' => array (),
319
+ 'width' => array ()),
320
+ 'tbody' => array(
321
+ 'align' => array (),
322
+ 'char' => array (),
323
+ 'charoff' => array (),
324
+ 'valign' => array ()),
325
+ 'td' => array(
326
+ 'abbr' => array (),
327
+ 'align' => array (),
328
+ 'axis' => array (),
329
+ 'bgcolor' => array (),
330
+ 'char' => array (),
331
+ 'charoff' => array (),
332
+ 'class' => array (),
333
+ 'colspan' => array (),
334
+ 'dir' => array(),
335
+ 'headers' => array (),
336
+ 'height' => array (),
337
+ 'nowrap' => array (),
338
+ 'rowspan' => array (),
339
+ 'scope' => array (),
340
+ 'style' => array (),
341
+ 'valign' => array (),
342
+ 'width' => array ()),
343
+ 'textarea' => array(
344
+ 'cols' => array (),
345
+ 'rows' => array (),
346
+ 'disabled' => array (),
347
+ 'name' => array (),
348
+ 'readonly' => array ()),
349
+ 'tfoot' => array(
350
+ 'align' => array (),
351
+ 'char' => array (),
352
+ 'class' => array (),
353
+ 'charoff' => array (),
354
+ 'valign' => array ()),
355
+ 'th' => array(
356
+ 'abbr' => array (),
357
+ 'align' => array (),
358
+ 'axis' => array (),
359
+ 'bgcolor' => array (),
360
+ 'char' => array (),
361
+ 'charoff' => array (),
362
+ 'class' => array (),
363
+ 'colspan' => array (),
364
+ 'headers' => array (),
365
+ 'height' => array (),
366
+ 'nowrap' => array (),
367
+ 'rowspan' => array (),
368
+ 'scope' => array (),
369
+ 'valign' => array (),
370
+ 'width' => array ()),
371
+ 'thead' => array(
372
+ 'align' => array (),
373
+ 'char' => array (),
374
+ 'charoff' => array (),
375
+ 'class' => array (),
376
+ 'valign' => array ()),
377
+ 'title' => array(),
378
+ 'tr' => array(
379
+ 'align' => array (),
380
+ 'bgcolor' => array (),
381
+ 'char' => array (),
382
+ 'charoff' => array (),
383
+ 'class' => array (),
384
+ 'style' => array (),
385
+ 'valign' => array ()),
386
+ 'tt' => array(),
387
+ 'u' => array(),
388
+ 'ul' => array (
389
+ 'class' => array (),
390
+ 'style' => array (),
391
+ 'type' => array ()),
392
+ 'ol' => array (
393
+ 'class' => array (),
394
+ 'start' => array (),
395
+ 'style' => array (),
396
+ 'type' => array ()),
397
+ 'var' => array ());
398
+
399
+ /**
400
+ * Kses allowed HTML elements.
401
+ *
402
+ * @global array $allowedtags
403
+ * @since 1.0.0
404
+ */
405
+ $allowedtags = array(
406
+ 'a' => array(
407
+ 'href' => array (),
408
+ 'title' => array ()),
409
+ 'abbr' => array(
410
+ 'title' => array ()),
411
+ 'acronym' => array(
412
+ 'title' => array ()),
413
+ 'b' => array(),
414
+ 'blockquote' => array(
415
+ 'cite' => array ()),
416
+ // 'br' => array(),
417
+ 'cite' => array (),
418
+ 'code' => array(),
419
+ 'del' => array(
420
+ 'datetime' => array ()),
421
+ // 'dd' => array(),
422
+ // 'dl' => array(),
423
+ // 'dt' => array(),
424
+ 'em' => array (), 'i' => array (),
425
+ // 'ins' => array('datetime' => array(), 'cite' => array()),
426
+ // 'li' => array(),
427
+ // 'ol' => array(),
428
+ // 'p' => array(),
429
+ 'q' => array(
430
+ 'cite' => array ()),
431
+ 'strike' => array(),
432
+ 'strong' => array(),
433
+ // 'sub' => array(),
434
+ // 'sup' => array(),
435
+ // 'u' => array(),
436
+ // 'ul' => array(),
437
+ );
438
+
439
+ $allowedentitynames = array(
440
+ 'nbsp', 'iexcl', 'cent', 'pound', 'curren', 'yen',
441
+ 'brvbar', 'sect', 'uml', 'copy', 'ordf', 'laquo',
442
+ 'not', 'shy', 'reg', 'macr', 'deg', 'plusmn',
443
+ 'acute', 'micro', 'para', 'middot', 'cedil', 'ordm',
444
+ 'raquo', 'iquest', 'Agrave', 'Aacute', 'Acirc', 'Atilde',
445
+ 'Auml', 'Aring', 'AElig', 'Ccedil', 'Egrave', 'Eacute',
446
+ 'Ecirc', 'Euml', 'Igrave', 'Iacute', 'Icirc', 'Iuml',
447
+ 'ETH', 'Ntilde', 'Ograve', 'Oacute', 'Ocirc', 'Otilde',
448
+ 'Ouml', 'times', 'Oslash', 'Ugrave', 'Uacute', 'Ucirc',
449
+ 'Uuml', 'Yacute', 'THORN', 'szlig', 'agrave', 'aacute',
450
+ 'acirc', 'atilde', 'auml', 'aring', 'aelig', 'ccedil',
451
+ 'egrave', 'eacute', 'ecirc', 'euml', 'igrave', 'iacute',
452
+ 'icirc', 'iuml', 'eth', 'ntilde', 'ograve', 'oacute',
453
+ 'ocirc', 'otilde', 'ouml', 'divide', 'oslash', 'ugrave',
454
+ 'uacute', 'ucirc', 'uuml', 'yacute', 'thorn', 'yuml',
455
+ 'quot', 'amp', 'lt', 'gt', 'apos', 'OElig',
456
+ 'oelig', 'Scaron', 'scaron', 'Yuml', 'circ', 'tilde',
457
+ 'ensp', 'emsp', 'thinsp', 'zwnj', 'zwj', 'lrm',
458
+ 'rlm', 'ndash', 'mdash', 'lsquo', 'rsquo', 'sbquo',
459
+ 'ldquo', 'rdquo', 'bdquo', 'dagger', 'Dagger', 'permil',
460
+ 'lsaquo', 'rsaquo', 'euro', 'fnof', 'Alpha', 'Beta',
461
+ 'Gamma', 'Delta', 'Epsilon', 'Zeta', 'Eta', 'Theta',
462
+ 'Iota', 'Kappa', 'Lambda', 'Mu', 'Nu', 'Xi',
463
+ 'Omicron', 'Pi', 'Rho', 'Sigma', 'Tau', 'Upsilon',
464
+ 'Phi', 'Chi', 'Psi', 'Omega', 'alpha', 'beta',
465
+ 'gamma', 'delta', 'epsilon', 'zeta', 'eta', 'theta',
466
+ 'iota', 'kappa', 'lambda', 'mu', 'nu', 'xi',
467
+ 'omicron', 'pi', 'rho', 'sigmaf', 'sigma', 'tau',
468
+ 'upsilon', 'phi', 'chi', 'psi', 'omega', 'thetasym',
469
+ 'upsih', 'piv', 'bull', 'hellip', 'prime', 'Prime',
470
+ 'oline', 'frasl', 'weierp', 'image', 'real', 'trade',
471
+ 'alefsym', 'larr', 'uarr', 'rarr', 'darr', 'harr',
472
+ 'crarr', 'lArr', 'uArr', 'rArr', 'dArr', 'hArr',
473
+ 'forall', 'part', 'exist', 'empty', 'nabla', 'isin',
474
+ 'notin', 'ni', 'prod', 'sum', 'minus', 'lowast',
475
+ 'radic', 'prop', 'infin', 'ang', 'and', 'or',
476
+ 'cap', 'cup', 'int', 'sim', 'cong', 'asymp',
477
+ 'ne', 'equiv', 'le', 'ge', 'sub', 'sup',
478
+ 'nsub', 'sube', 'supe', 'oplus', 'otimes', 'perp',
479
+ 'sdot', 'lceil', 'rceil', 'lfloor', 'rfloor', 'lang',
480
+ 'rang', 'loz', 'spades', 'clubs', 'hearts', 'diams',
481
+ );
482
+ }
483
 
484
  /**
485
  * Filters content and keeps only allowable HTML elements.
490
  * call this function.
491
  *
492
  * The default allowed protocols are 'http', 'https', 'ftp', 'mailto', 'news',
493
+ * 'irc', 'gopher', 'nntp', 'feed', 'telnet, 'mms', 'rtsp' and 'svn'. This
494
+ * covers all common link protocols, except for 'javascript' which should not
495
+ * be allowed for untrusted users.
496
  *
497
  * @since 1.0.0
498
  *
501
  * @param array $allowed_protocols Optional. Allowed protocol in links.
502
  * @return string Filtered content with only allowed HTML elements
503
  */
504
+ function wp_kses($string, $allowed_html, $allowed_protocols = array ()) {
505
+ $allowed_protocols = wp_parse_args( $allowed_protocols, apply_filters('kses_allowed_protocols', array ('http', 'https', 'ftp', 'ftps', 'mailto', 'news', 'irc', 'gopher', 'nntp', 'feed', 'telnet', 'mms', 'rtsp', 'svn') ));
506
  $string = wp_kses_no_null($string);
507
  $string = wp_kses_js_entities($string);
508
  $string = wp_kses_normalize_entities($string);
556
  global $pass_allowed_html, $pass_allowed_protocols;
557
  $pass_allowed_html = $allowed_html;
558
  $pass_allowed_protocols = $allowed_protocols;
559
+ return preg_replace_callback( '%((<!--.*?(-->|$))|(<[^>]*(>|$)|>))%', '_wp_kses_split_callback', $string );
560
+ }
561
+
562
+ /**
563
+ * Callback for wp_kses_split.
564
+ *
565
+ * @since 3.1.0
566
+ * @access private
567
+ */
568
+ function _wp_kses_split_callback( $match ) {
569
+ global $pass_allowed_html, $pass_allowed_protocols;
570
+ return wp_kses_split2( $match[1], $pass_allowed_html, $pass_allowed_protocols );
571
  }
572
 
573
  /**
652
  # Is there a closing XHTML slash at the end of the attributes?
653
 
654
  $xhtml_slash = '';
655
+ if (preg_match('%\s*/\s*$%', $attr))
656
  $xhtml_slash = ' /';
657
 
658
  # Are any attributes allowed at all for this element?
690
  break;
691
  }
692
 
693
+ if ( strtolower($arreach['name']) == 'style' ) {
694
+ $orig_value = $arreach['value'];
695
+
696
+ $value = safecss_filter_attr($orig_value);
697
+
698
+ if ( empty($value) )
699
+ continue;
700
+
701
+ $arreach['value'] = $value;
702
+
703
+ $arreach['whole'] = str_replace($orig_value, $value, $arreach['whole']);
704
+ }
705
+
706
  if ($ok)
707
  $attr2 .= ' '.$arreach['whole']; # it passed them
708
  } # if !is_array($current)
778
 
779
  case 2 : # attribute value, a URL after href= for instance
780
 
781
+ if (preg_match('%^"([^"]*)"(\s+|/?$)%', $attr, $match))
782
  # "value"
783
  {
784
  $thisval = $match[1];
785
+ if ( in_array(strtolower($attrname), $uris) )
786
  $thisval = wp_kses_bad_protocol($thisval, $allowed_protocols);
787
 
788
  if(FALSE === array_key_exists($attrname, $attrarr)) {
794
  break;
795
  }
796
 
797
+ if (preg_match("%^'([^']*)'(\s+|/?$)%", $attr, $match))
798
  # 'value'
799
  {
800
  $thisval = $match[1];
801
+ if ( in_array(strtolower($attrname), $uris) )
802
  $thisval = wp_kses_bad_protocol($thisval, $allowed_protocols);
803
 
804
  if(FALSE === array_key_exists($attrname, $attrarr)) {
810
  break;
811
  }
812
 
813
+ if (preg_match("%^([^\s\"']+)(\s+|/?$)%", $attr, $match))
814
  # value
815
  {
816
  $thisval = $match[1];
817
+ if ( in_array(strtolower($attrname), $uris) )
818
  $thisval = wp_kses_bad_protocol($thisval, $allowed_protocols);
819
 
820
  if(FALSE === array_key_exists($attrname, $attrarr)) {
853
  * @since 1.0.0
854
  *
855
  * @param string $value Attribute value
856
+ * @param string $vless Whether the value is valueless. Use 'y' or 'n'
857
  * @param string $checkname What $checkvalue is checking for.
858
  * @param mixed $checkvalue What constraint the value should pass
859
+ * @return bool Whether check passes
860
  */
861
  function wp_kses_check_attr_val($value, $vless, $checkname, $checkvalue) {
862
  $ok = true;
932
  */
933
  function wp_kses_bad_protocol($string, $allowed_protocols) {
934
  $string = wp_kses_no_null($string);
 
935
  $string2 = $string.'a';
936
 
937
  while ($string != $string2) {
1037
  * @return string Sanitized content
1038
  */
1039
  function wp_kses_bad_protocol_once($string, $allowed_protocols) {
1040
+ $string2 = preg_split( '/:|&#0*58;|&#x0*3a;/i', $string, 2 );
1041
+ if ( isset($string2[1]) && ! preg_match('%/\?%', $string2[0]) )
1042
+ $string = wp_kses_bad_protocol_once2( $string2[0], $allowed_protocols ) . trim( $string2[1] );
 
 
 
 
 
1043
 
1044
  return $string;
1045
  }
1053
  * @access private
1054
  * @since 1.0.0
1055
  *
1056
+ * @param string $string URI scheme to check against the whitelist
1057
+ * @param string $allowed_protocols Allowed protocols
1058
  * @return string Sanitized content
1059
  */
1060
+ function wp_kses_bad_protocol_once2( $string, $allowed_protocols ) {
 
 
 
 
 
 
 
 
 
 
 
1061
  $string2 = wp_kses_decode_entities($string);
1062
  $string2 = preg_replace('/\s/', '', $string2);
1063
  $string2 = wp_kses_no_null($string2);
 
 
1064
  $string2 = strtolower($string2);
1065
 
1066
  $allowed = false;
1067
+ foreach ( (array) $allowed_protocols as $one_protocol )
1068
+ if ( strtolower($one_protocol) == $string2 ) {
1069
  $allowed = true;
1070
  break;
1071
  }
1094
 
1095
  # Change back the allowed entities in our entity whitelist
1096
 
1097
+ $string = preg_replace_callback('/&amp;([A-Za-z]{2,8});/', 'wp_kses_named_entities', $string);
1098
+ $string = preg_replace_callback('/&amp;#(0*[0-9]{1,7});/', 'wp_kses_normalize_entities2', $string);
1099
+ $string = preg_replace_callback('/&amp;#[Xx](0*[0-9A-Fa-f]{1,6});/', 'wp_kses_normalize_entities3', $string);
1100
 
1101
  return $string;
1102
  }
1103
 
1104
+ /**
1105
+ * Callback for wp_kses_normalize_entities() regular expression.
1106
+ *
1107
+ * This function only accepts valid named entity references, which are finite,
1108
+ * case-sensitive, and highly scrutinized by HTML and XML validators.
1109
+ *
1110
+ * @since 3.0.0
1111
+ *
1112
+ * @param array $matches preg_replace_callback() matches array
1113
+ * @return string Correctly encoded entity
1114
+ */
1115
+ function wp_kses_named_entities($matches) {
1116
+ global $allowedentitynames;
1117
+
1118
+ if ( empty($matches[1]) )
1119
+ return '';
1120
+
1121
+ $i = $matches[1];
1122
+ return ( ( ! in_array($i, $allowedentitynames) ) ? "&amp;$i;" : "&$i;" );
1123
+ }
1124
+
1125
  /**
1126
  * Callback for wp_kses_normalize_entities() regular expression.
1127
  *
1135
  * @return string Correctly encoded entity
1136
  */
1137
  function wp_kses_normalize_entities2($matches) {
1138
+ if ( empty($matches[1]) )
1139
  return '';
1140
 
1141
  $i = $matches[1];
1142
+ if (valid_unicode($i)) {
1143
+ $i = str_pad(ltrim($i,'0'), 3, '0', STR_PAD_LEFT);
1144
+ $i = "&#$i;";
1145
+ } else {
1146
+ $i = "&amp;#$i;";
1147
+ }
1148
+
1149
+ return $i;
1150
  }
1151
 
1152
  /**
1161
  * @return string Correctly encoded entity
1162
  */
1163
  function wp_kses_normalize_entities3($matches) {
1164
+ if ( empty($matches[1]) )
1165
  return '';
1166
 
1167
+ $hexchars = $matches[1];
1168
+ return ( ( ! valid_unicode(hexdec($hexchars)) ) ? "&amp;#x$hexchars;" : '&#x'.ltrim($hexchars,'0').';' );
1169
  }
1170
 
1171
  /**
1194
  * @return string Content after decoded entities
1195
  */
1196
  function wp_kses_decode_entities($string) {
1197
+ $string = preg_replace_callback('/&#([0-9]+);/', '_wp_kses_decode_entities_chr', $string);
1198
+ $string = preg_replace_callback('/&#[Xx]([0-9A-Fa-f]+);/', '_wp_kses_decode_entities_chr_hexdec', $string);
1199
 
1200
  return $string;
1201
  }
1202
+
1203
+ /**
1204
+ * Regex callback for wp_kses_decode_entities()
1205
+ *
1206
+ * @param array $match preg match
1207
+ * @return string
1208
+ */
1209
+ function _wp_kses_decode_entities_chr( $match ) {
1210
+ return chr( $match[1] );
1211
+ }
1212
+
1213
+ /**
1214
+ * Regex callback for wp_kses_decode_entities()
1215
+ *
1216
+ * @param array $match preg match
1217
+ * @return string
1218
+ */
1219
+ function _wp_kses_decode_entities_chr_hexdec( $match ) {
1220
+ return chr( hexdec( $match[1] ) );
1221
+ }
1222
+
1223
+ /**
1224
+ * Sanitize content with allowed HTML Kses rules.
1225
+ *
1226
+ * @since 1.0.0
1227
+ * @uses $allowedtags
1228
+ *
1229
+ * @param string $data Content to filter, expected to be escaped with slashes
1230
+ * @return string Filtered content
1231
+ */
1232
+ function wp_filter_kses($data) {
1233
+ global $allowedtags;
1234
+ return addslashes( wp_kses(stripslashes( $data ), $allowedtags) );
1235
+ }
1236
+
1237
+ /**
1238
+ * Sanitize content with allowed HTML Kses rules.
1239
+ *
1240
+ * @since 2.9.0
1241
+ * @uses $allowedtags
1242
+ *
1243
+ * @param string $data Content to filter, expected to not be escaped
1244
+ * @return string Filtered content
1245
+ */
1246
+ function wp_kses_data($data) {
1247
+ global $allowedtags;
1248
+ return wp_kses( $data , $allowedtags );
1249
+ }
1250
+
1251
+ /**
1252
+ * Sanitize content for allowed HTML tags for post content.
1253
+ *
1254
+ * Post content refers to the page contents of the 'post' type and not $_POST
1255
+ * data from forms.
1256
+ *
1257
+ * @since 2.0.0
1258
+ * @uses $allowedposttags
1259
+ *
1260
+ * @param string $data Post content to filter, expected to be escaped with slashes
1261
+ * @return string Filtered post content with allowed HTML tags and attributes intact.
1262
+ */
1263
+ function wp_filter_post_kses($data) {
1264
+ global $allowedposttags;
1265
+ return addslashes ( wp_kses(stripslashes( $data ), $allowedposttags) );
1266
+ }
1267
+
1268
+ /**
1269
+ * Sanitize content for allowed HTML tags for post content.
1270
+ *
1271
+ * Post content refers to the page contents of the 'post' type and not $_POST
1272
+ * data from forms.
1273
+ *
1274
+ * @since 2.9.0
1275
+ * @uses $allowedposttags
1276
+ *
1277
+ * @param string $data Post content to filter
1278
+ * @return string Filtered post content with allowed HTML tags and attributes intact.
1279
+ */
1280
+ function wp_kses_post($data) {
1281
+ global $allowedposttags;
1282
+ return wp_kses( $data , $allowedposttags );
1283
+ }
1284
+
1285
+ /**
1286
+ * Strips all of the HTML in the content.
1287
+ *
1288
+ * @since 2.1.0
1289
+ *
1290
+ * @param string $data Content to strip all HTML from
1291
+ * @return string Filtered content without any HTML
1292
+ */
1293
+ function wp_filter_nohtml_kses($data) {
1294
+ return addslashes ( wp_kses(stripslashes( $data ), array()) );
1295
+ }
1296
+
1297
+ // ! function kses_init_filters()
1298
+ // ! function kses_remove_filters()
1299
+ // ! function kses_init()
1300
+
1301
+ /**
1302
+ * Inline CSS filter
1303
+ *
1304
+ * @since 2.8.1
1305
+ */
1306
+ function safecss_filter_attr( $css, $deprecated = '' ) {
1307
+ if ( !empty( $deprecated ) )
1308
+ _deprecated_argument( __FUNCTION__, '2.8.1' ); // Never implemented
1309
+
1310
+ $css = wp_kses_no_null($css);
1311
+ $css = str_replace(array("\n","\r","\t"), '', $css);
1312
+
1313
+ if ( preg_match( '%[\\(&=}]|/\*%', $css ) ) // remove any inline css containing \ ( & } = or comments
1314
+ return '';
1315
+
1316
+ $css_array = explode( ';', trim( $css ) );
1317
+ $allowed_attr = apply_filters( 'safe_style_css', array( 'text-align', 'margin', 'color', 'float',
1318
+ 'border', 'background', 'background-color', 'border-bottom', 'border-bottom-color',
1319
+ 'border-bottom-style', 'border-bottom-width', 'border-collapse', 'border-color', 'border-left',
1320
+ 'border-left-color', 'border-left-style', 'border-left-width', 'border-right', 'border-right-color',
1321
+ 'border-right-style', 'border-right-width', 'border-spacing', 'border-style', 'border-top',
1322
+ 'border-top-color', 'border-top-style', 'border-top-width', 'border-width', 'caption-side',
1323
+ 'clear', 'cursor', 'direction', 'font', 'font-family', 'font-size', 'font-style',
1324
+ 'font-variant', 'font-weight', 'height', 'letter-spacing', 'line-height', 'margin-bottom',
1325
+ 'margin-left', 'margin-right', 'margin-top', 'overflow', 'padding', 'padding-bottom',
1326
+ 'padding-left', 'padding-right', 'padding-top', 'text-decoration', 'text-indent', 'vertical-align',
1327
+ 'width' ) );
1328
+
1329
+ if ( empty($allowed_attr) )
1330
+ return $css;
1331
+
1332
+ $css = '';
1333
+ foreach ( $css_array as $css_item ) {
1334
+ if ( $css_item == '' )
1335
+ continue;
1336
+ $css_item = trim( $css_item );
1337
+ $found = false;
1338
+ if ( strpos( $css_item, ':' ) === false ) {
1339
+ $found = true;
1340
+ } else {
1341
+ $parts = split( ':', $css_item );
1342
+ if ( in_array( trim( $parts[0] ), $allowed_attr ) )
1343
+ $found = true;
1344
+ }
1345
+ if ( $found ) {
1346
+ if( $css != '' )
1347
+ $css .= ';';
1348
+ $css .= $css_item;
1349
+ }
1350
+ }
1351
+
1352
+ return $css;
1353
+ }
bp-forums/bbpress/bb-includes/class.bp-options.php CHANGED
@@ -25,9 +25,6 @@ class BP_Options
25
  case 'cron_uri':
26
  return bb_get_uri( 'bb-cron.php', array( 'check' => BP_Options::get( 'cron_check' ) ), BB_URI_CONTEXT_WP_HTTP_REQUEST );
27
  break;
28
- case 'cron_check':
29
- return bb_hash( '187425' );
30
- break;
31
  case 'wp_http_version':
32
  return 'bbPress/' . bb_get_option( 'version' );
33
  break;
25
  case 'cron_uri':
26
  return bb_get_uri( 'bb-cron.php', array( 'check' => BP_Options::get( 'cron_check' ) ), BB_URI_CONTEXT_WP_HTTP_REQUEST );
27
  break;
 
 
 
28
  case 'wp_http_version':
29
  return 'bbPress/' . bb_get_option( 'version' );
30
  break;
bp-forums/bbpress/bb-includes/functions.bb-core.php CHANGED
@@ -351,16 +351,45 @@ function bb_timer_stop($display = 0, $precision = 3) { //if called like bb_timer
351
  }
352
 
353
  // GMT -> so many minutes ago
354
- function bb_since( $original, $do_more = 0 ) {
355
- $today = time();
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
356
 
357
- if ( !is_numeric($original) ) {
358
- if ( $today < $_original = bb_gmtstrtotime( str_replace(',', ' ', $original) ) ) // Looks like bb_since was called twice
 
 
359
  return $original;
360
- else
361
  $original = $_original;
 
362
  }
363
-
 
 
 
 
 
 
 
 
 
 
364
  // array of time period chunks
365
  $chunks = array(
366
  ( 60 * 60 * 24 * 365 ), // years
@@ -372,33 +401,35 @@ function bb_since( $original, $do_more = 0 ) {
372
  ( 1 ) // seconds
373
  );
374
 
375
- $since = $today - $original;
376
-
377
- for ($i = 0, $j = count($chunks); $i < $j; $i++) {
378
- $seconds = $chunks[$i];
379
-
380
- if ( 0 != $count = floor($since / $seconds) )
 
 
 
 
 
 
 
 
 
 
 
 
 
 
381
  break;
 
382
  }
383
 
384
- $trans = array(
385
- _n( '%d year', '%d years', $count ),
386
- _n( '%d month', '%d months', $count ),
387
- _n( '%d week', '%d weeks', $count ),
388
- _n( '%d day', '%d days', $count ),
389
- _n( '%d hour', '%d hours', $count ),
390
- _n( '%d minute', '%d minutes', $count ),
391
- _n( '%d second', '%d seconds', $count )
392
- );
393
-
394
- $print = sprintf( $trans[$i], $count );
395
-
396
- if ( $do_more && $i + 1 < $j) {
397
- $seconds2 = $chunks[$i + 1];
398
- if ( 0 != $count2 = floor( ($since - $seconds * $count) / $seconds2) )
399
- $print .= sprintf( $trans[$i + 1], $count2 );
400
  }
401
- return $print;
 
402
  }
403
 
404
  function bb_current_time( $type = 'timestamp' ) {
@@ -701,9 +732,13 @@ function bb_repermalink() {
701
  $user = bb_get_current_user(); // Attempt to go to the current users profile
702
  } else {
703
  if ( bb_get_option( 'mod_rewrite' ) === 'slugs') {
704
- $user = bb_get_user_by_nicename( $id ); // Get by the user_nicename
 
 
705
  } else {
706
- $user = bb_get_user( $id ); // Get by the ID
 
 
707
  }
708
  }
709
 
351
  }
352
 
353
  // GMT -> so many minutes ago
354
+ function bb_since( $original, $args = '' )
355
+ {
356
+ $defaults = array(
357
+ 'levels' => 1,
358
+ 'separator' => ', '
359
+ );
360
+
361
+ // $args used to be $do_more
362
+ // $do_more = 0 is equivalent to $args['levels'] = 1
363
+ // $do_more = 1 is equivalent to $args['levels'] = 2
364
+ if ( !is_array( $args ) ) {
365
+ $args = array(
366
+ 'levels' => abs( (integer) $args ) + 1
367
+ );
368
+ }
369
+
370
+ $args = wp_parse_args( $args, $defaults );
371
+ extract( $args, EXTR_SKIP );
372
 
373
+ $today = (integer) time();
374
+
375
+ if ( !is_numeric( $original ) ) {
376
+ if ( $today < $_original = bb_gmtstrtotime( str_replace( ',', ' ', $original ) ) ) { // Looks like bb_since was called twice
377
  return $original;
378
+ } else {
379
  $original = $_original;
380
+ }
381
  }
382
+
383
+ $seconds = $today - ( (integer) $original );
384
+ if ( 0 === $seconds ) {
385
+ return sprintf( _n( '%d second', '%d seconds', 0 ), 0 );
386
+ }
387
+
388
+ $levels = abs( (integer) $levels );
389
+ if ( 0 === $levels ) {
390
+ return '';
391
+ }
392
+
393
  // array of time period chunks
394
  $chunks = array(
395
  ( 60 * 60 * 24 * 365 ), // years
401
  ( 1 ) // seconds
402
  );
403
 
404
+ $caught = 0;
405
+ $parts = array();
406
+ for ( $i = 0; $i < count( $chunks ); $i++ ) {
407
+ if ( ( $count = floor( $seconds / $chunks[$i] ) ) || $caught ) {
408
+ if ( $count ) {
409
+ $trans = array(
410
+ _n( '%d year', '%d years', $count ),
411
+ _n( '%d month', '%d months', $count ),
412
+ _n( '%d week', '%d weeks', $count ),
413
+ _n( '%d day', '%d days', $count ),
414
+ _n( '%d hour', '%d hours', $count ),
415
+ _n( '%d minute', '%d minutes', $count ),
416
+ _n( '%d second', '%d seconds', $count )
417
+ );
418
+ $parts[] = sprintf( $trans[$i], $count );
419
+ }
420
+ $caught++;
421
+ $seconds = $seconds - ( $count * $chunks[$i] );
422
+ }
423
+ if ( $caught === $levels ) {
424
  break;
425
+ }
426
  }
427
 
428
+ if ( empty( $parts ) ) {
429
+ return sprintf( _n( '%d second', '%d seconds', 0 ), 0 );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
430
  }
431
+
432
+ return join( $separator, $parts );
433
  }
434
 
435
  function bb_current_time( $type = 'timestamp' ) {
732
  $user = bb_get_current_user(); // Attempt to go to the current users profile
733
  } else {
734
  if ( bb_get_option( 'mod_rewrite' ) === 'slugs') {
735
+ if ( !$user = bb_get_user_by_nicename( $id ) ) {
736
+ $user = bb_get_user( $id );
737
+ }
738
  } else {
739
+ if ( !$user = bb_get_user( $id ) ) {
740
+ $user = bb_get_user_by_nicename( $id );
741
+ }
742
  }
743
  }
744
 
bp-forums/bbpress/bb-includes/functions.bb-deprecated.php CHANGED
@@ -640,8 +640,11 @@ function bb_pull_cols( $obj_array ) {
640
 
641
  // $length parameter is deprecated
642
  function bb_random_pass( $length ) {
643
- bb_log_deprecated('function', __FUNCTION__, 'wp_generate_password');
644
- return wp_generate_password();
 
 
 
645
  }
646
 
647
  // Old RSS related functions
640
 
641
  // $length parameter is deprecated
642
  function bb_random_pass( $length ) {
643
+ bb_log_deprecated('function', __FUNCTION__, 'bb_generate_password');
644
+ if ( 12 < (int) $length ) {
645
+ $length = 12;
646
+ }
647
+ return bb_generate_password( $length );
648
  }
649
 
650
  // Old RSS related functions
bp-forums/bbpress/bb-includes/functions.bb-pluggable.php CHANGED
@@ -368,20 +368,19 @@ function bb_create_nonce($action = -1) {
368
  }
369
  endif;
370
 
371
- function _bb_get_key( $key, $default_key = false ) {
372
- if ( !$default_key ) {
373
- global $bb_default_secret_key;
374
- $default_key = $bb_default_secret_key;
375
- }
376
 
377
- if ( defined( $key ) && '' != constant( $key ) && $default_key != constant( $key ) ) {
378
  return constant( $key );
379
  }
380
 
381
- return $default_key;
382
  }
383
 
384
- function _bb_get_salt( $constants, $option = false ) {
 
385
  if ( !is_array( $constants ) ) {
386
  $constants = array( $constants );
387
  }
@@ -398,7 +397,7 @@ function _bb_get_salt( $constants, $option = false ) {
398
  }
399
  $salt = bb_get_option( $option );
400
  if ( empty( $salt ) ) {
401
- $salt = bb_generate_password();
402
  bb_update_option( $option, $salt );
403
  }
404
  return $salt;
@@ -419,27 +418,29 @@ if ( !function_exists( 'bb_salt' ) ) :
419
  *
420
  * @return string Salt value for the given scheme
421
  */
422
- function bb_salt($scheme = 'auth') {
 
 
423
  $secret_key = _bb_get_key( 'BB_SECRET_KEY' );
424
 
425
  switch ($scheme) {
426
  case 'auth':
427
- $secret_key = _bb_get_key( 'BB_AUTH_KEY', $secret_key );
428
  $salt = _bb_get_salt( array( 'BB_AUTH_SALT', 'BB_SECRET_SALT' ) );
429
  break;
430
 
431
  case 'secure_auth':
432
- $secret_key = _bb_get_key( 'BB_SECURE_AUTH_KEY', $secret_key );
433
  $salt = _bb_get_salt( 'BB_SECURE_AUTH_SALT' );
434
  break;
435
 
436
  case 'logged_in':
437
- $secret_key = _bb_get_key( 'BB_LOGGED_IN_KEY', $secret_key );
438
  $salt = _bb_get_salt( 'BB_LOGGED_IN_SALT' );
439
  break;
440
 
441
  case 'nonce':
442
- $secret_key = _bb_get_key( 'BB_NONCE_KEY', $secret_key );
443
  $salt = _bb_get_salt( 'BB_NONCE_SALT' );
444
  break;
445
 
368
  }
369
  endif;
370
 
371
+ function _bb_get_key( $key, $default_key = false )
372
+ {
373
+ global $bb_default_secret_key;
 
 
374
 
375
+ if ( defined( $key ) && '' != constant( $key ) && $bb_default_secret_key != constant( $key ) ) {
376
  return constant( $key );
377
  }
378
 
379
+ return '';
380
  }
381
 
382
+ function _bb_get_salt( $constants, $option = false )
383
+ {
384
  if ( !is_array( $constants ) ) {
385
  $constants = array( $constants );
386
  }
397
  }
398
  $salt = bb_get_option( $option );
399
  if ( empty( $salt ) ) {
400
+ $salt = bb_generate_password( 64 );
401
  bb_update_option( $option, $salt );
402
  }
403
  return $salt;
418
  *
419
  * @return string Salt value for the given scheme
420
  */
421
+ function bb_salt( $scheme = 'auth' )
422
+ {
423
+ // Deprecated
424
  $secret_key = _bb_get_key( 'BB_SECRET_KEY' );
425
 
426
  switch ($scheme) {
427
  case 'auth':
428
+ $secret_key = _bb_get_key( 'BB_AUTH_KEY' );
429
  $salt = _bb_get_salt( array( 'BB_AUTH_SALT', 'BB_SECRET_SALT' ) );
430
  break;
431
 
432
  case 'secure_auth':
433
+ $secret_key = _bb_get_key( 'BB_SECURE_AUTH_KEY' );
434
  $salt = _bb_get_salt( 'BB_SECURE_AUTH_SALT' );
435
  break;
436
 
437
  case 'logged_in':
438
+ $secret_key = _bb_get_key( 'BB_LOGGED_IN_KEY' );
439
  $salt = _bb_get_salt( 'BB_LOGGED_IN_SALT' );
440
  break;
441
 
442
  case 'nonce':
443
+ $secret_key = _bb_get_key( 'BB_NONCE_KEY' );
444
  $salt = _bb_get_salt( 'BB_NONCE_SALT' );
445
  break;
446
 
bp-forums/bbpress/bb-includes/functions.bb-posts.php CHANGED
@@ -94,6 +94,7 @@ function bb_cache_first_posts( $_topics = false, $author_cache = true ) {
94
  function bb_cache_posts( $query, $post_id_query = false ) {
95
  global $bbdb;
96
 
 
97
  $_query_post_ids = array();
98
  $_query_posts = array();
99
  $_cached_posts = array();
94
  function bb_cache_posts( $query, $post_id_query = false ) {
95
  global $bbdb;
96
 
97
+ $_query = '';
98
  $_query_post_ids = array();
99
  $_query_posts = array();
100
  $_cached_posts = array();
bp-forums/bbpress/bb-includes/functions.bb-template.php CHANGED
@@ -254,13 +254,13 @@ function bb_post_template() {
254
  function post_form( $args = array() ) {
255
  global $page, $topic, $forum;
256
 
257
- if ( is_string( $args ) ) {
258
- $args['h2'] = $args;
259
- }
260
  $defaults = array(
261
  'h2' => '',
262
  'last_page_only' => true
263
  );
 
 
 
264
  $args = wp_parse_args( $args, $defaults );
265
  extract( $args, EXTR_SKIP );
266
 
@@ -1523,17 +1523,13 @@ function bb_get_topic_move_dropdown( $args = '' )
1523
  if ( !$dropdown )
1524
  return;
1525
 
1526
- $r = $before . '<form id="topic-move" method="post" action="' . bb_get_uri( 'bb-admin/topic-move.php', null, BB_URI_CONTEXT_FORM_ACTION + BB_URI_CONTEXT_BB_ADMIN ) . '">' . "\n";
1527
- $r .= '<fieldset>' . "\n";
1528
- $r .= '<div>' . "\n";
1529
  $r .= '<input type="hidden" name="topic_id" value="' . $topic->topic_id . '" />' . "\n";
1530
  $r .= '<label for="forum-id">'. __( 'Move to' ) . '</label>' . "\n";
1531
  $r .= $dropdown . "\n";
1532
  $r .= bb_nonce_field( 'move-topic_' . $topic->topic_id, '_wpnonce', true , false );
1533
  $r .= '<input type="submit" name="Submit" value="' . __( 'Move' ) . '" />' . "\n";
1534
- $r .= '</div>' . "\n";
1535
- $r .= '</fieldset>' . "\n";
1536
- $r .= '</form>' . $after;
1537
 
1538
  return $r;
1539
  }
@@ -3506,6 +3502,9 @@ function _bb_time_function_return( $time, $args ) {
3506
  case 'mysql' :
3507
  $format = 'Y-m-d H:i:s';
3508
  break;
 
 
 
3509
  endswitch;
3510
 
3511
  if ( $args['localize'] ) {
254
  function post_form( $args = array() ) {
255
  global $page, $topic, $forum;
256
 
 
 
 
257
  $defaults = array(
258
  'h2' => '',
259
  'last_page_only' => true
260
  );
261
+ if ( is_string( $args ) ) {
262
+ $defaults['h2'] = $args;
263
+ }
264
  $args = wp_parse_args( $args, $defaults );
265
  extract( $args, EXTR_SKIP );
266
 
1523
  if ( !$dropdown )
1524
  return;
1525
 
1526
+ $r = $before . '<form id="topic-move" method="post" action="' . bb_get_uri( 'bb-admin/topic-move.php', null, BB_URI_CONTEXT_FORM_ACTION + BB_URI_CONTEXT_BB_ADMIN ) . '"><fieldset><div>' . "\n";
 
 
1527
  $r .= '<input type="hidden" name="topic_id" value="' . $topic->topic_id . '" />' . "\n";
1528
  $r .= '<label for="forum-id">'. __( 'Move to' ) . '</label>' . "\n";
1529
  $r .= $dropdown . "\n";
1530
  $r .= bb_nonce_field( 'move-topic_' . $topic->topic_id, '_wpnonce', true , false );
1531
  $r .= '<input type="submit" name="Submit" value="' . __( 'Move' ) . '" />' . "\n";
1532
+ $r .= '</div></fieldset></form>' . $after;
 
 
1533
 
1534
  return $r;
1535
  }
3502
  case 'mysql' :
3503
  $format = 'Y-m-d H:i:s';
3504
  break;
3505
+ case 'datetime' :
3506
+ $format = bb_get_option( 'datetime_format' );
3507
+ break;
3508
  endswitch;
3509
 
3510
  if ( $args['localize'] ) {
bp-forums/bbpress/bb-includes/functions.bb-users.php CHANGED
@@ -252,37 +252,48 @@ function bb_update_user( $user_id, $user_email, $user_url, $display_name ) {
252
  * @param string $user_login
253
  * @return bool
254
  */
255
- function bb_reset_email( $user_login ) {
 
256
  global $bbdb;
257
 
258
  $user_login = sanitize_user( $user_login, true );
259
 
260
- if ( !$user = $bbdb->get_row( $bbdb->prepare( "SELECT * FROM $bbdb->users WHERE user_login = %s", $user_login ) ) )
261
- return new WP_Error('user_does_not_exist', __('The specified user does not exist.'));
 
262
 
263
- $resetkey = substr(md5(bb_generate_password()), 0, 15);
264
  bb_update_usermeta( $user->ID, 'newpwdkey', $resetkey );
265
 
 
 
 
 
 
 
266
  $message = sprintf(
267
- __("If you wanted to reset your password, you may do so by visiting the following address:\n\n%s\n\nIf you don't want to reset your password, just ignore this email. Thanks!"),
268
- bb_get_uri(
269
- 'bb-reset-password.php',
270
- array('key' => $resetkey),
271
- BB_URI_CONTEXT_TEXT + BB_URI_CONTEXT_BB_USER_FORMS
272
- )
 
 
273
  );
 
274
 
275
  $mail_result = bb_mail(
276
  bb_get_user_email( $user->ID ),
277
- bb_get_option('name') . ': ' . __('Password Reset'),
278
  $message
279
  );
280
 
281
- if (!$mail_result) {
282
- return new WP_Error('sending_mail_failed', __('The email containing the password reset link could not be sent.'));
283
- } else {
284
- return true;
285
  }
 
 
286
  }
287
 
288
  /**
@@ -297,29 +308,42 @@ function bb_reset_email( $user_login ) {
297
  * @param string $key
298
  * @return unknown
299
  */
300
- function bb_reset_password( $key ) {
 
301
  global $bbdb;
 
302
  $key = sanitize_user( $key, true );
303
- if ( empty( $key ) )
304
- return new WP_Error('key_not_found', __('Key not found.'));
305
- if ( !$user_id = $bbdb->get_var( $bbdb->prepare( "SELECT user_id FROM $bbdb->usermeta WHERE meta_key = 'newpwdkey' AND meta_value = %s", $key ) ) )
306
- return new WP_Error('key_not_found', __('Key not found.'));
307
- if ( $user = new BP_User( $user_id ) ) {
308
- if ( bb_has_broken_pass( $user->ID ) )
309
- bb_block_current_user();
310
- if ( !$user->has_cap( 'change_user_password', $user->ID ) )
311
- return new WP_Error('permission_denied', __('You are not allowed to change your password.'));
312
- $newpass = bb_generate_password();
313
- bb_update_user_password( $user->ID, $newpass );
314
- if (!bb_send_pass( $user->ID, $newpass )) {
315
- return new WP_Error('sending_mail_failed', __('The email containing the new password could not be sent.'));
316
- } else {
317
- bb_update_usermeta( $user->ID, 'newpwdkey', '' );
318
- return true;
319
- }
320
- } else {
321
- return new WP_Error('key_not_found', __('Key not found.'));
322
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
323
  }
324
 
325
  /**
@@ -357,16 +381,30 @@ function bb_update_user_password( $user_id, $password ) {
357
  * @param string $pass
358
  * @return bool
359
  */
360
- function bb_send_pass( $user, $pass ) {
361
- if ( !$user = bb_get_user( $user ) )
 
362
  return false;
 
363
 
364
- $message = __("Your username is: %1\$s \nYour password is: %2\$s \nYou can now log in: %3\$s \n\nEnjoy!");
 
 
 
 
 
 
 
 
 
 
 
 
365
 
366
  return bb_mail(
367
  bb_get_user_email( $user->ID ),
368
- bb_get_option('name') . ': ' . __('Password'),
369
- sprintf($message, $user->user_login, $pass, bb_get_uri(null, null, BB_URI_CONTEXT_TEXT))
370
  );
371
  }
372
 
252
  * @param string $user_login
253
  * @return bool
254
  */
255
+ function bb_reset_email( $user_login )
256
+ {
257
  global $bbdb;
258
 
259
  $user_login = sanitize_user( $user_login, true );
260
 
261
+ if ( !$user = $bbdb->get_row( $bbdb->prepare( "SELECT * FROM $bbdb->users WHERE user_login = %s", $user_login ) ) ) {
262
+ return new WP_Error( 'user_does_not_exist', __( 'The specified user does not exist.' ) );
263
+ }
264
 
265
+ $resetkey = substr( md5( bb_generate_password() ), 0, 15 );
266
  bb_update_usermeta( $user->ID, 'newpwdkey', $resetkey );
267
 
268
+ $reseturi = bb_get_uri(
269
+ 'bb-reset-password.php',
270
+ array( 'key' => $resetkey ),
271
+ BB_URI_CONTEXT_TEXT + BB_URI_CONTEXT_BB_USER_FORMS
272
+ );
273
+
274
  $message = sprintf(
275
+ __( "If you wanted to reset your password, you may do so by visiting the following address:\n\n%s\n\nIf you don't want to reset your password, just ignore this email. Thanks!" ),
276
+ $reseturi
277
+ );
278
+ $message = apply_filters( 'bb_reset_email_message', $message, $user, $reseturi, $resetkey );
279
+
280
+ $subject = sprintf(
281
+ __( '%s: Password Reset' ),
282
+ bb_get_option( 'name' )
283
  );
284
+ $subject = apply_filters( 'bb_reset_email_subject', $subject, $user );
285
 
286
  $mail_result = bb_mail(
287
  bb_get_user_email( $user->ID ),
288
+ $subject,
289
  $message
290
  );
291
 
292
+ if ( !$mail_result ) {
293
+ return new WP_Error( 'sending_mail_failed', __( 'The email containing the password reset link could not be sent.' ) );
 
 
294
  }
295
+
296
+ return true;
297
  }
298
 
299
  /**
308
  * @param string $key
309
  * @return unknown
310
  */
311
+ function bb_reset_password( $key )
312
+ {
313
  global $bbdb;
314
+
315
  $key = sanitize_user( $key, true );
316
+
317
+ if ( empty( $key ) || !is_string( $key ) ) {
318
+ return new WP_Error( 'invalid_key', __( 'Invalid key' ) );
319
+ }
320
+
321
+ if ( !$user_id = $bbdb->get_var( $bbdb->prepare( "SELECT user_id FROM $bbdb->usermeta WHERE meta_key = 'newpwdkey' AND meta_value = %s", $key ) ) ) {
322
+ return new WP_Error( 'invalid_key', __( 'Invalid key' ) );
323
+ }
324
+
325
+ $user = new BP_User( $user_id );
326
+
327
+ if ( !$user || is_wp_error( $user ) ) {
328
+ return new WP_Error( 'invalid_key', __( 'Invalid key' ) );
 
 
 
 
 
 
329
  }
330
+
331
+ if ( bb_has_broken_pass( $user->ID ) ) {
332
+ bb_block_current_user();
333
+ }
334
+
335
+ if ( !$user->has_cap( 'change_user_password', $user->ID ) ) {
336
+ return new WP_Error( 'permission_denied', __( 'You are not allowed to change your password.' ) );
337
+ }
338
+
339
+ $newpass = bb_generate_password();
340
+ bb_update_user_password( $user->ID, $newpass );
341
+ if ( !bb_send_pass( $user->ID, $newpass ) ) {
342
+ return new WP_Error( 'sending_mail_failed', __( 'The email containing the new password could not be sent.' ) );
343
+ }
344
+
345
+ bb_update_usermeta( $user->ID, 'newpwdkey', '' );
346
+ return true;
347
  }
348
 
349
  /**
381
  * @param string $pass
382
  * @return bool
383
  */
384
+ function bb_send_pass( $user, $pass )
385
+ {
386
+ if ( !$user = bb_get_user( $user ) ) {
387
  return false;
388
+ }
389
 
390
+ $message = sprintf(
391
+ __( "Your username is: %1\$s \nYour password is: %2\$s \nYou can now log in: %3\$s \n\nEnjoy!" ),
392
+ $user->user_login,
393
+ $pass,
394
+ bb_get_uri( null, null, BB_URI_CONTEXT_TEXT )
395
+ );
396
+ $message = apply_filters( 'bb_send_pass_message', $message, $user, $pass );
397
+
398
+ $subject = sprintf(
399
+ __( '%s: Password' ),
400
+ bb_get_option( 'name' )
401
+ );
402
+ $subject = apply_filters( 'bb_send_pass_subject', $subject, $user );
403
 
404
  return bb_mail(
405
  bb_get_user_email( $user->ID ),
406
+ $subject,
407
+ $message
408
  );
409
  }
410
 
bp-forums/bbpress/bb-includes/js/jquery/interface.js CHANGED
@@ -1,12 +1,13 @@
1
- /**
2
- * Interface Elements for jQuery
3
- *
4
- * http://interface.eyecon.ro
5
- *
6
- * Copyright (c) 2006 Stefan Petre
7
- * Dual licensed under the MIT (MIT-LICENSE.txt)
8
- * and GPL (GPL-LICENSE.txt) licenses.
9
- *
10
- *
11
- */
 
12
  eval(function(p,a,c,k,e,d){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--){d[e(c)]=k[c]||e(c)}k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1};while(c--){if(k[c]){p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c])}}return p}('k.f2={2r:u(M){E q.1E(u(){if(!M.aR||!M.aZ)E;D el=q;el.2l={aq:M.aq||cO,aR:M.aR,aZ:M.aZ,8e:M.8e||\'fV\',aJ:M.aJ||\'fV\',2Y:M.2Y&&2g M.2Y==\'u\'?M.2Y:I,3i:M.2Y&&2g M.3i==\'u\'?M.3i:I,7U:M.7U&&2g M.7U==\'u\'?M.7U:I,as:k(M.aR,q),8f:k(M.aZ,q),H:M.H||8J,67:M.67||0};el.2l.8f.2G().B(\'W\',\'9R\').eq(0).B({W:el.2l.aq+\'U\',19:\'2B\'}).2T();el.2l.as.1E(u(2N){q.7X=2N}).gC(u(){k(q).2R(el.2l.aJ)},u(){k(q).4i(el.2l.aJ)}).1J(\'5h\',u(e){if(el.2l.67==q.7X)E;el.2l.as.eq(el.2l.67).4i(el.2l.8e).2T().eq(q.7X).2R(el.2l.8e).2T();el.2l.8f.eq(el.2l.67).5w({W:0},el.2l.H,u(){q.14.19=\'1o\';if(el.2l.3i){el.2l.3i.1D(el,[q])}}).2T().eq(q.7X).1Y().5w({W:el.2l.aq},el.2l.H,u(){q.14.19=\'2B\';if(el.2l.2Y){el.2l.2Y.1D(el,[q])}}).2T();if(el.2l.7U){el.2l.7U.1D(el,[q,el.2l.8f.K(q.7X),el.2l.as.K(el.2l.67),el.2l.8f.K(el.2l.67)])}el.2l.67=q.7X}).eq(0).2R(el.2l.8e).2T();k(q).B(\'W\',k(q).B(\'W\')).B(\'2U\',\'2K\')})}};k.fn.gN=k.f2.2r;k.aA={2r:u(M){E q.1E(u(){D el=q;D 7E=2*18.2Q/f1;D an=2*18.2Q;if(k(el).B(\'Y\')!=\'2s\'&&k(el).B(\'Y\')!=\'1P\'){k(el).B(\'Y\',\'2s\')}el.1l={1R:k(M.1R,q),2F:M.2F,6q:M.6q,aD:M.aD,an:an,1N:k.1a.2o(q),Y:k.1a.3w(q),26:18.2Q/2,bi:M.bi,8p:M.6r,6r:[],aG:I,7E:2*18.2Q/f1};el.1l.fB=(el.1l.1N.w-el.1l.2F)/2;el.1l.7D=(el.1l.1N.h-el.1l.6q-el.1l.6q*el.1l.8p)/2;el.1l.2D=2*18.2Q/el.1l.1R.1N();el.1l.ba=el.1l.1N.w/2;el.1l.b9=el.1l.1N.h/2-el.1l.6q*el.1l.8p;D ak=1h.3F(\'22\');k(ak).B({Y:\'1P\',3I:1,Q:0,O:0});k(el).1S(ak);el.1l.1R.1E(u(2N){a6=k(\'1T\',q).K(0);W=T(el.1l.6q*el.1l.8p);if(k.3a.4t){3E=1h.3F(\'1T\');k(3E).B(\'Y\',\'1P\');3E.2J=a6.2J;3E.14.5E=\'gE 9n:9w.9y.cC(1G=60, 14=1, gB=0, gA=0, gv=0, gF=0)\'}P{3E=1h.3F(\'3E\');if(3E.fD){4L=3E.fD("2d");3E.14.Y=\'1P\';3E.14.W=W+\'U\';3E.14.Z=el.1l.2F+\'U\';3E.W=W;3E.Z=el.1l.2F;4L.gu();4L.gO(0,W);4L.gk(1,-1);4L.gp(a6,0,0,el.1l.2F,W);4L.6H();4L.gm="gG-4l";D ap=4L.hy(0,0,0,W);ap.fs(1,"fr(1V, 1V, 1V, 1)");ap.fs(0,"fr(1V, 1V, 1V, 0.6)");4L.hx=ap;if(hA.hB.3J(\'hw\')!=-1){4L.hv()}P{4L.hu(0,0,el.1l.2F,W)}}}el.1l.6r[2N]=3E;k(ak).1S(3E)}).1J(\'9z\',u(e){el.1l.aG=1b;el.1l.H=el.1l.7E*0.1*el.1l.H/18.3S(el.1l.H);E I}).1J(\'8B\',u(e){el.1l.aG=I;E I});k.aA.7T(el);el.1l.H=el.1l.7E*0.2;el.1l.ht=1X.6V(u(){el.1l.26+=el.1l.H;if(el.1l.26>an)el.1l.26=0;k.aA.7T(el)},20);k(el).1J(\'8B\',u(){el.1l.H=el.1l.7E*0.2*el.1l.H/18.3S(el.1l.H)}).1J(\'3D\',u(e){if(el.1l.aG==I){1s=k.1a.4a(e);fz=el.1l.1N.w-1s.x+el.1l.Y.x;el.1l.H=el.1l.bi*el.1l.7E*(el.1l.1N.w/2-fz)/(el.1l.1N.w/2)}})})},7T:u(el){el.1l.1R.1E(u(2N){b8=el.1l.26+2N*el.1l.2D;x=el.1l.fB*18.5H(b8);y=el.1l.7D*18.83(b8);f9=T(2a*(el.1l.7D+y)/(2*el.1l.7D));fk=(el.1l.7D+y)/(2*el.1l.7D);Z=T((el.1l.2F-el.1l.aD)*fk+el.1l.aD);W=T(Z*el.1l.6q/el.1l.2F);q.14.Q=el.1l.b9+y-W/2+"U";q.14.O=el.1l.ba+x-Z/2+"U";q.14.Z=Z+"U";q.14.W=W+"U";q.14.3I=f9;el.1l.6r[2N].14.Q=T(el.1l.b9+y+W-1-W/2)+"U";el.1l.6r[2N].14.O=T(el.1l.ba+x-Z/2)+"U";el.1l.6r[2N].14.Z=Z+"U";el.1l.6r[2N].14.W=T(W*el.1l.8p)+"U"})}};k.fn.hI=k.aA.2r;k.23({G:{c8:u(p,n,1W,1H,1m){E((-18.5H(p*18.2Q)/2)+0.5)*1H+1W},hK:u(p,n,1W,1H,1m){E 1H*(n/=1m)*n*n+1W},fl:u(p,n,1W,1H,1m){E-1H*((n=n/1m-1)*n*n*n-1)+1W},hm:u(p,n,1W,1H,1m){if((n/=1m/2)<1)E 1H/2*n*n*n*n+1W;E-1H/2*((n-=2)*n*n*n-2)+1W},8l:u(p,n,1W,1H,1m){if((n/=1m)<(1/2.75)){E 1H*(7.aB*n*n)+1W}P if(n<(2/2.75)){E 1H*(7.aB*(n-=(1.5/2.75))*n+.75)+1W}P if(n<(2.5/2.75)){E 1H*(7.aB*(n-=(2.25/2.75))*n+.gY)+1W}P{E 1H*(7.aB*(n-=(2.h2/2.75))*n+.gX)+1W}},cr:u(p,n,1W,1H,1m){if(k.G.8l)E 1H-k.G.8l(p,1m-n,0,1H,1m)+1W;E 1W+1H},gW:u(p,n,1W,1H,1m){if(k.G.cr&&k.G.8l)if(n<1m/2)E k.G.cr(p,n*2,0,1H,1m)*.5+1W;E k.G.8l(p,n*2-1m,0,1H,1m)*.5+1H*.5+1W;E 1W+1H},gQ:u(p,n,1W,1H,1m){D a,s;if(n==0)E 1W;if((n/=1m)==1)E 1W+1H;a=1H*0.3;p=1m*.3;if(a<18.3S(1H)){a=1H;s=p/4}P{s=p/(2*18.2Q)*18.cb(1H/a)}E-(a*18.6b(2,10*(n-=1))*18.83((n*1m-s)*(2*18.2Q)/p))+1W},gT:u(p,n,1W,1H,1m){D a,s;if(n==0)E 1W;if((n/=1m/2)==2)E 1W+1H;a=1H*0.3;p=1m*.3;if(a<18.3S(1H)){a=1H;s=p/4}P{s=p/(2*18.2Q)*18.cb(1H/a)}E a*18.6b(2,-10*n)*18.83((n*1m-s)*(2*18.2Q)/p)+1H+1W},gV:u(p,n,1W,1H,1m){D a,s;if(n==0)E 1W;if((n/=1m/2)==2)E 1W+1H;a=1H*0.3;p=1m*.3;if(a<18.3S(1H)){a=1H;s=p/4}P{s=p/(2*18.2Q)*18.cb(1H/a)}if(n<1){E-.5*(a*18.6b(2,10*(n-=1))*18.83((n*1m-s)*(2*18.2Q)/p))+1W}E a*18.6b(2,-10*(n-=1))*18.83((n*1m-s)*(2*18.2Q)/p)*.5+1H+1W}}});k.6n={2r:u(M){E q.1E(u(){D el=q;el.1F={1R:k(M.1R,q),1Z:k(M.1Z,q),1M:k.1a.3w(q),2F:M.2F,ax:M.ax,7Y:M.7Y,ge:M.ge,51:M.51,6x:M.6x};k.6n.aH(el,0);k(1X).1J(\'gU\',u(){el.1F.1M=k.1a.3w(el);k.6n.aH(el,0);k.6n.7T(el)});k.6n.7T(el);el.1F.1R.1J(\'9z\',u(){k(el.1F.ax,q).K(0).14.19=\'2B\'}).1J(\'8B\',u(){k(el.1F.ax,q).K(0).14.19=\'1o\'});k(1h).1J(\'3D\',u(e){D 1s=k.1a.4a(e);D 5s=0;if(el.1F.51&&el.1F.51==\'cv\')D aI=1s.x-el.1F.1M.x-(el.4c-el.1F.2F*el.1F.1R.1N())/2-el.1F.2F/2;P if(el.1F.51&&el.1F.51==\'2L\')D aI=1s.x-el.1F.1M.x-el.4c+el.1F.2F*el.1F.1R.1N();P D aI=1s.x-el.1F.1M.x;D fP=18.6b(1s.y-el.1F.1M.y-el.5W/2,2);el.1F.1R.1E(u(2N){45=18.ez(18.6b(aI-2N*el.1F.2F,2)+fP);45-=el.1F.2F/2;45=45<0?0:45;45=45>el.1F.7Y?el.1F.7Y:45;45=el.1F.7Y-45;bB=el.1F.6x*45/el.1F.7Y;q.14.Z=el.1F.2F+bB+\'U\';q.14.O=el.1F.2F*2N+5s+\'U\';5s+=bB});k.6n.aH(el,5s)})})},aH:u(el,5s){if(el.1F.51)if(el.1F.51==\'cv\')el.1F.1Z.K(0).14.O=(el.4c-el.1F.2F*el.1F.1R.1N())/2-5s/2+\'U\';P if(el.1F.51==\'O\')el.1F.1Z.K(0).14.O=-5s/el.1F.1R.1N()+\'U\';P if(el.1F.51==\'2L\')el.1F.1Z.K(0).14.O=(el.4c-el.1F.2F*el.1F.1R.1N())-5s/2+\'U\';el.1F.1Z.K(0).14.Z=el.1F.2F*el.1F.1R.1N()+5s+\'U\'},7T:u(el){el.1F.1R.1E(u(2N){q.14.Z=el.1F.2F+\'U\';q.14.O=el.1F.2F*2N+\'U\'})}};k.fn.hi=k.6n.2r;k.N={1c:S,8R:S,3A:S,2I:S,4y:S,cl:S,1d:S,2h:S,1R:S,5o:u(){k.N.8R.5o();if(k.N.3A){k.N.3A.2G()}},4w:u(){k.N.1R=S;k.N.2h=S;k.N.4y=k.N.1d.2y;if(k.N.1c.B(\'19\')==\'2B\'){if(k.N.1d.1f.fx){3m(k.N.1d.1f.fx.1u){1e\'c6\':k.N.1c.7a(k.N.1d.1f.fx.1m,k.N.5o);1r;1e\'1z\':k.N.1c.fq(k.N.1d.1f.fx.1m,k.N.5o);1r;1e\'a7\':k.N.1c.g3(k.N.1d.1f.fx.1m,k.N.5o);1r}}P{k.N.1c.2G()}if(k.N.1d.1f.3i)k.N.1d.1f.3i.1D(k.N.1d,[k.N.1c,k.N.3A])}P{k.N.5o()}1X.bH(k.N.2I)},dQ:u(){D 1d=k.N.1d;D 4d=k.N.aY(1d);if(1d&&4d.3o!=k.N.4y&&4d.3o.1g>=1d.1f.aL){k.N.4y=4d.3o;k.N.cl=4d.3o;81={2n:k(1d).1p(\'hj\')||\'2n\',2y:4d.3o};k.hl({1u:\'hk\',81:k.hf(81),he:u(fZ){1d.1f.4e=k(\'3o\',fZ);1N=1d.1f.4e.1N();if(1N>0){D 5p=\'\';1d.1f.4e.1E(u(2N){5p+=\'<8P 4I="\'+k(\'2y\',q).3g()+\'" 8K="\'+2N+\'" 14="9b: ad;">\'+k(\'3g\',q).3g()+\'</8P>\'});if(1d.1f.aU){D 3M=k(\'2y\',1d.1f.4e.K(0)).3g();1d.2y=4d.3j+3M+1d.1f.3N+4d.66;k.N.6J(1d,4d.3o.1g!=3M.1g?(4d.3j.1g+4d.3o.1g):3M.1g,4d.3o.1g!=3M.1g?(4d.3j.1g+3M.1g):3M.1g)}if(1N>0){k.N.cj(1d,5p)}P{k.N.4w()}}P{k.N.4w()}},5N:1d.1f.aN})}},cj:u(1d,5p){k.N.8R.3x(5p);k.N.1R=k(\'8P\',k.N.8R.K(0));k.N.1R.9z(k.N.di).1J(\'5h\',k.N.dj);D Y=k.1a.3w(1d);D 1N=k.1a.2o(1d);k.N.1c.B(\'Q\',Y.y+1N.hb+\'U\').B(\'O\',Y.x+\'U\').2R(1d.1f.aM);if(k.N.3A){k.N.3A.B(\'19\',\'2B\').B(\'Q\',Y.y+1N.hb+\'U\').B(\'O\',Y.x+\'U\').B(\'Z\',k.N.1c.B(\'Z\')).B(\'W\',k.N.1c.B(\'W\'))}k.N.2h=0;k.N.1R.K(0).3l=1d.1f.7H;k.N.8Q(1d,1d.1f.4e.K(0),\'7J\');if(k.N.1c.B(\'19\')==\'1o\'){if(1d.1f.bV){D cp=k.1a.aT(1d,1b);D cm=k.1a.6U(1d,1b);k.N.1c.B(\'Z\',1d.4c-(k.dF?(cp.l+cp.r+cm.l+cm.r):0)+\'U\')}if(1d.1f.fx){3m(1d.1f.fx.1u){1e\'c6\':k.N.1c.7f(1d.1f.fx.1m);1r;1e\'1z\':k.N.1c.fo(1d.1f.fx.1m);1r;1e\'a7\':k.N.1c.gb(1d.1f.fx.1m);1r}}P{k.N.1c.1Y()}if(k.N.1d.1f.2Y)k.N.1d.1f.2Y.1D(k.N.1d,[k.N.1c,k.N.3A])}},dO:u(){D 1d=q;if(1d.1f.4e){k.N.4y=1d.2y;k.N.cl=1d.2y;D 5p=\'\';1d.1f.4e.1E(u(2N){2y=k(\'2y\',q).3g().6c();fY=1d.2y.6c();if(2y.3J(fY)==0){5p+=\'<8P 4I="\'+k(\'2y\',q).3g()+\'" 8K="\'+2N+\'" 14="9b: ad;">\'+k(\'3g\',q).3g()+\'</8P>\'}});if(5p!=\'\'){k.N.cj(1d,5p);q.1f.9x=1b;E}}1d.1f.4e=S;q.1f.9x=I},6J:u(2n,26,2T){if(2n.b1){D 6t=2n.b1();6t.hp(1b);6t.dI("ck",26);6t.ha("ck",-2T+26);6t.8C()}P if(2n.aF){2n.aF(26,2T)}P{if(2n.5q){2n.5q=26;2n.dN=2T}}2n.6K()},f0:u(2n){if(2n.5q)E 2n.5q;P if(2n.b1){D 6t=1h.6J.dZ();D eX=6t.h9();E 0-eX.dI(\'ck\',-h6)}},aY:u(2n){D 4P={2y:2n.2y,3j:\'\',66:\'\',3o:\'\'};if(2n.1f.aQ){D 8N=I;D 5q=k.N.f0(2n)||0;D 4T=4P.2y.7C(2n.1f.3N);24(D i=0;i<4T.1g;i++){if((4P.3j.1g+4T[i].1g>=5q||5q==0)&&!8N){if(4P.3j.1g<=5q)4P.3o=4T[i];P 4P.66+=4T[i]+(4T[i]!=\'\'?2n.1f.3N:\'\');8N=1b}P if(8N){4P.66+=4T[i]+(4T[i]!=\'\'?2n.1f.3N:\'\')}if(!8N){4P.3j+=4T[i]+(4T.1g>1?2n.1f.3N:\'\')}}}P{4P.3o=4P.2y}E 4P},bU:u(e){1X.bH(k.N.2I);D 1d=k.N.aY(q);D 3K=e.7L||e.7K||-1;if(/13|27|35|36|38|40|9/.48(3K)&&k.N.1R){if(1X.2k){1X.2k.bT=1b;1X.2k.c0=I}P{e.aP();e.aW()}if(k.N.2h!=S)k.N.1R.K(k.N.2h||0).3l=\'\';P k.N.2h=-1;3m(3K){1e 9:1e 13:if(k.N.2h==-1)k.N.2h=0;D 2h=k.N.1R.K(k.N.2h||0);D 3M=2h.5C(\'4I\');q.2y=1d.3j+3M+q.1f.3N+1d.66;k.N.4y=1d.3o;k.N.6J(q,1d.3j.1g+3M.1g+q.1f.3N.1g,1d.3j.1g+3M.1g+q.1f.3N.1g);k.N.4w();if(q.1f.68){4u=T(2h.5C(\'8K\'))||0;k.N.8Q(q,q.1f.4e.K(4u),\'68\')}if(q.7W)q.7W(I);E 3K!=13;1r;1e 27:q.2y=1d.3j+k.N.4y+q.1f.3N+1d.66;q.1f.4e=S;k.N.4w();if(q.7W)q.7W(I);E I;1r;1e 35:k.N.2h=k.N.1R.1N()-1;1r;1e 36:k.N.2h=0;1r;1e 38:k.N.2h--;if(k.N.2h<0)k.N.2h=k.N.1R.1N()-1;1r;1e 40:k.N.2h++;if(k.N.2h==k.N.1R.1N())k.N.2h=0;1r}k.N.8Q(q,q.1f.4e.K(k.N.2h||0),\'7J\');k.N.1R.K(k.N.2h||0).3l=q.1f.7H;if(k.N.1R.K(k.N.2h||0).7W)k.N.1R.K(k.N.2h||0).7W(I);if(q.1f.aU){D aK=k.N.1R.K(k.N.2h||0).5C(\'4I\');q.2y=1d.3j+aK+q.1f.3N+1d.66;if(k.N.4y.1g!=aK.1g)k.N.6J(q,1d.3j.1g+k.N.4y.1g,1d.3j.1g+aK.1g)}E I}k.N.dO.1D(q);if(q.1f.9x==I){if(1d.3o!=k.N.4y&&1d.3o.1g>=q.1f.aL)k.N.2I=1X.9T(k.N.dQ,q.1f.54);if(k.N.1R){k.N.4w()}}E 1b},8Q:u(2n,3o,1u){if(2n.1f[1u]){D 81={};ar=3o.f3(\'*\');24(i=0;i<ar.1g;i++){81[ar[i].4Y]=ar[i].7c.h4}2n.1f[1u].1D(2n,[81])}},di:u(e){if(k.N.1R){if(k.N.2h!=S)k.N.1R.K(k.N.2h||0).3l=\'\';k.N.1R.K(k.N.2h||0).3l=\'\';k.N.2h=T(q.5C(\'8K\'))||0;k.N.1R.K(k.N.2h||0).3l=k.N.1d.1f.7H}},dj:u(2k){1X.bH(k.N.2I);2k=2k||k.2k.gS(1X.2k);2k.aP();2k.aW();D 1d=k.N.aY(k.N.1d);D 3M=q.5C(\'4I\');k.N.1d.2y=1d.3j+3M+k.N.1d.1f.3N+1d.66;k.N.4y=q.5C(\'4I\');k.N.6J(k.N.1d,1d.3j.1g+3M.1g+k.N.1d.1f.3N.1g,1d.3j.1g+3M.1g+k.N.1d.1f.3N.1g);k.N.4w();if(k.N.1d.1f.68){4u=T(q.5C(\'8K\'))||0;k.N.8Q(k.N.1d,k.N.1d.1f.4e.K(4u),\'68\')}E I},eJ:u(e){3K=e.7L||e.7K||-1;if(/13|27|35|36|38|40/.48(3K)&&k.N.1R){if(1X.2k){1X.2k.bT=1b;1X.2k.c0=I}P{e.aP();e.aW()}E I}},2r:u(M){if(!M.aN||!k.1a){E}if(!k.N.1c){if(k.3a.4t){k(\'2e\',1h).1S(\'<3A 14="19:1o;Y:1P;5E:9n:9w.9y.cC(1G=0);" id="ds" 2J="ek:I;" ej="0" ep="cD"></3A>\');k.N.3A=k(\'#ds\')}k(\'2e\',1h).1S(\'<22 id="dr" 14="Y: 1P; Q: 0; O: 0; z-cZ: h3; 19: 1o;"><9h 14="6w: 0;8F: 0; h1-14: 1o; z-cZ: h0;">&7k;</9h></22>\');k.N.1c=k(\'#dr\');k.N.8R=k(\'9h\',k.N.1c)}E q.1E(u(){if(q.4Y!=\'ch\'&&q.5C(\'1u\')!=\'3g\')E;q.1f={};q.1f.aN=M.aN;q.1f.aL=18.3S(T(M.aL)||1);q.1f.aM=M.aM?M.aM:\'\';q.1f.7H=M.7H?M.7H:\'\';q.1f.68=M.68&&M.68.1K==2A?M.68:S;q.1f.2Y=M.2Y&&M.2Y.1K==2A?M.2Y:S;q.1f.3i=M.3i&&M.3i.1K==2A?M.3i:S;q.1f.7J=M.7J&&M.7J.1K==2A?M.7J:S;q.1f.bV=M.bV||I;q.1f.aQ=M.aQ||I;q.1f.3N=q.1f.aQ?(M.3N||\', \'):\'\';q.1f.aU=M.aU?1b:I;q.1f.54=18.3S(T(M.54)||aC);if(M.fx&&M.fx.1K==7M){if(!M.fx.1u||!/c6|1z|a7/.48(M.fx.1u)){M.fx.1u=\'1z\'}if(M.fx.1u==\'1z\'&&!k.fx.1z)E;if(M.fx.1u==\'a7\'&&!k.fx.61)E;M.fx.1m=18.3S(T(M.fx.1m)||8J);if(M.fx.1m>q.1f.54){M.fx.1m=q.1f.54-2a}q.1f.fx=M.fx}q.1f.4e=S;q.1f.9x=I;k(q).1p(\'bU\',\'eN\').6K(u(){k.N.1d=q;k.N.4y=q.2y}).dH(k.N.eJ).6y(k.N.bU).5B(u(){k.N.2I=1X.9T(k.N.4w,hM)})})}};k.fn.hR=k.N.2r;k.1y={2I:S,4Q:S,29:S,2D:10,26:u(el,4J,2D,eG){k.1y.4Q=el;k.1y.29=4J;k.1y.2D=T(2D)||10;k.1y.2I=1X.6V(k.1y.eF,T(eG)||40)},eF:u(){24(i=0;i<k.1y.29.1g;i++){if(!k.1y.29[i].2X){k.1y.29[i].2X=k.23(k.1a.7G(k.1y.29[i]),k.1a.74(k.1y.29[i]),k.1a.6z(k.1y.29[i]))}P{k.1y.29[i].2X.t=k.1y.29[i].3d;k.1y.29[i].2X.l=k.1y.29[i].3c}if(k.1y.4Q.A&&k.1y.4Q.A.7q==1b){69={x:k.1y.4Q.A.2v,y:k.1y.4Q.A.2q,1C:k.1y.4Q.A.1B.1C,hb:k.1y.4Q.A.1B.hb}}P{69=k.23(k.1a.7G(k.1y.4Q),k.1a.74(k.1y.4Q))}if(k.1y.29[i].2X.t>0&&k.1y.29[i].2X.y+k.1y.29[i].2X.t>69.y){k.1y.29[i].3d-=k.1y.2D}P if(k.1y.29[i].2X.t<=k.1y.29[i].2X.h&&k.1y.29[i].2X.t+k.1y.29[i].2X.hb<69.y+69.hb){k.1y.29[i].3d+=k.1y.2D}if(k.1y.29[i].2X.l>0&&k.1y.29[i].2X.x+k.1y.29[i].2X.l>69.x){k.1y.29[i].3c-=k.1y.2D}P if(k.1y.29[i].2X.l<=k.1y.29[i].2X.hP&&k.1y.29[i].2X.l+k.1y.29[i].2X.1C<69.x+69.1C){k.1y.29[i].3c+=k.1y.2D}}},8o:u(){1X.5T(k.1y.2I);k.1y.4Q=S;k.1y.29=S;24(i in k.1y.29){k.1y.29[i].2X=S}}};k.11={1c:S,F:S,4U:u(){E q.1E(u(){if(q.9I){q.A.5e.3q(\'5v\',k.11.bN);q.A=S;q.9I=I;if(k.3a.4t){q.bE="eN"}P{q.14.hq=\'\';q.14.e1=\'\';q.14.e7=\'\'}}})},bN:u(e){if(k.11.F!=S){k.11.9A(e);E I}D C=q.3U;k(1h).1J(\'3D\',k.11.bX).1J(\'5P\',k.11.9A);C.A.1s=k.1a.4a(e);C.A.4B=C.A.1s;C.A.7q=I;C.A.ho=q!=q.3U;k.11.F=C;if(C.A.5i&&q!=q.3U){bS=k.1a.3w(C.31);bQ=k.1a.2o(C);bR={x:T(k.B(C,\'O\'))||0,y:T(k.B(C,\'Q\'))||0};dx=C.A.4B.x-bS.x-bQ.1C/2-bR.x;dy=C.A.4B.y-bS.y-bQ.hb/2-bR.y;k.3b.5c(C,[dx,dy])}E k.7n||I},ea:u(e){D C=k.11.F;C.A.7q=1b;D 9G=C.14;C.A.7V=k.B(C,\'19\');C.A.4n=k.B(C,\'Y\');if(!C.A.cz)C.A.cz=C.A.4n;C.A.2c={x:T(k.B(C,\'O\'))||0,y:T(k.B(C,\'Q\'))||0};C.A.9B=0;C.A.ai=0;if(k.3a.4t){D bW=k.1a.6U(C,1b);C.A.9B=bW.l||0;C.A.ai=bW.t||0}C.A.1B=k.23(k.1a.3w(C),k.1a.2o(C));if(C.A.4n!=\'2s\'&&C.A.4n!=\'1P\'){9G.Y=\'2s\'}k.11.1c.5o();D 5g=C.fI(1b);k(5g).B({19:\'2B\',O:\'2P\',Q:\'2P\'});5g.14.5K=\'0\';5g.14.5z=\'0\';5g.14.5k=\'0\';5g.14.5j=\'0\';k.11.1c.1S(5g);D 3Y=k.11.1c.K(0).14;if(C.A.bD){3Y.Z=\'9F\';3Y.W=\'9F\'}P{3Y.W=C.A.1B.hb+\'U\';3Y.Z=C.A.1B.1C+\'U\'}3Y.19=\'2B\';3Y.5K=\'2P\';3Y.5z=\'2P\';3Y.5k=\'2P\';3Y.5j=\'2P\';k.23(C.A.1B,k.1a.2o(5g));if(C.A.2V){if(C.A.2V.O){C.A.2c.x+=C.A.1s.x-C.A.1B.x-C.A.2V.O;C.A.1B.x=C.A.1s.x-C.A.2V.O}if(C.A.2V.Q){C.A.2c.y+=C.A.1s.y-C.A.1B.y-C.A.2V.Q;C.A.1B.y=C.A.1s.y-C.A.2V.Q}if(C.A.2V.2L){C.A.2c.x+=C.A.1s.x-C.A.1B.x-C.A.1B.hb+C.A.2V.2L;C.A.1B.x=C.A.1s.x-C.A.1B.1C+C.A.2V.2L}if(C.A.2V.4D){C.A.2c.y+=C.A.1s.y-C.A.1B.y-C.A.1B.hb+C.A.2V.4D;C.A.1B.y=C.A.1s.y-C.A.1B.hb+C.A.2V.4D}}C.A.2v=C.A.2c.x;C.A.2q=C.A.2c.y;if(C.A.8s||C.A.2p==\'94\'){8U=k.1a.6U(C.31,1b);C.A.1B.x=C.8t+(k.3a.4t?0:k.3a.7I?-8U.l:8U.l);C.A.1B.y=C.8G+(k.3a.4t?0:k.3a.7I?-8U.t:8U.t);k(C.31).1S(k.11.1c.K(0))}if(C.A.2p){k.11.c5(C);C.A.5t.2p=k.11.ce}if(C.A.5i){k.3b.ct(C)}3Y.O=C.A.1B.x-C.A.9B+\'U\';3Y.Q=C.A.1B.y-C.A.ai+\'U\';3Y.Z=C.A.1B.1C+\'U\';3Y.W=C.A.1B.hb+\'U\';k.11.F.A.9E=I;if(C.A.gx){C.A.5t.6a=k.11.c7}if(C.A.3I!=I){k.11.1c.B(\'3I\',C.A.3I)}if(C.A.1G){k.11.1c.B(\'1G\',C.A.1G);if(1X.71){k.11.1c.B(\'5E\',\'8V(1G=\'+C.A.1G*2a+\')\')}}if(C.A.7O){k.11.1c.2R(C.A.7O);k.11.1c.K(0).7c.14.19=\'1o\'}if(C.A.4o)C.A.4o.1D(C,[5g,C.A.2c.x,C.A.2c.y]);if(k.1x&&k.1x.8D>0){k.1x.ed(C)}if(C.A.46==I){9G.19=\'1o\'}E I},c5:u(C){if(C.A.2p.1K==b0){if(C.A.2p==\'94\'){C.A.28=k.23({x:0,y:0},k.1a.2o(C.31));D 8S=k.1a.6U(C.31,1b);C.A.28.w=C.A.28.1C-8S.l-8S.r;C.A.28.h=C.A.28.hb-8S.t-8S.b}P if(C.A.2p==\'1h\'){D bY=k.1a.bm();C.A.28={x:0,y:0,w:bY.w,h:bY.h}}}P if(C.A.2p.1K==7F){C.A.28={x:T(C.A.2p[0])||0,y:T(C.A.2p[1])||0,w:T(C.A.2p[2])||0,h:T(C.A.2p[3])||0}}C.A.28.dx=C.A.28.x-C.A.1B.x;C.A.28.dy=C.A.28.y-C.A.1B.y},9H:u(F){if(F.A.8s||F.A.2p==\'94\'){k(\'2e\',1h).1S(k.11.1c.K(0))}k.11.1c.5o().2G().B(\'1G\',1);if(1X.71){k.11.1c.B(\'5E\',\'8V(1G=2a)\')}},9A:u(e){k(1h).3q(\'3D\',k.11.bX).3q(\'5P\',k.11.9A);if(k.11.F==S){E}D F=k.11.F;k.11.F=S;if(F.A.7q==I){E I}if(F.A.44==1b){k(F).B(\'Y\',F.A.4n)}D 9G=F.14;if(F.5i){k.11.1c.B(\'9b\',\'8j\')}if(F.A.7O){k.11.1c.4i(F.A.7O)}if(F.A.6N==I){if(F.A.fx>0){if(!F.A.1O||F.A.1O==\'4j\'){D x=12 k.fx(F,{1m:F.A.fx},\'O\');x.1L(F.A.2c.x,F.A.8y)}if(!F.A.1O||F.A.1O==\'49\'){D y=12 k.fx(F,{1m:F.A.fx},\'Q\');y.1L(F.A.2c.y,F.A.8v)}}P{if(!F.A.1O||F.A.1O==\'4j\')F.14.O=F.A.8y+\'U\';if(!F.A.1O||F.A.1O==\'49\')F.14.Q=F.A.8v+\'U\'}k.11.9H(F);if(F.A.46==I){k(F).B(\'19\',F.A.7V)}}P if(F.A.fx>0){F.A.9E=1b;D dh=I;if(k.1x&&k.1t&&F.A.44){dh=k.1a.3w(k.1t.1c.K(0))}k.11.1c.5w({O:dh?dh.x:F.A.1B.x,Q:dh?dh.y:F.A.1B.y},F.A.fx,u(){F.A.9E=I;if(F.A.46==I){F.14.19=F.A.7V}k.11.9H(F)})}P{k.11.9H(F);if(F.A.46==I){k(F).B(\'19\',F.A.7V)}}if(k.1x&&k.1x.8D>0){k.1x.eO(F)}if(k.1t&&F.A.44){k.1t.fC(F)}if(F.A.2Z&&(F.A.8y!=F.A.2c.x||F.A.8v!=F.A.2c.y)){F.A.2Z.1D(F,F.A.b3||[0,0,F.A.8y,F.A.8v])}if(F.A.3T)F.A.3T.1D(F);E I},c7:u(x,y,dx,dy){if(dx!=0)dx=T((dx+(q.A.gx*dx/18.3S(dx))/2)/q.A.gx)*q.A.gx;if(dy!=0)dy=T((dy+(q.A.gy*dy/18.3S(dy))/2)/q.A.gy)*q.A.gy;E{dx:dx,dy:dy,x:0,y:0}},ce:u(x,y,dx,dy){dx=18.3L(18.3r(dx,q.A.28.dx),q.A.28.w+q.A.28.dx-q.A.1B.1C);dy=18.3L(18.3r(dy,q.A.28.dy),q.A.28.h+q.A.28.dy-q.A.1B.hb);E{dx:dx,dy:dy,x:0,y:0}},bX:u(e){if(k.11.F==S||k.11.F.A.9E==1b){E}D F=k.11.F;F.A.4B=k.1a.4a(e);if(F.A.7q==I){45=18.ez(18.6b(F.A.1s.x-F.A.4B.x,2)+18.6b(F.A.1s.y-F.A.4B.y,2));if(45<F.A.6M){E}P{k.11.ea(e)}}D dx=F.A.4B.x-F.A.1s.x;D dy=F.A.4B.y-F.A.1s.y;24(D i in F.A.5t){D 3y=F.A.5t[i].1D(F,[F.A.2c.x+dx,F.A.2c.y+dy,dx,dy]);if(3y&&3y.1K==7M){dx=i!=\'7R\'?3y.dx:(3y.x-F.A.2c.x);dy=i!=\'7R\'?3y.dy:(3y.y-F.A.2c.y)}}F.A.2v=F.A.1B.x+dx-F.A.9B;F.A.2q=F.A.1B.y+dy-F.A.ai;if(F.A.5i&&(F.A.3H||F.A.2Z)){k.3b.3H(F,F.A.2v,F.A.2q)}if(F.A.4m)F.A.4m.1D(F,[F.A.2c.x+dx,F.A.2c.y+dy]);if(!F.A.1O||F.A.1O==\'4j\'){F.A.8y=F.A.2c.x+dx;k.11.1c.K(0).14.O=F.A.2v+\'U\'}if(!F.A.1O||F.A.1O==\'49\'){F.A.8v=F.A.2c.y+dy;k.11.1c.K(0).14.Q=F.A.2q+\'U\'}if(k.1x&&k.1x.8D>0){k.1x.al(F)}E I},2r:u(o){if(!k.11.1c){k(\'2e\',1h).1S(\'<22 id="e8"></22>\');k.11.1c=k(\'#e8\');D el=k.11.1c.K(0);D 4J=el.14;4J.Y=\'1P\';4J.19=\'1o\';4J.9b=\'8j\';4J.eu=\'1o\';4J.2U=\'2K\';if(1X.71){el.bE="e4"}P{4J.gi=\'1o\';4J.e7=\'1o\';4J.e1=\'1o\'}}if(!o){o={}}E q.1E(u(){if(q.9I||!k.1a)E;if(1X.71){q.gh=u(){E I};q.gj=u(){E I}}D el=q;D 5e=o.3v?k(q).gf(o.3v):k(q);if(k.3a.4t){5e.1E(u(){q.bE="e4"})}P{5e.B(\'-gI-7R-8C\',\'1o\');5e.B(\'7R-8C\',\'1o\');5e.B(\'-gH-7R-8C\',\'1o\')}q.A={5e:5e,6N:o.6N?1b:I,46:o.46?1b:I,44:o.44?o.44:I,5i:o.5i?o.5i:I,8s:o.8s?o.8s:I,3I:o.3I?T(o.3I)||0:I,1G:o.1G?2m(o.1G):I,fx:T(o.fx)||S,6R:o.6R?o.6R:I,5t:{},1s:{},4o:o.4o&&o.4o.1K==2A?o.4o:I,3T:o.3T&&o.3T.1K==2A?o.3T:I,2Z:o.2Z&&o.2Z.1K==2A?o.2Z:I,1O:/49|4j/.48(o.1O)?o.1O:I,6M:o.6M?T(o.6M)||0:0,2V:o.2V?o.2V:I,bD:o.bD?1b:I,7O:o.7O||I};if(o.5t&&o.5t.1K==2A)q.A.5t.7R=o.5t;if(o.4m&&o.4m.1K==2A)q.A.4m=o.4m;if(o.2p&&((o.2p.1K==b0&&(o.2p==\'94\'||o.2p==\'1h\'))||(o.2p.1K==7F&&o.2p.1g==4))){q.A.2p=o.2p}if(o.2O){q.A.2O=o.2O}if(o.6a){if(2g o.6a==\'gz\'){q.A.gx=T(o.6a)||1;q.A.gy=T(o.6a)||1}P if(o.6a.1g==2){q.A.gx=T(o.6a[0])||1;q.A.gy=T(o.6a[1])||1}}if(o.3H&&o.3H.1K==2A){q.A.3H=o.3H}q.9I=1b;5e.1E(u(){q.3U=el});5e.1J(\'5v\',k.11.bN)})}};k.fn.23({aS:k.11.4U,7t:k.11.2r});k.1x={du:u(5J,5G,7Q,7S){E 5J<=k.11.F.A.2v&&(5J+7Q)>=(k.11.F.A.2v+k.11.F.A.1B.w)&&5G<=k.11.F.A.2q&&(5G+7S)>=(k.11.F.A.2q+k.11.F.A.1B.h)?1b:I},cV:u(5J,5G,7Q,7S){E!(5J>(k.11.F.A.2v+k.11.F.A.1B.w)||(5J+7Q)<k.11.F.A.2v||5G>(k.11.F.A.2q+k.11.F.A.1B.h)||(5G+7S)<k.11.F.A.2q)?1b:I},1s:u(5J,5G,7Q,7S){E 5J<k.11.F.A.4B.x&&(5J+7Q)>k.11.F.A.4B.x&&5G<k.11.F.A.4B.y&&(5G+7S)>k.11.F.A.4B.y?1b:I},5r:I,3Q:{},8D:0,3P:{},ed:u(C){if(k.11.F==S){E}D i;k.1x.3Q={};D bJ=I;24(i in k.1x.3P){if(k.1x.3P[i]!=S){D 1j=k.1x.3P[i].K(0);if(k(k.11.F).is(\'.\'+1j.1i.a)){if(1j.1i.m==I){1j.1i.p=k.23(k.1a.7G(1j),k.1a.74(1j));1j.1i.m=1b}if(1j.1i.ac){k.1x.3P[i].2R(1j.1i.ac)}k.1x.3Q[i]=k.1x.3P[i];if(k.1t&&1j.1i.s&&k.11.F.A.44){1j.1i.el=k(\'.\'+1j.1i.a,1j);C.14.19=\'1o\';k.1t.cT(1j);1j.1i.ay=k.1t.8x(k.1p(1j,\'id\')).7l;C.14.19=C.A.7V;bJ=1b}if(1j.1i.9i){1j.1i.9i.1D(k.1x.3P[i].K(0),[k.11.F])}}}}if(bJ){k.1t.26()}},dS:u(){k.1x.3Q={};24(i in k.1x.3P){if(k.1x.3P[i]!=S){D 1j=k.1x.3P[i].K(0);if(k(k.11.F).is(\'.\'+1j.1i.a)){1j.1i.p=k.23(k.1a.7G(1j),k.1a.74(1j));if(1j.1i.ac){k.1x.3P[i].2R(1j.1i.ac)}k.1x.3Q[i]=k.1x.3P[i];if(k.1t&&1j.1i.s&&k.11.F.A.44){1j.1i.el=k(\'.\'+1j.1i.a,1j);C.14.19=\'1o\';k.1t.cT(1j);C.14.19=C.A.7V}}}}},al:u(e){if(k.11.F==S){E}k.1x.5r=I;D i;D bK=I;D eQ=0;24(i in k.1x.3Q){D 1j=k.1x.3Q[i].K(0);if(k.1x.5r==I&&k.1x[1j.1i.t](1j.1i.p.x,1j.1i.p.y,1j.1i.p.1C,1j.1i.p.hb)){if(1j.1i.hc&&1j.1i.h==I){k.1x.3Q[i].2R(1j.1i.hc)}if(1j.1i.h==I&&1j.1i.7x){bK=1b}1j.1i.h=1b;k.1x.5r=1j;if(k.1t&&1j.1i.s&&k.11.F.A.44){k.1t.1c.K(0).3l=1j.1i.eV;k.1t.al(1j)}eQ++}P if(1j.1i.h==1b){if(1j.1i.7y){1j.1i.7y.1D(1j,[e,k.11.1c.K(0).7c,1j.1i.fx])}if(1j.1i.hc){k.1x.3Q[i].4i(1j.1i.hc)}1j.1i.h=I}}if(k.1t&&!k.1x.5r&&k.11.F.44){k.1t.1c.K(0).14.19=\'1o\'}if(bK){k.1x.5r.1i.7x.1D(k.1x.5r,[e,k.11.1c.K(0).7c])}},eO:u(e){D i;24(i in k.1x.3Q){D 1j=k.1x.3Q[i].K(0);if(1j.1i.ac){k.1x.3Q[i].4i(1j.1i.ac)}if(1j.1i.hc){k.1x.3Q[i].4i(1j.1i.hc)}if(1j.1i.s){k.1t.7s[k.1t.7s.1g]=i}if(1j.1i.9l&&1j.1i.h==1b){1j.1i.h=I;1j.1i.9l.1D(1j,[e,1j.1i.fx])}1j.1i.m=I;1j.1i.h=I}k.1x.3Q={}},4U:u(){E q.1E(u(){if(q.9j){if(q.1i.s){id=k.1p(q,\'id\');k.1t.5L[id]=S;k(\'.\'+q.1i.a,q).aS()}k.1x.3P[\'d\'+q.c2]=S;q.9j=I;q.f=S}})},2r:u(o){E q.1E(u(){if(q.9j==1b||!o.3C||!k.1a||!k.11){E}q.1i={a:o.3C,ac:o.9J||I,hc:o.a5||I,eV:o.58||I,9l:o.gq||o.9l||I,7x:o.7x||o.dC||I,7y:o.7y||o.fO||I,9i:o.9i||I,t:o.6I&&(o.6I==\'du\'||o.6I==\'cV\')?o.6I:\'1s\',fx:o.fx?o.fx:I,m:I,h:I};if(o.cQ==1b&&k.1t){id=k.1p(q,\'id\');k.1t.5L[id]=q.1i.a;q.1i.s=1b;if(o.2Z){q.1i.2Z=o.2Z;q.1i.ay=k.1t.8x(id).7l}}q.9j=1b;q.c2=T(18.6o()*c9);k.1x.3P[\'d\'+q.c2]=k(q);k.1x.8D++})}};k.fn.23({dR:k.1x.4U,do:k.1x.2r});k.gD=k.1x.dS;k.3B={1c:S,8L:u(){3g=q.2y;if(!3g)E;14={dz:k(q).B(\'dz\')||\'\',4A:k(q).B(\'4A\')||\'\',8Z:k(q).B(\'8Z\')||\'\',dP:k(q).B(\'dP\')||\'\',dT:k(q).B(\'dT\')||\'\',dU:k(q).B(\'dU\')||\'\',c3:k(q).B(\'c3\')||\'\',dY:k(q).B(\'dY\')||\'\'};k.3B.1c.B(14);3x=k.3B.dX(3g);3x=3x.4E(12 bb("\\\\n","g"),"<br />");k.3B.1c.3x(\'gL\');ci=k.3B.1c.K(0).4c;k.3B.1c.3x(3x);Z=k.3B.1c.K(0).4c+ci;if(q.6l.2M&&Z>q.6l.2M[0]){Z=q.6l.2M[0]}q.14.Z=Z+\'U\';if(q.4Y==\'cf\'){W=k.3B.1c.K(0).5W+ci;if(q.6l.2M&&W>q.6l.2M[1]){W=q.6l.2M[1]}q.14.W=W+\'U\'}},dX:u(3g){cg={\'&\':\'&gK;\',\'<\':\'&gJ;\',\'>\':\'&gt;\',\'"\':\'&gs;\'};24(i in cg){3g=3g.4E(12 bb(i,\'g\'),cg[i])}E 3g},2r:u(2M){if(k.3B.1c==S){k(\'2e\',1h).1S(\'<22 id="dE" 14="Y: 1P; Q: 0; O: 0; 3n: 2K;"></22>\');k.3B.1c=k(\'#dE\')}E q.1E(u(){if(/cf|ch/.48(q.4Y)){if(q.4Y==\'ch\'){dB=q.5C(\'1u\');if(!/3g|gr/.48(dB)){E}}if(2M&&(2M.1K==bn||(2M.1K==7F&&2M.1g==2))){if(2M.1K==bn)2M=[2M,2M];P{2M[0]=T(2M[0])||8J;2M[1]=T(2M[1])||8J}q.6l={2M:2M}}k(q).5B(k.3B.8L).6y(k.3B.8L).dH(k.3B.8L);k.3B.8L.1D(q)}})}};k.fn.kc=k.3B.2r;k.4K=u(e){if(/^kd$|^ke$|^ka$|^6L$|^k9$|^k5$|^k4$|^k6$|^k7$|^2e$|^k8$|^kf$|^kg$|^kn$|^ko$|^kp$|^kq$/i.48(e.9N))E I;P E 1b};k.fx.a0=u(e,65){D c=e.7c;D cs=c.14;cs.Y=65.Y;cs.5K=65.3G.t;cs.5j=65.3G.l;cs.5k=65.3G.b;cs.5z=65.3G.r;cs.Q=65.Q+\'U\';cs.O=65.O+\'U\';e.31.ew(c,e);e.31.km(e)};k.fx.9P=u(e){if(!k.4K(e))E I;D t=k(e);D es=e.14;D 73=I;if(t.B(\'19\')==\'1o\'){5Y=t.B(\'3n\');t.B(\'3n\',\'2K\').1Y();73=1b}D V={};V.Y=t.B(\'Y\');V.1q=k.1a.2o(e);V.3G=k.1a.cy(e);D co=e.4Z?e.4Z.ei:t.B(\'hU\');V.Q=T(t.B(\'Q\'))||0;V.O=T(t.B(\'O\'))||0;D eo=\'kl\'+T(18.6o()*c9);D 6u=1h.3F(/^1T$|^br$|^kh$|^hr$|^8C$|^kj$|^8T$|^3A$|^kk$|^k3$|^k2$|^9h$|^dl$|^jM$/i.48(e.9N)?\'22\':e.9N);k.1p(6u,\'id\',eo);D jN=k(6u).2R(\'jO\');D 4h=6u.14;D Q=0;D O=0;if(V.Y==\'2s\'||V.Y==\'1P\'){Q=V.Q;O=V.O}4h.Q=Q+\'U\';4h.O=O+\'U\';4h.Y=V.Y!=\'2s\'&&V.Y!=\'1P\'?\'2s\':V.Y;4h.W=V.1q.hb+\'U\';4h.Z=V.1q.1C+\'U\';4h.5K=V.3G.t;4h.5z=V.3G.r;4h.5k=V.3G.b;4h.5j=V.3G.l;4h.2U=\'2K\';if(k.3a.4t){4h.ei=co}P{4h.jK=co}if(k.3a=="4t"){es.5E="8V(1G="+0.ex*2a+")"}es.1G=0.ex;e.31.ew(6u,e);6u.jF(e);es.5K=\'2P\';es.5z=\'2P\';es.5k=\'2P\';es.5j=\'2P\';es.Y=\'1P\';es.eu=\'1o\';es.Q=\'2P\';es.O=\'2P\';if(73){t.2G();es.3n=5Y}E{V:V,3p:k(6u)}};k.fx.8E={jE:[0,1V,1V],jG:[eD,1V,1V],jH:[e6,e6,jI],jP:[0,0,0],ks:[0,0,1V],jY:[dv,42,42],jZ:[0,1V,1V],k0:[0,0,7w],k1:[0,7w,7w],jX:[cn,cn,cn],jS:[0,2a,0],jR:[jT,jU,eb],jV:[7w,0,7w],kr:[85,eb,47],kP:[1V,eA,0],kN:[kO,50,kx],kF:[7w,0,0],kD:[ku,f8,kt],ky:[kH,0,9C],kL:[1V,0,1V],kM:[1V,kJ,0],kv:[0,6C,0],kA:[75,0,kE],kC:[eD,eB,eA],kG:[kI,kB,eB],kw:[e0,1V,1V],kz:[eL,kK,eL],kQ:[9C,9C,9C],jC:[1V,iy,iz],iA:[1V,1V,e0],iB:[0,1V,0],ix:[1V,0,1V],iv:[6C,0,0],iq:[0,0,6C],ip:[6C,6C,0],ir:[1V,dv,0],it:[1V,ah,iu],iC:[6C,0,6C],iD:[1V,0,0],iK:[ah,ah,ah],iL:[1V,1V,1V],iM:[1V,1V,0]};k.fx.6D=u(4x,dm){if(k.fx.8E[4x])E{r:k.fx.8E[4x][0],g:k.fx.8E[4x][1],b:k.fx.8E[4x][2]};P if(2W=/^6Y\\(\\s*([0-9]{1,3})\\s*,\\s*([0-9]{1,3})\\s*,\\s*([0-9]{1,3})\\s*\\)$/.a4(4x))E{r:T(2W[1]),g:T(2W[2]),b:T(2W[3])};P if(2W=/6Y\\(\\s*([0-9]+(?:\\.[0-9]+)?)\\%\\s*,\\s*([0-9]+(?:\\.[0-9]+)?)\\%\\s*,\\s*([0-9]+(?:\\.[0-9]+)?)\\%\\s*\\)$/.a4(4x))E{r:2m(2W[1])*2.55,g:2m(2W[2])*2.55,b:2m(2W[3])*2.55};P if(2W=/^#([a-fA-79-9])([a-fA-79-9])([a-fA-79-9])$/.a4(4x))E{r:T("77"+2W[1]+2W[1]),g:T("77"+2W[2]+2W[2]),b:T("77"+2W[3]+2W[3])};P if(2W=/^#([a-fA-79-9]{2})([a-fA-79-9]{2})([a-fA-79-9]{2})$/.a4(4x))E{r:T("77"+2W[1]),g:T("77"+2W[2]),b:T("77"+2W[3])};P E dm==1b?I:{r:1V,g:1V,b:1V}};k.fx.dD={5Q:1,5b:1,5O:1,4S:1,4D:1,4A:1,W:1,O:1,c3:1,iI:1,5k:1,5j:1,5z:1,5K:1,8b:1,6x:1,8c:1,av:1,1G:1,iE:1,iF:1,5n:1,4X:1,5U:1,5M:1,2L:1,jD:1,Q:1,Z:1,3I:1};k.fx.dA={7i:1,iG:1,iH:1,io:1,im:1,4x:1,i2:1};k.fx.8A=[\'i3\',\'i4\',\'i5\',\'i1\'];k.fx.cc={\'cd\':[\'2E\',\'dK\'],\'a8\':[\'2E\',\'bh\'],\'6w\':[\'6w\',\'\'],\'8F\':[\'8F\',\'\']};k.fn.23({5w:u(5X,H,G,J){E q.1w(u(){D a1=k.H(H,G,J);D e=12 k.dM(q,a1,5X)})},c4:u(H,J){E q.1w(u(){D a1=k.H(H,J);D e=12 k.c4(q,a1)})},8o:u(2D){E q.1E(u(){if(q.6d)k.by(q,2D)})},i0:u(2D){E q.1E(u(){if(q.6d)k.by(q,2D);if(q.1w&&q.1w[\'fx\'])q.1w.fx=[]})}});k.23({c4:u(2f,M){D z=q,3t;z.2D=u(){if(k.fQ(M.21))M.21.1D(2f)};z.2I=6V(u(){z.2D()},M.1m);2f.6d=z},G:{c8:u(p,n,1W,1H,1m){E((-18.5H(p*18.2Q)/2)+0.5)*1H+1W}},dM:u(2f,M,5X){D z=q,3t;D y=2f.14;D fR=k.B(2f,"2U");D 72=k.B(2f,"19");D 2j={};z.9O=(12 7g()).7z();M.G=M.G&&k.G[M.G]?M.G:\'c8\';z.ag=u(2w,43){if(k.fx.dD[2w]){if(43==\'1Y\'||43==\'2G\'||43==\'3R\'){if(!2f.6v)2f.6v={};D r=2m(k.6E(2f,2w));2f.6v[2w]=r&&r>-c9?r:(2m(k.B(2f,2w))||0);43=43==\'3R\'?(72==\'1o\'?\'1Y\':\'2G\'):43;M[43]=1b;2j[2w]=43==\'1Y\'?[0,2f.6v[2w]]:[2f.6v[2w],0];if(2w!=\'1G\')y[2w]=2j[2w][0]+(2w!=\'3I\'&&2w!=\'8Z\'?\'U\':\'\');P k.1p(y,"1G",2j[2w][0])}P{2j[2w]=[2m(k.6E(2f,2w)),2m(43)||0]}}P if(k.fx.dA[2w])2j[2w]=[k.fx.6D(k.6E(2f,2w)),k.fx.6D(43)];P if(/^6w$|8F$|2E$|a8$|cd$/i.48(2w)){D m=43.4E(/\\s+/g,\' \').4E(/6Y\\s*\\(\\s*/g,\'6Y(\').4E(/\\s*,\\s*/g,\',\').4E(/\\s*\\)/g,\')\').d5(/([^\\s]+)/g);3m(2w){1e\'6w\':1e\'8F\':1e\'cd\':1e\'a8\':m[3]=m[3]||m[1]||m[0];m[2]=m[2]||m[0];m[1]=m[1]||m[0];24(D i=0;i<k.fx.8A.1g;i++){D 64=k.fx.cc[2w][0]+k.fx.8A[i]+k.fx.cc[2w][1];2j[64]=2w==\'a8\'?[k.fx.6D(k.6E(2f,64)),k.fx.6D(m[i])]:[2m(k.6E(2f,64)),2m(m[i])]}1r;1e\'2E\':24(D i=0;i<m.1g;i++){D bd=2m(m[i]);D a9=!hX(bd)?\'dK\':(!/cu|1o|2K|hY|hZ|i6|i7|ii|ij|ik|il/i.48(m[i])?\'bh\':I);if(a9){24(D j=0;j<k.fx.8A.1g;j++){64=\'2E\'+k.fx.8A[j]+a9;2j[64]=a9==\'bh\'?[k.fx.6D(k.6E(2f,64)),k.fx.6D(m[i])]:[2m(k.6E(2f,64)),bd]}}P{y[\'ie\']=m[i]}}1r}}P{y[2w]=43}E I};24(p in 5X){if(p==\'14\'){D 5f=k.bl(5X[p]);24(7A in 5f){q.ag(7A,5f[7A])}}P if(p==\'3l\'){if(1h.af)24(D i=0;i<1h.af.1g;i++){D 7e=1h.af[i].7e||1h.af[i].i9||S;if(7e){24(D j=0;j<7e.1g;j++){if(7e[j].i8==\'.\'+5X[p]){D 6X=12 bb(\'\\.\'+5X[p]+\' {\');D 5Z=7e[j].14.9X;D 5f=k.bl(5Z.4E(6X,\'\').4E(/}/g,\'\'));24(7A in 5f){q.ag(7A,5f[7A])}}}}}}P{q.ag(p,5X[p])}}y.19=72==\'1o\'?\'2B\':72;y.2U=\'2K\';z.2D=u(){D t=(12 7g()).7z();if(t>M.1m+z.9O){5T(z.2I);z.2I=S;24(p in 2j){if(p=="1G")k.1p(y,"1G",2j[p][1]);P if(2g 2j[p][1]==\'8T\')y[p]=\'6Y(\'+2j[p][1].r+\',\'+2j[p][1].g+\',\'+2j[p][1].b+\')\';P y[p]=2j[p][1]+(p!=\'3I\'&&p!=\'8Z\'?\'U\':\'\')}if(M.2G||M.1Y)24(D p in 2f.6v)if(p=="1G")k.1p(y,p,2f.6v[p]);P y[p]="";y.19=M.2G?\'1o\':(72!=\'1o\'?72:\'2B\');y.2U=fR;2f.6d=S;if(k.fQ(M.21))M.21.1D(2f)}P{D n=t-q.9O;D 8w=n/M.1m;24(p in 2j){if(2g 2j[p][1]==\'8T\'){y[p]=\'6Y(\'+T(k.G[M.G](8w,n,2j[p][0].r,(2j[p][1].r-2j[p][0].r),M.1m))+\',\'+T(k.G[M.G](8w,n,2j[p][0].g,(2j[p][1].g-2j[p][0].g),M.1m))+\',\'+T(k.G[M.G](8w,n,2j[p][0].b,(2j[p][1].b-2j[p][0].b),M.1m))+\')\'}P{D bz=k.G[M.G](8w,n,2j[p][0],(2j[p][1]-2j[p][0]),M.1m);if(p=="1G")k.1p(y,"1G",bz);P y[p]=bz+(p!=\'3I\'&&p!=\'8Z\'?\'U\':\'\')}}}};z.2I=6V(u(){z.2D()},13);2f.6d=z},by:u(2f,2D){if(2D)2f.6d.9O-=iO;P{1X.5T(2f.6d.2I);2f.6d=S;k.2H(2f,"fx")}}});k.bl=u(5Z){D 5f={};if(2g 5Z==\'4V\'){5Z=5Z.6c().7C(\';\');24(D i=0;i<5Z.1g;i++){6X=5Z[i].7C(\':\');if(6X.1g==2){5f[k.g6(6X[0].4E(/\\-(\\w)/g,u(m,c){E c.jo()}))]=k.g6(6X[1])}}}E 5f};k.fn.23({g3:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.61(q,H,J,\'4F\',G)})},gb:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.61(q,H,J,\'4r\',G)})},jl:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.61(q,H,J,\'fJ\',G)})},jk:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.61(q,H,J,\'O\',G)})},jg:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.61(q,H,J,\'2L\',G)})},jf:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.61(q,H,J,\'fh\',G)})}});k.fx.61=u(e,H,J,2S,G){if(!k.4K(e)){k.2H(e,\'1n\');E I}D z=q;z.el=k(e);z.1N=k.1a.2o(e);z.G=2g J==\'4V\'?J:G||S;if(!e.4s)e.4s=z.el.B(\'19\');if(2S==\'fJ\'){2S=z.el.B(\'19\')==\'1o\'?\'4r\':\'4F\'}P if(2S==\'fh\'){2S=z.el.B(\'19\')==\'1o\'?\'2L\':\'O\'}z.el.1Y();z.H=H;z.J=2g J==\'u\'?J:S;z.fx=k.fx.9P(e);z.2S=2S;z.21=u(){if(z.J&&z.J.1K==2A){z.J.1D(z.el.K(0))}if(z.2S==\'4r\'||z.2S==\'2L\'){z.el.B(\'19\',z.el.K(0).4s==\'1o\'?\'2B\':z.el.K(0).4s)}P{z.el.2G()}k.fx.a0(z.fx.3p.K(0),z.fx.V);k.2H(z.el.K(0),\'1n\')};3m(z.2S){1e\'4F\':63=12 k.fx(z.fx.3p.K(0),k.H(z.H,z.G,z.21),\'W\');63.1L(z.fx.V.1q.hb,0);1r;1e\'4r\':z.fx.3p.B(\'W\',\'9R\');z.el.1Y();63=12 k.fx(z.fx.3p.K(0),k.H(z.H,z.G,z.21),\'W\');63.1L(0,z.fx.V.1q.hb);1r;1e\'O\':63=12 k.fx(z.fx.3p.K(0),k.H(z.H,z.G,z.21),\'Z\');63.1L(z.fx.V.1q.1C,0);1r;1e\'2L\':z.fx.3p.B(\'Z\',\'9R\');z.el.1Y();63=12 k.fx(z.fx.3p.K(0),k.H(z.H,z.G,z.21),\'Z\');63.1L(0,z.fx.V.1q.1C);1r}};k.fn.ji=u(5D,J){E q.1w(\'1n\',u(){if(!k.4K(q)){k.2H(q,\'1n\');E I}D e=12 k.fx.f4(q,5D,J);e.bp()})};k.fx.f4=u(e,5D,J){D z=q;z.el=k(e);z.el.1Y();z.J=J;z.5D=T(5D)||40;z.V={};z.V.Y=z.el.B(\'Y\');z.V.Q=T(z.el.B(\'Q\'))||0;z.V.O=T(z.el.B(\'O\'))||0;if(z.V.Y!=\'2s\'&&z.V.Y!=\'1P\'){z.el.B(\'Y\',\'2s\')}z.3V=5;z.5y=1;z.bp=u(){z.5y++;z.e=12 k.fx(z.el.K(0),{1m:jj,21:u(){z.e=12 k.fx(z.el.K(0),{1m:80,21:u(){z.5D=T(z.5D/2);if(z.5y<=z.3V)z.bp();P{z.el.B(\'Y\',z.V.Y).B(\'Q\',z.V.Q+\'U\').B(\'O\',z.V.O+\'U\');k.2H(z.el.K(0),\'1n\');if(z.J&&z.J.1K==2A){z.J.1D(z.el.K(0))}}}},\'Q\');z.e.1L(z.V.Q-z.5D,z.V.Q)}},\'Q\');z.e.1L(z.V.Q,z.V.Q-z.5D)}};k.fn.23({jy:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'4r\',\'4l\',G)})},jz:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'4r\',\'in\',G)})},jA:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'4r\',\'3R\',G)})},jB:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'4F\',\'4l\',G)})},jx:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'4F\',\'in\',G)})},jw:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'4F\',\'3R\',G)})},js:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'O\',\'4l\',G)})},jt:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'O\',\'in\',G)})},ju:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'O\',\'3R\',G)})},jv:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'2L\',\'4l\',G)})},je:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'2L\',\'in\',G)})},jd:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'2L\',\'3R\',G)})}});k.fx.4f=u(e,H,J,2S,1u,G){if(!k.4K(e)){k.2H(e,\'1n\');E I}D z=q;z.el=k(e);z.G=2g J==\'4V\'?J:G||S;z.V={};z.V.Y=z.el.B(\'Y\');z.V.Q=z.el.B(\'Q\');z.V.O=z.el.B(\'O\');if(!e.4s)e.4s=z.el.B(\'19\');if(1u==\'3R\'){1u=z.el.B(\'19\')==\'1o\'?\'in\':\'4l\'}z.el.1Y();if(z.V.Y!=\'2s\'&&z.V.Y!=\'1P\'){z.el.B(\'Y\',\'2s\')}z.1u=1u;J=2g J==\'u\'?J:S;8H=1;3m(2S){1e\'4F\':z.e=12 k.fx(z.el.K(0),k.H(H-15,z.G,J),\'Q\');z.62=2m(z.V.Q)||0;z.9K=z.fG;8H=-1;1r;1e\'4r\':z.e=12 k.fx(z.el.K(0),k.H(H-15,z.G,J),\'Q\');z.62=2m(z.V.Q)||0;z.9K=z.fG;1r;1e\'2L\':z.e=12 k.fx(z.el.K(0),k.H(H-15,z.G,J),\'O\');z.62=2m(z.V.O)||0;z.9K=z.fy;1r;1e\'O\':z.e=12 k.fx(z.el.K(0),k.H(H-15,z.G,J),\'O\');z.62=2m(z.V.O)||0;z.9K=z.fy;8H=-1;1r}z.e2=12 k.fx(z.el.K(0),k.H(H,z.G,u(){z.el.B(z.V);if(z.1u==\'4l\'){z.el.B(\'19\',\'1o\')}P z.el.B(\'19\',z.el.K(0).4s==\'1o\'?\'2B\':z.el.K(0).4s);k.2H(z.el.K(0),\'1n\')}),\'1G\');if(1u==\'in\'){z.e.1L(z.62+2a*8H,z.62);z.e2.1L(0,1)}P{z.e.1L(z.62,z.62+2a*8H);z.e2.1L(1,0)}};k.fn.23({j0:u(H,W,J,G){E q.1w(\'1n\',u(){12 k.fx.9L(q,H,W,J,\'fp\',G)})},iW:u(H,W,J,G){E q.1w(\'1n\',u(){12 k.fx.9L(q,H,W,J,\'9M\',G)})},iV:u(H,W,J,G){E q.1w(\'1n\',u(){12 k.fx.9L(q,H,W,J,\'3R\',G)})}});k.fx.9L=u(e,H,W,J,1u,G){if(!k.4K(e)){k.2H(e,\'1n\');E I}D z=q;z.el=k(e);z.G=2g J==\'4V\'?J:G||S;z.J=2g J==\'u\'?J:S;if(1u==\'3R\'){1u=z.el.B(\'19\')==\'1o\'?\'9M\':\'fp\'}z.H=H;z.W=W&&W.1K==bn?W:20;z.fx=k.fx.9P(e);z.1u=1u;z.21=u(){if(z.J&&z.J.1K==2A){z.J.1D(z.el.K(0))}if(z.1u==\'9M\'){z.el.1Y()}P{z.el.2G()}k.fx.a0(z.fx.3p.K(0),z.fx.V);k.2H(z.el.K(0),\'1n\')};if(z.1u==\'9M\'){z.el.1Y();z.fx.3p.B(\'W\',z.W+\'U\').B(\'Z\',\'9R\');z.ef=12 k.fx(z.fx.3p.K(0),k.H(z.H,z.G,u(){z.ef=12 k.fx(z.fx.3p.K(0),k.H(z.H,z.G,z.21),\'W\');z.ef.1L(z.W,z.fx.V.1q.hb)}),\'Z\');z.ef.1L(0,z.fx.V.1q.1C)}P{z.ef=12 k.fx(z.fx.3p.K(0),k.H(z.H,z.G,u(){z.ef=12 k.fx(z.fx.3p.K(0),k.H(z.H,z.G,z.21),\'Z\');z.ef.1L(z.fx.V.1q.1C,0)}),\'W\');z.ef.1L(z.fx.V.1q.hb,z.W)}};k.fn.iR=u(H,4x,J,G){E q.1w(\'fv\',u(){q.6W=k(q).1p("14")||\'\';G=2g J==\'4V\'?J:G||S;J=2g J==\'u\'?J:S;D 9S=k(q).B(\'7i\');D 8I=q.31;7d(9S==\'cu\'&&8I){9S=k(8I).B(\'7i\');8I=8I.31}k(q).B(\'7i\',4x);if(2g q.6W==\'8T\')q.6W=q.6W["9X"];k(q).5w({\'7i\':9S},H,G,u(){k.2H(q,\'fv\');if(2g k(q).1p("14")==\'8T\'){k(q).1p("14")["9X"]="";k(q).1p("14")["9X"]=q.6W}P{k(q).1p("14",q.6W)}if(J)J.1D(q)})})};k.fn.23({iT:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.5m(q,H,J,\'49\',\'6g\',G)})},iU:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.5m(q,H,J,\'4j\',\'6g\',G)})},j1:u(H,J,G){E q.1w(\'1n\',u(){if(k.B(q,\'19\')==\'1o\'){12 k.fx.5m(q,H,J,\'4j\',\'6Z\',G)}P{12 k.fx.5m(q,H,J,\'4j\',\'6g\',G)}})},j2:u(H,J,G){E q.1w(\'1n\',u(){if(k.B(q,\'19\')==\'1o\'){12 k.fx.5m(q,H,J,\'49\',\'6Z\',G)}P{12 k.fx.5m(q,H,J,\'49\',\'6g\',G)}})},j9:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.5m(q,H,J,\'49\',\'6Z\',G)})},ja:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.5m(q,H,J,\'4j\',\'6Z\',G)})}});k.fx.5m=u(e,H,J,2S,1u,G){if(!k.4K(e)){k.2H(e,\'1n\');E I}D z=q;D 73=I;z.el=k(e);z.G=2g J==\'4V\'?J:G||S;z.J=2g J==\'u\'?J:S;z.1u=1u;z.H=H;z.2i=k.1a.2o(e);z.V={};z.V.Y=z.el.B(\'Y\');z.V.19=z.el.B(\'19\');if(z.V.19==\'1o\'){5Y=z.el.B(\'3n\');z.el.1Y();73=1b}z.V.Q=z.el.B(\'Q\');z.V.O=z.el.B(\'O\');if(73){z.el.2G();z.el.B(\'3n\',5Y)}z.V.Z=z.2i.w+\'U\';z.V.W=z.2i.h+\'U\';z.V.2U=z.el.B(\'2U\');z.2i.Q=T(z.V.Q)||0;z.2i.O=T(z.V.O)||0;if(z.V.Y!=\'2s\'&&z.V.Y!=\'1P\'){z.el.B(\'Y\',\'2s\')}z.el.B(\'2U\',\'2K\').B(\'W\',1u==\'6Z\'&&2S==\'49\'?1:z.2i.h+\'U\').B(\'Z\',1u==\'6Z\'&&2S==\'4j\'?1:z.2i.w+\'U\');z.21=u(){z.el.B(z.V);if(z.1u==\'6g\')z.el.2G();P z.el.1Y();k.2H(z.el.K(0),\'1n\')};3m(2S){1e\'49\':z.eh=12 k.fx(z.el.K(0),k.H(H-15,z.G,J),\'W\');z.et=12 k.fx(z.el.K(0),k.H(z.H,z.G,z.21),\'Q\');if(z.1u==\'6g\'){z.eh.1L(z.2i.h,0);z.et.1L(z.2i.Q,z.2i.Q+z.2i.h/2)}P{z.eh.1L(0,z.2i.h);z.et.1L(z.2i.Q+z.2i.h/2,z.2i.Q)}1r;1e\'4j\':z.eh=12 k.fx(z.el.K(0),k.H(H-15,z.G,J),\'Z\');z.et=12 k.fx(z.el.K(0),k.H(z.H,z.G,z.21),\'O\');if(z.1u==\'6g\'){z.eh.1L(z.2i.w,0);z.et.1L(z.2i.O,z.2i.O+z.2i.w/2)}P{z.eh.1L(0,z.2i.w);z.et.1L(z.2i.O+z.2i.w/2,z.2i.O)}1r}};k.fn.bg=u(H,3V,J){E q.1w(\'1n\',u(){if(!k.4K(q)){k.2H(q,\'1n\');E I}D fx=12 k.fx.bg(q,H,3V,J);fx.bf()})};k.fx.bg=u(el,H,3V,J){D z=q;z.3V=3V;z.5y=1;z.el=el;z.H=H;z.J=J;k(z.el).1Y();z.bf=u(){z.5y++;z.e=12 k.fx(z.el,k.H(z.H,u(){z.ef=12 k.fx(z.el,k.H(z.H,u(){if(z.5y<=z.3V)z.bf();P{k.2H(z.el,\'1n\');if(z.J&&z.J.1K==2A){z.J.1D(z.el)}}}),\'1G\');z.ef.1L(0,1)}),\'1G\');z.e.1L(1,0)}};k.fn.23({jb:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.6G(q,H,1,2a,1b,J,\'fa\',G)})},jc:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.6G(q,H,2a,1,1b,J,\'b4\',G)})},j8:u(H,J,G){E q.1w(\'1n\',u(){D G=G||\'fl\';12 k.fx.6G(q,H,2a,f8,1b,J,\'6h\',G)})},6G:u(H,57,30,6H,J,G){E q.1w(\'1n\',u(){12 k.fx.6G(q,H,57,30,6H,J,\'6G\',G)})}});k.fx.6G=u(e,H,57,30,6H,J,1u,G){if(!k.4K(e)){k.2H(e,\'1n\');E I}D z=q;z.el=k(e);z.57=T(57)||2a;z.30=T(30)||2a;z.G=2g J==\'4V\'?J:G||S;z.J=2g J==\'u\'?J:S;z.1m=k.H(H).1m;z.6H=6H||S;z.2i=k.1a.2o(e);z.V={Z:z.el.B(\'Z\'),W:z.el.B(\'W\'),4A:z.el.B(\'4A\')||\'2a%\',Y:z.el.B(\'Y\'),19:z.el.B(\'19\'),Q:z.el.B(\'Q\'),O:z.el.B(\'O\'),2U:z.el.B(\'2U\'),4S:z.el.B(\'4S\'),5O:z.el.B(\'5O\'),5Q:z.el.B(\'5Q\'),5b:z.el.B(\'5b\'),5M:z.el.B(\'5M\'),5U:z.el.B(\'5U\'),5n:z.el.B(\'5n\'),4X:z.el.B(\'4X\')};z.Z=T(z.V.Z)||e.4c||0;z.W=T(z.V.W)||e.5W||0;z.Q=T(z.V.Q)||0;z.O=T(z.V.O)||0;1q=[\'em\',\'U\',\'j7\',\'%\'];24(i in 1q){if(z.V.4A.3J(1q[i])>0){z.fg=1q[i];z.4A=2m(z.V.4A)}if(z.V.4S.3J(1q[i])>0){z.fc=1q[i];z.bw=2m(z.V.4S)||0}if(z.V.5O.3J(1q[i])>0){z.fe=1q[i];z.bc=2m(z.V.5O)||0}if(z.V.5Q.3J(1q[i])>0){z.fL=1q[i];z.bA=2m(z.V.5Q)||0}if(z.V.5b.3J(1q[i])>0){z.g8=1q[i];z.bt=2m(z.V.5b)||0}if(z.V.5M.3J(1q[i])>0){z.g4=1q[i];z.bx=2m(z.V.5M)||0}if(z.V.5U.3J(1q[i])>0){z.g9=1q[i];z.bv=2m(z.V.5U)||0}if(z.V.5n.3J(1q[i])>0){z.gc=1q[i];z.bj=2m(z.V.5n)||0}if(z.V.4X.3J(1q[i])>0){z.fK=1q[i];z.b7=2m(z.V.4X)||0}}if(z.V.Y!=\'2s\'&&z.V.Y!=\'1P\'){z.el.B(\'Y\',\'2s\')}z.el.B(\'2U\',\'2K\');z.1u=1u;3m(z.1u){1e\'fa\':z.4b=z.Q+z.2i.h/2;z.5a=z.Q;z.4k=z.O+z.2i.w/2;z.59=z.O;1r;1e\'b4\':z.5a=z.Q+z.2i.h/2;z.4b=z.Q;z.59=z.O+z.2i.w/2;z.4k=z.O;1r;1e\'6h\':z.5a=z.Q-z.2i.h/4;z.4b=z.Q;z.59=z.O-z.2i.w/4;z.4k=z.O;1r}z.be=I;z.t=(12 7g).7z();z.4w=u(){5T(z.2I);z.2I=S};z.2D=u(){if(z.be==I){z.el.1Y();z.be=1b}D t=(12 7g).7z();D n=t-z.t;D p=n/z.1m;if(t>=z.1m+z.t){9T(u(){o=1;if(z.1u){t=z.5a;l=z.59;if(z.1u==\'6h\')o=0}z.bs(z.30,l,t,1b,o)},13);z.4w()}P{o=1;if(!k.G||!k.G[z.G]){s=((-18.5H(p*18.2Q)/2)+0.5)*(z.30-z.57)+z.57}P{s=k.G[z.G](p,n,z.57,(z.30-z.57),z.1m)}if(z.1u){if(!k.G||!k.G[z.G]){t=((-18.5H(p*18.2Q)/2)+0.5)*(z.5a-z.4b)+z.4b;l=((-18.5H(p*18.2Q)/2)+0.5)*(z.59-z.4k)+z.4k;if(z.1u==\'6h\')o=((-18.5H(p*18.2Q)/2)+0.5)*(-0.9Y)+0.9Y}P{t=k.G[z.G](p,n,z.4b,(z.5a-z.4b),z.1m);l=k.G[z.G](p,n,z.4k,(z.59-z.4k),z.1m);if(z.1u==\'6h\')o=k.G[z.G](p,n,0.9Y,-0.9Y,z.1m)}}z.bs(s,l,t,I,o)}};z.2I=6V(u(){z.2D()},13);z.bs=u(4q,O,Q,fM,1G){z.el.B(\'W\',z.W*4q/2a+\'U\').B(\'Z\',z.Z*4q/2a+\'U\').B(\'O\',O+\'U\').B(\'Q\',Q+\'U\').B(\'4A\',z.4A*4q/2a+z.fg);if(z.bw)z.el.B(\'4S\',z.bw*4q/2a+z.fc);if(z.bc)z.el.B(\'5O\',z.bc*4q/2a+z.fe);if(z.bA)z.el.B(\'5Q\',z.bA*4q/2a+z.fL);if(z.bt)z.el.B(\'5b\',z.bt*4q/2a+z.g8);if(z.bx)z.el.B(\'5M\',z.bx*4q/2a+z.g4);if(z.bv)z.el.B(\'5U\',z.bv*4q/2a+z.g9);if(z.bj)z.el.B(\'5n\',z.bj*4q/2a+z.gc);if(z.b7)z.el.B(\'4X\',z.b7*4q/2a+z.fK);if(z.1u==\'6h\'){if(1X.71)z.el.K(0).14.5E="8V(1G="+1G*2a+")";z.el.K(0).14.1G=1G}if(fM){if(z.6H){z.el.B(z.V)}if(z.1u==\'b4\'||z.1u==\'6h\'){z.el.B(\'19\',\'1o\');if(z.1u==\'6h\'){if(1X.71)z.el.K(0).14.5E="8V(1G="+2a+")";z.el.K(0).14.1G=1}}P z.el.B(\'19\',\'2B\');if(z.J)z.J.1D(z.el.K(0));k.2H(z.el.K(0),\'1n\')}}};k.fn.23({9U:u(H,1O,G){o=k.H(H);E q.1w(\'1n\',u(){12 k.fx.9U(q,o,1O,G)})},j6:u(H,1O,G){E q.1E(u(){k(\'a[@3h*="#"]\',q).5h(u(e){fW=q.3h.7C(\'#\');k(\'#\'+fW[1]).9U(H,1O,G);E I})})}});k.fx.9U=u(e,o,1O,G){D z=q;z.o=o;z.e=e;z.1O=/fT|gd/.48(1O)?1O:I;z.G=G;p=k.1a.3w(e);s=k.1a.6z();z.4w=u(){5T(z.2I);z.2I=S;k.2H(z.e,\'1n\')};z.t=(12 7g).7z();s.h=s.h>s.ih?(s.h-s.ih):s.h;s.w=s.w>s.iw?(s.w-s.iw):s.w;z.5a=p.y>s.h?s.h:p.y;z.59=p.x>s.w?s.w:p.x;z.4b=s.t;z.4k=s.l;z.2D=u(){D t=(12 7g).7z();D n=t-z.t;D p=n/z.o.1m;if(t>=z.o.1m+z.t){z.4w();9T(u(){z.d3(z.5a,z.59)},13)}P{if(!z.1O||z.1O==\'fT\'){if(!k.G||!k.G[z.G]){9V=((-18.5H(p*18.2Q)/2)+0.5)*(z.5a-z.4b)+z.4b}P{9V=k.G[z.G](p,n,z.4b,(z.5a-z.4b),z.o.1m)}}P{9V=z.4b}if(!z.1O||z.1O==\'gd\'){if(!k.G||!k.G[z.G]){9W=((-18.5H(p*18.2Q)/2)+0.5)*(z.59-z.4k)+z.4k}P{9W=k.G[z.G](p,n,z.4k,(z.59-z.4k),z.o.1m)}}P{9W=z.4k}z.d3(9V,9W)}};z.d3=u(t,l){1X.j4(l,t)};z.2I=6V(u(){z.2D()},13)};k.fn.cY=u(3V,J){E q.1w(\'1n\',u(){if(!k.4K(q)){k.2H(q,\'1n\');E I}D e=12 k.fx.cY(q,3V,J);e.cG()})};k.fx.cY=u(e,3V,J){D z=q;z.el=k(e);z.el.1Y();z.3V=T(3V)||3;z.J=J;z.5y=1;z.V={};z.V.Y=z.el.B(\'Y\');z.V.Q=T(z.el.B(\'Q\'))||0;z.V.O=T(z.el.B(\'O\'))||0;if(z.V.Y!=\'2s\'&&z.V.Y!=\'1P\'){z.el.B(\'Y\',\'2s\')}z.cG=u(){z.5y++;z.e=12 k.fx(z.el.K(0),{1m:60,21:u(){z.e=12 k.fx(z.el.K(0),{1m:60,21:u(){z.e=12 k.fx(e,{1m:60,21:u(){if(z.5y<=z.3V)z.cG();P{z.el.B(\'Y\',z.V.Y).B(\'Q\',z.V.Q+\'U\').B(\'O\',z.V.O+\'U\');k.2H(z.el.K(0),\'1n\');if(z.J&&z.J.1K==2A){z.J.1D(z.el.K(0))}}}},\'O\');z.e.1L(z.V.O-20,z.V.O)}},\'O\');z.e.1L(z.V.O+20,z.V.O-20)}},\'O\');z.e.1L(z.V.O,z.V.O+20)}};k.fn.23({fo:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'4F\',\'in\',G)})},fq:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'4F\',\'4l\',G)})},iY:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'4F\',\'3R\',G)})},iX:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'4r\',\'in\',G)})},jr:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'4r\',\'4l\',G)})},jq:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'4r\',\'3R\',G)})},jp:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'O\',\'in\',G)})},jn:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'O\',\'4l\',G)})},jm:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'O\',\'3R\',G)})},iP:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'2L\',\'in\',G)})},ic:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'2L\',\'4l\',G)})},ib:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'2L\',\'3R\',G)})}});k.fx.1z=u(e,H,J,2S,1u,G){if(!k.4K(e)){k.2H(e,\'1n\');E I}D z=q;z.el=k(e);z.G=2g J==\'4V\'?J:G||S;z.J=2g J==\'u\'?J:S;if(1u==\'3R\'){1u=z.el.B(\'19\')==\'1o\'?\'in\':\'4l\'}if(!e.4s)e.4s=z.el.B(\'19\');z.el.1Y();z.H=H;z.fx=k.fx.9P(e);z.1u=1u;z.2S=2S;z.21=u(){if(z.1u==\'4l\')z.el.B(\'3n\',\'2K\');k.fx.a0(z.fx.3p.K(0),z.fx.V);if(z.1u==\'in\'){z.el.B(\'19\',z.el.K(0).4s==\'1o\'?\'2B\':z.el.K(0).4s)}P{z.el.B(\'19\',\'1o\');z.el.B(\'3n\',\'dd\')}if(z.J&&z.J.1K==2A){z.J.1D(z.el.K(0))}k.2H(z.el.K(0),\'1n\')};3m(z.2S){1e\'4F\':z.ef=12 k.fx(z.el.K(0),k.H(z.H,z.G,z.21),\'Q\');z.7v=12 k.fx(z.fx.3p.K(0),k.H(z.H,z.G),\'W\');if(z.1u==\'in\'){z.ef.1L(-z.fx.V.1q.hb,0);z.7v.1L(0,z.fx.V.1q.hb)}P{z.ef.1L(0,-z.fx.V.1q.hb);z.7v.1L(z.fx.V.1q.hb,0)}1r;1e\'4r\':z.ef=12 k.fx(z.el.K(0),k.H(z.H,z.G,z.21),\'Q\');if(z.1u==\'in\'){z.ef.1L(z.fx.V.1q.hb,0)}P{z.ef.1L(0,z.fx.V.1q.hb)}1r;1e\'O\':z.ef=12 k.fx(z.el.K(0),k.H(z.H,z.G,z.21),\'O\');z.7v=12 k.fx(z.fx.3p.K(0),k.H(z.H,z.G),\'Z\');if(z.1u==\'in\'){z.ef.1L(-z.fx.V.1q.1C,0);z.7v.1L(0,z.fx.V.1q.1C)}P{z.ef.1L(0,-z.fx.V.1q.1C);z.7v.1L(z.fx.V.1q.1C,0)}1r;1e\'2L\':z.ef=12 k.fx(z.el.K(0),k.H(z.H,z.G,z.21),\'O\');if(z.1u==\'in\'){z.ef.1L(z.fx.V.1q.1C,0)}P{z.ef.1L(0,z.fx.V.1q.1C)}1r}};k.3f=S;k.fn.ig=u(o){E q.1w(\'1n\',u(){12 k.fx.dG(q,o)})};k.fx.dG=u(e,o){if(k.3f==S){k(\'2e\',1h).1S(\'<22 id="3f"></22>\');k.3f=k(\'#3f\')}k.3f.B(\'19\',\'2B\').B(\'Y\',\'1P\');D z=q;z.el=k(e);if(!o||!o.30){E}if(o.30.1K==b0&&1h.9e(o.30)){o.30=1h.9e(o.30)}P if(!o.30.dq){E}if(!o.1m){o.1m=g5}z.1m=o.1m;z.30=o.30;z.8r=o.3l;z.21=o.21;if(z.8r){k.3f.2R(z.8r)}z.a3=0;z.a2=0;if(k.dF){z.a3=(T(k.3f.B(\'5b\'))||0)+(T(k.3f.B(\'5O\'))||0)+(T(k.3f.B(\'4X\'))||0)+(T(k.3f.B(\'5U\'))||0);z.a2=(T(k.3f.B(\'4S\'))||0)+(T(k.3f.B(\'5Q\'))||0)+(T(k.3f.B(\'5M\'))||0)+(T(k.3f.B(\'5n\'))||0)}z.26=k.23(k.1a.3w(z.el.K(0)),k.1a.2o(z.el.K(0)));z.2T=k.23(k.1a.3w(z.30),k.1a.2o(z.30));z.26.1C-=z.a3;z.26.hb-=z.a2;z.2T.1C-=z.a3;z.2T.hb-=z.a2;z.J=o.21;k.3f.B(\'Z\',z.26.1C+\'U\').B(\'W\',z.26.hb+\'U\').B(\'Q\',z.26.y+\'U\').B(\'O\',z.26.x+\'U\').5w({Q:z.2T.y,O:z.2T.x,Z:z.2T.1C,W:z.2T.hb},z.1m,u(){if(z.8r)k.3f.4i(z.8r);k.3f.B(\'19\',\'1o\');if(z.21&&z.21.1K==2A){z.21.1D(z.el.K(0),[z.30])}k.2H(z.el.K(0),\'1n\')})};k.1v={M:{2E:10,ec:\'1Q/iJ.eZ\',e3:\'<1T 2J="1Q/6g.da" />\',eW:0.8,d8:\'iN a6\',dc:\'57\',3W:8J},jQ:I,jW:I,6j:S,8m:I,8k:I,d1:u(2k){if(!k.1v.8k||k.1v.8m)E;D 3K=2k.7L||2k.7K||-1;3m(3K){1e 35:if(k.1v.6j)k.1v.26(S,k(\'a[@4I=\'+k.1v.6j+\']:jJ\').K(0));1r;1e 36:if(k.1v.6j)k.1v.26(S,k(\'a[@4I=\'+k.1v.6j+\']:jL\').K(0));1r;1e 37:1e 8:1e 33:1e 80:1e kb:D 9p=k(\'#87\');if(9p.K(0).53!=S){9p.K(0).53.1D(9p.K(0))}1r;1e 38:1r;1e 39:1e 34:1e 32:1e gl:1e 78:D 9k=k(\'#88\');if(9k.K(0).53!=S){9k.K(0).53.1D(9k.K(0))}1r;1e 40:1r;1e 27:k.1v.au();1r}},7q:u(M){if(M)k.23(k.1v.M,M);if(1X.2k){k(\'2e\',1h).1J(\'6y\',k.1v.d1)}P{k(1h).1J(\'6y\',k.1v.d1)}k(\'a\').1E(u(){el=k(q);en=el.1p(\'4I\')||\'\';e9=el.1p(\'3h\')||\'\';ev=/\\.da|\\.gw|\\.8X|\\.eZ|\\.gn/g;if(e9.6c().d5(ev)!=S&&en.6c().3J(\'eU\')==0){el.1J(\'5h\',k.1v.26)}});if(k.3a.4t){3A=1h.3F(\'3A\');k(3A).1p({id:\'cN\',2J:\'ek:I;\',ej:\'cD\',ep:\'cD\'}).B({19:\'1o\',Y:\'1P\',Q:\'0\',O:\'0\',5E:\'9n:9w.9y.cC(1G=0)\'});k(\'2e\').1S(3A)}8n=1h.3F(\'22\');k(8n).1p(\'id\',\'cP\').B({Y:\'1P\',19:\'1o\',Q:\'0\',O:\'0\',1G:0}).1S(1h.8M(\' \')).1J(\'5h\',k.1v.au);6A=1h.3F(\'22\');k(6A).1p(\'id\',\'eK\').B({4X:k.1v.M.2E+\'U\'}).1S(1h.8M(\' \'));cE=1h.3F(\'22\');k(cE).1p(\'id\',\'dg\').B({4X:k.1v.M.2E+\'U\',5n:k.1v.M.2E+\'U\'}).1S(1h.8M(\' \'));cF=1h.3F(\'a\');k(cF).1p({id:\'gg\',3h:\'#\'}).B({Y:\'1P\',2L:k.1v.M.2E+\'U\',Q:\'0\'}).1S(k.1v.M.e3).1J(\'5h\',k.1v.au);7m=1h.3F(\'22\');k(7m).1p(\'id\',\'cM\').B({Y:\'2s\',cA:\'O\',6w:\'0 9F\',3I:1}).1S(6A).1S(cE).1S(cF);2b=1h.3F(\'1T\');2b.2J=k.1v.M.ec;k(2b).1p(\'id\',\'eM\').B({Y:\'1P\'});4G=1h.3F(\'a\');k(4G).1p({id:\'87\',3h:\'#\'}).B({Y:\'1P\',19:\'1o\',2U:\'2K\',ey:\'1o\'}).1S(1h.8M(\' \'));4M=1h.3F(\'a\');k(4M).1p({id:\'88\',3h:\'#\'}).B({Y:\'1P\',2U:\'2K\',ey:\'1o\'}).1S(1h.8M(\' \'));1Z=1h.3F(\'22\');k(1Z).1p(\'id\',\'eE\').B({19:\'1o\',Y:\'2s\',2U:\'2K\',cA:\'O\',6w:\'0 9F\',Q:\'0\',O:\'0\',3I:2}).1S([2b,4G,4M]);6F=1h.3F(\'22\');k(6F).1p(\'id\',\'ao\').B({19:\'1o\',Y:\'1P\',2U:\'2K\',Q:\'0\',O:\'0\',cA:\'cv\',7i:\'cu\',hC:\'0\'}).1S([1Z,7m]);k(\'2e\').1S(8n).1S(6F)},26:u(e,C){el=C?k(C):k(q);9t=el.1p(\'4I\');D 6B,4u,4G,4M;if(9t!=\'eU\'){k.1v.6j=9t;8Y=k(\'a[@4I=\'+9t+\']\');6B=8Y.1N();4u=8Y.cZ(C?C:q);4G=8Y.K(4u-1);4M=8Y.K(4u+1)}89=el.1p(\'3h\');6A=el.1p(\'4g\');3O=k.1a.6z();8n=k(\'#cP\');if(!k.1v.8k){k.1v.8k=1b;if(k.3a.4t){k(\'#cN\').B(\'W\',18.3r(3O.ih,3O.h)+\'U\').B(\'Z\',18.3r(3O.iw,3O.w)+\'U\').1Y()}8n.B(\'W\',18.3r(3O.ih,3O.h)+\'U\').B(\'Z\',18.3r(3O.iw,3O.w)+\'U\').1Y().fX(cO,k.1v.M.eW,u(){k.1v.cw(89,6A,3O,6B,4u,4G,4M)});k(\'#ao\').B(\'Z\',18.3r(3O.iw,3O.w)+\'U\')}P{k(\'#87\').K(0).53=S;k(\'#88\').K(0).53=S;k.1v.cw(89,6A,3O,6B,4u,4G,4M)}E I},cw:u(89,gP,3O,6B,4u,4G,4M){k(\'#cW\').bk();aX=k(\'#87\');aX.2G();aO=k(\'#88\');aO.2G();2b=k(\'#eM\');1Z=k(\'#eE\');6F=k(\'#ao\');7m=k(\'#cM\').B(\'3n\',\'2K\');k(\'#eK\').3x(6A);k.1v.8m=1b;if(6B)k(\'#dg\').3x(k.1v.M.d8+\' \'+(4u+1)+\' \'+k.1v.M.dc+\' \'+6B);if(4G){aX.K(0).53=u(){q.5B();k.1v.26(S,4G);E I}}if(4M){aO.K(0).53=u(){q.5B();k.1v.26(S,4M);E I}}2b.1Y();82=k.1a.2o(1Z.K(0));56=18.3r(82.1C,2b.K(0).Z+k.1v.M.2E*2);6f=18.3r(82.hb,2b.K(0).W+k.1v.M.2E*2);2b.B({O:(56-2b.K(0).Z)/2+\'U\',Q:(6f-2b.K(0).W)/2+\'U\'});1Z.B({Z:56+\'U\',W:6f+\'U\'}).1Y();dw=k.1a.bm();6F.B(\'Q\',3O.t+(dw.h/15)+\'U\');if(6F.B(\'19\')==\'1o\'){6F.1Y().7f(k.1v.M.3W)}6k=12 9s;k(6k).1p(\'id\',\'cW\').1J(\'hJ\',u(){56=6k.Z+k.1v.M.2E*2;6f=6k.W+k.1v.M.2E*2;2b.2G();1Z.5w({W:6f},82.hb!=6f?k.1v.M.3W:1,u(){1Z.5w({Z:56},82.1C!=56?k.1v.M.3W:1,u(){1Z.bG(6k);k(6k).B({Y:\'1P\',O:k.1v.M.2E+\'U\',Q:k.1v.M.2E+\'U\'}).7f(k.1v.M.3W,u(){db=k.1a.2o(7m.K(0));if(4G){aX.B({O:k.1v.M.2E+\'U\',Q:k.1v.M.2E+\'U\',Z:56/2-k.1v.M.2E*3+\'U\',W:6f-k.1v.M.2E*2+\'U\'}).1Y()}if(4M){aO.B({O:56/2+k.1v.M.2E*2+\'U\',Q:k.1v.M.2E+\'U\',Z:56/2-k.1v.M.2E*3+\'U\',W:6f-k.1v.M.2E*2+\'U\'}).1Y()}7m.B({Z:56+\'U\',Q:-db.hb+\'U\',3n:\'dd\'}).5w({Q:-1},k.1v.M.3W,u(){k.1v.8m=I})})})})});6k.2J=89},au:u(){k(\'#cW\').bk();k(\'#ao\').2G();k(\'#cM\').B(\'3n\',\'2K\');k(\'#cP\').fX(cO,0,u(){k(q).2G();if(k.3a.4t){k(\'#cN\').2G()}});k(\'#87\').K(0).53=S;k(\'#88\').K(0).53=S;k.1v.6j=S;k.1v.8k=I;k.1v.8m=I;E I}};k.R={1A:S,41:S,F:S,1s:S,1q:S,Y:S,9a:u(e){k.R.F=(q.d0)?q.d0:q;k.R.1s=k.1a.4a(e);k.R.1q={Z:T(k(k.R.F).B(\'Z\'))||0,W:T(k(k.R.F).B(\'W\'))||0};k.R.Y={Q:T(k(k.R.F).B(\'Q\'))||0,O:T(k(k.R.F).B(\'O\'))||0};k(1h).1J(\'3D\',k.R.cR).1J(\'5P\',k.R.cK);if(2g k.R.F.1k.g2===\'u\'){k.R.F.1k.g2.1D(k.R.F)}E I},cK:u(e){k(1h).3q(\'3D\',k.R.cR).3q(\'5P\',k.R.cK);if(2g k.R.F.1k.fN===\'u\'){k.R.F.1k.fN.1D(k.R.F)}k.R.F=S},cR:u(e){if(!k.R.F){E}1s=k.1a.4a(e);7p=k.R.Y.Q-k.R.1s.y+1s.y;7r=k.R.Y.O-k.R.1s.x+1s.x;7p=18.3r(18.3L(7p,k.R.F.1k.8g-k.R.1q.W),k.R.F.1k.7h);7r=18.3r(18.3L(7r,k.R.F.1k.8h-k.R.1q.Z),k.R.F.1k.70);if(2g k.R.F.1k.4m===\'u\'){D 8a=k.R.F.1k.4m.1D(k.R.F,[7r,7p]);if(2g 8a==\'hh\'&&8a.1g==2){7r=8a[0];7p=8a[1]}}k.R.F.14.Q=7p+\'U\';k.R.F.14.O=7r+\'U\';E I},26:u(e){k(1h).1J(\'3D\',k.R.8j).1J(\'5P\',k.R.8o);k.R.1A=q.1A;k.R.41=q.41;k.R.1s=k.1a.4a(e);k.R.1q={Z:T(k(q.1A).B(\'Z\'))||0,W:T(k(q.1A).B(\'W\'))||0};k.R.Y={Q:T(k(q.1A).B(\'Q\'))||0,O:T(k(q.1A).B(\'O\'))||0};if(k.R.1A.1k.4o){k.R.1A.1k.4o.1D(k.R.1A,[q])}E I},8o:u(){k(1h).3q(\'3D\',k.R.8j).3q(\'5P\',k.R.8o);if(k.R.1A.1k.3T){k.R.1A.1k.3T.1D(k.R.1A,[k.R.41])}k.R.1A=S;k.R.41=S},6i:u(dx,az){E 18.3L(18.3r(k.R.1q.Z+dx*az,k.R.1A.1k.av),k.R.1A.1k.6x)},6m:u(dy,az){E 18.3L(18.3r(k.R.1q.W+dy*az,k.R.1A.1k.8c),k.R.1A.1k.8b)},fb:u(W){E 18.3L(18.3r(W,k.R.1A.1k.8c),k.R.1A.1k.8b)},8j:u(e){if(k.R.1A==S){E}1s=k.1a.4a(e);dx=1s.x-k.R.1s.x;dy=1s.y-k.R.1s.y;1I={Z:k.R.1q.Z,W:k.R.1q.W};2z={Q:k.R.Y.Q,O:k.R.Y.O};3m(k.R.41){1e\'e\':1I.Z=k.R.6i(dx,1);1r;1e\'fj\':1I.Z=k.R.6i(dx,1);1I.W=k.R.6m(dy,1);1r;1e\'w\':1I.Z=k.R.6i(dx,-1);2z.O=k.R.Y.O-1I.Z+k.R.1q.Z;1r;1e\'5F\':1I.Z=k.R.6i(dx,-1);2z.O=k.R.Y.O-1I.Z+k.R.1q.Z;1I.W=k.R.6m(dy,1);1r;1e\'76\':1I.W=k.R.6m(dy,-1);2z.Q=k.R.Y.Q-1I.W+k.R.1q.W;1I.Z=k.R.6i(dx,-1);2z.O=k.R.Y.O-1I.Z+k.R.1q.Z;1r;1e\'n\':1I.W=k.R.6m(dy,-1);2z.Q=k.R.Y.Q-1I.W+k.R.1q.W;1r;1e\'at\':1I.W=k.R.6m(dy,-1);2z.Q=k.R.Y.Q-1I.W+k.R.1q.W;1I.Z=k.R.6i(dx,1);1r;1e\'s\':1I.W=k.R.6m(dy,1);1r}if(k.R.1A.1k.4v){if(k.R.41==\'n\'||k.R.41==\'s\')4p=1I.W*k.R.1A.1k.4v;P 4p=1I.Z;4W=k.R.fb(4p*k.R.1A.1k.4v);4p=4W/k.R.1A.1k.4v;3m(k.R.41){1e\'n\':1e\'76\':1e\'at\':2z.Q+=1I.W-4W;1r}3m(k.R.41){1e\'76\':1e\'w\':1e\'5F\':2z.O+=1I.Z-4p;1r}1I.W=4W;1I.Z=4p}if(2z.Q<k.R.1A.1k.7h){4W=1I.W+2z.Q-k.R.1A.1k.7h;2z.Q=k.R.1A.1k.7h;if(k.R.1A.1k.4v){4p=4W/k.R.1A.1k.4v;3m(k.R.41){1e\'76\':1e\'w\':1e\'5F\':2z.O+=1I.Z-4p;1r}1I.Z=4p}1I.W=4W}if(2z.O<k.R.1A.1k.70){4p=1I.Z+2z.O-k.R.1A.1k.70;2z.O=k.R.1A.1k.70;if(k.R.1A.1k.4v){4W=4p*k.R.1A.1k.4v;3m(k.R.41){1e\'n\':1e\'76\':1e\'at\':2z.Q+=1I.W-4W;1r}1I.W=4W}1I.Z=4p}if(2z.Q+1I.W>k.R.1A.1k.8g){1I.W=k.R.1A.1k.8g-2z.Q;if(k.R.1A.1k.4v){1I.Z=1I.W/k.R.1A.1k.4v}}if(2z.O+1I.Z>k.R.1A.1k.8h){1I.Z=k.R.1A.1k.8h-2z.O;if(k.R.1A.1k.4v){1I.W=1I.Z*k.R.1A.1k.4v}}D 6p=I;if(k.R.1A.1k.f7){6p=k.R.1A.1k.f7.1D(k.R.1A,[1I,2z]);if(6p){if(6p.1q){k.23(1I,6p.1q)}if(6p.Y){k.23(2z,6p.Y)}}}8d=k.R.1A.14;8d.O=2z.O+\'U\';8d.Q=2z.Q+\'U\';8d.Z=1I.Z+\'U\';8d.W=1I.W+\'U\';E I},2r:u(M){if(!M||!M.3Z||M.3Z.1K!=7M){E}E q.1E(u(){D el=q;el.1k=M;el.1k.av=M.av||10;el.1k.8c=M.8c||10;el.1k.6x=M.6x||6P;el.1k.8b=M.8b||6P;el.1k.7h=M.7h||-aC;el.1k.70=M.70||-aC;el.1k.8h=M.8h||6P;el.1k.8g=M.8g||6P;d6=k(el).B(\'Y\');if(!(d6==\'2s\'||d6==\'1P\')){el.14.Y=\'2s\'}fS=/n|at|e|fj|s|5F|w|76/g;24(i in el.1k.3Z){if(i.6c().d5(fS)!=S){if(el.1k.3Z[i].1K==b0){3v=k(el.1k.3Z[i]);if(3v.1N()>0){el.1k.3Z[i]=3v.K(0)}}if(el.1k.3Z[i].4Y){el.1k.3Z[i].1A=el;el.1k.3Z[i].41=i;k(el.1k.3Z[i]).1J(\'5v\',k.R.26)}}}if(el.1k.5S){if(2g el.1k.5S===\'4V\'){aV=k(el.1k.5S);if(aV.1N()>0){aV.1E(u(){q.d0=el});aV.1J(\'5v\',k.R.9a)}}P if(el.1k.5S==1b){k(q).1J(\'5v\',k.R.9a)}}})},4U:u(){E q.1E(u(){D el=q;24(i in el.1k.3Z){el.1k.3Z[i].1A=S;el.1k.3Z[i].41=S;k(el.1k.3Z[i]).3q(\'5v\',k.R.26)}if(el.1k.5S){if(2g el.1k.5S===\'4V\'){3v=k(el.1k.5S);if(3v.1N()>0){3v.3q(\'5v\',k.R.9a)}}P if(el.1k.5S==1b){k(q).3q(\'5v\',k.R.9a)}}el.1k=S})}};k.fn.23({hz:k.R.2r,hs:k.R.4U});k.2C=S;k.7n=I;k.3k=S;k.7o=[];k.9v=u(e){D 3K=e.7L||e.7K||-1;if(3K==17||3K==16){k.7n=1b}};k.9u=u(e){k.7n=I};k.dL=u(e){q.f.1s=k.1a.4a(e);q.f.1M=k.23(k.1a.3w(q),k.1a.2o(q));q.f.3e=k.1a.6z(q);q.f.1s.x-=q.f.1M.x;q.f.1s.y-=q.f.1M.y;k(q).1S(k.2C.K(0));if(q.f.hc)k.2C.2R(q.f.hc).B(\'19\',\'2B\');k.2C.B({19:\'2B\',Z:\'2P\',W:\'2P\'});if(q.f.o){k.2C.B(\'1G\',q.f.o)}k.3k=q;k.96=I;k.7o=[];q.f.el.1E(u(){q.1M={x:q.8t+(q.4Z&&!k.3a.7I?T(q.4Z.5b)||0:0)+(k.3k.3c||0),y:q.8G+(q.4Z&&!k.3a.7I?T(q.4Z.4S)||0:0)+(k.3k.3d||0),1C:q.4c,hb:q.5W};if(q.s==1b){if(k.7n==I){q.s=I;k(q).4i(k.3k.f.7j)}P{k.96=1b;k.7o[k.7o.1g]=k.1p(q,\'id\')}}});k.am.1D(q,[e]);k(1h).1J(\'3D\',k.am).1J(\'5P\',k.cX);E I};k.am=u(e){if(!k.3k)E;k.fd.1D(k.3k,[e])};k.fd=u(e){if(!k.3k)E;D 1s=k.1a.4a(e);D 3e=k.1a.6z(k.3k);1s.x+=3e.l-q.f.3e.l-q.f.1M.x;1s.y+=3e.t-q.f.3e.t-q.f.1M.y;D 93=18.3L(1s.x,q.f.1s.x);D 5F=18.3L(18.3S(1s.x-q.f.1s.x),18.3S(q.f.3e.w-93));D 99=18.3L(1s.y,q.f.1s.y);D 9g=18.3L(18.3S(1s.y-q.f.1s.y),18.3S(q.f.3e.h-99));if(q.3d>0&&1s.y-20<q.3d){D 3X=18.3L(3e.t,10);99-=3X;9g+=3X;q.3d-=3X}P if(q.3d+q.f.1M.h<q.f.3e.h&&1s.y+20>q.3d+q.f.1M.h){D 3X=18.3L(q.f.3e.h-q.3d,10);q.3d+=3X;if(q.3d!=3e.t)9g+=3X}if(q.3c>0&&1s.x-20<q.3c){D 3X=18.3L(3e.l,10);93-=3X;5F+=3X;q.3c-=3X}P if(q.3c+q.f.1M.w<q.f.3e.w&&1s.x+20>q.3c+q.f.1M.w){D 3X=18.3L(q.f.3e.w-q.3c,10);q.3c+=3X;if(q.3c!=3e.l)5F+=3X}k.2C.B({O:93+\'U\',Q:99+\'U\',Z:5F+\'U\',W:9g+\'U\'});k.2C.l=93+q.f.3e.l;k.2C.t=99+q.f.3e.t;k.2C.r=k.2C.l+5F;k.2C.b=k.2C.t+9g;k.96=I;q.f.el.1E(u(){aw=k.7o.3J(k.1p(q,\'id\'));if(!(q.1M.x>k.2C.r||(q.1M.x+q.1M.1C)<k.2C.l||q.1M.y>k.2C.b||(q.1M.y+q.1M.hb)<k.2C.t)){k.96=1b;if(q.s!=1b){q.s=1b;k(q).2R(k.3k.f.7j)}if(aw!=-1){q.s=I;k(q).4i(k.3k.f.7j)}}P if((q.s==1b)&&(aw==-1)){q.s=I;k(q).4i(k.3k.f.7j)}P if((!q.s)&&(k.7n==1b)&&(aw!=-1)){q.s=1b;k(q).2R(k.3k.f.7j)}});E I};k.cX=u(e){if(!k.3k)E;k.g0.1D(k.3k,[e])};k.g0=u(e){k(1h).3q(\'3D\',k.am).3q(\'5P\',k.cX);if(!k.3k)E;k.2C.B(\'19\',\'1o\');if(q.f.hc)k.2C.4i(q.f.hc);k.3k=I;k(\'2e\').1S(k.2C.K(0));if(k.96==1b){if(q.f.98)q.f.98(k.cJ(k.1p(q,\'id\')))}P{if(q.f.9d)q.f.9d(k.cJ(k.1p(q,\'id\')))}k.7o=[]};k.cJ=u(s){D h=\'\';D o=[];if(a=k(\'#\'+s)){a.K(0).f.el.1E(u(){if(q.s==1b){if(h.1g>0){h+=\'&\'}h+=s+\'[]=\'+k.1p(q,\'id\');o[o.1g]=k.1p(q,\'id\')}})}E{7l:h,o:o}};k.fn.gZ=u(o){if(!k.2C){k(\'2e\',1h).1S(\'<22 id="2C"></22>\').1J(\'7B\',k.9v).1J(\'6y\',k.9u);k.2C=k(\'#2C\');k.2C.B({Y:\'1P\',19:\'1o\'});if(1X.2k){k(\'2e\',1h).1J(\'7B\',k.9v).1J(\'6y\',k.9u)}P{k(1h).1J(\'7B\',k.9v).1J(\'6y\',k.9u)}}if(!o){o={}}E q.1E(u(){if(q.eP)E;q.eP=1b;q.f={a:o.3C,o:o.1G?2m(o.1G):I,7j:o.eS?o.eS:I,hc:o.58?o.58:I,98:o.98?o.98:I,9d:o.9d?o.9d:I};q.f.el=k(\'.\'+o.3C);k(q).1J(\'5v\',k.dL).B(\'Y\',\'2s\')})};k.3b={bM:1,eH:u(3t){D 3t=3t;E q.1E(u(){q.4z.6s.1E(u(ab){k.3b.5c(q,3t[ab])})})},K:u(){D 3t=[];q.1E(u(cL){if(q.bI){3t[cL]=[];D C=q;D 1q=k.1a.2o(q);q.4z.6s.1E(u(ab){D x=q.8t;D y=q.8G;92=T(x*2a/(1q.w-q.4c));91=T(y*2a/(1q.h-q.5W));3t[cL][ab]=[92||0,91||0,x||0,y||0]})}});E 3t},ct:u(C){C.A.fu=C.A.28.w-C.A.1B.1C;C.A.fw=C.A.28.h-C.A.1B.hb;if(C.9r.4z.bC){9Z=C.9r.4z.6s.K(C.bF+1);if(9Z){C.A.28.w=(T(k(9Z).B(\'O\'))||0)+C.A.1B.1C;C.A.28.h=(T(k(9Z).B(\'Q\'))||0)+C.A.1B.hb}9Q=C.9r.4z.6s.K(C.bF-1);if(9Q){D cU=T(k(9Q).B(\'O\'))||0;D cH=T(k(9Q).B(\'O\'))||0;C.A.28.x+=cU;C.A.28.y+=cH;C.A.28.w-=cU;C.A.28.h-=cH}}C.A.g7=C.A.28.w-C.A.1B.1C;C.A.eC=C.A.28.h-C.A.1B.hb;if(C.A.2O){C.A.gx=((C.A.28.w-C.A.1B.1C)/C.A.2O)||1;C.A.gy=((C.A.28.h-C.A.1B.hb)/C.A.2O)||1;C.A.fU=C.A.g7/C.A.2O;C.A.fH=C.A.eC/C.A.2O}C.A.28.dx=C.A.28.x-C.A.2c.x;C.A.28.dy=C.A.28.y-C.A.2c.y;k.11.1c.B(\'9b\',\'ad\')},3H:u(C,x,y){if(C.A.2O){fE=T(x/C.A.fU);92=fE*2a/C.A.2O;ft=T(y/C.A.fH);91=ft*2a/C.A.2O}P{92=T(x*2a/C.A.fu);91=T(y*2a/C.A.fw)}C.A.b3=[92||0,91||0,x||0,y||0];if(C.A.3H)C.A.3H.1D(C,C.A.b3)},eI:u(2k){3K=2k.7L||2k.7K||-1;3m(3K){1e 35:k.3b.5c(q.3U,[ae,ae]);1r;1e 36:k.3b.5c(q.3U,[-ae,-ae]);1r;1e 37:k.3b.5c(q.3U,[-q.3U.A.gx||-1,0]);1r;1e 38:k.3b.5c(q.3U,[0,-q.3U.A.gy||-1]);1r;1e 39:k.3b.5c(q.3U,[q.3U.A.gx||1,0]);1r;1e 40:k.11.5c(q.3U,[0,q.3U.A.gy||1]);1r}},5c:u(C,Y){if(!C.A){E}C.A.1B=k.23(k.1a.3w(C),k.1a.2o(C));C.A.2c={x:T(k.B(C,\'O\'))||0,y:T(k.B(C,\'Q\'))||0};C.A.4n=k.B(C,\'Y\');if(C.A.4n!=\'2s\'&&C.A.4n!=\'1P\'){C.14.Y=\'2s\'}k.11.c5(C);k.3b.ct(C);dx=T(Y[0])||0;dy=T(Y[1])||0;2v=C.A.2c.x+dx;2q=C.A.2c.y+dy;if(C.A.2O){3y=k.11.c7.1D(C,[2v,2q,dx,dy]);if(3y.1K==7M){dx=3y.dx;dy=3y.dy}2v=C.A.2c.x+dx;2q=C.A.2c.y+dy}3y=k.11.ce.1D(C,[2v,2q,dx,dy]);if(3y&&3y.1K==7M){dx=3y.dx;dy=3y.dy}2v=C.A.2c.x+dx;2q=C.A.2c.y+dy;if(C.A.5i&&(C.A.3H||C.A.2Z)){k.3b.3H(C,2v,2q)}2v=!C.A.1O||C.A.1O==\'4j\'?2v:C.A.2c.x||0;2q=!C.A.1O||C.A.1O==\'49\'?2q:C.A.2c.y||0;C.14.O=2v+\'U\';C.14.Q=2q+\'U\'},2r:u(o){E q.1E(u(){if(q.bI==1b||!o.3C||!k.1a||!k.11||!k.1x){E}5x=k(o.3C,q);if(5x.1N()==0){E}D 4N={2p:\'94\',5i:1b,3H:o.3H&&o.3H.1K==2A?o.3H:S,2Z:o.2Z&&o.2Z.1K==2A?o.2Z:S,3v:q,1G:o.1G||I};if(o.2O&&T(o.2O)){4N.2O=T(o.2O)||1;4N.2O=4N.2O>0?4N.2O:1}if(5x.1N()==1)5x.7t(4N);P{k(5x.K(0)).7t(4N);4N.3v=S;5x.7t(4N)}5x.7B(k.3b.eI);5x.1p(\'bM\',k.3b.bM++);q.bI=1b;q.4z={};q.4z.er=4N.er;q.4z.2O=4N.2O;q.4z.6s=5x;q.4z.bC=o.bC?1b:I;bZ=q;bZ.4z.6s.1E(u(2N){q.bF=2N;q.9r=bZ});if(o.3t&&o.3t.1K==7F){24(i=o.3t.1g-1;i>=0;i--){if(o.3t[i].1K==7F&&o.3t[i].1g==2){el=q.4z.6s.K(i);if(el.4Y){k.3b.5c(el,o.3t[i])}}}}})}};k.fn.23({hN:k.3b.2r,hS:k.3b.eH,hG:k.3b.K});k.2u={5I:[],eg:u(){q.5B();X=q.31;id=k.1p(X,\'id\');if(k.2u.5I[id]!=S){1X.5T(k.2u.5I[id])}1z=X.L.3u+1;if(X.L.1Q.1g<1z){1z=1}1Q=k(\'1T\',X.L.5u);X.L.3u=1z;if(1Q.1N()>0){1Q.7a(X.L.3W,k.2u.95)}},dp:u(){q.5B();X=q.31;id=k.1p(X,\'id\');if(k.2u.5I[id]!=S){1X.5T(k.2u.5I[id])}1z=X.L.3u-1;1Q=k(\'1T\',X.L.5u);if(1z<1){1z=X.L.1Q.1g}X.L.3u=1z;if(1Q.1N()>0){1Q.7a(X.L.3W,k.2u.95)}},2I:u(c){X=1h.9e(c);if(X.L.6o){1z=X.L.3u;7d(1z==X.L.3u){1z=1+T(18.6o()*X.L.1Q.1g)}}P{1z=X.L.3u+1;if(X.L.1Q.1g<1z){1z=1}}1Q=k(\'1T\',X.L.5u);X.L.3u=1z;if(1Q.1N()>0){1Q.7a(X.L.3W,k.2u.95)}},go:u(o){D X;if(o&&o.1K==7M){if(o.2b){X=1h.9e(o.2b.X);5N=1X.hn.3h.7C("#");o.2b.6S=S;if(5N.1g==2){1z=T(5N[1]);1Y=5N[1].4E(1z,\'\');if(k.1p(X,\'id\')!=1Y){1z=1}}P{1z=1}}if(o.90){o.90.5B();X=o.90.31.31;id=k.1p(X,\'id\');if(k.2u.5I[id]!=S){1X.5T(k.2u.5I[id])}5N=o.90.3h.7C("#");1z=T(5N[1]);1Y=5N[1].4E(1z,\'\');if(k.1p(X,\'id\')!=1Y){1z=1}}if(X.L.1Q.1g<1z||1z<1){1z=1}X.L.3u=1z;52=k.1a.2o(X);dt=k.1a.aT(X);d9=k.1a.6U(X);if(X.L.3z){X.L.3z.o.B(\'19\',\'1o\')}if(X.L.3s){X.L.3s.o.B(\'19\',\'1o\')}if(X.L.2b){y=T(dt.t)+T(d9.t);if(X.L.1U){if(X.L.1U.5A==\'Q\'){y+=X.L.1U.4C.hb}P{52.h-=X.L.1U.4C.hb}}if(X.L.2x){if(X.L.2x&&X.L.2x.6Q==\'Q\'){y+=X.L.2x.4C.hb}P{52.h-=X.L.2x.4C.hb}}if(!X.L.c1){X.L.df=o.2b?o.2b.W:(T(X.L.2b.B(\'W\'))||0);X.L.c1=o.2b?o.2b.Z:(T(X.L.2b.B(\'Z\'))||0)}X.L.2b.B(\'Q\',y+(52.h-X.L.df)/2+\'U\');X.L.2b.B(\'O\',(52.1C-X.L.c1)/2+\'U\');X.L.2b.B(\'19\',\'2B\')}1Q=k(\'1T\',X.L.5u);if(1Q.1N()>0){1Q.7a(X.L.3W,k.2u.95)}P{aj=k(\'a\',X.L.1U.o).K(1z-1);k(aj).2R(X.L.1U.5R);D 1T=12 9s();1T.X=k.1p(X,\'id\');1T.1z=1z-1;1T.2J=X.L.1Q[X.L.3u-1].2J;if(1T.21){1T.6S=S;k.2u.19.1D(1T)}P{1T.6S=k.2u.19}if(X.L.2x){X.L.2x.o.3x(X.L.1Q[1z-1].6L)}}}},95:u(){X=q.31.31;X.L.5u.B(\'19\',\'1o\');if(X.L.1U.5R){aj=k(\'a\',X.L.1U.o).4i(X.L.1U.5R).K(X.L.3u-1);k(aj).2R(X.L.1U.5R)}D 1T=12 9s();1T.X=k.1p(X,\'id\');1T.1z=X.L.3u-1;1T.2J=X.L.1Q[X.L.3u-1].2J;if(1T.21){1T.6S=S;k.2u.19.1D(1T)}P{1T.6S=k.2u.19}if(X.L.2x){X.L.2x.o.3x(X.L.1Q[X.L.3u-1].6L)}},19:u(){X=1h.9e(q.X);if(X.L.3z){X.L.3z.o.B(\'19\',\'1o\')}if(X.L.3s){X.L.3s.o.B(\'19\',\'1o\')}52=k.1a.2o(X);y=0;if(X.L.1U){if(X.L.1U.5A==\'Q\'){y+=X.L.1U.4C.hb}P{52.h-=X.L.1U.4C.hb}}if(X.L.2x){if(X.L.2x&&X.L.2x.6Q==\'Q\'){y+=X.L.2x.4C.hb}P{52.h-=X.L.2x.4C.hb}}hg=k(\'.ca\',X);y=y+(52.h-q.W)/2;x=(52.1C-q.Z)/2;X.L.5u.B(\'Q\',y+\'U\').B(\'O\',x+\'U\').3x(\'<1T 2J="\'+q.2J+\'" />\');X.L.5u.7f(X.L.3W);3s=X.L.3u+1;if(3s>X.L.1Q.1g){3s=1}3z=X.L.3u-1;if(3z<1){3z=X.L.1Q.1g}X.L.3s.o.B(\'19\',\'2B\').B(\'Q\',y+\'U\').B(\'O\',x+2*q.Z/3+\'U\').B(\'Z\',q.Z/3+\'U\').B(\'W\',q.W+\'U\').1p(\'4g\',X.L.1Q[3s-1].6L);X.L.3s.o.K(0).3h=\'#\'+3s+k.1p(X,\'id\');X.L.3z.o.B(\'19\',\'2B\').B(\'Q\',y+\'U\').B(\'O\',x+\'U\').B(\'Z\',q.Z/3+\'U\').B(\'W\',q.W+\'U\').1p(\'4g\',X.L.1Q[3z-1].6L);X.L.3z.o.K(0).3h=\'#\'+3z+k.1p(X,\'id\')},2r:u(o){if(!o||!o.1Z||k.2u.5I[o.1Z])E;D 1Z=k(\'#\'+o.1Z);D el=1Z.K(0);if(el.14.Y!=\'1P\'&&el.14.Y!=\'2s\'){el.14.Y=\'2s\'}el.14.2U=\'2K\';if(1Z.1N()==0)E;el.L={};el.L.1Q=o.1Q?o.1Q:[];el.L.6o=o.6o&&o.6o==1b||I;97=el.f3(\'hL\');24(i=0;i<97.1g;i++){7Z=el.L.1Q.1g;el.L.1Q[7Z]={2J:97[i].2J,6L:97[i].4g||97[i].hD||\'\'}}if(el.L.1Q.1g==0){E}el.L.4n=k.23(k.1a.3w(el),k.1a.2o(el));el.L.b5=k.1a.aT(el);el.L.bu=k.1a.6U(el);t=T(el.L.b5.t)+T(el.L.bu.t);b=T(el.L.b5.b)+T(el.L.bu.b);k(\'1T\',el).bk();el.L.3W=o.3W?o.3W:g5;if(o.5A||o.9f||o.5R){el.L.1U={};1Z.1S(\'<22 6T="g1"></22>\');el.L.1U.o=k(\'.g1\',el);if(o.9f){el.L.1U.9f=o.9f;el.L.1U.o.2R(o.9f)}if(o.5R){el.L.1U.5R=o.5R}el.L.1U.o.B(\'Y\',\'1P\').B(\'Z\',el.L.4n.w+\'U\');if(o.5A&&o.5A==\'Q\'){el.L.1U.5A=\'Q\';el.L.1U.o.B(\'Q\',t+\'U\')}P{el.L.1U.5A=\'4D\';el.L.1U.o.B(\'4D\',b+\'U\')}el.L.1U.aE=o.aE?o.aE:\' \';24(D i=0;i<el.L.1Q.1g;i++){7Z=T(i)+1;el.L.1U.o.1S(\'<a 3h="#\'+7Z+o.1Z+\'" 6T="gR" 4g="\'+el.L.1Q[i].6L+\'">\'+7Z+\'</a>\'+(7Z!=el.L.1Q.1g?el.L.1U.aE:\'\'))}k(\'a\',el.L.1U.o).1J(\'5h\',u(){k.2u.go({90:q})});el.L.1U.4C=k.1a.2o(el.L.1U.o.K(0))}if(o.6Q||o.9c){el.L.2x={};1Z.1S(\'<22 6T="dn">&7k;</22>\');el.L.2x.o=k(\'.dn\',el);if(o.9c){el.L.2x.9c=o.9c;el.L.2x.o.2R(o.9c)}el.L.2x.o.B(\'Y\',\'1P\').B(\'Z\',el.L.4n.w+\'U\');if(o.6Q&&o.6Q==\'Q\'){el.L.2x.6Q=\'Q\';el.L.2x.o.B(\'Q\',(el.L.1U&&el.L.1U.5A==\'Q\'?el.L.1U.4C.hb+t:t)+\'U\')}P{el.L.2x.6Q=\'4D\';el.L.2x.o.B(\'4D\',(el.L.1U&&el.L.1U.5A==\'4D\'?el.L.1U.4C.hb+b:b)+\'U\')}el.L.2x.4C=k.1a.2o(el.L.2x.o.K(0))}if(o.9D){el.L.3s={9D:o.9D};1Z.1S(\'<a 3h="#2\'+o.1Z+\'" 6T="eY">&7k;</a>\');el.L.3s.o=k(\'.eY\',el);el.L.3s.o.B(\'Y\',\'1P\').B(\'19\',\'1o\').B(\'2U\',\'2K\').B(\'4A\',\'eR\').2R(el.L.3s.9D);el.L.3s.o.1J(\'5h\',k.2u.eg)}if(o.9o){el.L.3z={9o:o.9o};1Z.1S(\'<a 3h="#0\'+o.1Z+\'" 6T="ee">&7k;</a>\');el.L.3z.o=k(\'.ee\',el);el.L.3z.o.B(\'Y\',\'1P\').B(\'19\',\'1o\').B(\'2U\',\'2K\').B(\'4A\',\'eR\').2R(el.L.3z.9o);el.L.3z.o.1J(\'5h\',k.2u.dp)}1Z.bG(\'<22 6T="ca"></22>\');el.L.5u=k(\'.ca\',el);el.L.5u.B(\'Y\',\'1P\').B(\'Q\',\'2P\').B(\'O\',\'2P\').B(\'19\',\'1o\');if(o.2b){1Z.bG(\'<22 6T="dW" 14="19: 1o;"><1T 2J="\'+o.2b+\'" /></22>\');el.L.2b=k(\'.dW\',el);el.L.2b.B(\'Y\',\'1P\');D 1T=12 9s();1T.X=o.1Z;1T.2J=o.2b;if(1T.21){1T.6S=S;k.2u.go({2b:1T})}P{1T.6S=u(){k.2u.go({2b:q})}}}P{k.2u.go({1Z:el})}if(o.cS){fi=T(o.cS)*aC}k.2u.5I[o.1Z]=o.cS?1X.6V(\'k.2u.2I(\\\'\'+o.1Z+\'\\\')\',fi):S}};k.X=k.2u.2r;k.1t={7s:[],5L:{},1c:I,7u:S,26:u(){if(k.11.F==S){E}D 4O,3G,c,cs;k.1t.1c.K(0).3l=k.11.F.A.6R;4O=k.1t.1c.K(0).14;4O.19=\'2B\';k.1t.1c.1B=k.23(k.1a.3w(k.1t.1c.K(0)),k.1a.2o(k.1t.1c.K(0)));4O.Z=k.11.F.A.1B.1C+\'U\';4O.W=k.11.F.A.1B.hb+\'U\';3G=k.1a.cy(k.11.F);4O.5K=3G.t;4O.5z=3G.r;4O.5k=3G.b;4O.5j=3G.l;if(k.11.F.A.46==1b){c=k.11.F.fI(1b);cs=c.14;cs.5K=\'2P\';cs.5z=\'2P\';cs.5k=\'2P\';cs.5j=\'2P\';cs.19=\'2B\';k.1t.1c.5o().1S(c)}k(k.11.F).f5(k.1t.1c.K(0));k.11.F.14.19=\'1o\'},fC:u(e){if(!e.A.44&&k.1x.5r.cQ){if(e.A.3T)e.A.3T.1D(F);k(e).B(\'Y\',e.A.cz||e.A.4n);k(e).aS();k(k.1x.5r).f6(e)}k.1t.1c.4i(e.A.6R).3x(\'&7k;\');k.1t.7u=S;D 4O=k.1t.1c.K(0).14;4O.19=\'1o\';k.1t.1c.f5(e);if(e.A.fx>0){k(e).7f(e.A.fx)}k(\'2e\').1S(k.1t.1c.K(0));D 86=[];D 8q=I;24(D i=0;i<k.1t.7s.1g;i++){D 1j=k.1x.3P[k.1t.7s[i]].K(0);D id=k.1p(1j,\'id\');D 8i=k.1t.8x(id);if(1j.1i.ay!=8i.7l){1j.1i.ay=8i.7l;if(8q==I&&1j.1i.2Z){8q=1j.1i.2Z}8i.id=id;86[86.1g]=8i}}k.1t.7s=[];if(8q!=I&&86.1g>0){8q(86)}},al:u(e,o){if(!k.11.F)E;D 6e=I;D i=0;if(e.1i.el.1N()>0){24(i=e.1i.el.1N();i>0;i--){if(e.1i.el.K(i-1)!=k.11.F){if(!e.5V.b2){if((e.1i.el.K(i-1).1M.y+e.1i.el.K(i-1).1M.hb/2)>k.11.F.A.2q){6e=e.1i.el.K(i-1)}P{1r}}P{if((e.1i.el.K(i-1).1M.x+e.1i.el.K(i-1).1M.1C/2)>k.11.F.A.2v&&(e.1i.el.K(i-1).1M.y+e.1i.el.K(i-1).1M.hb/2)>k.11.F.A.2q){6e=e.1i.el.K(i-1)}}}}}if(6e&&k.1t.7u!=6e){k.1t.7u=6e;k(6e).h5(k.1t.1c.K(0))}P if(!6e&&(k.1t.7u!=S||k.1t.1c.K(0).31!=e)){k.1t.7u=S;k(e).1S(k.1t.1c.K(0))}k.1t.1c.K(0).14.19=\'2B\'},cT:u(e){if(k.11.F==S){E}e.1i.el.1E(u(){q.1M=k.23(k.1a.74(q),k.1a.7G(q))})},8x:u(s){D i;D h=\'\';D o={};if(s){if(k.1t.5L[s]){o[s]=[];k(\'#\'+s+\' .\'+k.1t.5L[s]).1E(u(){if(h.1g>0){h+=\'&\'}h+=s+\'[]=\'+k.1p(q,\'id\');o[s][o[s].1g]=k.1p(q,\'id\')})}P{24(a in s){if(k.1t.5L[s[a]]){o[s[a]]=[];k(\'#\'+s[a]+\' .\'+k.1t.5L[s[a]]).1E(u(){if(h.1g>0){h+=\'&\'}h+=s[a]+\'[]=\'+k.1p(q,\'id\');o[s[a]][o[s[a]].1g]=k.1p(q,\'id\')})}}}}P{24(i in k.1t.5L){o[i]=[];k(\'#\'+i+\' .\'+k.1t.5L[i]).1E(u(){if(h.1g>0){h+=\'&\'}h+=i+\'[]=\'+k.1p(q,\'id\');o[i][o[i].1g]=k.1p(q,\'id\')})}}E{7l:h,o:o}},fF:u(e){if(!e.dq){E}E q.1E(u(){if(!q.5V||!k(e).is(\'.\'+q.5V.3C))k(e).2R(q.5V.3C);k(e).7t(q.5V.A)})},4U:u(){E q.1E(u(){k(\'.\'+q.5V.3C).aS();k(q).dR();q.5V=S;q.fm=S})},2r:u(o){if(o.3C&&k.1a&&k.11&&k.1x){if(!k.1t.1c){k(\'2e\',1h).1S(\'<22 id="e5">&7k;</22>\');k.1t.1c=k(\'#e5\');k.1t.1c.K(0).14.19=\'1o\'}q.do({3C:o.3C,9J:o.9J?o.9J:I,a5:o.a5?o.a5:I,58:o.58?o.58:I,7x:o.7x||o.dC,7y:o.7y||o.fO,cQ:1b,2Z:o.2Z||o.ia,fx:o.fx?o.fx:I,46:o.46?1b:I,6I:o.6I?o.6I:\'cV\'});E q.1E(u(){D A={6N:o.6N?1b:I,ff:6P,1G:o.1G?2m(o.1G):I,6R:o.58?o.58:I,fx:o.fx?o.fx:I,44:1b,46:o.46?1b:I,3v:o.3v?o.3v:S,2p:o.2p?o.2p:S,4o:o.4o&&o.4o.1K==2A?o.4o:I,4m:o.4m&&o.4m.1K==2A?o.4m:I,3T:o.3T&&o.3T.1K==2A?o.3T:I,1O:/49|4j/.48(o.1O)?o.1O:I,6M:o.6M?T(o.6M)||0:I,2V:o.2V?o.2V:I};k(\'.\'+o.3C,q).7t(A);q.fm=1b;q.5V={3C:o.3C,6N:o.6N?1b:I,ff:6P,1G:o.1G?2m(o.1G):I,6R:o.58?o.58:I,fx:o.fx?o.fx:I,44:1b,46:o.46?1b:I,3v:o.3v?o.3v:S,2p:o.2p?o.2p:S,b2:o.b2?1b:I,A:A}})}}};k.fn.23({j3:k.1t.2r,f6:k.1t.fF,iS:k.1t.4U});k.iZ=k.1t.8x;k.2t={6O:S,7b:I,9m:S,6K:u(e){k.2t.7b=1b;k.2t.1Y(e,q,1b)},cq:u(e){if(k.2t.6O!=q)E;k.2t.7b=I;k.2t.2G(e,q)},1Y:u(e,el,7b){if(k.2t.6O!=S)E;if(!el){el=q}k.2t.6O=el;1M=k.23(k.1a.3w(el),k.1a.2o(el));8u=k(el);4g=8u.1p(\'4g\');3h=8u.1p(\'3h\');if(4g){k.2t.9m=4g;8u.1p(\'4g\',\'\');k(\'#eT\').3x(4g);if(3h)k(\'#bL\').3x(3h.4E(\'jh://\',\'\'));P k(\'#bL\').3x(\'\');1c=k(\'#8z\');if(el.4H.3l){1c.K(0).3l=el.4H.3l}P{1c.K(0).3l=\'\'}bo=k.1a.2o(1c.K(0));ga=7b&&el.4H.Y==\'bO\'?\'4D\':el.4H.Y;3m(ga){1e\'Q\':2q=1M.y-bo.hb;2v=1M.x;1r;1e\'O\':2q=1M.y;2v=1M.x-bo.1C;1r;1e\'2L\':2q=1M.y;2v=1M.x+1M.1C;1r;1e\'bO\':k(\'2e\').1J(\'3D\',k.2t.3D);1s=k.1a.4a(e);2q=1s.y+15;2v=1s.x+15;1r;ad:2q=1M.y+1M.hb;2v=1M.x;1r}1c.B({Q:2q+\'U\',O:2v+\'U\'});if(el.4H.54==I){1c.1Y()}P{1c.7f(el.4H.54)}if(el.4H.2Y)el.4H.2Y.1D(el);8u.1J(\'8B\',k.2t.2G).1J(\'5B\',k.2t.cq)}},3D:u(e){if(k.2t.6O==S){k(\'2e\').3q(\'3D\',k.2t.3D);E}1s=k.1a.4a(e);k(\'#8z\').B({Q:1s.y+15+\'U\',O:1s.x+15+\'U\'})},2G:u(e,el){if(!el){el=q}if(k.2t.7b!=1b&&k.2t.6O==el){k.2t.6O=S;k(\'#8z\').7a(1);k(el).1p(\'4g\',k.2t.9m).3q(\'8B\',k.2t.2G).3q(\'5B\',k.2t.cq);if(el.4H.3i)el.4H.3i.1D(el);k.2t.9m=S}},2r:u(M){if(!k.2t.1c){k(\'2e\').1S(\'<22 id="8z"><22 id="eT"></22><22 id="bL"></22></22>\');k(\'#8z\').B({Y:\'1P\',3I:6P,19:\'1o\'});k.2t.1c=1b}E q.1E(u(){if(k.1p(q,\'4g\')){q.4H={Y:/Q|4D|O|2L|bO/.48(M.Y)?M.Y:\'4D\',3l:M.3l?M.3l:I,54:M.54?M.54:I,2Y:M.2Y&&M.2Y.1K==2A?M.2Y:I,3i:M.3i&&M.3i.1K==2A?M.3i:I};D el=k(q);el.1J(\'9z\',k.2t.1Y);el.1J(\'6K\',k.2t.6K)}})}};k.fn.hO=k.2t.2r;k.84={bq:u(e){3K=e.7L||e.7K||-1;if(3K==9){if(1X.2k){1X.2k.bT=1b;1X.2k.c0=I}P{e.aP();e.aW()}if(q.b1){1h.6J.dZ().3g="\\t";q.dV=u(){q.6K();q.dV=S}}P if(q.aF){26=q.5q;2T=q.dN;q.2y=q.2y.hd(0,26)+"\\t"+q.2y.h8(2T);q.aF(26+1,26+1);q.6K()}E I}},4U:u(){E q.1E(u(){if(q.7P&&q.7P==1b){k(q).3q(\'7B\',k.84.bq);q.7P=I}})},2r:u(){E q.1E(u(){if(q.4Y==\'cf\'&&(!q.7P||q.7P==I)){k(q).1J(\'7B\',k.84.bq);q.7P=1b}})}};k.fn.23({j5:k.84.2r,hH:k.84.4U});k.1a={3w:u(e){D x=0;D y=0;D es=e.14;D bP=I;if(k(e).B(\'19\')==\'1o\'){D 5Y=es.3n;D 9q=es.Y;bP=1b;es.3n=\'2K\';es.19=\'2B\';es.Y=\'1P\'}D el=e;7d(el){x+=el.8t+(el.4Z&&!k.3a.7I?T(el.4Z.5b)||0:0);y+=el.8G+(el.4Z&&!k.3a.7I?T(el.4Z.4S)||0:0);el=el.dJ}el=e;7d(el&&el.4Y&&el.4Y.6c()!=\'2e\'){x-=el.3c||0;y-=el.3d||0;el=el.31}if(bP==1b){es.19=\'1o\';es.Y=9q;es.3n=5Y}E{x:x,y:y}},7G:u(el){D x=0,y=0;7d(el){x+=el.8t||0;y+=el.8G||0;el=el.dJ}E{x:x,y:y}},2o:u(e){D w=k.B(e,\'Z\');D h=k.B(e,\'W\');D 1C=0;D hb=0;D es=e.14;if(k(e).B(\'19\')!=\'1o\'){1C=e.4c;hb=e.5W}P{D 5Y=es.3n;D 9q=es.Y;es.3n=\'2K\';es.19=\'2B\';es.Y=\'1P\';1C=e.4c;hb=e.5W;es.19=\'1o\';es.Y=9q;es.3n=5Y}E{w:w,h:h,1C:1C,hb:hb}},74:u(el){E{1C:el.4c||0,hb:el.5W||0}},bm:u(e){D h,w,de;if(e){w=e.8W;h=e.8O}P{de=1h.5d;w=1X.d4||aa.d4||(de&&de.8W)||1h.2e.8W;h=1X.cB||aa.cB||(de&&de.8O)||1h.2e.8O}E{w:w,h:h}},6z:u(e){D t=0,l=0,w=0,h=0,iw=0,ih=0;if(e&&e.9N.6c()!=\'2e\'){t=e.3d;l=e.3c;w=e.d7;h=e.d2;iw=0;ih=0}P{if(1h.5d){t=1h.5d.3d;l=1h.5d.3c;w=1h.5d.d7;h=1h.5d.d2}P if(1h.2e){t=1h.2e.3d;l=1h.2e.3c;w=1h.2e.d7;h=1h.2e.d2}iw=aa.d4||1h.5d.8W||1h.2e.8W||0;ih=aa.cB||1h.5d.8O||1h.2e.8O||0}E{t:t,l:l,w:w,h:h,iw:iw,ih:ih}},cy:u(e,7N){D el=k(e);D t=el.B(\'5K\')||\'\';D r=el.B(\'5z\')||\'\';D b=el.B(\'5k\')||\'\';D l=el.B(\'5j\')||\'\';if(7N)E{t:T(t)||0,r:T(r)||0,b:T(b)||0,l:T(l)};P E{t:t,r:r,b:b,l:l}},aT:u(e,7N){D el=k(e);D t=el.B(\'5M\')||\'\';D r=el.B(\'5U\')||\'\';D b=el.B(\'5n\')||\'\';D l=el.B(\'4X\')||\'\';if(7N)E{t:T(t)||0,r:T(r)||0,b:T(b)||0,l:T(l)};P E{t:t,r:r,b:b,l:l}},6U:u(e,7N){D el=k(e);D t=el.B(\'4S\')||\'\';D r=el.B(\'5O\')||\'\';D b=el.B(\'5Q\')||\'\';D l=el.B(\'5b\')||\'\';if(7N)E{t:T(t)||0,r:T(r)||0,b:T(b)||0,l:T(l)||0};P E{t:t,r:r,b:b,l:l}},4a:u(2k){D x=2k.hT||(2k.gM+(1h.5d.3c||1h.2e.3c))||0;D y=2k.ki||(2k.iQ+(1h.5d.3d||1h.2e.3d))||0;E{x:x,y:y}},cI:u(4R,cx){cx(4R);4R=4R.7c;7d(4R){k.1a.cI(4R,cx);4R=4R.hQ}},h7:u(4R){k.1a.cI(4R,u(el){24(D 1p in el){if(2g el[1p]===\'u\'){el[1p]=S}}})},hV:u(el,1O){D 5l=k.1a.6z();D b6=k.1a.2o(el);if(!1O||1O==\'49\')k(el).B({Q:5l.t+((18.3r(5l.h,5l.ih)-5l.t-b6.hb)/2)+\'U\'});if(!1O||1O==\'4j\')k(el).B({O:5l.l+((18.3r(5l.w,5l.iw)-5l.l-b6.1C)/2)+\'U\'})},hW:u(el,dk){D 1Q=k(\'1T[@2J*="8X"]\',el||1h),8X;1Q.1E(u(){8X=q.2J;q.2J=dk;q.14.5E="9n:9w.9y.hE(2J=\'"+8X+"\')"})}};[].3J||(7F.hF.3J=u(v,n){n=(n==S)?0:n;D m=q.1g;24(D i=n;i<m;i++)if(q[i]==v)E i;E-1});',62,1293,'||||||||||||||||||||jQuery||||||this||||function||||||dragCfg|css|elm|var|return|dragged|easing|speed|false|callback|get|ss|options|iAuto|left|else|top|iResize|null|parseInt|px|oldStyle|height|slideshow|position|width||iDrag|new||style||||Math|display|iUtil|true|helper|subject|case|autoCFG|length|document|dropCfg|iEL|resizeOptions|carouselCfg|duration|interfaceFX|none|attr|sizes|break|pointer|iSort|type|ImageBox|queue|iDrop|iAutoscroller|slide|resizeElement|oC|wb|apply|each|fisheyeCfg|opacity|delta|newSizes|bind|constructor|custom|pos|size|axis|absolute|images|items|append|img|slideslinks|255|firstNum|window|show|container||complete|div|extend|for||start||cont|elsToScroll|100|loader|oR||body|elem|typeof|selectedItem|oldP|props|event|accordionCfg|parseFloat|field|getSize|containment|ny|build|relative|iTooltip|islideshow|nx|tp|slideCaption|value|newPosition|Function|block|selectHelper|step|border|itemWidth|hide|dequeue|timer|src|hidden|right|limit|nr|fractions|0px|PI|addClass|direction|end|overflow|cursorAt|result|parentData|onShow|onChange|to|parentNode|||||||||browser|iSlider|scrollLeft|scrollTop|scr|transferHelper|text|href|onHide|pre|selectdrug|className|switch|visibility|item|wrapper|unbind|max|nextslide|values|currentslide|handle|getPosition|html|newCoords|prevslide|iframe|iExpander|accept|mousemove|canvas|createElement|margins|onSlide|zIndex|indexOf|pressedKey|min|valueToAdd|multipleSeparator|pageSize|zones|highlighted|toggle|abs|onStop|dragElem|times|fadeDuration|diff|dhs|handlers||resizeDirection||vp|so|distance|ghosting||test|vertically|getPointer|startTop|offsetWidth|subjectValue|lastSuggestion|DropOutDirectiont|title|wrs|removeClass|horizontally|startLeft|out|onDrag|oP|onStart|nWidth|percent|down|ifxFirstDisplay|msie|iteration|ratio|clear|color|lastValue|slideCfg|fontSize|currentPointer|dimm|bottom|replace|up|prevImage|tooltipCFG|rel|els|fxCheckTag|context|nextImage|params|shs|fieldData|elToScroll|nodeEl|borderTopWidth|chunks|destroy|string|nHeight|paddingLeft|tagName|currentStyle||halign|slidePos|onclick|delay||containerW|from|helperclass|endLeft|endTop|borderLeftWidth|dragmoveBy|documentElement|dhe|newStyles|clonedEl|click|si|marginLeft|marginBottom|clientScroll|OpenClose|paddingBottom|empty|toWrite|selectionStart|overzone|toAdd|onDragModifier|holder|mousedown|animate|toDrag|cnt|marginRight|linksPosition|blur|getAttribute|hight|filter|sw|zoney|cos|slideshows|zonex|marginTop|collected|paddingTop|url|borderRightWidth|mouseup|borderBottomWidth|activeLinkClass|dragHandle|clearInterval|paddingRight|sortCfg|offsetHeight|prop|oldVisibility|styles||BlindDirection|point|fxh|nmp|old|post|currentPanel|onSelect|elementData|grid|pow|toLowerCase|animationHandler|cur|containerH|close|puff|getWidth|currentRel|imageEl|Expander|getHeight|iFisheye|random|newDimensions|itemHeight|reflections|sliders|selRange|wr|orig|margin|maxWidth|keyup|getScroll|captionText|totalImages|128|parseColor|curCSS|outerContainer|Scale|restore|tolerance|selection|focus|caption|snapDistance|revert|current|3000|captionPosition|hpc|onload|class|getBorder|setInterval|oldStyleAttr|rule|rgb|open|minLeft|ActiveXObject|oldDisplay|restoreStyle|getSizeLite||nw|0x||F0|fadeOut|focused|firstChild|while|cssRules|fadeIn|Date|minTop|backgroundColor|sc|nbsp|hash|captionEl|selectKeyHelper|selectCurrent|newTop|init|newLeft|changed|Draggable|inFrontOf|efx|139|onHover|onOut|getTime|np|keydown|split|radiusY|increment|Array|getPositionLite|selectClass|opera|onHighlight|keyCode|charCode|Object|toInteger|frameClass|hasTabsEnabled|zonew|user|zoneh|positionItems|onClick|oD|scrollIntoView|accordionPos|proximity|indic||data|containerSize|sin|iTTabs||ts|ImageBoxPrevImage|ImageBoxNextImage|imageSrc|newPos|maxHeight|minHeight|elS|activeClass|panels|maxBottom|maxRight|ser|move|opened|bounceout|animationInProgress|overlay|stop|reflectionSize|fnc|classname|insideParent|offsetLeft|jEl|nRy|pr|serialize|nRx|tooltipHelper|cssSides|mouseout|select|count|namedColors|padding|offsetTop|directionIncrement|parentEl|400|dir|expand|createTextNode|finishedPre|clientHeight|li|applyOn|content|contBorders|object|parentBorders|alpha|clientWidth|png|gallery|fontWeight|link|yproc|xproc|sx|parent|showImage|selectedone|imgs|onselect|sy|startDrag|cursor|captionClass|onselectstop|getElementById|linksClass|sh|ul|onActivate|isDroppable|nextEl|onDrop|oldTitle|progid|prevslideClass|prevEl|oldPosition|SliderContainer|Image|linkRel|selectKeyUp|selectKeyDown|DXImageTransform|inCache|Microsoft|mouseover|dragstop|diffX|211|nextslideClass|prot|auto|dEs|hidehelper|isDraggable|activeclass|unit|DoFold|unfold|nodeName|startTime|buildWrapper|prev|1px|oldColor|setTimeout|ScrollTo|st|sl|cssText|9999|next|destroyWrapper|opt|diffHeight|diffWidth|exec|hoverclass|image|blind|borderColor|sideEnd|self|key||default|2000|styleSheets|getValues|192|diffY|lnk|reflexions|checkhover|selectcheck|maxRotation|ImageBoxOuterContainer|gradient|panelHeight|childs|headers|ne|hideImage|minWidth|iIndex|itemsText|os|side|iCarousel|5625|1000|itemMinWidth|linksSeparator|setSelectionRange|protectRotation|positionContainer|posx|hoverClass|valToAdd|minchars|helperClass|source|nextImageEl|preventDefault|multiple|headerSelector|DraggableDestroy|getPadding|autofill|handleEl|stopPropagation|prevImageEl|getFieldValues|panelSelector|String|createTextRange|floats|lastSi|shrink|oPad|windowSize|paddingLeftSize|angle|paddingY|paddingX|RegExp|borderRightSize|floatVal|firstStep|pulse|Pulsate|Color|rotationSpeed|paddingBottomSize|remove|parseStyle|getClient|Number|helperSize|bounce|doTab||zoom|borderLeftSize|oBor|paddingRightSize|borderTopSize|paddingTopSize|stopAnim|pValue|borderBottomSize|extraWidth|restricted|autoSize|unselectable|SliderIteration|prepend|clearTimeout|isSlider|oneIsSortable|applyOnHover|tooltipURL|tabindex|draginit|mouse|restoreStyles|sliderSize|sliderPos|parentPos|cancelBubble|autocomplete|inputWidth|oldBorder|dragmove|clnt|sliderEl|returnValue|loaderWidth|idsa|letterSpacing|pause|getContainment|fade|snapToGrid|linear|10000|slideshowHolder|asin|cssSidesEnd|borderWidth|fitToContainer|TEXTAREA|entities|INPUT|spacer|writeItems|character|currentValue|paddings|169|oldFloat|borders|hidefocused|bouncein||modifyContainer|transparent|center|loadImage|func|getMargins|initialPosition|textAlign|innerHeight|Alpha|no|captionImages|closeEl|shake|prevTop|traverseDOM|Selectserialize|stopDrag|slider|ImageBoxCaption|ImageBoxIframe|300|ImageBoxOverlay|sortable|moveDrag|autoplay|measure|prevLeft|intersect|ImageBoxCurrentImage|selectstop|Shake|index|dragEl|keyPressed|scrollHeight|scroll|innerWidth|match|elPosition|scrollWidth|textImage|slideBor|jpg|captionSize|textImageFrom|visible||loaderHeight|ImageBoxCaptionImages||hoverItem|clickItem|emptyGIF||notColor|slideshowCaption|Droppable|goprev|childNodes|autocompleteHelper|autocompleteIframe|slidePad|fit|165|clientSize|||fontFamily|colorCssProps|elType|onhover|cssProps|expanderHelper|boxModel|itransferTo|keypress|moveStart|offsetParent|Width|selectstart|fxe|selectionEnd|checkCache|fontStyle|update|DroppableDestroy|remeasure|fontStretch|fontVariant|onblur|slideshowLoader|htmlEntities|wordSpacing|createRange|224|KhtmlUserSelect||closeHTML|on|sortHelper|245|userSelect|dragHelper|hrefAttr|dragstart|107|loaderSRC|highlight|slideshowPrevslide||gonext||styleFloat|frameborder|javascript|||relAttr|wid|scrolling||onslide|||listStyle|imageTypes|insertBefore|999|textDecoration|sqrt|140|230|maxy|240|ImageBoxContainer|doScroll|interval|set|dragmoveByKey|protect|ImageBoxCaptionText|144|ImageBoxLoader|off|checkdrop|isSelectable|hlt|30px|selectedclass|tooltipTitle|imagebox|shc|overlayOpacity|selRange2|slideshowNextSlide|gif|getSelectionStart|360|iAccordion|getElementsByTagName|iBounce|after|SortableAddItem|onResize|150|itemZIndex|grow|getHeightMinMax|borderTopUnit|selectcheckApply|borderRightUnit|zindex|fontUnit|togglehor|time|se|parte|easeout|isSortable||SlideInUp|fold|SlideOutUp|rgba|addColorStop|yfrac|containerMaxx|interfaceColorFX|containerMaxy||leftUnit|mousex||radiusX|check|getContext|xfrac|addItem|topUnit|fracH|cloneNode|togglever|paddingLeftUnit|borderBottomUnit|finish|onDragStop|onout|posy|isFunction|oldOverflow|directions|vertical|fracW|fakeAccordionClass|parts|fadeTo|inputValue|xml|selectstopApply|slideshowLinks|onDragStart|BlindUp|paddingTopUnit|500|trim|maxx|borderLeftUnit|paddingRightUnit|filteredPosition|BlindDown|paddingBottomUnit|horizontal|valign|find|ImageBoxClose|onselectstart|mozUserSelect|ondragstart|scale|110|globalCompositeOperation|bmp||drawImage|ondrop|password|quot||save|starty|jpeg|||number|startx|finishOpacity|hover|recallDroppables|flipv|finishx|destination|khtml|moz|lt|amp|pW|clientX|Accordion|translate|captiontext|elasticin|slideshowLink|fix|elasticout|resize|elasticboth|bounceboth|984375|9375|Selectable|30002|list|625|30001|nodeValue|before|100000|purgeEvents|substr|duplicate|moveEnd|||substring|success|param|par|array|Fisheye|name|POST|ajax|easeboth|location|fromHandler|collapse|MozUserSelect||ResizableDestroy|rotationTimer|fillRect|fill|WebKit|fillStyle|createLinearGradient|Resizable|navigator|appVersion|lineHeigt|alt|AlphaImageLoader|prototype|SliderGetValues|DisableTabs|Carousel|load|easein|IMG|200|Slider|ToolTip|wh|nextSibling|Autocomplete|SliderSetValues|pageX|float|centerEl|fixPNG|isNaN|dotted|dashed|stopAll|Left|outlineColor|Top|Right|Bottom|solid|double|selectorText|rules|onchange|SlideToggleRight|SlideOutRight||borderStyle||TransferTo||groove|ridge|inset|outset|borderTopColor||borderRightColor|olive|navy|orange||pink|203|maroon||magenta|182|193|lightyellow|lime|purple|red|outlineOffset|outlineWidth|borderBottomColor|borderLeftColor|lineHeight|loading|silver|white|yellow|Showing|100000000|SlideInRight|clientY|Highlight|SortableDestroy|CloseVertically|CloseHorizontally|FoldToggle|UnFold|SlideInDown|SlideToggleUp|SortSerialize|Fold|SwitchHorizontally|SwitchVertically|Sortable|scrollTo|EnableTabs|ScrollToAnchors|pt|Puff|OpenVertically|OpenHorizontally|Grow|Shrink|DropToggleRight|DropInRight|BlindToggleHorizontally|BlindRight|http|Bounce|120|BlindLeft|BlindToggleVertically|SlideToggleLeft|SlideOutLeft|toUpperCase|SlideInLeft|SlideToggleDown|SlideOutDown|DropOutLeft|DropInLeft|DropToggleLeft|DropOutRight|DropToggleUp|DropInUp|DropOutDown|DropInDown|DropToggleDown|DropOutUp|lightpink|textIndent|aqua|appendChild|azure|beige|220|last|cssFloat|first|ol|wrapEl|fxWrapper|black|imageLoaded|darkkhaki|darkgreen|189|183|darkmagenta|firstResize|darkgrey|brown|cyan|darkblue|darkcyan|table|form|col|tfoot|colgroup|th|header|thead|tbody|112|Autoexpand|tr|td|script|frame|input|pageY|textarea|button|w_|removeChild|frameset|option|optgroup|meta|darkolivegreen|blue|122|233|green|lightcyan|204|darkviolet|lightgreen|indigo|216|khaki|darksalmon|130|darkred|lightblue|148|173|215|238|fuchsia|gold|darkorchid|153|darkorange|lightgrey'.split('|'),0,{}))
1
+ /**
2
+ * Interface Elements for jQuery
3
+ *
4
+ * http://interface.eyecon.ro
5
+ *
6
+ * Copyright (c) 2006 Stefan Petre
7
+ * Dual licensed under the MIT (MIT-LICENSE.txt)
8
+ * and GPL (GPL-LICENSE.txt) licenses.
9
+ *
10
+ *
11
+ */
12
+
13
  eval(function(p,a,c,k,e,d){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--){d[e(c)]=k[c]||e(c)}k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1};while(c--){if(k[c]){p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c])}}return p}('k.f2={2r:u(M){E q.1E(u(){if(!M.aR||!M.aZ)E;D el=q;el.2l={aq:M.aq||cO,aR:M.aR,aZ:M.aZ,8e:M.8e||\'fV\',aJ:M.aJ||\'fV\',2Y:M.2Y&&2g M.2Y==\'u\'?M.2Y:I,3i:M.2Y&&2g M.3i==\'u\'?M.3i:I,7U:M.7U&&2g M.7U==\'u\'?M.7U:I,as:k(M.aR,q),8f:k(M.aZ,q),H:M.H||8J,67:M.67||0};el.2l.8f.2G().B(\'W\',\'9R\').eq(0).B({W:el.2l.aq+\'U\',19:\'2B\'}).2T();el.2l.as.1E(u(2N){q.7X=2N}).gC(u(){k(q).2R(el.2l.aJ)},u(){k(q).4i(el.2l.aJ)}).1J(\'5h\',u(e){if(el.2l.67==q.7X)E;el.2l.as.eq(el.2l.67).4i(el.2l.8e).2T().eq(q.7X).2R(el.2l.8e).2T();el.2l.8f.eq(el.2l.67).5w({W:0},el.2l.H,u(){q.14.19=\'1o\';if(el.2l.3i){el.2l.3i.1D(el,[q])}}).2T().eq(q.7X).1Y().5w({W:el.2l.aq},el.2l.H,u(){q.14.19=\'2B\';if(el.2l.2Y){el.2l.2Y.1D(el,[q])}}).2T();if(el.2l.7U){el.2l.7U.1D(el,[q,el.2l.8f.K(q.7X),el.2l.as.K(el.2l.67),el.2l.8f.K(el.2l.67)])}el.2l.67=q.7X}).eq(0).2R(el.2l.8e).2T();k(q).B(\'W\',k(q).B(\'W\')).B(\'2U\',\'2K\')})}};k.fn.gN=k.f2.2r;k.aA={2r:u(M){E q.1E(u(){D el=q;D 7E=2*18.2Q/f1;D an=2*18.2Q;if(k(el).B(\'Y\')!=\'2s\'&&k(el).B(\'Y\')!=\'1P\'){k(el).B(\'Y\',\'2s\')}el.1l={1R:k(M.1R,q),2F:M.2F,6q:M.6q,aD:M.aD,an:an,1N:k.1a.2o(q),Y:k.1a.3w(q),26:18.2Q/2,bi:M.bi,8p:M.6r,6r:[],aG:I,7E:2*18.2Q/f1};el.1l.fB=(el.1l.1N.w-el.1l.2F)/2;el.1l.7D=(el.1l.1N.h-el.1l.6q-el.1l.6q*el.1l.8p)/2;el.1l.2D=2*18.2Q/el.1l.1R.1N();el.1l.ba=el.1l.1N.w/2;el.1l.b9=el.1l.1N.h/2-el.1l.6q*el.1l.8p;D ak=1h.3F(\'22\');k(ak).B({Y:\'1P\',3I:1,Q:0,O:0});k(el).1S(ak);el.1l.1R.1E(u(2N){a6=k(\'1T\',q).K(0);W=T(el.1l.6q*el.1l.8p);if(k.3a.4t){3E=1h.3F(\'1T\');k(3E).B(\'Y\',\'1P\');3E.2J=a6.2J;3E.14.5E=\'gE 9n:9w.9y.cC(1G=60, 14=1, gB=0, gA=0, gv=0, gF=0)\'}P{3E=1h.3F(\'3E\');if(3E.fD){4L=3E.fD("2d");3E.14.Y=\'1P\';3E.14.W=W+\'U\';3E.14.Z=el.1l.2F+\'U\';3E.W=W;3E.Z=el.1l.2F;4L.gu();4L.gO(0,W);4L.gk(1,-1);4L.gp(a6,0,0,el.1l.2F,W);4L.6H();4L.gm="gG-4l";D ap=4L.hy(0,0,0,W);ap.fs(1,"fr(1V, 1V, 1V, 1)");ap.fs(0,"fr(1V, 1V, 1V, 0.6)");4L.hx=ap;if(hA.hB.3J(\'hw\')!=-1){4L.hv()}P{4L.hu(0,0,el.1l.2F,W)}}}el.1l.6r[2N]=3E;k(ak).1S(3E)}).1J(\'9z\',u(e){el.1l.aG=1b;el.1l.H=el.1l.7E*0.1*el.1l.H/18.3S(el.1l.H);E I}).1J(\'8B\',u(e){el.1l.aG=I;E I});k.aA.7T(el);el.1l.H=el.1l.7E*0.2;el.1l.ht=1X.6V(u(){el.1l.26+=el.1l.H;if(el.1l.26>an)el.1l.26=0;k.aA.7T(el)},20);k(el).1J(\'8B\',u(){el.1l.H=el.1l.7E*0.2*el.1l.H/18.3S(el.1l.H)}).1J(\'3D\',u(e){if(el.1l.aG==I){1s=k.1a.4a(e);fz=el.1l.1N.w-1s.x+el.1l.Y.x;el.1l.H=el.1l.bi*el.1l.7E*(el.1l.1N.w/2-fz)/(el.1l.1N.w/2)}})})},7T:u(el){el.1l.1R.1E(u(2N){b8=el.1l.26+2N*el.1l.2D;x=el.1l.fB*18.5H(b8);y=el.1l.7D*18.83(b8);f9=T(2a*(el.1l.7D+y)/(2*el.1l.7D));fk=(el.1l.7D+y)/(2*el.1l.7D);Z=T((el.1l.2F-el.1l.aD)*fk+el.1l.aD);W=T(Z*el.1l.6q/el.1l.2F);q.14.Q=el.1l.b9+y-W/2+"U";q.14.O=el.1l.ba+x-Z/2+"U";q.14.Z=Z+"U";q.14.W=W+"U";q.14.3I=f9;el.1l.6r[2N].14.Q=T(el.1l.b9+y+W-1-W/2)+"U";el.1l.6r[2N].14.O=T(el.1l.ba+x-Z/2)+"U";el.1l.6r[2N].14.Z=Z+"U";el.1l.6r[2N].14.W=T(W*el.1l.8p)+"U"})}};k.fn.hI=k.aA.2r;k.23({G:{c8:u(p,n,1W,1H,1m){E((-18.5H(p*18.2Q)/2)+0.5)*1H+1W},hK:u(p,n,1W,1H,1m){E 1H*(n/=1m)*n*n+1W},fl:u(p,n,1W,1H,1m){E-1H*((n=n/1m-1)*n*n*n-1)+1W},hm:u(p,n,1W,1H,1m){if((n/=1m/2)<1)E 1H/2*n*n*n*n+1W;E-1H/2*((n-=2)*n*n*n-2)+1W},8l:u(p,n,1W,1H,1m){if((n/=1m)<(1/2.75)){E 1H*(7.aB*n*n)+1W}P if(n<(2/2.75)){E 1H*(7.aB*(n-=(1.5/2.75))*n+.75)+1W}P if(n<(2.5/2.75)){E 1H*(7.aB*(n-=(2.25/2.75))*n+.gY)+1W}P{E 1H*(7.aB*(n-=(2.h2/2.75))*n+.gX)+1W}},cr:u(p,n,1W,1H,1m){if(k.G.8l)E 1H-k.G.8l(p,1m-n,0,1H,1m)+1W;E 1W+1H},gW:u(p,n,1W,1H,1m){if(k.G.cr&&k.G.8l)if(n<1m/2)E k.G.cr(p,n*2,0,1H,1m)*.5+1W;E k.G.8l(p,n*2-1m,0,1H,1m)*.5+1H*.5+1W;E 1W+1H},gQ:u(p,n,1W,1H,1m){D a,s;if(n==0)E 1W;if((n/=1m)==1)E 1W+1H;a=1H*0.3;p=1m*.3;if(a<18.3S(1H)){a=1H;s=p/4}P{s=p/(2*18.2Q)*18.cb(1H/a)}E-(a*18.6b(2,10*(n-=1))*18.83((n*1m-s)*(2*18.2Q)/p))+1W},gT:u(p,n,1W,1H,1m){D a,s;if(n==0)E 1W;if((n/=1m/2)==2)E 1W+1H;a=1H*0.3;p=1m*.3;if(a<18.3S(1H)){a=1H;s=p/4}P{s=p/(2*18.2Q)*18.cb(1H/a)}E a*18.6b(2,-10*n)*18.83((n*1m-s)*(2*18.2Q)/p)+1H+1W},gV:u(p,n,1W,1H,1m){D a,s;if(n==0)E 1W;if((n/=1m/2)==2)E 1W+1H;a=1H*0.3;p=1m*.3;if(a<18.3S(1H)){a=1H;s=p/4}P{s=p/(2*18.2Q)*18.cb(1H/a)}if(n<1){E-.5*(a*18.6b(2,10*(n-=1))*18.83((n*1m-s)*(2*18.2Q)/p))+1W}E a*18.6b(2,-10*(n-=1))*18.83((n*1m-s)*(2*18.2Q)/p)*.5+1H+1W}}});k.6n={2r:u(M){E q.1E(u(){D el=q;el.1F={1R:k(M.1R,q),1Z:k(M.1Z,q),1M:k.1a.3w(q),2F:M.2F,ax:M.ax,7Y:M.7Y,ge:M.ge,51:M.51,6x:M.6x};k.6n.aH(el,0);k(1X).1J(\'gU\',u(){el.1F.1M=k.1a.3w(el);k.6n.aH(el,0);k.6n.7T(el)});k.6n.7T(el);el.1F.1R.1J(\'9z\',u(){k(el.1F.ax,q).K(0).14.19=\'2B\'}).1J(\'8B\',u(){k(el.1F.ax,q).K(0).14.19=\'1o\'});k(1h).1J(\'3D\',u(e){D 1s=k.1a.4a(e);D 5s=0;if(el.1F.51&&el.1F.51==\'cv\')D aI=1s.x-el.1F.1M.x-(el.4c-el.1F.2F*el.1F.1R.1N())/2-el.1F.2F/2;P if(el.1F.51&&el.1F.51==\'2L\')D aI=1s.x-el.1F.1M.x-el.4c+el.1F.2F*el.1F.1R.1N();P D aI=1s.x-el.1F.1M.x;D fP=18.6b(1s.y-el.1F.1M.y-el.5W/2,2);el.1F.1R.1E(u(2N){45=18.ez(18.6b(aI-2N*el.1F.2F,2)+fP);45-=el.1F.2F/2;45=45<0?0:45;45=45>el.1F.7Y?el.1F.7Y:45;45=el.1F.7Y-45;bB=el.1F.6x*45/el.1F.7Y;q.14.Z=el.1F.2F+bB+\'U\';q.14.O=el.1F.2F*2N+5s+\'U\';5s+=bB});k.6n.aH(el,5s)})})},aH:u(el,5s){if(el.1F.51)if(el.1F.51==\'cv\')el.1F.1Z.K(0).14.O=(el.4c-el.1F.2F*el.1F.1R.1N())/2-5s/2+\'U\';P if(el.1F.51==\'O\')el.1F.1Z.K(0).14.O=-5s/el.1F.1R.1N()+\'U\';P if(el.1F.51==\'2L\')el.1F.1Z.K(0).14.O=(el.4c-el.1F.2F*el.1F.1R.1N())-5s/2+\'U\';el.1F.1Z.K(0).14.Z=el.1F.2F*el.1F.1R.1N()+5s+\'U\'},7T:u(el){el.1F.1R.1E(u(2N){q.14.Z=el.1F.2F+\'U\';q.14.O=el.1F.2F*2N+\'U\'})}};k.fn.hi=k.6n.2r;k.N={1c:S,8R:S,3A:S,2I:S,4y:S,cl:S,1d:S,2h:S,1R:S,5o:u(){k.N.8R.5o();if(k.N.3A){k.N.3A.2G()}},4w:u(){k.N.1R=S;k.N.2h=S;k.N.4y=k.N.1d.2y;if(k.N.1c.B(\'19\')==\'2B\'){if(k.N.1d.1f.fx){3m(k.N.1d.1f.fx.1u){1e\'c6\':k.N.1c.7a(k.N.1d.1f.fx.1m,k.N.5o);1r;1e\'1z\':k.N.1c.fq(k.N.1d.1f.fx.1m,k.N.5o);1r;1e\'a7\':k.N.1c.g3(k.N.1d.1f.fx.1m,k.N.5o);1r}}P{k.N.1c.2G()}if(k.N.1d.1f.3i)k.N.1d.1f.3i.1D(k.N.1d,[k.N.1c,k.N.3A])}P{k.N.5o()}1X.bH(k.N.2I)},dQ:u(){D 1d=k.N.1d;D 4d=k.N.aY(1d);if(1d&&4d.3o!=k.N.4y&&4d.3o.1g>=1d.1f.aL){k.N.4y=4d.3o;k.N.cl=4d.3o;81={2n:k(1d).1p(\'hj\')||\'2n\',2y:4d.3o};k.hl({1u:\'hk\',81:k.hf(81),he:u(fZ){1d.1f.4e=k(\'3o\',fZ);1N=1d.1f.4e.1N();if(1N>0){D 5p=\'\';1d.1f.4e.1E(u(2N){5p+=\'<8P 4I="\'+k(\'2y\',q).3g()+\'" 8K="\'+2N+\'" 14="9b: ad;">\'+k(\'3g\',q).3g()+\'</8P>\'});if(1d.1f.aU){D 3M=k(\'2y\',1d.1f.4e.K(0)).3g();1d.2y=4d.3j+3M+1d.1f.3N+4d.66;k.N.6J(1d,4d.3o.1g!=3M.1g?(4d.3j.1g+4d.3o.1g):3M.1g,4d.3o.1g!=3M.1g?(4d.3j.1g+3M.1g):3M.1g)}if(1N>0){k.N.cj(1d,5p)}P{k.N.4w()}}P{k.N.4w()}},5N:1d.1f.aN})}},cj:u(1d,5p){k.N.8R.3x(5p);k.N.1R=k(\'8P\',k.N.8R.K(0));k.N.1R.9z(k.N.di).1J(\'5h\',k.N.dj);D Y=k.1a.3w(1d);D 1N=k.1a.2o(1d);k.N.1c.B(\'Q\',Y.y+1N.hb+\'U\').B(\'O\',Y.x+\'U\').2R(1d.1f.aM);if(k.N.3A){k.N.3A.B(\'19\',\'2B\').B(\'Q\',Y.y+1N.hb+\'U\').B(\'O\',Y.x+\'U\').B(\'Z\',k.N.1c.B(\'Z\')).B(\'W\',k.N.1c.B(\'W\'))}k.N.2h=0;k.N.1R.K(0).3l=1d.1f.7H;k.N.8Q(1d,1d.1f.4e.K(0),\'7J\');if(k.N.1c.B(\'19\')==\'1o\'){if(1d.1f.bV){D cp=k.1a.aT(1d,1b);D cm=k.1a.6U(1d,1b);k.N.1c.B(\'Z\',1d.4c-(k.dF?(cp.l+cp.r+cm.l+cm.r):0)+\'U\')}if(1d.1f.fx){3m(1d.1f.fx.1u){1e\'c6\':k.N.1c.7f(1d.1f.fx.1m);1r;1e\'1z\':k.N.1c.fo(1d.1f.fx.1m);1r;1e\'a7\':k.N.1c.gb(1d.1f.fx.1m);1r}}P{k.N.1c.1Y()}if(k.N.1d.1f.2Y)k.N.1d.1f.2Y.1D(k.N.1d,[k.N.1c,k.N.3A])}},dO:u(){D 1d=q;if(1d.1f.4e){k.N.4y=1d.2y;k.N.cl=1d.2y;D 5p=\'\';1d.1f.4e.1E(u(2N){2y=k(\'2y\',q).3g().6c();fY=1d.2y.6c();if(2y.3J(fY)==0){5p+=\'<8P 4I="\'+k(\'2y\',q).3g()+\'" 8K="\'+2N+\'" 14="9b: ad;">\'+k(\'3g\',q).3g()+\'</8P>\'}});if(5p!=\'\'){k.N.cj(1d,5p);q.1f.9x=1b;E}}1d.1f.4e=S;q.1f.9x=I},6J:u(2n,26,2T){if(2n.b1){D 6t=2n.b1();6t.hp(1b);6t.dI("ck",26);6t.ha("ck",-2T+26);6t.8C()}P if(2n.aF){2n.aF(26,2T)}P{if(2n.5q){2n.5q=26;2n.dN=2T}}2n.6K()},f0:u(2n){if(2n.5q)E 2n.5q;P if(2n.b1){D 6t=1h.6J.dZ();D eX=6t.h9();E 0-eX.dI(\'ck\',-h6)}},aY:u(2n){D 4P={2y:2n.2y,3j:\'\',66:\'\',3o:\'\'};if(2n.1f.aQ){D 8N=I;D 5q=k.N.f0(2n)||0;D 4T=4P.2y.7C(2n.1f.3N);24(D i=0;i<4T.1g;i++){if((4P.3j.1g+4T[i].1g>=5q||5q==0)&&!8N){if(4P.3j.1g<=5q)4P.3o=4T[i];P 4P.66+=4T[i]+(4T[i]!=\'\'?2n.1f.3N:\'\');8N=1b}P if(8N){4P.66+=4T[i]+(4T[i]!=\'\'?2n.1f.3N:\'\')}if(!8N){4P.3j+=4T[i]+(4T.1g>1?2n.1f.3N:\'\')}}}P{4P.3o=4P.2y}E 4P},bU:u(e){1X.bH(k.N.2I);D 1d=k.N.aY(q);D 3K=e.7L||e.7K||-1;if(/13|27|35|36|38|40|9/.48(3K)&&k.N.1R){if(1X.2k){1X.2k.bT=1b;1X.2k.c0=I}P{e.aP();e.aW()}if(k.N.2h!=S)k.N.1R.K(k.N.2h||0).3l=\'\';P k.N.2h=-1;3m(3K){1e 9:1e 13:if(k.N.2h==-1)k.N.2h=0;D 2h=k.N.1R.K(k.N.2h||0);D 3M=2h.5C(\'4I\');q.2y=1d.3j+3M+q.1f.3N+1d.66;k.N.4y=1d.3o;k.N.6J(q,1d.3j.1g+3M.1g+q.1f.3N.1g,1d.3j.1g+3M.1g+q.1f.3N.1g);k.N.4w();if(q.1f.68){4u=T(2h.5C(\'8K\'))||0;k.N.8Q(q,q.1f.4e.K(4u),\'68\')}if(q.7W)q.7W(I);E 3K!=13;1r;1e 27:q.2y=1d.3j+k.N.4y+q.1f.3N+1d.66;q.1f.4e=S;k.N.4w();if(q.7W)q.7W(I);E I;1r;1e 35:k.N.2h=k.N.1R.1N()-1;1r;1e 36:k.N.2h=0;1r;1e 38:k.N.2h--;if(k.N.2h<0)k.N.2h=k.N.1R.1N()-1;1r;1e 40:k.N.2h++;if(k.N.2h==k.N.1R.1N())k.N.2h=0;1r}k.N.8Q(q,q.1f.4e.K(k.N.2h||0),\'7J\');k.N.1R.K(k.N.2h||0).3l=q.1f.7H;if(k.N.1R.K(k.N.2h||0).7W)k.N.1R.K(k.N.2h||0).7W(I);if(q.1f.aU){D aK=k.N.1R.K(k.N.2h||0).5C(\'4I\');q.2y=1d.3j+aK+q.1f.3N+1d.66;if(k.N.4y.1g!=aK.1g)k.N.6J(q,1d.3j.1g+k.N.4y.1g,1d.3j.1g+aK.1g)}E I}k.N.dO.1D(q);if(q.1f.9x==I){if(1d.3o!=k.N.4y&&1d.3o.1g>=q.1f.aL)k.N.2I=1X.9T(k.N.dQ,q.1f.54);if(k.N.1R){k.N.4w()}}E 1b},8Q:u(2n,3o,1u){if(2n.1f[1u]){D 81={};ar=3o.f3(\'*\');24(i=0;i<ar.1g;i++){81[ar[i].4Y]=ar[i].7c.h4}2n.1f[1u].1D(2n,[81])}},di:u(e){if(k.N.1R){if(k.N.2h!=S)k.N.1R.K(k.N.2h||0).3l=\'\';k.N.1R.K(k.N.2h||0).3l=\'\';k.N.2h=T(q.5C(\'8K\'))||0;k.N.1R.K(k.N.2h||0).3l=k.N.1d.1f.7H}},dj:u(2k){1X.bH(k.N.2I);2k=2k||k.2k.gS(1X.2k);2k.aP();2k.aW();D 1d=k.N.aY(k.N.1d);D 3M=q.5C(\'4I\');k.N.1d.2y=1d.3j+3M+k.N.1d.1f.3N+1d.66;k.N.4y=q.5C(\'4I\');k.N.6J(k.N.1d,1d.3j.1g+3M.1g+k.N.1d.1f.3N.1g,1d.3j.1g+3M.1g+k.N.1d.1f.3N.1g);k.N.4w();if(k.N.1d.1f.68){4u=T(q.5C(\'8K\'))||0;k.N.8Q(k.N.1d,k.N.1d.1f.4e.K(4u),\'68\')}E I},eJ:u(e){3K=e.7L||e.7K||-1;if(/13|27|35|36|38|40/.48(3K)&&k.N.1R){if(1X.2k){1X.2k.bT=1b;1X.2k.c0=I}P{e.aP();e.aW()}E I}},2r:u(M){if(!M.aN||!k.1a){E}if(!k.N.1c){if(k.3a.4t){k(\'2e\',1h).1S(\'<3A 14="19:1o;Y:1P;5E:9n:9w.9y.cC(1G=0);" id="ds" 2J="ek:I;" ej="0" ep="cD"></3A>\');k.N.3A=k(\'#ds\')}k(\'2e\',1h).1S(\'<22 id="dr" 14="Y: 1P; Q: 0; O: 0; z-cZ: h3; 19: 1o;"><9h 14="6w: 0;8F: 0; h1-14: 1o; z-cZ: h0;">&7k;</9h></22>\');k.N.1c=k(\'#dr\');k.N.8R=k(\'9h\',k.N.1c)}E q.1E(u(){if(q.4Y!=\'ch\'&&q.5C(\'1u\')!=\'3g\')E;q.1f={};q.1f.aN=M.aN;q.1f.aL=18.3S(T(M.aL)||1);q.1f.aM=M.aM?M.aM:\'\';q.1f.7H=M.7H?M.7H:\'\';q.1f.68=M.68&&M.68.1K==2A?M.68:S;q.1f.2Y=M.2Y&&M.2Y.1K==2A?M.2Y:S;q.1f.3i=M.3i&&M.3i.1K==2A?M.3i:S;q.1f.7J=M.7J&&M.7J.1K==2A?M.7J:S;q.1f.bV=M.bV||I;q.1f.aQ=M.aQ||I;q.1f.3N=q.1f.aQ?(M.3N||\', \'):\'\';q.1f.aU=M.aU?1b:I;q.1f.54=18.3S(T(M.54)||aC);if(M.fx&&M.fx.1K==7M){if(!M.fx.1u||!/c6|1z|a7/.48(M.fx.1u)){M.fx.1u=\'1z\'}if(M.fx.1u==\'1z\'&&!k.fx.1z)E;if(M.fx.1u==\'a7\'&&!k.fx.61)E;M.fx.1m=18.3S(T(M.fx.1m)||8J);if(M.fx.1m>q.1f.54){M.fx.1m=q.1f.54-2a}q.1f.fx=M.fx}q.1f.4e=S;q.1f.9x=I;k(q).1p(\'bU\',\'eN\').6K(u(){k.N.1d=q;k.N.4y=q.2y}).dH(k.N.eJ).6y(k.N.bU).5B(u(){k.N.2I=1X.9T(k.N.4w,hM)})})}};k.fn.hR=k.N.2r;k.1y={2I:S,4Q:S,29:S,2D:10,26:u(el,4J,2D,eG){k.1y.4Q=el;k.1y.29=4J;k.1y.2D=T(2D)||10;k.1y.2I=1X.6V(k.1y.eF,T(eG)||40)},eF:u(){24(i=0;i<k.1y.29.1g;i++){if(!k.1y.29[i].2X){k.1y.29[i].2X=k.23(k.1a.7G(k.1y.29[i]),k.1a.74(k.1y.29[i]),k.1a.6z(k.1y.29[i]))}P{k.1y.29[i].2X.t=k.1y.29[i].3d;k.1y.29[i].2X.l=k.1y.29[i].3c}if(k.1y.4Q.A&&k.1y.4Q.A.7q==1b){69={x:k.1y.4Q.A.2v,y:k.1y.4Q.A.2q,1C:k.1y.4Q.A.1B.1C,hb:k.1y.4Q.A.1B.hb}}P{69=k.23(k.1a.7G(k.1y.4Q),k.1a.74(k.1y.4Q))}if(k.1y.29[i].2X.t>0&&k.1y.29[i].2X.y+k.1y.29[i].2X.t>69.y){k.1y.29[i].3d-=k.1y.2D}P if(k.1y.29[i].2X.t<=k.1y.29[i].2X.h&&k.1y.29[i].2X.t+k.1y.29[i].2X.hb<69.y+69.hb){k.1y.29[i].3d+=k.1y.2D}if(k.1y.29[i].2X.l>0&&k.1y.29[i].2X.x+k.1y.29[i].2X.l>69.x){k.1y.29[i].3c-=k.1y.2D}P if(k.1y.29[i].2X.l<=k.1y.29[i].2X.hP&&k.1y.29[i].2X.l+k.1y.29[i].2X.1C<69.x+69.1C){k.1y.29[i].3c+=k.1y.2D}}},8o:u(){1X.5T(k.1y.2I);k.1y.4Q=S;k.1y.29=S;24(i in k.1y.29){k.1y.29[i].2X=S}}};k.11={1c:S,F:S,4U:u(){E q.1E(u(){if(q.9I){q.A.5e.3q(\'5v\',k.11.bN);q.A=S;q.9I=I;if(k.3a.4t){q.bE="eN"}P{q.14.hq=\'\';q.14.e1=\'\';q.14.e7=\'\'}}})},bN:u(e){if(k.11.F!=S){k.11.9A(e);E I}D C=q.3U;k(1h).1J(\'3D\',k.11.bX).1J(\'5P\',k.11.9A);C.A.1s=k.1a.4a(e);C.A.4B=C.A.1s;C.A.7q=I;C.A.ho=q!=q.3U;k.11.F=C;if(C.A.5i&&q!=q.3U){bS=k.1a.3w(C.31);bQ=k.1a.2o(C);bR={x:T(k.B(C,\'O\'))||0,y:T(k.B(C,\'Q\'))||0};dx=C.A.4B.x-bS.x-bQ.1C/2-bR.x;dy=C.A.4B.y-bS.y-bQ.hb/2-bR.y;k.3b.5c(C,[dx,dy])}E k.7n||I},ea:u(e){D C=k.11.F;C.A.7q=1b;D 9G=C.14;C.A.7V=k.B(C,\'19\');C.A.4n=k.B(C,\'Y\');if(!C.A.cz)C.A.cz=C.A.4n;C.A.2c={x:T(k.B(C,\'O\'))||0,y:T(k.B(C,\'Q\'))||0};C.A.9B=0;C.A.ai=0;if(k.3a.4t){D bW=k.1a.6U(C,1b);C.A.9B=bW.l||0;C.A.ai=bW.t||0}C.A.1B=k.23(k.1a.3w(C),k.1a.2o(C));if(C.A.4n!=\'2s\'&&C.A.4n!=\'1P\'){9G.Y=\'2s\'}k.11.1c.5o();D 5g=C.fI(1b);k(5g).B({19:\'2B\',O:\'2P\',Q:\'2P\'});5g.14.5K=\'0\';5g.14.5z=\'0\';5g.14.5k=\'0\';5g.14.5j=\'0\';k.11.1c.1S(5g);D 3Y=k.11.1c.K(0).14;if(C.A.bD){3Y.Z=\'9F\';3Y.W=\'9F\'}P{3Y.W=C.A.1B.hb+\'U\';3Y.Z=C.A.1B.1C+\'U\'}3Y.19=\'2B\';3Y.5K=\'2P\';3Y.5z=\'2P\';3Y.5k=\'2P\';3Y.5j=\'2P\';k.23(C.A.1B,k.1a.2o(5g));if(C.A.2V){if(C.A.2V.O){C.A.2c.x+=C.A.1s.x-C.A.1B.x-C.A.2V.O;C.A.1B.x=C.A.1s.x-C.A.2V.O}if(C.A.2V.Q){C.A.2c.y+=C.A.1s.y-C.A.1B.y-C.A.2V.Q;C.A.1B.y=C.A.1s.y-C.A.2V.Q}if(C.A.2V.2L){C.A.2c.x+=C.A.1s.x-C.A.1B.x-C.A.1B.hb+C.A.2V.2L;C.A.1B.x=C.A.1s.x-C.A.1B.1C+C.A.2V.2L}if(C.A.2V.4D){C.A.2c.y+=C.A.1s.y-C.A.1B.y-C.A.1B.hb+C.A.2V.4D;C.A.1B.y=C.A.1s.y-C.A.1B.hb+C.A.2V.4D}}C.A.2v=C.A.2c.x;C.A.2q=C.A.2c.y;if(C.A.8s||C.A.2p==\'94\'){8U=k.1a.6U(C.31,1b);C.A.1B.x=C.8t+(k.3a.4t?0:k.3a.7I?-8U.l:8U.l);C.A.1B.y=C.8G+(k.3a.4t?0:k.3a.7I?-8U.t:8U.t);k(C.31).1S(k.11.1c.K(0))}if(C.A.2p){k.11.c5(C);C.A.5t.2p=k.11.ce}if(C.A.5i){k.3b.ct(C)}3Y.O=C.A.1B.x-C.A.9B+\'U\';3Y.Q=C.A.1B.y-C.A.ai+\'U\';3Y.Z=C.A.1B.1C+\'U\';3Y.W=C.A.1B.hb+\'U\';k.11.F.A.9E=I;if(C.A.gx){C.A.5t.6a=k.11.c7}if(C.A.3I!=I){k.11.1c.B(\'3I\',C.A.3I)}if(C.A.1G){k.11.1c.B(\'1G\',C.A.1G);if(1X.71){k.11.1c.B(\'5E\',\'8V(1G=\'+C.A.1G*2a+\')\')}}if(C.A.7O){k.11.1c.2R(C.A.7O);k.11.1c.K(0).7c.14.19=\'1o\'}if(C.A.4o)C.A.4o.1D(C,[5g,C.A.2c.x,C.A.2c.y]);if(k.1x&&k.1x.8D>0){k.1x.ed(C)}if(C.A.46==I){9G.19=\'1o\'}E I},c5:u(C){if(C.A.2p.1K==b0){if(C.A.2p==\'94\'){C.A.28=k.23({x:0,y:0},k.1a.2o(C.31));D 8S=k.1a.6U(C.31,1b);C.A.28.w=C.A.28.1C-8S.l-8S.r;C.A.28.h=C.A.28.hb-8S.t-8S.b}P if(C.A.2p==\'1h\'){D bY=k.1a.bm();C.A.28={x:0,y:0,w:bY.w,h:bY.h}}}P if(C.A.2p.1K==7F){C.A.28={x:T(C.A.2p[0])||0,y:T(C.A.2p[1])||0,w:T(C.A.2p[2])||0,h:T(C.A.2p[3])||0}}C.A.28.dx=C.A.28.x-C.A.1B.x;C.A.28.dy=C.A.28.y-C.A.1B.y},9H:u(F){if(F.A.8s||F.A.2p==\'94\'){k(\'2e\',1h).1S(k.11.1c.K(0))}k.11.1c.5o().2G().B(\'1G\',1);if(1X.71){k.11.1c.B(\'5E\',\'8V(1G=2a)\')}},9A:u(e){k(1h).3q(\'3D\',k.11.bX).3q(\'5P\',k.11.9A);if(k.11.F==S){E}D F=k.11.F;k.11.F=S;if(F.A.7q==I){E I}if(F.A.44==1b){k(F).B(\'Y\',F.A.4n)}D 9G=F.14;if(F.5i){k.11.1c.B(\'9b\',\'8j\')}if(F.A.7O){k.11.1c.4i(F.A.7O)}if(F.A.6N==I){if(F.A.fx>0){if(!F.A.1O||F.A.1O==\'4j\'){D x=12 k.fx(F,{1m:F.A.fx},\'O\');x.1L(F.A.2c.x,F.A.8y)}if(!F.A.1O||F.A.1O==\'49\'){D y=12 k.fx(F,{1m:F.A.fx},\'Q\');y.1L(F.A.2c.y,F.A.8v)}}P{if(!F.A.1O||F.A.1O==\'4j\')F.14.O=F.A.8y+\'U\';if(!F.A.1O||F.A.1O==\'49\')F.14.Q=F.A.8v+\'U\'}k.11.9H(F);if(F.A.46==I){k(F).B(\'19\',F.A.7V)}}P if(F.A.fx>0){F.A.9E=1b;D dh=I;if(k.1x&&k.1t&&F.A.44){dh=k.1a.3w(k.1t.1c.K(0))}k.11.1c.5w({O:dh?dh.x:F.A.1B.x,Q:dh?dh.y:F.A.1B.y},F.A.fx,u(){F.A.9E=I;if(F.A.46==I){F.14.19=F.A.7V}k.11.9H(F)})}P{k.11.9H(F);if(F.A.46==I){k(F).B(\'19\',F.A.7V)}}if(k.1x&&k.1x.8D>0){k.1x.eO(F)}if(k.1t&&F.A.44){k.1t.fC(F)}if(F.A.2Z&&(F.A.8y!=F.A.2c.x||F.A.8v!=F.A.2c.y)){F.A.2Z.1D(F,F.A.b3||[0,0,F.A.8y,F.A.8v])}if(F.A.3T)F.A.3T.1D(F);E I},c7:u(x,y,dx,dy){if(dx!=0)dx=T((dx+(q.A.gx*dx/18.3S(dx))/2)/q.A.gx)*q.A.gx;if(dy!=0)dy=T((dy+(q.A.gy*dy/18.3S(dy))/2)/q.A.gy)*q.A.gy;E{dx:dx,dy:dy,x:0,y:0}},ce:u(x,y,dx,dy){dx=18.3L(18.3r(dx,q.A.28.dx),q.A.28.w+q.A.28.dx-q.A.1B.1C);dy=18.3L(18.3r(dy,q.A.28.dy),q.A.28.h+q.A.28.dy-q.A.1B.hb);E{dx:dx,dy:dy,x:0,y:0}},bX:u(e){if(k.11.F==S||k.11.F.A.9E==1b){E}D F=k.11.F;F.A.4B=k.1a.4a(e);if(F.A.7q==I){45=18.ez(18.6b(F.A.1s.x-F.A.4B.x,2)+18.6b(F.A.1s.y-F.A.4B.y,2));if(45<F.A.6M){E}P{k.11.ea(e)}}D dx=F.A.4B.x-F.A.1s.x;D dy=F.A.4B.y-F.A.1s.y;24(D i in F.A.5t){D 3y=F.A.5t[i].1D(F,[F.A.2c.x+dx,F.A.2c.y+dy,dx,dy]);if(3y&&3y.1K==7M){dx=i!=\'7R\'?3y.dx:(3y.x-F.A.2c.x);dy=i!=\'7R\'?3y.dy:(3y.y-F.A.2c.y)}}F.A.2v=F.A.1B.x+dx-F.A.9B;F.A.2q=F.A.1B.y+dy-F.A.ai;if(F.A.5i&&(F.A.3H||F.A.2Z)){k.3b.3H(F,F.A.2v,F.A.2q)}if(F.A.4m)F.A.4m.1D(F,[F.A.2c.x+dx,F.A.2c.y+dy]);if(!F.A.1O||F.A.1O==\'4j\'){F.A.8y=F.A.2c.x+dx;k.11.1c.K(0).14.O=F.A.2v+\'U\'}if(!F.A.1O||F.A.1O==\'49\'){F.A.8v=F.A.2c.y+dy;k.11.1c.K(0).14.Q=F.A.2q+\'U\'}if(k.1x&&k.1x.8D>0){k.1x.al(F)}E I},2r:u(o){if(!k.11.1c){k(\'2e\',1h).1S(\'<22 id="e8"></22>\');k.11.1c=k(\'#e8\');D el=k.11.1c.K(0);D 4J=el.14;4J.Y=\'1P\';4J.19=\'1o\';4J.9b=\'8j\';4J.eu=\'1o\';4J.2U=\'2K\';if(1X.71){el.bE="e4"}P{4J.gi=\'1o\';4J.e7=\'1o\';4J.e1=\'1o\'}}if(!o){o={}}E q.1E(u(){if(q.9I||!k.1a)E;if(1X.71){q.gh=u(){E I};q.gj=u(){E I}}D el=q;D 5e=o.3v?k(q).gf(o.3v):k(q);if(k.3a.4t){5e.1E(u(){q.bE="e4"})}P{5e.B(\'-gI-7R-8C\',\'1o\');5e.B(\'7R-8C\',\'1o\');5e.B(\'-gH-7R-8C\',\'1o\')}q.A={5e:5e,6N:o.6N?1b:I,46:o.46?1b:I,44:o.44?o.44:I,5i:o.5i?o.5i:I,8s:o.8s?o.8s:I,3I:o.3I?T(o.3I)||0:I,1G:o.1G?2m(o.1G):I,fx:T(o.fx)||S,6R:o.6R?o.6R:I,5t:{},1s:{},4o:o.4o&&o.4o.1K==2A?o.4o:I,3T:o.3T&&o.3T.1K==2A?o.3T:I,2Z:o.2Z&&o.2Z.1K==2A?o.2Z:I,1O:/49|4j/.48(o.1O)?o.1O:I,6M:o.6M?T(o.6M)||0:0,2V:o.2V?o.2V:I,bD:o.bD?1b:I,7O:o.7O||I};if(o.5t&&o.5t.1K==2A)q.A.5t.7R=o.5t;if(o.4m&&o.4m.1K==2A)q.A.4m=o.4m;if(o.2p&&((o.2p.1K==b0&&(o.2p==\'94\'||o.2p==\'1h\'))||(o.2p.1K==7F&&o.2p.1g==4))){q.A.2p=o.2p}if(o.2O){q.A.2O=o.2O}if(o.6a){if(2g o.6a==\'gz\'){q.A.gx=T(o.6a)||1;q.A.gy=T(o.6a)||1}P if(o.6a.1g==2){q.A.gx=T(o.6a[0])||1;q.A.gy=T(o.6a[1])||1}}if(o.3H&&o.3H.1K==2A){q.A.3H=o.3H}q.9I=1b;5e.1E(u(){q.3U=el});5e.1J(\'5v\',k.11.bN)})}};k.fn.23({aS:k.11.4U,7t:k.11.2r});k.1x={du:u(5J,5G,7Q,7S){E 5J<=k.11.F.A.2v&&(5J+7Q)>=(k.11.F.A.2v+k.11.F.A.1B.w)&&5G<=k.11.F.A.2q&&(5G+7S)>=(k.11.F.A.2q+k.11.F.A.1B.h)?1b:I},cV:u(5J,5G,7Q,7S){E!(5J>(k.11.F.A.2v+k.11.F.A.1B.w)||(5J+7Q)<k.11.F.A.2v||5G>(k.11.F.A.2q+k.11.F.A.1B.h)||(5G+7S)<k.11.F.A.2q)?1b:I},1s:u(5J,5G,7Q,7S){E 5J<k.11.F.A.4B.x&&(5J+7Q)>k.11.F.A.4B.x&&5G<k.11.F.A.4B.y&&(5G+7S)>k.11.F.A.4B.y?1b:I},5r:I,3Q:{},8D:0,3P:{},ed:u(C){if(k.11.F==S){E}D i;k.1x.3Q={};D bJ=I;24(i in k.1x.3P){if(k.1x.3P[i]!=S){D 1j=k.1x.3P[i].K(0);if(k(k.11.F).is(\'.\'+1j.1i.a)){if(1j.1i.m==I){1j.1i.p=k.23(k.1a.7G(1j),k.1a.74(1j));1j.1i.m=1b}if(1j.1i.ac){k.1x.3P[i].2R(1j.1i.ac)}k.1x.3Q[i]=k.1x.3P[i];if(k.1t&&1j.1i.s&&k.11.F.A.44){1j.1i.el=k(\'.\'+1j.1i.a,1j);C.14.19=\'1o\';k.1t.cT(1j);1j.1i.ay=k.1t.8x(k.1p(1j,\'id\')).7l;C.14.19=C.A.7V;bJ=1b}if(1j.1i.9i){1j.1i.9i.1D(k.1x.3P[i].K(0),[k.11.F])}}}}if(bJ){k.1t.26()}},dS:u(){k.1x.3Q={};24(i in k.1x.3P){if(k.1x.3P[i]!=S){D 1j=k.1x.3P[i].K(0);if(k(k.11.F).is(\'.\'+1j.1i.a)){1j.1i.p=k.23(k.1a.7G(1j),k.1a.74(1j));if(1j.1i.ac){k.1x.3P[i].2R(1j.1i.ac)}k.1x.3Q[i]=k.1x.3P[i];if(k.1t&&1j.1i.s&&k.11.F.A.44){1j.1i.el=k(\'.\'+1j.1i.a,1j);C.14.19=\'1o\';k.1t.cT(1j);C.14.19=C.A.7V}}}}},al:u(e){if(k.11.F==S){E}k.1x.5r=I;D i;D bK=I;D eQ=0;24(i in k.1x.3Q){D 1j=k.1x.3Q[i].K(0);if(k.1x.5r==I&&k.1x[1j.1i.t](1j.1i.p.x,1j.1i.p.y,1j.1i.p.1C,1j.1i.p.hb)){if(1j.1i.hc&&1j.1i.h==I){k.1x.3Q[i].2R(1j.1i.hc)}if(1j.1i.h==I&&1j.1i.7x){bK=1b}1j.1i.h=1b;k.1x.5r=1j;if(k.1t&&1j.1i.s&&k.11.F.A.44){k.1t.1c.K(0).3l=1j.1i.eV;k.1t.al(1j)}eQ++}P if(1j.1i.h==1b){if(1j.1i.7y){1j.1i.7y.1D(1j,[e,k.11.1c.K(0).7c,1j.1i.fx])}if(1j.1i.hc){k.1x.3Q[i].4i(1j.1i.hc)}1j.1i.h=I}}if(k.1t&&!k.1x.5r&&k.11.F.44){k.1t.1c.K(0).14.19=\'1o\'}if(bK){k.1x.5r.1i.7x.1D(k.1x.5r,[e,k.11.1c.K(0).7c])}},eO:u(e){D i;24(i in k.1x.3Q){D 1j=k.1x.3Q[i].K(0);if(1j.1i.ac){k.1x.3Q[i].4i(1j.1i.ac)}if(1j.1i.hc){k.1x.3Q[i].4i(1j.1i.hc)}if(1j.1i.s){k.1t.7s[k.1t.7s.1g]=i}if(1j.1i.9l&&1j.1i.h==1b){1j.1i.h=I;1j.1i.9l.1D(1j,[e,1j.1i.fx])}1j.1i.m=I;1j.1i.h=I}k.1x.3Q={}},4U:u(){E q.1E(u(){if(q.9j){if(q.1i.s){id=k.1p(q,\'id\');k.1t.5L[id]=S;k(\'.\'+q.1i.a,q).aS()}k.1x.3P[\'d\'+q.c2]=S;q.9j=I;q.f=S}})},2r:u(o){E q.1E(u(){if(q.9j==1b||!o.3C||!k.1a||!k.11){E}q.1i={a:o.3C,ac:o.9J||I,hc:o.a5||I,eV:o.58||I,9l:o.gq||o.9l||I,7x:o.7x||o.dC||I,7y:o.7y||o.fO||I,9i:o.9i||I,t:o.6I&&(o.6I==\'du\'||o.6I==\'cV\')?o.6I:\'1s\',fx:o.fx?o.fx:I,m:I,h:I};if(o.cQ==1b&&k.1t){id=k.1p(q,\'id\');k.1t.5L[id]=q.1i.a;q.1i.s=1b;if(o.2Z){q.1i.2Z=o.2Z;q.1i.ay=k.1t.8x(id).7l}}q.9j=1b;q.c2=T(18.6o()*c9);k.1x.3P[\'d\'+q.c2]=k(q);k.1x.8D++})}};k.fn.23({dR:k.1x.4U,do:k.1x.2r});k.gD=k.1x.dS;k.3B={1c:S,8L:u(){3g=q.2y;if(!3g)E;14={dz:k(q).B(\'dz\')||\'\',4A:k(q).B(\'4A\')||\'\',8Z:k(q).B(\'8Z\')||\'\',dP:k(q).B(\'dP\')||\'\',dT:k(q).B(\'dT\')||\'\',dU:k(q).B(\'dU\')||\'\',c3:k(q).B(\'c3\')||\'\',dY:k(q).B(\'dY\')||\'\'};k.3B.1c.B(14);3x=k.3B.dX(3g);3x=3x.4E(12 bb("\\\\n","g"),"<br />");k.3B.1c.3x(\'gL\');ci=k.3B.1c.K(0).4c;k.3B.1c.3x(3x);Z=k.3B.1c.K(0).4c+ci;if(q.6l.2M&&Z>q.6l.2M[0]){Z=q.6l.2M[0]}q.14.Z=Z+\'U\';if(q.4Y==\'cf\'){W=k.3B.1c.K(0).5W+ci;if(q.6l.2M&&W>q.6l.2M[1]){W=q.6l.2M[1]}q.14.W=W+\'U\'}},dX:u(3g){cg={\'&\':\'&gK;\',\'<\':\'&gJ;\',\'>\':\'&gt;\',\'"\':\'&gs;\'};24(i in cg){3g=3g.4E(12 bb(i,\'g\'),cg[i])}E 3g},2r:u(2M){if(k.3B.1c==S){k(\'2e\',1h).1S(\'<22 id="dE" 14="Y: 1P; Q: 0; O: 0; 3n: 2K;"></22>\');k.3B.1c=k(\'#dE\')}E q.1E(u(){if(/cf|ch/.48(q.4Y)){if(q.4Y==\'ch\'){dB=q.5C(\'1u\');if(!/3g|gr/.48(dB)){E}}if(2M&&(2M.1K==bn||(2M.1K==7F&&2M.1g==2))){if(2M.1K==bn)2M=[2M,2M];P{2M[0]=T(2M[0])||8J;2M[1]=T(2M[1])||8J}q.6l={2M:2M}}k(q).5B(k.3B.8L).6y(k.3B.8L).dH(k.3B.8L);k.3B.8L.1D(q)}})}};k.fn.kc=k.3B.2r;k.4K=u(e){if(/^kd$|^ke$|^ka$|^6L$|^k9$|^k5$|^k4$|^k6$|^k7$|^2e$|^k8$|^kf$|^kg$|^kn$|^ko$|^kp$|^kq$/i.48(e.9N))E I;P E 1b};k.fx.a0=u(e,65){D c=e.7c;D cs=c.14;cs.Y=65.Y;cs.5K=65.3G.t;cs.5j=65.3G.l;cs.5k=65.3G.b;cs.5z=65.3G.r;cs.Q=65.Q+\'U\';cs.O=65.O+\'U\';e.31.ew(c,e);e.31.km(e)};k.fx.9P=u(e){if(!k.4K(e))E I;D t=k(e);D es=e.14;D 73=I;if(t.B(\'19\')==\'1o\'){5Y=t.B(\'3n\');t.B(\'3n\',\'2K\').1Y();73=1b}D V={};V.Y=t.B(\'Y\');V.1q=k.1a.2o(e);V.3G=k.1a.cy(e);D co=e.4Z?e.4Z.ei:t.B(\'hU\');V.Q=T(t.B(\'Q\'))||0;V.O=T(t.B(\'O\'))||0;D eo=\'kl\'+T(18.6o()*c9);D 6u=1h.3F(/^1T$|^br$|^kh$|^hr$|^8C$|^kj$|^8T$|^3A$|^kk$|^k3$|^k2$|^9h$|^dl$|^jM$/i.48(e.9N)?\'22\':e.9N);k.1p(6u,\'id\',eo);D jN=k(6u).2R(\'jO\');D 4h=6u.14;D Q=0;D O=0;if(V.Y==\'2s\'||V.Y==\'1P\'){Q=V.Q;O=V.O}4h.Q=Q+\'U\';4h.O=O+\'U\';4h.Y=V.Y!=\'2s\'&&V.Y!=\'1P\'?\'2s\':V.Y;4h.W=V.1q.hb+\'U\';4h.Z=V.1q.1C+\'U\';4h.5K=V.3G.t;4h.5z=V.3G.r;4h.5k=V.3G.b;4h.5j=V.3G.l;4h.2U=\'2K\';if(k.3a.4t){4h.ei=co}P{4h.jK=co}if(k.3a=="4t"){es.5E="8V(1G="+0.ex*2a+")"}es.1G=0.ex;e.31.ew(6u,e);6u.jF(e);es.5K=\'2P\';es.5z=\'2P\';es.5k=\'2P\';es.5j=\'2P\';es.Y=\'1P\';es.eu=\'1o\';es.Q=\'2P\';es.O=\'2P\';if(73){t.2G();es.3n=5Y}E{V:V,3p:k(6u)}};k.fx.8E={jE:[0,1V,1V],jG:[eD,1V,1V],jH:[e6,e6,jI],jP:[0,0,0],ks:[0,0,1V],jY:[dv,42,42],jZ:[0,1V,1V],k0:[0,0,7w],k1:[0,7w,7w],jX:[cn,cn,cn],jS:[0,2a,0],jR:[jT,jU,eb],jV:[7w,0,7w],kr:[85,eb,47],kP:[1V,eA,0],kN:[kO,50,kx],kF:[7w,0,0],kD:[ku,f8,kt],ky:[kH,0,9C],kL:[1V,0,1V],kM:[1V,kJ,0],kv:[0,6C,0],kA:[75,0,kE],kC:[eD,eB,eA],kG:[kI,kB,eB],kw:[e0,1V,1V],kz:[eL,kK,eL],kQ:[9C,9C,9C],jC:[1V,iy,iz],iA:[1V,1V,e0],iB:[0,1V,0],ix:[1V,0,1V],iv:[6C,0,0],iq:[0,0,6C],ip:[6C,6C,0],ir:[1V,dv,0],it:[1V,ah,iu],iC:[6C,0,6C],iD:[1V,0,0],iK:[ah,ah,ah],iL:[1V,1V,1V],iM:[1V,1V,0]};k.fx.6D=u(4x,dm){if(k.fx.8E[4x])E{r:k.fx.8E[4x][0],g:k.fx.8E[4x][1],b:k.fx.8E[4x][2]};P if(2W=/^6Y\\(\\s*([0-9]{1,3})\\s*,\\s*([0-9]{1,3})\\s*,\\s*([0-9]{1,3})\\s*\\)$/.a4(4x))E{r:T(2W[1]),g:T(2W[2]),b:T(2W[3])};P if(2W=/6Y\\(\\s*([0-9]+(?:\\.[0-9]+)?)\\%\\s*,\\s*([0-9]+(?:\\.[0-9]+)?)\\%\\s*,\\s*([0-9]+(?:\\.[0-9]+)?)\\%\\s*\\)$/.a4(4x))E{r:2m(2W[1])*2.55,g:2m(2W[2])*2.55,b:2m(2W[3])*2.55};P if(2W=/^#([a-fA-79-9])([a-fA-79-9])([a-fA-79-9])$/.a4(4x))E{r:T("77"+2W[1]+2W[1]),g:T("77"+2W[2]+2W[2]),b:T("77"+2W[3]+2W[3])};P if(2W=/^#([a-fA-79-9]{2})([a-fA-79-9]{2})([a-fA-79-9]{2})$/.a4(4x))E{r:T("77"+2W[1]),g:T("77"+2W[2]),b:T("77"+2W[3])};P E dm==1b?I:{r:1V,g:1V,b:1V}};k.fx.dD={5Q:1,5b:1,5O:1,4S:1,4D:1,4A:1,W:1,O:1,c3:1,iI:1,5k:1,5j:1,5z:1,5K:1,8b:1,6x:1,8c:1,av:1,1G:1,iE:1,iF:1,5n:1,4X:1,5U:1,5M:1,2L:1,jD:1,Q:1,Z:1,3I:1};k.fx.dA={7i:1,iG:1,iH:1,io:1,im:1,4x:1,i2:1};k.fx.8A=[\'i3\',\'i4\',\'i5\',\'i1\'];k.fx.cc={\'cd\':[\'2E\',\'dK\'],\'a8\':[\'2E\',\'bh\'],\'6w\':[\'6w\',\'\'],\'8F\':[\'8F\',\'\']};k.fn.23({5w:u(5X,H,G,J){E q.1w(u(){D a1=k.H(H,G,J);D e=12 k.dM(q,a1,5X)})},c4:u(H,J){E q.1w(u(){D a1=k.H(H,J);D e=12 k.c4(q,a1)})},8o:u(2D){E q.1E(u(){if(q.6d)k.by(q,2D)})},i0:u(2D){E q.1E(u(){if(q.6d)k.by(q,2D);if(q.1w&&q.1w[\'fx\'])q.1w.fx=[]})}});k.23({c4:u(2f,M){D z=q,3t;z.2D=u(){if(k.fQ(M.21))M.21.1D(2f)};z.2I=6V(u(){z.2D()},M.1m);2f.6d=z},G:{c8:u(p,n,1W,1H,1m){E((-18.5H(p*18.2Q)/2)+0.5)*1H+1W}},dM:u(2f,M,5X){D z=q,3t;D y=2f.14;D fR=k.B(2f,"2U");D 72=k.B(2f,"19");D 2j={};z.9O=(12 7g()).7z();M.G=M.G&&k.G[M.G]?M.G:\'c8\';z.ag=u(2w,43){if(k.fx.dD[2w]){if(43==\'1Y\'||43==\'2G\'||43==\'3R\'){if(!2f.6v)2f.6v={};D r=2m(k.6E(2f,2w));2f.6v[2w]=r&&r>-c9?r:(2m(k.B(2f,2w))||0);43=43==\'3R\'?(72==\'1o\'?\'1Y\':\'2G\'):43;M[43]=1b;2j[2w]=43==\'1Y\'?[0,2f.6v[2w]]:[2f.6v[2w],0];if(2w!=\'1G\')y[2w]=2j[2w][0]+(2w!=\'3I\'&&2w!=\'8Z\'?\'U\':\'\');P k.1p(y,"1G",2j[2w][0])}P{2j[2w]=[2m(k.6E(2f,2w)),2m(43)||0]}}P if(k.fx.dA[2w])2j[2w]=[k.fx.6D(k.6E(2f,2w)),k.fx.6D(43)];P if(/^6w$|8F$|2E$|a8$|cd$/i.48(2w)){D m=43.4E(/\\s+/g,\' \').4E(/6Y\\s*\\(\\s*/g,\'6Y(\').4E(/\\s*,\\s*/g,\',\').4E(/\\s*\\)/g,\')\').d5(/([^\\s]+)/g);3m(2w){1e\'6w\':1e\'8F\':1e\'cd\':1e\'a8\':m[3]=m[3]||m[1]||m[0];m[2]=m[2]||m[0];m[1]=m[1]||m[0];24(D i=0;i<k.fx.8A.1g;i++){D 64=k.fx.cc[2w][0]+k.fx.8A[i]+k.fx.cc[2w][1];2j[64]=2w==\'a8\'?[k.fx.6D(k.6E(2f,64)),k.fx.6D(m[i])]:[2m(k.6E(2f,64)),2m(m[i])]}1r;1e\'2E\':24(D i=0;i<m.1g;i++){D bd=2m(m[i]);D a9=!hX(bd)?\'dK\':(!/cu|1o|2K|hY|hZ|i6|i7|ii|ij|ik|il/i.48(m[i])?\'bh\':I);if(a9){24(D j=0;j<k.fx.8A.1g;j++){64=\'2E\'+k.fx.8A[j]+a9;2j[64]=a9==\'bh\'?[k.fx.6D(k.6E(2f,64)),k.fx.6D(m[i])]:[2m(k.6E(2f,64)),bd]}}P{y[\'ie\']=m[i]}}1r}}P{y[2w]=43}E I};24(p in 5X){if(p==\'14\'){D 5f=k.bl(5X[p]);24(7A in 5f){q.ag(7A,5f[7A])}}P if(p==\'3l\'){if(1h.af)24(D i=0;i<1h.af.1g;i++){D 7e=1h.af[i].7e||1h.af[i].i9||S;if(7e){24(D j=0;j<7e.1g;j++){if(7e[j].i8==\'.\'+5X[p]){D 6X=12 bb(\'\\.\'+5X[p]+\' {\');D 5Z=7e[j].14.9X;D 5f=k.bl(5Z.4E(6X,\'\').4E(/}/g,\'\'));24(7A in 5f){q.ag(7A,5f[7A])}}}}}}P{q.ag(p,5X[p])}}y.19=72==\'1o\'?\'2B\':72;y.2U=\'2K\';z.2D=u(){D t=(12 7g()).7z();if(t>M.1m+z.9O){5T(z.2I);z.2I=S;24(p in 2j){if(p=="1G")k.1p(y,"1G",2j[p][1]);P if(2g 2j[p][1]==\'8T\')y[p]=\'6Y(\'+2j[p][1].r+\',\'+2j[p][1].g+\',\'+2j[p][1].b+\')\';P y[p]=2j[p][1]+(p!=\'3I\'&&p!=\'8Z\'?\'U\':\'\')}if(M.2G||M.1Y)24(D p in 2f.6v)if(p=="1G")k.1p(y,p,2f.6v[p]);P y[p]="";y.19=M.2G?\'1o\':(72!=\'1o\'?72:\'2B\');y.2U=fR;2f.6d=S;if(k.fQ(M.21))M.21.1D(2f)}P{D n=t-q.9O;D 8w=n/M.1m;24(p in 2j){if(2g 2j[p][1]==\'8T\'){y[p]=\'6Y(\'+T(k.G[M.G](8w,n,2j[p][0].r,(2j[p][1].r-2j[p][0].r),M.1m))+\',\'+T(k.G[M.G](8w,n,2j[p][0].g,(2j[p][1].g-2j[p][0].g),M.1m))+\',\'+T(k.G[M.G](8w,n,2j[p][0].b,(2j[p][1].b-2j[p][0].b),M.1m))+\')\'}P{D bz=k.G[M.G](8w,n,2j[p][0],(2j[p][1]-2j[p][0]),M.1m);if(p=="1G")k.1p(y,"1G",bz);P y[p]=bz+(p!=\'3I\'&&p!=\'8Z\'?\'U\':\'\')}}}};z.2I=6V(u(){z.2D()},13);2f.6d=z},by:u(2f,2D){if(2D)2f.6d.9O-=iO;P{1X.5T(2f.6d.2I);2f.6d=S;k.2H(2f,"fx")}}});k.bl=u(5Z){D 5f={};if(2g 5Z==\'4V\'){5Z=5Z.6c().7C(\';\');24(D i=0;i<5Z.1g;i++){6X=5Z[i].7C(\':\');if(6X.1g==2){5f[k.g6(6X[0].4E(/\\-(\\w)/g,u(m,c){E c.jo()}))]=k.g6(6X[1])}}}E 5f};k.fn.23({g3:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.61(q,H,J,\'4F\',G)})},gb:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.61(q,H,J,\'4r\',G)})},jl:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.61(q,H,J,\'fJ\',G)})},jk:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.61(q,H,J,\'O\',G)})},jg:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.61(q,H,J,\'2L\',G)})},jf:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.61(q,H,J,\'fh\',G)})}});k.fx.61=u(e,H,J,2S,G){if(!k.4K(e)){k.2H(e,\'1n\');E I}D z=q;z.el=k(e);z.1N=k.1a.2o(e);z.G=2g J==\'4V\'?J:G||S;if(!e.4s)e.4s=z.el.B(\'19\');if(2S==\'fJ\'){2S=z.el.B(\'19\')==\'1o\'?\'4r\':\'4F\'}P if(2S==\'fh\'){2S=z.el.B(\'19\')==\'1o\'?\'2L\':\'O\'}z.el.1Y();z.H=H;z.J=2g J==\'u\'?J:S;z.fx=k.fx.9P(e);z.2S=2S;z.21=u(){if(z.J&&z.J.1K==2A){z.J.1D(z.el.K(0))}if(z.2S==\'4r\'||z.2S==\'2L\'){z.el.B(\'19\',z.el.K(0).4s==\'1o\'?\'2B\':z.el.K(0).4s)}P{z.el.2G()}k.fx.a0(z.fx.3p.K(0),z.fx.V);k.2H(z.el.K(0),\'1n\')};3m(z.2S){1e\'4F\':63=12 k.fx(z.fx.3p.K(0),k.H(z.H,z.G,z.21),\'W\');63.1L(z.fx.V.1q.hb,0);1r;1e\'4r\':z.fx.3p.B(\'W\',\'9R\');z.el.1Y();63=12 k.fx(z.fx.3p.K(0),k.H(z.H,z.G,z.21),\'W\');63.1L(0,z.fx.V.1q.hb);1r;1e\'O\':63=12 k.fx(z.fx.3p.K(0),k.H(z.H,z.G,z.21),\'Z\');63.1L(z.fx.V.1q.1C,0);1r;1e\'2L\':z.fx.3p.B(\'Z\',\'9R\');z.el.1Y();63=12 k.fx(z.fx.3p.K(0),k.H(z.H,z.G,z.21),\'Z\');63.1L(0,z.fx.V.1q.1C);1r}};k.fn.ji=u(5D,J){E q.1w(\'1n\',u(){if(!k.4K(q)){k.2H(q,\'1n\');E I}D e=12 k.fx.f4(q,5D,J);e.bp()})};k.fx.f4=u(e,5D,J){D z=q;z.el=k(e);z.el.1Y();z.J=J;z.5D=T(5D)||40;z.V={};z.V.Y=z.el.B(\'Y\');z.V.Q=T(z.el.B(\'Q\'))||0;z.V.O=T(z.el.B(\'O\'))||0;if(z.V.Y!=\'2s\'&&z.V.Y!=\'1P\'){z.el.B(\'Y\',\'2s\')}z.3V=5;z.5y=1;z.bp=u(){z.5y++;z.e=12 k.fx(z.el.K(0),{1m:jj,21:u(){z.e=12 k.fx(z.el.K(0),{1m:80,21:u(){z.5D=T(z.5D/2);if(z.5y<=z.3V)z.bp();P{z.el.B(\'Y\',z.V.Y).B(\'Q\',z.V.Q+\'U\').B(\'O\',z.V.O+\'U\');k.2H(z.el.K(0),\'1n\');if(z.J&&z.J.1K==2A){z.J.1D(z.el.K(0))}}}},\'Q\');z.e.1L(z.V.Q-z.5D,z.V.Q)}},\'Q\');z.e.1L(z.V.Q,z.V.Q-z.5D)}};k.fn.23({jy:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'4r\',\'4l\',G)})},jz:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'4r\',\'in\',G)})},jA:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'4r\',\'3R\',G)})},jB:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'4F\',\'4l\',G)})},jx:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'4F\',\'in\',G)})},jw:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'4F\',\'3R\',G)})},js:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'O\',\'4l\',G)})},jt:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'O\',\'in\',G)})},ju:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'O\',\'3R\',G)})},jv:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'2L\',\'4l\',G)})},je:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'2L\',\'in\',G)})},jd:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.4f(q,H,J,\'2L\',\'3R\',G)})}});k.fx.4f=u(e,H,J,2S,1u,G){if(!k.4K(e)){k.2H(e,\'1n\');E I}D z=q;z.el=k(e);z.G=2g J==\'4V\'?J:G||S;z.V={};z.V.Y=z.el.B(\'Y\');z.V.Q=z.el.B(\'Q\');z.V.O=z.el.B(\'O\');if(!e.4s)e.4s=z.el.B(\'19\');if(1u==\'3R\'){1u=z.el.B(\'19\')==\'1o\'?\'in\':\'4l\'}z.el.1Y();if(z.V.Y!=\'2s\'&&z.V.Y!=\'1P\'){z.el.B(\'Y\',\'2s\')}z.1u=1u;J=2g J==\'u\'?J:S;8H=1;3m(2S){1e\'4F\':z.e=12 k.fx(z.el.K(0),k.H(H-15,z.G,J),\'Q\');z.62=2m(z.V.Q)||0;z.9K=z.fG;8H=-1;1r;1e\'4r\':z.e=12 k.fx(z.el.K(0),k.H(H-15,z.G,J),\'Q\');z.62=2m(z.V.Q)||0;z.9K=z.fG;1r;1e\'2L\':z.e=12 k.fx(z.el.K(0),k.H(H-15,z.G,J),\'O\');z.62=2m(z.V.O)||0;z.9K=z.fy;1r;1e\'O\':z.e=12 k.fx(z.el.K(0),k.H(H-15,z.G,J),\'O\');z.62=2m(z.V.O)||0;z.9K=z.fy;8H=-1;1r}z.e2=12 k.fx(z.el.K(0),k.H(H,z.G,u(){z.el.B(z.V);if(z.1u==\'4l\'){z.el.B(\'19\',\'1o\')}P z.el.B(\'19\',z.el.K(0).4s==\'1o\'?\'2B\':z.el.K(0).4s);k.2H(z.el.K(0),\'1n\')}),\'1G\');if(1u==\'in\'){z.e.1L(z.62+2a*8H,z.62);z.e2.1L(0,1)}P{z.e.1L(z.62,z.62+2a*8H);z.e2.1L(1,0)}};k.fn.23({j0:u(H,W,J,G){E q.1w(\'1n\',u(){12 k.fx.9L(q,H,W,J,\'fp\',G)})},iW:u(H,W,J,G){E q.1w(\'1n\',u(){12 k.fx.9L(q,H,W,J,\'9M\',G)})},iV:u(H,W,J,G){E q.1w(\'1n\',u(){12 k.fx.9L(q,H,W,J,\'3R\',G)})}});k.fx.9L=u(e,H,W,J,1u,G){if(!k.4K(e)){k.2H(e,\'1n\');E I}D z=q;z.el=k(e);z.G=2g J==\'4V\'?J:G||S;z.J=2g J==\'u\'?J:S;if(1u==\'3R\'){1u=z.el.B(\'19\')==\'1o\'?\'9M\':\'fp\'}z.H=H;z.W=W&&W.1K==bn?W:20;z.fx=k.fx.9P(e);z.1u=1u;z.21=u(){if(z.J&&z.J.1K==2A){z.J.1D(z.el.K(0))}if(z.1u==\'9M\'){z.el.1Y()}P{z.el.2G()}k.fx.a0(z.fx.3p.K(0),z.fx.V);k.2H(z.el.K(0),\'1n\')};if(z.1u==\'9M\'){z.el.1Y();z.fx.3p.B(\'W\',z.W+\'U\').B(\'Z\',\'9R\');z.ef=12 k.fx(z.fx.3p.K(0),k.H(z.H,z.G,u(){z.ef=12 k.fx(z.fx.3p.K(0),k.H(z.H,z.G,z.21),\'W\');z.ef.1L(z.W,z.fx.V.1q.hb)}),\'Z\');z.ef.1L(0,z.fx.V.1q.1C)}P{z.ef=12 k.fx(z.fx.3p.K(0),k.H(z.H,z.G,u(){z.ef=12 k.fx(z.fx.3p.K(0),k.H(z.H,z.G,z.21),\'Z\');z.ef.1L(z.fx.V.1q.1C,0)}),\'W\');z.ef.1L(z.fx.V.1q.hb,z.W)}};k.fn.iR=u(H,4x,J,G){E q.1w(\'fv\',u(){q.6W=k(q).1p("14")||\'\';G=2g J==\'4V\'?J:G||S;J=2g J==\'u\'?J:S;D 9S=k(q).B(\'7i\');D 8I=q.31;7d(9S==\'cu\'&&8I){9S=k(8I).B(\'7i\');8I=8I.31}k(q).B(\'7i\',4x);if(2g q.6W==\'8T\')q.6W=q.6W["9X"];k(q).5w({\'7i\':9S},H,G,u(){k.2H(q,\'fv\');if(2g k(q).1p("14")==\'8T\'){k(q).1p("14")["9X"]="";k(q).1p("14")["9X"]=q.6W}P{k(q).1p("14",q.6W)}if(J)J.1D(q)})})};k.fn.23({iT:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.5m(q,H,J,\'49\',\'6g\',G)})},iU:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.5m(q,H,J,\'4j\',\'6g\',G)})},j1:u(H,J,G){E q.1w(\'1n\',u(){if(k.B(q,\'19\')==\'1o\'){12 k.fx.5m(q,H,J,\'4j\',\'6Z\',G)}P{12 k.fx.5m(q,H,J,\'4j\',\'6g\',G)}})},j2:u(H,J,G){E q.1w(\'1n\',u(){if(k.B(q,\'19\')==\'1o\'){12 k.fx.5m(q,H,J,\'49\',\'6Z\',G)}P{12 k.fx.5m(q,H,J,\'49\',\'6g\',G)}})},j9:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.5m(q,H,J,\'49\',\'6Z\',G)})},ja:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.5m(q,H,J,\'4j\',\'6Z\',G)})}});k.fx.5m=u(e,H,J,2S,1u,G){if(!k.4K(e)){k.2H(e,\'1n\');E I}D z=q;D 73=I;z.el=k(e);z.G=2g J==\'4V\'?J:G||S;z.J=2g J==\'u\'?J:S;z.1u=1u;z.H=H;z.2i=k.1a.2o(e);z.V={};z.V.Y=z.el.B(\'Y\');z.V.19=z.el.B(\'19\');if(z.V.19==\'1o\'){5Y=z.el.B(\'3n\');z.el.1Y();73=1b}z.V.Q=z.el.B(\'Q\');z.V.O=z.el.B(\'O\');if(73){z.el.2G();z.el.B(\'3n\',5Y)}z.V.Z=z.2i.w+\'U\';z.V.W=z.2i.h+\'U\';z.V.2U=z.el.B(\'2U\');z.2i.Q=T(z.V.Q)||0;z.2i.O=T(z.V.O)||0;if(z.V.Y!=\'2s\'&&z.V.Y!=\'1P\'){z.el.B(\'Y\',\'2s\')}z.el.B(\'2U\',\'2K\').B(\'W\',1u==\'6Z\'&&2S==\'49\'?1:z.2i.h+\'U\').B(\'Z\',1u==\'6Z\'&&2S==\'4j\'?1:z.2i.w+\'U\');z.21=u(){z.el.B(z.V);if(z.1u==\'6g\')z.el.2G();P z.el.1Y();k.2H(z.el.K(0),\'1n\')};3m(2S){1e\'49\':z.eh=12 k.fx(z.el.K(0),k.H(H-15,z.G,J),\'W\');z.et=12 k.fx(z.el.K(0),k.H(z.H,z.G,z.21),\'Q\');if(z.1u==\'6g\'){z.eh.1L(z.2i.h,0);z.et.1L(z.2i.Q,z.2i.Q+z.2i.h/2)}P{z.eh.1L(0,z.2i.h);z.et.1L(z.2i.Q+z.2i.h/2,z.2i.Q)}1r;1e\'4j\':z.eh=12 k.fx(z.el.K(0),k.H(H-15,z.G,J),\'Z\');z.et=12 k.fx(z.el.K(0),k.H(z.H,z.G,z.21),\'O\');if(z.1u==\'6g\'){z.eh.1L(z.2i.w,0);z.et.1L(z.2i.O,z.2i.O+z.2i.w/2)}P{z.eh.1L(0,z.2i.w);z.et.1L(z.2i.O+z.2i.w/2,z.2i.O)}1r}};k.fn.bg=u(H,3V,J){E q.1w(\'1n\',u(){if(!k.4K(q)){k.2H(q,\'1n\');E I}D fx=12 k.fx.bg(q,H,3V,J);fx.bf()})};k.fx.bg=u(el,H,3V,J){D z=q;z.3V=3V;z.5y=1;z.el=el;z.H=H;z.J=J;k(z.el).1Y();z.bf=u(){z.5y++;z.e=12 k.fx(z.el,k.H(z.H,u(){z.ef=12 k.fx(z.el,k.H(z.H,u(){if(z.5y<=z.3V)z.bf();P{k.2H(z.el,\'1n\');if(z.J&&z.J.1K==2A){z.J.1D(z.el)}}}),\'1G\');z.ef.1L(0,1)}),\'1G\');z.e.1L(1,0)}};k.fn.23({jb:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.6G(q,H,1,2a,1b,J,\'fa\',G)})},jc:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.6G(q,H,2a,1,1b,J,\'b4\',G)})},j8:u(H,J,G){E q.1w(\'1n\',u(){D G=G||\'fl\';12 k.fx.6G(q,H,2a,f8,1b,J,\'6h\',G)})},6G:u(H,57,30,6H,J,G){E q.1w(\'1n\',u(){12 k.fx.6G(q,H,57,30,6H,J,\'6G\',G)})}});k.fx.6G=u(e,H,57,30,6H,J,1u,G){if(!k.4K(e)){k.2H(e,\'1n\');E I}D z=q;z.el=k(e);z.57=T(57)||2a;z.30=T(30)||2a;z.G=2g J==\'4V\'?J:G||S;z.J=2g J==\'u\'?J:S;z.1m=k.H(H).1m;z.6H=6H||S;z.2i=k.1a.2o(e);z.V={Z:z.el.B(\'Z\'),W:z.el.B(\'W\'),4A:z.el.B(\'4A\')||\'2a%\',Y:z.el.B(\'Y\'),19:z.el.B(\'19\'),Q:z.el.B(\'Q\'),O:z.el.B(\'O\'),2U:z.el.B(\'2U\'),4S:z.el.B(\'4S\'),5O:z.el.B(\'5O\'),5Q:z.el.B(\'5Q\'),5b:z.el.B(\'5b\'),5M:z.el.B(\'5M\'),5U:z.el.B(\'5U\'),5n:z.el.B(\'5n\'),4X:z.el.B(\'4X\')};z.Z=T(z.V.Z)||e.4c||0;z.W=T(z.V.W)||e.5W||0;z.Q=T(z.V.Q)||0;z.O=T(z.V.O)||0;1q=[\'em\',\'U\',\'j7\',\'%\'];24(i in 1q){if(z.V.4A.3J(1q[i])>0){z.fg=1q[i];z.4A=2m(z.V.4A)}if(z.V.4S.3J(1q[i])>0){z.fc=1q[i];z.bw=2m(z.V.4S)||0}if(z.V.5O.3J(1q[i])>0){z.fe=1q[i];z.bc=2m(z.V.5O)||0}if(z.V.5Q.3J(1q[i])>0){z.fL=1q[i];z.bA=2m(z.V.5Q)||0}if(z.V.5b.3J(1q[i])>0){z.g8=1q[i];z.bt=2m(z.V.5b)||0}if(z.V.5M.3J(1q[i])>0){z.g4=1q[i];z.bx=2m(z.V.5M)||0}if(z.V.5U.3J(1q[i])>0){z.g9=1q[i];z.bv=2m(z.V.5U)||0}if(z.V.5n.3J(1q[i])>0){z.gc=1q[i];z.bj=2m(z.V.5n)||0}if(z.V.4X.3J(1q[i])>0){z.fK=1q[i];z.b7=2m(z.V.4X)||0}}if(z.V.Y!=\'2s\'&&z.V.Y!=\'1P\'){z.el.B(\'Y\',\'2s\')}z.el.B(\'2U\',\'2K\');z.1u=1u;3m(z.1u){1e\'fa\':z.4b=z.Q+z.2i.h/2;z.5a=z.Q;z.4k=z.O+z.2i.w/2;z.59=z.O;1r;1e\'b4\':z.5a=z.Q+z.2i.h/2;z.4b=z.Q;z.59=z.O+z.2i.w/2;z.4k=z.O;1r;1e\'6h\':z.5a=z.Q-z.2i.h/4;z.4b=z.Q;z.59=z.O-z.2i.w/4;z.4k=z.O;1r}z.be=I;z.t=(12 7g).7z();z.4w=u(){5T(z.2I);z.2I=S};z.2D=u(){if(z.be==I){z.el.1Y();z.be=1b}D t=(12 7g).7z();D n=t-z.t;D p=n/z.1m;if(t>=z.1m+z.t){9T(u(){o=1;if(z.1u){t=z.5a;l=z.59;if(z.1u==\'6h\')o=0}z.bs(z.30,l,t,1b,o)},13);z.4w()}P{o=1;if(!k.G||!k.G[z.G]){s=((-18.5H(p*18.2Q)/2)+0.5)*(z.30-z.57)+z.57}P{s=k.G[z.G](p,n,z.57,(z.30-z.57),z.1m)}if(z.1u){if(!k.G||!k.G[z.G]){t=((-18.5H(p*18.2Q)/2)+0.5)*(z.5a-z.4b)+z.4b;l=((-18.5H(p*18.2Q)/2)+0.5)*(z.59-z.4k)+z.4k;if(z.1u==\'6h\')o=((-18.5H(p*18.2Q)/2)+0.5)*(-0.9Y)+0.9Y}P{t=k.G[z.G](p,n,z.4b,(z.5a-z.4b),z.1m);l=k.G[z.G](p,n,z.4k,(z.59-z.4k),z.1m);if(z.1u==\'6h\')o=k.G[z.G](p,n,0.9Y,-0.9Y,z.1m)}}z.bs(s,l,t,I,o)}};z.2I=6V(u(){z.2D()},13);z.bs=u(4q,O,Q,fM,1G){z.el.B(\'W\',z.W*4q/2a+\'U\').B(\'Z\',z.Z*4q/2a+\'U\').B(\'O\',O+\'U\').B(\'Q\',Q+\'U\').B(\'4A\',z.4A*4q/2a+z.fg);if(z.bw)z.el.B(\'4S\',z.bw*4q/2a+z.fc);if(z.bc)z.el.B(\'5O\',z.bc*4q/2a+z.fe);if(z.bA)z.el.B(\'5Q\',z.bA*4q/2a+z.fL);if(z.bt)z.el.B(\'5b\',z.bt*4q/2a+z.g8);if(z.bx)z.el.B(\'5M\',z.bx*4q/2a+z.g4);if(z.bv)z.el.B(\'5U\',z.bv*4q/2a+z.g9);if(z.bj)z.el.B(\'5n\',z.bj*4q/2a+z.gc);if(z.b7)z.el.B(\'4X\',z.b7*4q/2a+z.fK);if(z.1u==\'6h\'){if(1X.71)z.el.K(0).14.5E="8V(1G="+1G*2a+")";z.el.K(0).14.1G=1G}if(fM){if(z.6H){z.el.B(z.V)}if(z.1u==\'b4\'||z.1u==\'6h\'){z.el.B(\'19\',\'1o\');if(z.1u==\'6h\'){if(1X.71)z.el.K(0).14.5E="8V(1G="+2a+")";z.el.K(0).14.1G=1}}P z.el.B(\'19\',\'2B\');if(z.J)z.J.1D(z.el.K(0));k.2H(z.el.K(0),\'1n\')}}};k.fn.23({9U:u(H,1O,G){o=k.H(H);E q.1w(\'1n\',u(){12 k.fx.9U(q,o,1O,G)})},j6:u(H,1O,G){E q.1E(u(){k(\'a[@3h*="#"]\',q).5h(u(e){fW=q.3h.7C(\'#\');k(\'#\'+fW[1]).9U(H,1O,G);E I})})}});k.fx.9U=u(e,o,1O,G){D z=q;z.o=o;z.e=e;z.1O=/fT|gd/.48(1O)?1O:I;z.G=G;p=k.1a.3w(e);s=k.1a.6z();z.4w=u(){5T(z.2I);z.2I=S;k.2H(z.e,\'1n\')};z.t=(12 7g).7z();s.h=s.h>s.ih?(s.h-s.ih):s.h;s.w=s.w>s.iw?(s.w-s.iw):s.w;z.5a=p.y>s.h?s.h:p.y;z.59=p.x>s.w?s.w:p.x;z.4b=s.t;z.4k=s.l;z.2D=u(){D t=(12 7g).7z();D n=t-z.t;D p=n/z.o.1m;if(t>=z.o.1m+z.t){z.4w();9T(u(){z.d3(z.5a,z.59)},13)}P{if(!z.1O||z.1O==\'fT\'){if(!k.G||!k.G[z.G]){9V=((-18.5H(p*18.2Q)/2)+0.5)*(z.5a-z.4b)+z.4b}P{9V=k.G[z.G](p,n,z.4b,(z.5a-z.4b),z.o.1m)}}P{9V=z.4b}if(!z.1O||z.1O==\'gd\'){if(!k.G||!k.G[z.G]){9W=((-18.5H(p*18.2Q)/2)+0.5)*(z.59-z.4k)+z.4k}P{9W=k.G[z.G](p,n,z.4k,(z.59-z.4k),z.o.1m)}}P{9W=z.4k}z.d3(9V,9W)}};z.d3=u(t,l){1X.j4(l,t)};z.2I=6V(u(){z.2D()},13)};k.fn.cY=u(3V,J){E q.1w(\'1n\',u(){if(!k.4K(q)){k.2H(q,\'1n\');E I}D e=12 k.fx.cY(q,3V,J);e.cG()})};k.fx.cY=u(e,3V,J){D z=q;z.el=k(e);z.el.1Y();z.3V=T(3V)||3;z.J=J;z.5y=1;z.V={};z.V.Y=z.el.B(\'Y\');z.V.Q=T(z.el.B(\'Q\'))||0;z.V.O=T(z.el.B(\'O\'))||0;if(z.V.Y!=\'2s\'&&z.V.Y!=\'1P\'){z.el.B(\'Y\',\'2s\')}z.cG=u(){z.5y++;z.e=12 k.fx(z.el.K(0),{1m:60,21:u(){z.e=12 k.fx(z.el.K(0),{1m:60,21:u(){z.e=12 k.fx(e,{1m:60,21:u(){if(z.5y<=z.3V)z.cG();P{z.el.B(\'Y\',z.V.Y).B(\'Q\',z.V.Q+\'U\').B(\'O\',z.V.O+\'U\');k.2H(z.el.K(0),\'1n\');if(z.J&&z.J.1K==2A){z.J.1D(z.el.K(0))}}}},\'O\');z.e.1L(z.V.O-20,z.V.O)}},\'O\');z.e.1L(z.V.O+20,z.V.O-20)}},\'O\');z.e.1L(z.V.O,z.V.O+20)}};k.fn.23({fo:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'4F\',\'in\',G)})},fq:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'4F\',\'4l\',G)})},iY:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'4F\',\'3R\',G)})},iX:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'4r\',\'in\',G)})},jr:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'4r\',\'4l\',G)})},jq:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'4r\',\'3R\',G)})},jp:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'O\',\'in\',G)})},jn:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'O\',\'4l\',G)})},jm:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'O\',\'3R\',G)})},iP:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'2L\',\'in\',G)})},ic:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'2L\',\'4l\',G)})},ib:u(H,J,G){E q.1w(\'1n\',u(){12 k.fx.1z(q,H,J,\'2L\',\'3R\',G)})}});k.fx.1z=u(e,H,J,2S,1u,G){if(!k.4K(e)){k.2H(e,\'1n\');E I}D z=q;z.el=k(e);z.G=2g J==\'4V\'?J:G||S;z.J=2g J==\'u\'?J:S;if(1u==\'3R\'){1u=z.el.B(\'19\')==\'1o\'?\'in\':\'4l\'}if(!e.4s)e.4s=z.el.B(\'19\');z.el.1Y();z.H=H;z.fx=k.fx.9P(e);z.1u=1u;z.2S=2S;z.21=u(){if(z.1u==\'4l\')z.el.B(\'3n\',\'2K\');k.fx.a0(z.fx.3p.K(0),z.fx.V);if(z.1u==\'in\'){z.el.B(\'19\',z.el.K(0).4s==\'1o\'?\'2B\':z.el.K(0).4s)}P{z.el.B(\'19\',\'1o\');z.el.B(\'3n\',\'dd\')}if(z.J&&z.J.1K==2A){z.J.1D(z.el.K(0))}k.2H(z.el.K(0),\'1n\')};3m(z.2S){1e\'4F\':z.ef=12 k.fx(z.el.K(0),k.H(z.H,z.G,z.21),\'Q\');z.7v=12 k.fx(z.fx.3p.K(0),k.H(z.H,z.G),\'W\');if(z.1u==\'in\'){z.ef.1L(-z.fx.V.1q.hb,0);z.7v.1L(0,z.fx.V.1q.hb)}P{z.ef.1L(0,-z.fx.V.1q.hb);z.7v.1L(z.fx.V.1q.hb,0)}1r;1e\'4r\':z.ef=12 k.fx(z.el.K(0),k.H(z.H,z.G,z.21),\'Q\');if(z.1u==\'in\'){z.ef.1L(z.fx.V.1q.hb,0)}P{z.ef.1L(0,z.fx.V.1q.hb)}1r;1e\'O\':z.ef=12 k.fx(z.el.K(0),k.H(z.H,z.G,z.21),\'O\');z.7v=12 k.fx(z.fx.3p.K(0),k.H(z.H,z.G),\'Z\');if(z.1u==\'in\'){z.ef.1L(-z.fx.V.1q.1C,0);z.7v.1L(0,z.fx.V.1q.1C)}P{z.ef.1L(0,-z.fx.V.1q.1C);z.7v.1L(z.fx.V.1q.1C,0)}1r;1e\'2L\':z.ef=12 k.fx(z.el.K(0),k.H(z.H,z.G,z.21),\'O\');if(z.1u==\'in\'){z.ef.1L(z.fx.V.1q.1C,0)}P{z.ef.1L(0,z.fx.V.1q.1C)}1r}};k.3f=S;k.fn.ig=u(o){E q.1w(\'1n\',u(){12 k.fx.dG(q,o)})};k.fx.dG=u(e,o){if(k.3f==S){k(\'2e\',1h).1S(\'<22 id="3f"></22>\');k.3f=k(\'#3f\')}k.3f.B(\'19\',\'2B\').B(\'Y\',\'1P\');D z=q;z.el=k(e);if(!o||!o.30){E}if(o.30.1K==b0&&1h.9e(o.30)){o.30=1h.9e(o.30)}P if(!o.30.dq){E}if(!o.1m){o.1m=g5}z.1m=o.1m;z.30=o.30;z.8r=o.3l;z.21=o.21;if(z.8r){k.3f.2R(z.8r)}z.a3=0;z.a2=0;if(k.dF){z.a3=(T(k.3f.B(\'5b\'))||0)+(T(k.3f.B(\'5O\'))||0)+(T(k.3f.B(\'4X\'))||0)+(T(k.3f.B(\'5U\'))||0);z.a2=(T(k.3f.B(\'4S\'))||0)+(T(k.3f.B(\'5Q\'))||0)+(T(k.3f.B(\'5M\'))||0)+(T(k.3f.B(\'5n\'))||0)}z.26=k.23(k.1a.3w(z.el.K(0)),k.1a.2o(z.el.K(0)));z.2T=k.23(k.1a.3w(z.30),k.1a.2o(z.30));z.26.1C-=z.a3;z.26.hb-=z.a2;z.2T.1C-=z.a3;z.2T.hb-=z.a2;z.J=o.21;k.3f.B(\'Z\',z.26.1C+\'U\').B(\'W\',z.26.hb+\'U\').B(\'Q\',z.26.y+\'U\').B(\'O\',z.26.x+\'U\').5w({Q:z.2T.y,O:z.2T.x,Z:z.2T.1C,W:z.2T.hb},z.1m,u(){if(z.8r)k.3f.4i(z.8r);k.3f.B(\'19\',\'1o\');if(z.21&&z.21.1K==2A){z.21.1D(z.el.K(0),[z.30])}k.2H(z.el.K(0),\'1n\')})};k.1v={M:{2E:10,ec:\'1Q/iJ.eZ\',e3:\'<1T 2J="1Q/6g.da" />\',eW:0.8,d8:\'iN a6\',dc:\'57\',3W:8J},jQ:I,jW:I,6j:S,8m:I,8k:I,d1:u(2k){if(!k.1v.8k||k.1v.8m)E;D 3K=2k.7L||2k.7K||-1;3m(3K){1e 35:if(k.1v.6j)k.1v.26(S,k(\'a[@4I=\'+k.1v.6j+\']:jJ\').K(0));1r;1e 36:if(k.1v.6j)k.1v.26(S,k(\'a[@4I=\'+k.1v.6j+\']:jL\').K(0));1r;1e 37:1e 8:1e 33:1e 80:1e kb:D 9p=k(\'#87\');if(9p.K(0).53!=S){9p.K(0).53.1D(9p.K(0))}1r;1e 38:1r;1e 39:1e 34:1e 32:1e gl:1e 78:D 9k=k(\'#88\');if(9k.K(0).53!=S){9k.K(0).53.1D(9k.K(0))}1r;1e 40:1r;1e 27:k.1v.au();1r}},7q:u(M){if(M)k.23(k.1v.M,M);if(1X.2k){k(\'2e\',1h).1J(\'6y\',k.1v.d1)}P{k(1h).1J(\'6y\',k.1v.d1)}k(\'a\').1E(u(){el=k(q);en=el.1p(\'4I\')||\'\';e9=el.1p(\'3h\')||\'\';ev=/\\.da|\\.gw|\\.8X|\\.eZ|\\.gn/g;if(e9.6c().d5(ev)!=S&&en.6c().3J(\'eU\')==0){el.1J(\'5h\',k.1v.26)}});if(k.3a.4t){3A=1h.3F(\'3A\');k(3A).1p({id:\'cN\',2J:\'ek:I;\',ej:\'cD\',ep:\'cD\'}).B({19:\'1o\',Y:\'1P\',Q:\'0\',O:\'0\',5E:\'9n:9w.9y.cC(1G=0)\'});k(\'2e\').1S(3A)}8n=1h.3F(\'22\');k(8n).1p(\'id\',\'cP\').B({Y:\'1P\',19:\'1o\',Q:\'0\',O:\'0\',1G:0}).1S(1h.8M(\' \')).1J(\'5h\',k.1v.au);6A=1h.3F(\'22\');k(6A).1p(\'id\',\'eK\').B({4X:k.1v.M.2E+\'U\'}).1S(1h.8M(\' \'));cE=1h.3F(\'22\');k(cE).1p(\'id\',\'dg\').B({4X:k.1v.M.2E+\'U\',5n:k.1v.M.2E+\'U\'}).1S(1h.8M(\' \'));cF=1h.3F(\'a\');k(cF).1p({id:\'gg\',3h:\'#\'}).B({Y:\'1P\',2L:k.1v.M.2E+\'U\',Q:\'0\'}).1S(k.1v.M.e3).1J(\'5h\',k.1v.au);7m=1h.3F(\'22\');k(7m).1p(\'id\',\'cM\').B({Y:\'2s\',cA:\'O\',6w:\'0 9F\',3I:1}).1S(6A).1S(cE).1S(cF);2b=1h.3F(\'1T\');2b.2J=k.1v.M.ec;k(2b).1p(\'id\',\'eM\').B({Y:\'1P\'});4G=1h.3F(\'a\');k(4G).1p({id:\'87\',3h:\'#\'}).B({Y:\'1P\',19:\'1o\',2U:\'2K\',ey:\'1o\'}).1S(1h.8M(\' \'));4M=1h.3F(\'a\');k(4M).1p({id:\'88\',3h:\'#\'}).B({Y:\'1P\',2U:\'2K\',ey:\'1o\'}).1S(1h.8M(\' \'));1Z=1h.3F(\'22\');k(1Z).1p(\'id\',\'eE\').B({19:\'1o\',Y:\'2s\',2U:\'2K\',cA:\'O\',6w:\'0 9F\',Q:\'0\',O:\'0\',3I:2}).1S([2b,4G,4M]);6F=1h.3F(\'22\');k(6F).1p(\'id\',\'ao\').B({19:\'1o\',Y:\'1P\',2U:\'2K\',Q:\'0\',O:\'0\',cA:\'cv\',7i:\'cu\',hC:\'0\'}).1S([1Z,7m]);k(\'2e\').1S(8n).1S(6F)},26:u(e,C){el=C?k(C):k(q);9t=el.1p(\'4I\');D 6B,4u,4G,4M;if(9t!=\'eU\'){k.1v.6j=9t;8Y=k(\'a[@4I=\'+9t+\']\');6B=8Y.1N();4u=8Y.cZ(C?C:q);4G=8Y.K(4u-1);4M=8Y.K(4u+1)}89=el.1p(\'3h\');6A=el.1p(\'4g\');3O=k.1a.6z();8n=k(\'#cP\');if(!k.1v.8k){k.1v.8k=1b;if(k.3a.4t){k(\'#cN\').B(\'W\',18.3r(3O.ih,3O.h)+\'U\').B(\'Z\',18.3r(3O.iw,3O.w)+\'U\').1Y()}8n.B(\'W\',18.3r(3O.ih,3O.h)+\'U\').B(\'Z\',18.3r(3O.iw,3O.w)+\'U\').1Y().fX(cO,k.1v.M.eW,u(){k.1v.cw(89,6A,3O,6B,4u,4G,4M)});k(\'#ao\').B(\'Z\',18.3r(3O.iw,3O.w)+\'U\')}P{k(\'#87\').K(0).53=S;k(\'#88\').K(0).53=S;k.1v.cw(89,6A,3O,6B,4u,4G,4M)}E I},cw:u(89,gP,3O,6B,4u,4G,4M){k(\'#cW\').bk();aX=k(\'#87\');aX.2G();aO=k(\'#88\');aO.2G();2b=k(\'#eM\');1Z=k(\'#eE\');6F=k(\'#ao\');7m=k(\'#cM\').B(\'3n\',\'2K\');k(\'#eK\').3x(6A);k.1v.8m=1b;if(6B)k(\'#dg\').3x(k.1v.M.d8+\' \'+(4u+1)+\' \'+k.1v.M.dc+\' \'+6B);if(4G){aX.K(0).53=u(){q.5B();k.1v.26(S,4G);E I}}if(4M){aO.K(0).53=u(){q.5B();k.1v.26(S,4M);E I}}2b.1Y();82=k.1a.2o(1Z.K(0));56=18.3r(82.1C,2b.K(0).Z+k.1v.M.2E*2);6f=18.3r(82.hb,2b.K(0).W+k.1v.M.2E*2);2b.B({O:(56-2b.K(0).Z)/2+\'U\',Q:(6f-2b.K(0).W)/2+\'U\'});1Z.B({Z:56+\'U\',W:6f+\'U\'}).1Y();dw=k.1a.bm();6F.B(\'Q\',3O.t+(dw.h/15)+\'U\');if(6F.B(\'19\')==\'1o\'){6F.1Y().7f(k.1v.M.3W)}6k=12 9s;k(6k).1p(\'id\',\'cW\').1J(\'hJ\',u(){56=6k.Z+k.1v.M.2E*2;6f=6k.W+k.1v.M.2E*2;2b.2G();1Z.5w({W:6f},82.hb!=6f?k.1v.M.3W:1,u(){1Z.5w({Z:56},82.1C!=56?k.1v.M.3W:1,u(){1Z.bG(6k);k(6k).B({Y:\'1P\',O:k.1v.M.2E+\'U\',Q:k.1v.M.2E+\'U\'}).7f(k.1v.M.3W,u(){db=k.1a.2o(7m.K(0));if(4G){aX.B({O:k.1v.M.2E+\'U\',Q:k.1v.M.2E+\'U\',Z:56/2-k.1v.M.2E*3+\'U\',W:6f-k.1v.M.2E*2+\'U\'}).1Y()}if(4M){aO.B({O:56/2+k.1v.M.2E*2+\'U\',Q:k.1v.M.2E+\'U\',Z:56/2-k.1v.M.2E*3+\'U\',W:6f-k.1v.M.2E*2+\'U\'}).1Y()}7m.B({Z:56+\'U\',Q:-db.hb+\'U\',3n:\'dd\'}).5w({Q:-1},k.1v.M.3W,u(){k.1v.8m=I})})})})});6k.2J=89},au:u(){k(\'#cW\').bk();k(\'#ao\').2G();k(\'#cM\').B(\'3n\',\'2K\');k(\'#cP\').fX(cO,0,u(){k(q).2G();if(k.3a.4t){k(\'#cN\').2G()}});k(\'#87\').K(0).53=S;k(\'#88\').K(0).53=S;k.1v.6j=S;k.1v.8k=I;k.1v.8m=I;E I}};k.R={1A:S,41:S,F:S,1s:S,1q:S,Y:S,9a:u(e){k.R.F=(q.d0)?q.d0:q;k.R.1s=k.1a.4a(e);k.R.1q={Z:T(k(k.R.F).B(\'Z\'))||0,W:T(k(k.R.F).B(\'W\'))||0};k.R.Y={Q:T(k(k.R.F).B(\'Q\'))||0,O:T(k(k.R.F).B(\'O\'))||0};k(1h).1J(\'3D\',k.R.cR).1J(\'5P\',k.R.cK);if(2g k.R.F.1k.g2===\'u\'){k.R.F.1k.g2.1D(k.R.F)}E I},cK:u(e){k(1h).3q(\'3D\',k.R.cR).3q(\'5P\',k.R.cK);if(2g k.R.F.1k.fN===\'u\'){k.R.F.1k.fN.1D(k.R.F)}k.R.F=S},cR:u(e){if(!k.R.F){E}1s=k.1a.4a(e);7p=k.R.Y.Q-k.R.1s.y+1s.y;7r=k.R.Y.O-k.R.1s.x+1s.x;7p=18.3r(18.3L(7p,k.R.F.1k.8g-k.R.1q.W),k.R.F.1k.7h);7r=18.3r(18.3L(7r,k.R.F.1k.8h-k.R.1q.Z),k.R.F.1k.70);if(2g k.R.F.1k.4m===\'u\'){D 8a=k.R.F.1k.4m.1D(k.R.F,[7r,7p]);if(2g 8a==\'hh\'&&8a.1g==2){7r=8a[0];7p=8a[1]}}k.R.F.14.Q=7p+\'U\';k.R.F.14.O=7r+\'U\';E I},26:u(e){k(1h).1J(\'3D\',k.R.8j).1J(\'5P\',k.R.8o);k.R.1A=q.1A;k.R.41=q.41;k.R.1s=k.1a.4a(e);k.R.1q={Z:T(k(q.1A).B(\'Z\'))||0,W:T(k(q.1A).B(\'W\'))||0};k.R.Y={Q:T(k(q.1A).B(\'Q\'))||0,O:T(k(q.1A).B(\'O\'))||0};if(k.R.1A.1k.4o){k.R.1A.1k.4o.1D(k.R.1A,[q])}E I},8o:u(){k(1h).3q(\'3D\',k.R.8j).3q(\'5P\',k.R.8o);if(k.R.1A.1k.3T){k.R.1A.1k.3T.1D(k.R.1A,[k.R.41])}k.R.1A=S;k.R.41=S},6i:u(dx,az){E 18.3L(18.3r(k.R.1q.Z+dx*az,k.R.1A.1k.av),k.R.1A.1k.6x)},6m:u(dy,az){E 18.3L(18.3r(k.R.1q.W+dy*az,k.R.1A.1k.8c),k.R.1A.1k.8b)},fb:u(W){E 18.3L(18.3r(W,k.R.1A.1k.8c),k.R.1A.1k.8b)},8j:u(e){if(k.R.1A==S){E}1s=k.1a.4a(e);dx=1s.x-k.R.1s.x;dy=1s.y-k.R.1s.y;1I={Z:k.R.1q.Z,W:k.R.1q.W};2z={Q:k.R.Y.Q,O:k.R.Y.O};3m(k.R.41){1e\'e\':1I.Z=k.R.6i(dx,1);1r;1e\'fj\':1I.Z=k.R.6i(dx,1);1I.W=k.R.6m(dy,1);1r;1e\'w\':1I.Z=k.R.6i(dx,-1);2z.O=k.R.Y.O-1I.Z+k.R.1q.Z;1r;1e\'5F\':1I.Z=k.R.6i(dx,-1);2z.O=k.R.Y.O-1I.Z+k.R.1q.Z;1I.W=k.R.6m(dy,1);1r;1e\'76\':1I.W=k.R.6m(dy,-1);2z.Q=k.R.Y.Q-1I.W+k.R.1q.W;1I.Z=k.R.6i(dx,-1);2z.O=k.R.Y.O-1I.Z+k.R.1q.Z;1r;1e\'n\':1I.W=k.R.6m(dy,-1);2z.Q=k.R.Y.Q-1I.W+k.R.1q.W;1r;1e\'at\':1I.W=k.R.6m(dy,-1);2z.Q=k.R.Y.Q-1I.W+k.R.1q.W;1I.Z=k.R.6i(dx,1);1r;1e\'s\':1I.W=k.R.6m(dy,1);1r}if(k.R.1A.1k.4v){if(k.R.41==\'n\'||k.R.41==\'s\')4p=1I.W*k.R.1A.1k.4v;P 4p=1I.Z;4W=k.R.fb(4p*k.R.1A.1k.4v);4p=4W/k.R.1A.1k.4v;3m(k.R.41){1e\'n\':1e\'76\':1e\'at\':2z.Q+=1I.W-4W;1r}3m(k.R.41){1e\'76\':1e\'w\':1e\'5F\':2z.O+=1I.Z-4p;1r}1I.W=4W;1I.Z=4p}if(2z.Q<k.R.1A.1k.7h){4W=1I.W+2z.Q-k.R.1A.1k.7h;2z.Q=k.R.1A.1k.7h;if(k.R.1A.1k.4v){4p=4W/k.R.1A.1k.4v;3m(k.R.41){1e\'76\':1e\'w\':1e\'5F\':2z.O+=1I.Z-4p;1r}1I.Z=4p}1I.W=4W}if(2z.O<k.R.1A.1k.70){4p=1I.Z+2z.O-k.R.1A.1k.70;2z.O=k.R.1A.1k.70;if(k.R.1A.1k.4v){4W=4p*k.R.1A.1k.4v;3m(k.R.41){1e\'n\':1e\'76\':1e\'at\':2z.Q+=1I.W-4W;1r}1I.W=4W}1I.Z=4p}if(2z.Q+1I.W>k.R.1A.1k.8g){1I.W=k.R.1A.1k.8g-2z.Q;if(k.R.1A.1k.4v){1I.Z=1I.W/k.R.1A.1k.4v}}if(2z.O+1I.Z>k.R.1A.1k.8h){1I.Z=k.R.1A.1k.8h-2z.O;if(k.R.1A.1k.4v){1I.W=1I.Z*k.R.1A.1k.4v}}D 6p=I;if(k.R.1A.1k.f7){6p=k.R.1A.1k.f7.1D(k.R.1A,[1I,2z]);if(6p){if(6p.1q){k.23(1I,6p.1q)}if(6p.Y){k.23(2z,6p.Y)}}}8d=k.R.1A.14;8d.O=2z.O+\'U\';8d.Q=2z.Q+\'U\';8d.Z=1I.Z+\'U\';8d.W=1I.W+\'U\';E I},2r:u(M){if(!M||!M.3Z||M.3Z.1K!=7M){E}E q.1E(u(){D el=q;el.1k=M;el.1k.av=M.av||10;el.1k.8c=M.8c||10;el.1k.6x=M.6x||6P;el.1k.8b=M.8b||6P;el.1k.7h=M.7h||-aC;el.1k.70=M.70||-aC;el.1k.8h=M.8h||6P;el.1k.8g=M.8g||6P;d6=k(el).B(\'Y\');if(!(d6==\'2s\'||d6==\'1P\')){el.14.Y=\'2s\'}fS=/n|at|e|fj|s|5F|w|76/g;24(i in el.1k.3Z){if(i.6c().d5(fS)!=S){if(el.1k.3Z[i].1K==b0){3v=k(el.1k.3Z[i]);if(3v.1N()>0){el.1k.3Z[i]=3v.K(0)}}if(el.1k.3Z[i].4Y){el.1k.3Z[i].1A=el;el.1k.3Z[i].41=i;k(el.1k.3Z[i]).1J(\'5v\',k.R.26)}}}if(el.1k.5S){if(2g el.1k.5S===\'4V\'){aV=k(el.1k.5S);if(aV.1N()>0){aV.1E(u(){q.d0=el});aV.1J(\'5v\',k.R.9a)}}P if(el.1k.5S==1b){k(q).1J(\'5v\',k.R.9a)}}})},4U:u(){E q.1E(u(){D el=q;24(i in el.1k.3Z){el.1k.3Z[i].1A=S;el.1k.3Z[i].41=S;k(el.1k.3Z[i]).3q(\'5v\',k.R.26)}if(el.1k.5S){if(2g el.1k.5S===\'4V\'){3v=k(el.1k.5S);if(3v.1N()>0){3v.3q(\'5v\',k.R.9a)}}P if(el.1k.5S==1b){k(q).3q(\'5v\',k.R.9a)}}el.1k=S})}};k.fn.23({hz:k.R.2r,hs:k.R.4U});k.2C=S;k.7n=I;k.3k=S;k.7o=[];k.9v=u(e){D 3K=e.7L||e.7K||-1;if(3K==17||3K==16){k.7n=1b}};k.9u=u(e){k.7n=I};k.dL=u(e){q.f.1s=k.1a.4a(e);q.f.1M=k.23(k.1a.3w(q),k.1a.2o(q));q.f.3e=k.1a.6z(q);q.f.1s.x-=q.f.1M.x;q.f.1s.y-=q.f.1M.y;k(q).1S(k.2C.K(0));if(q.f.hc)k.2C.2R(q.f.hc).B(\'19\',\'2B\');k.2C.B({19:\'2B\',Z:\'2P\',W:\'2P\'});if(q.f.o){k.2C.B(\'1G\',q.f.o)}k.3k=q;k.96=I;k.7o=[];q.f.el.1E(u(){q.1M={x:q.8t+(q.4Z&&!k.3a.7I?T(q.4Z.5b)||0:0)+(k.3k.3c||0),y:q.8G+(q.4Z&&!k.3a.7I?T(q.4Z.4S)||0:0)+(k.3k.3d||0),1C:q.4c,hb:q.5W};if(q.s==1b){if(k.7n==I){q.s=I;k(q).4i(k.3k.f.7j)}P{k.96=1b;k.7o[k.7o.1g]=k.1p(q,\'id\')}}});k.am.1D(q,[e]);k(1h).1J(\'3D\',k.am).1J(\'5P\',k.cX);E I};k.am=u(e){if(!k.3k)E;k.fd.1D(k.3k,[e])};k.fd=u(e){if(!k.3k)E;D 1s=k.1a.4a(e);D 3e=k.1a.6z(k.3k);1s.x+=3e.l-q.f.3e.l-q.f.1M.x;1s.y+=3e.t-q.f.3e.t-q.f.1M.y;D 93=18.3L(1s.x,q.f.1s.x);D 5F=18.3L(18.3S(1s.x-q.f.1s.x),18.3S(q.f.3e.w-93));D 99=18.3L(1s.y,q.f.1s.y);D 9g=18.3L(18.3S(1s.y-q.f.1s.y),18.3S(q.f.3e.h-99));if(q.3d>0&&1s.y-20<q.3d){D 3X=18.3L(3e.t,10);99-=3X;9g+=3X;q.3d-=3X}P if(q.3d+q.f.1M.h<q.f.3e.h&&1s.y+20>q.3d+q.f.1M.h){D 3X=18.3L(q.f.3e.h-q.3d,10);q.3d+=3X;if(q.3d!=3e.t)9g+=3X}if(q.3c>0&&1s.x-20<q.3c){D 3X=18.3L(3e.l,10);93-=3X;5F+=3X;q.3c-=3X}P if(q.3c+q.f.1M.w<q.f.3e.w&&1s.x+20>q.3c+q.f.1M.w){D 3X=18.3L(q.f.3e.w-q.3c,10);q.3c+=3X;if(q.3c!=3e.l)5F+=3X}k.2C.B({O:93+\'U\',Q:99+\'U\',Z:5F+\'U\',W:9g+\'U\'});k.2C.l=93+q.f.3e.l;k.2C.t=99+q.f.3e.t;k.2C.r=k.2C.l+5F;k.2C.b=k.2C.t+9g;k.96=I;q.f.el.1E(u(){aw=k.7o.3J(k.1p(q,\'id\'));if(!(q.1M.x>k.2C.r||(q.1M.x+q.1M.1C)<k.2C.l||q.1M.y>k.2C.b||(q.1M.y+q.1M.hb)<k.2C.t)){k.96=1b;if(q.s!=1b){q.s=1b;k(q).2R(k.3k.f.7j)}if(aw!=-1){q.s=I;k(q).4i(k.3k.f.7j)}}P if((q.s==1b)&&(aw==-1)){q.s=I;k(q).4i(k.3k.f.7j)}P if((!q.s)&&(k.7n==1b)&&(aw!=-1)){q.s=1b;k(q).2R(k.3k.f.7j)}});E I};k.cX=u(e){if(!k.3k)E;k.g0.1D(k.3k,[e])};k.g0=u(e){k(1h).3q(\'3D\',k.am).3q(\'5P\',k.cX);if(!k.3k)E;k.2C.B(\'19\',\'1o\');if(q.f.hc)k.2C.4i(q.f.hc);k.3k=I;k(\'2e\').1S(k.2C.K(0));if(k.96==1b){if(q.f.98)q.f.98(k.cJ(k.1p(q,\'id\')))}P{if(q.f.9d)q.f.9d(k.cJ(k.1p(q,\'id\')))}k.7o=[]};k.cJ=u(s){D h=\'\';D o=[];if(a=k(\'#\'+s)){a.K(0).f.el.1E(u(){if(q.s==1b){if(h.1g>0){h+=\'&\'}h+=s+\'[]=\'+k.1p(q,\'id\');o[o.1g]=k.1p(q,\'id\')}})}E{7l:h,o:o}};k.fn.gZ=u(o){if(!k.2C){k(\'2e\',1h).1S(\'<22 id="2C"></22>\').1J(\'7B\',k.9v).1J(\'6y\',k.9u);k.2C=k(\'#2C\');k.2C.B({Y:\'1P\',19:\'1o\'});if(1X.2k){k(\'2e\',1h).1J(\'7B\',k.9v).1J(\'6y\',k.9u)}P{k(1h).1J(\'7B\',k.9v).1J(\'6y\',k.9u)}}if(!o){o={}}E q.1E(u(){if(q.eP)E;q.eP=1b;q.f={a:o.3C,o:o.1G?2m(o.1G):I,7j:o.eS?o.eS:I,hc:o.58?o.58:I,98:o.98?o.98:I,9d:o.9d?o.9d:I};q.f.el=k(\'.\'+o.3C);k(q).1J(\'5v\',k.dL).B(\'Y\',\'2s\')})};k.3b={bM:1,eH:u(3t){D 3t=3t;E q.1E(u(){q.4z.6s.1E(u(ab){k.3b.5c(q,3t[ab])})})},K:u(){D 3t=[];q.1E(u(cL){if(q.bI){3t[cL]=[];D C=q;D 1q=k.1a.2o(q);q.4z.6s.1E(u(ab){D x=q.8t;D y=q.8G;92=T(x*2a/(1q.w-q.4c));91=T(y*2a/(1q.h-q.5W));3t[cL][ab]=[92||0,91||0,x||0,y||0]})}});E 3t},ct:u(C){C.A.fu=C.A.28.w-C.A.1B.1C;C.A.fw=C.A.28.h-C.A.1B.hb;if(C.9r.4z.bC){9Z=C.9r.4z.6s.K(C.bF+1);if(9Z){C.A.28.w=(T(k(9Z).B(\'O\'))||0)+C.A.1B.1C;C.A.28.h=(T(k(9Z).B(\'Q\'))||0)+C.A.1B.hb}9Q=C.9r.4z.6s.K(C.bF-1);if(9Q){D cU=T(k(9Q).B(\'O\'))||0;D cH=T(k(9Q).B(\'O\'))||0;C.A.28.x+=cU;C.A.28.y+=cH;C.A.28.w-=cU;C.A.28.h-=cH}}C.A.g7=C.A.28.w-C.A.1B.1C;C.A.eC=C.A.28.h-C.A.1B.hb;if(C.A.2O){C.A.gx=((C.A.28.w-C.A.1B.1C)/C.A.2O)||1;C.A.gy=((C.A.28.h-C.A.1B.hb)/C.A.2O)||1;C.A.fU=C.A.g7/C.A.2O;C.A.fH=C.A.eC/C.A.2O}C.A.28.dx=C.A.28.x-C.A.2c.x;C.A.28.dy=C.A.28.y-C.A.2c.y;k.11.1c.B(\'9b\',\'ad\')},3H:u(C,x,y){if(C.A.2O){fE=T(x/C.A.fU);92=fE*2a/C.A.2O;ft=T(y/C.A.fH);91=ft*2a/C.A.2O}P{92=T(x*2a/C.A.fu);91=T(y*2a/C.A.fw)}C.A.b3=[92||0,91||0,x||0,y||0];if(C.A.3H)C.A.3H.1D(C,C.A.b3)},eI:u(2k){3K=2k.7L||2k.7K||-1;3m(3K){1e 35:k.3b.5c(q.3U,[ae,ae]);1r;1e 36:k.3b.5c(q.3U,[-ae,-ae]);1r;1e 37:k.3b.5c(q.3U,[-q.3U.A.gx||-1,0]);1r;1e 38:k.3b.5c(q.3U,[0,-q.3U.A.gy||-1]);1r;1e 39:k.3b.5c(q.3U,[q.3U.A.gx||1,0]);1r;1e 40:k.11.5c(q.3U,[0,q.3U.A.gy||1]);1r}},5c:u(C,Y){if(!C.A){E}C.A.1B=k.23(k.1a.3w(C),k.1a.2o(C));C.A.2c={x:T(k.B(C,\'O\'))||0,y:T(k.B(C,\'Q\'))||0};C.A.4n=k.B(C,\'Y\');if(C.A.4n!=\'2s\'&&C.A.4n!=\'1P\'){C.14.Y=\'2s\'}k.11.c5(C);k.3b.ct(C);dx=T(Y[0])||0;dy=T(Y[1])||0;2v=C.A.2c.x+dx;2q=C.A.2c.y+dy;if(C.A.2O){3y=k.11.c7.1D(C,[2v,2q,dx,dy]);if(3y.1K==7M){dx=3y.dx;dy=3y.dy}2v=C.A.2c.x+dx;2q=C.A.2c.y+dy}3y=k.11.ce.1D(C,[2v,2q,dx,dy]);if(3y&&3y.1K==7M){dx=3y.dx;dy=3y.dy}2v=C.A.2c.x+dx;2q=C.A.2c.y+dy;if(C.A.5i&&(C.A.3H||C.A.2Z)){k.3b.3H(C,2v,2q)}2v=!C.A.1O||C.A.1O==\'4j\'?2v:C.A.2c.x||0;2q=!C.A.1O||C.A.1O==\'49\'?2q:C.A.2c.y||0;C.14.O=2v+\'U\';C.14.Q=2q+\'U\'},2r:u(o){E q.1E(u(){if(q.bI==1b||!o.3C||!k.1a||!k.11||!k.1x){E}5x=k(o.3C,q);if(5x.1N()==0){E}D 4N={2p:\'94\',5i:1b,3H:o.3H&&o.3H.1K==2A?o.3H:S,2Z:o.2Z&&o.2Z.1K==2A?o.2Z:S,3v:q,1G:o.1G||I};if(o.2O&&T(o.2O)){4N.2O=T(o.2O)||1;4N.2O=4N.2O>0?4N.2O:1}if(5x.1N()==1)5x.7t(4N);P{k(5x.K(0)).7t(4N);4N.3v=S;5x.7t(4N)}5x.7B(k.3b.eI);5x.1p(\'bM\',k.3b.bM++);q.bI=1b;q.4z={};q.4z.er=4N.er;q.4z.2O=4N.2O;q.4z.6s=5x;q.4z.bC=o.bC?1b:I;bZ=q;bZ.4z.6s.1E(u(2N){q.bF=2N;q.9r=bZ});if(o.3t&&o.3t.1K==7F){24(i=o.3t.1g-1;i>=0;i--){if(o.3t[i].1K==7F&&o.3t[i].1g==2){el=q.4z.6s.K(i);if(el.4Y){k.3b.5c(el,o.3t[i])}}}}})}};k.fn.23({hN:k.3b.2r,hS:k.3b.eH,hG:k.3b.K});k.2u={5I:[],eg:u(){q.5B();X=q.31;id=k.1p(X,\'id\');if(k.2u.5I[id]!=S){1X.5T(k.2u.5I[id])}1z=X.L.3u+1;if(X.L.1Q.1g<1z){1z=1}1Q=k(\'1T\',X.L.5u);X.L.3u=1z;if(1Q.1N()>0){1Q.7a(X.L.3W,k.2u.95)}},dp:u(){q.5B();X=q.31;id=k.1p(X,\'id\');if(k.2u.5I[id]!=S){1X.5T(k.2u.5I[id])}1z=X.L.3u-1;1Q=k(\'1T\',X.L.5u);if(1z<1){1z=X.L.1Q.1g}X.L.3u=1z;if(1Q.1N()>0){1Q.7a(X.L.3W,k.2u.95)}},2I:u(c){X=1h.9e(c);if(X.L.6o){1z=X.L.3u;7d(1z==X.L.3u){1z=1+T(18.6o()*X.L.1Q.1g)}}P{1z=X.L.3u+1;if(X.L.1Q.1g<1z){1z=1}}1Q=k(\'1T\',X.L.5u);X.L.3u=1z;if(1Q.1N()>0){1Q.7a(X.L.3W,k.2u.95)}},go:u(o){D X;if(o&&o.1K==7M){if(o.2b){X=1h.9e(o.2b.X);5N=1X.hn.3h.7C("#");o.2b.6S=S;if(5N.1g==2){1z=T(5N[1]);1Y=5N[1].4E(1z,\'\');if(k.1p(X,\'id\')!=1Y){1z=1}}P{1z=1}}if(o.90){o.90.5B();X=o.90.31.31;id=k.1p(X,\'id\');if(k.2u.5I[id]!=S){1X.5T(k.2u.5I[id])}5N=o.90.3h.7C("#");1z=T(5N[1]);1Y=5N[1].4E(1z,\'\');if(k.1p(X,\'id\')!=1Y){1z=1}}if(X.L.1Q.1g<1z||1z<1){1z=1}X.L.3u=1z;52=k.1a.2o(X);dt=k.1a.aT(X);d9=k.1a.6U(X);if(X.L.3z){X.L.3z.o.B(\'19\',\'1o\')}if(X.L.3s){X.L.3s.o.B(\'19\',\'1o\')}if(X.L.2b){y=T(dt.t)+T(d9.t);if(X.L.1U){if(X.L.1U.5A==\'Q\'){y+=X.L.1U.4C.hb}P{52.h-=X.L.1U.4C.hb}}if(X.L.2x){if(X.L.2x&&X.L.2x.6Q==\'Q\'){y+=X.L.2x.4C.hb}P{52.h-=X.L.2x.4C.hb}}if(!X.L.c1){X.L.df=o.2b?o.2b.W:(T(X.L.2b.B(\'W\'))||0);X.L.c1=o.2b?o.2b.Z:(T(X.L.2b.B(\'Z\'))||0)}X.L.2b.B(\'Q\',y+(52.h-X.L.df)/2+\'U\');X.L.2b.B(\'O\',(52.1C-X.L.c1)/2+\'U\');X.L.2b.B(\'19\',\'2B\')}1Q=k(\'1T\',X.L.5u);if(1Q.1N()>0){1Q.7a(X.L.3W,k.2u.95)}P{aj=k(\'a\',X.L.1U.o).K(1z-1);k(aj).2R(X.L.1U.5R);D 1T=12 9s();1T.X=k.1p(X,\'id\');1T.1z=1z-1;1T.2J=X.L.1Q[X.L.3u-1].2J;if(1T.21){1T.6S=S;k.2u.19.1D(1T)}P{1T.6S=k.2u.19}if(X.L.2x){X.L.2x.o.3x(X.L.1Q[1z-1].6L)}}}},95:u(){X=q.31.31;X.L.5u.B(\'19\',\'1o\');if(X.L.1U.5R){aj=k(\'a\',X.L.1U.o).4i(X.L.1U.5R).K(X.L.3u-1);k(aj).2R(X.L.1U.5R)}D 1T=12 9s();1T.X=k.1p(X,\'id\');1T.1z=X.L.3u-1;1T.2J=X.L.1Q[X.L.3u-1].2J;if(1T.21){1T.6S=S;k.2u.19.1D(1T)}P{1T.6S=k.2u.19}if(X.L.2x){X.L.2x.o.3x(X.L.1Q[X.L.3u-1].6L)}},19:u(){X=1h.9e(q.X);if(X.L.3z){X.L.3z.o.B(\'19\',\'1o\')}if(X.L.3s){X.L.3s.o.B(\'19\',\'1o\')}52=k.1a.2o(X);y=0;if(X.L.1U){if(X.L.1U.5A==\'Q\'){y+=X.L.1U.4C.hb}P{52.h-=X.L.1U.4C.hb}}if(X.L.2x){if(X.L.2x&&X.L.2x.6Q==\'Q\'){y+=X.L.2x.4C.hb}P{52.h-=X.L.2x.4C.hb}}hg=k(\'.ca\',X);y=y+(52.h-q.W)/2;x=(52.1C-q.Z)/2;X.L.5u.B(\'Q\',y+\'U\').B(\'O\',x+\'U\').3x(\'<1T 2J="\'+q.2J+\'" />\');X.L.5u.7f(X.L.3W);3s=X.L.3u+1;if(3s>X.L.1Q.1g){3s=1}3z=X.L.3u-1;if(3z<1){3z=X.L.1Q.1g}X.L.3s.o.B(\'19\',\'2B\').B(\'Q\',y+\'U\').B(\'O\',x+2*q.Z/3+\'U\').B(\'Z\',q.Z/3+\'U\').B(\'W\',q.W+\'U\').1p(\'4g\',X.L.1Q[3s-1].6L);X.L.3s.o.K(0).3h=\'#\'+3s+k.1p(X,\'id\');X.L.3z.o.B(\'19\',\'2B\').B(\'Q\',y+\'U\').B(\'O\',x+\'U\').B(\'Z\',q.Z/3+\'U\').B(\'W\',q.W+\'U\').1p(\'4g\',X.L.1Q[3z-1].6L);X.L.3z.o.K(0).3h=\'#\'+3z+k.1p(X,\'id\')},2r:u(o){if(!o||!o.1Z||k.2u.5I[o.1Z])E;D 1Z=k(\'#\'+o.1Z);D el=1Z.K(0);if(el.14.Y!=\'1P\'&&el.14.Y!=\'2s\'){el.14.Y=\'2s\'}el.14.2U=\'2K\';if(1Z.1N()==0)E;el.L={};el.L.1Q=o.1Q?o.1Q:[];el.L.6o=o.6o&&o.6o==1b||I;97=el.f3(\'hL\');24(i=0;i<97.1g;i++){7Z=el.L.1Q.1g;el.L.1Q[7Z]={2J:97[i].2J,6L:97[i].4g||97[i].hD||\'\'}}if(el.L.1Q.1g==0){E}el.L.4n=k.23(k.1a.3w(el),k.1a.2o(el));el.L.b5=k.1a.aT(el);el.L.bu=k.1a.6U(el);t=T(el.L.b5.t)+T(el.L.bu.t);b=T(el.L.b5.b)+T(el.L.bu.b);k(\'1T\',el).bk();el.L.3W=o.3W?o.3W:g5;if(o.5A||o.9f||o.5R){el.L.1U={};1Z.1S(\'<22 6T="g1"></22>\');el.L.1U.o=k(\'.g1\',el);if(o.9f){el.L.1U.9f=o.9f;el.L.1U.o.2R(o.9f)}if(o.5R){el.L.1U.5R=o.5R}el.L.1U.o.B(\'Y\',\'1P\').B(\'Z\',el.L.4n.w+\'U\');if(o.5A&&o.5A==\'Q\'){el.L.1U.5A=\'Q\';el.L.1U.o.B(\'Q\',t+\'U\')}P{el.L.1U.5A=\'4D\';el.L.1U.o.B(\'4D\',b+\'U\')}el.L.1U.aE=o.aE?o.aE:\' \';24(D i=0;i<el.L.1Q.1g;i++){7Z=T(i)+1;el.L.1U.o.1S(\'<a 3h="#\'+7Z+o.1Z+\'" 6T="gR" 4g="\'+el.L.1Q[i].6L+\'">\'+7Z+\'</a>\'+(7Z!=el.L.1Q.1g?el.L.1U.aE:\'\'))}k(\'a\',el.L.1U.o).1J(\'5h\',u(){k.2u.go({90:q})});el.L.1U.4C=k.1a.2o(el.L.1U.o.K(0))}if(o.6Q||o.9c){el.L.2x={};1Z.1S(\'<22 6T="dn">&7k;</22>\');el.L.2x.o=k(\'.dn\',el);if(o.9c){el.L.2x.9c=o.9c;el.L.2x.o.2R(o.9c)}el.L.2x.o.B(\'Y\',\'1P\').B(\'Z\',el.L.4n.w+\'U\');if(o.6Q&&o.6Q==\'Q\'){el.L.2x.6Q=\'Q\';el.L.2x.o.B(\'Q\',(el.L.1U&&el.L.1U.5A==\'Q\'?el.L.1U.4C.hb+t:t)+\'U\')}P{el.L.2x.6Q=\'4D\';el.L.2x.o.B(\'4D\',(el.L.1U&&el.L.1U.5A==\'4D\'?el.L.1U.4C.hb+b:b)+\'U\')}el.L.2x.4C=k.1a.2o(el.L.2x.o.K(0))}if(o.9D){el.L.3s={9D:o.9D};1Z.1S(\'<a 3h="#2\'+o.1Z+\'" 6T="eY">&7k;</a>\');el.L.3s.o=k(\'.eY\',el);el.L.3s.o.B(\'Y\',\'1P\').B(\'19\',\'1o\').B(\'2U\',\'2K\').B(\'4A\',\'eR\').2R(el.L.3s.9D);el.L.3s.o.1J(\'5h\',k.2u.eg)}if(o.9o){el.L.3z={9o:o.9o};1Z.1S(\'<a 3h="#0\'+o.1Z+\'" 6T="ee">&7k;</a>\');el.L.3z.o=k(\'.ee\',el);el.L.3z.o.B(\'Y\',\'1P\').B(\'19\',\'1o\').B(\'2U\',\'2K\').B(\'4A\',\'eR\').2R(el.L.3z.9o);el.L.3z.o.1J(\'5h\',k.2u.dp)}1Z.bG(\'<22 6T="ca"></22>\');el.L.5u=k(\'.ca\',el);el.L.5u.B(\'Y\',\'1P\').B(\'Q\',\'2P\').B(\'O\',\'2P\').B(\'19\',\'1o\');if(o.2b){1Z.bG(\'<22 6T="dW" 14="19: 1o;"><1T 2J="\'+o.2b+\'" /></22>\');el.L.2b=k(\'.dW\',el);el.L.2b.B(\'Y\',\'1P\');D 1T=12 9s();1T.X=o.1Z;1T.2J=o.2b;if(1T.21){1T.6S=S;k.2u.go({2b:1T})}P{1T.6S=u(){k.2u.go({2b:q})}}}P{k.2u.go({1Z:el})}if(o.cS){fi=T(o.cS)*aC}k.2u.5I[o.1Z]=o.cS?1X.6V(\'k.2u.2I(\\\'\'+o.1Z+\'\\\')\',fi):S}};k.X=k.2u.2r;k.1t={7s:[],5L:{},1c:I,7u:S,26:u(){if(k.11.F==S){E}D 4O,3G,c,cs;k.1t.1c.K(0).3l=k.11.F.A.6R;4O=k.1t.1c.K(0).14;4O.19=\'2B\';k.1t.1c.1B=k.23(k.1a.3w(k.1t.1c.K(0)),k.1a.2o(k.1t.1c.K(0)));4O.Z=k.11.F.A.1B.1C+\'U\';4O.W=k.11.F.A.1B.hb+\'U\';3G=k.1a.cy(k.11.F);4O.5K=3G.t;4O.5z=3G.r;4O.5k=3G.b;4O.5j=3G.l;if(k.11.F.A.46==1b){c=k.11.F.fI(1b);cs=c.14;cs.5K=\'2P\';cs.5z=\'2P\';cs.5k=\'2P\';cs.5j=\'2P\';cs.19=\'2B\';k.1t.1c.5o().1S(c)}k(k.11.F).f5(k.1t.1c.K(0));k.11.F.14.19=\'1o\'},fC:u(e){if(!e.A.44&&k.1x.5r.cQ){if(e.A.3T)e.A.3T.1D(F);k(e).B(\'Y\',e.A.cz||e.A.4n);k(e).aS();k(k.1x.5r).f6(e)}k.1t.1c.4i(e.A.6R).3x(\'&7k;\');k.1t.7u=S;D 4O=k.1t.1c.K(0).14;4O.19=\'1o\';k.1t.1c.f5(e);if(e.A.fx>0){k(e).7f(e.A.fx)}k(\'2e\').1S(k.1t.1c.K(0));D 86=[];D 8q=I;24(D i=0;i<k.1t.7s.1g;i++){D 1j=k.1x.3P[k.1t.7s[i]].K(0);D id=k.1p(1j,\'id\');D 8i=k.1t.8x(id);if(1j.1i.ay!=8i.7l){1j.1i.ay=8i.7l;if(8q==I&&1j.1i.2Z){8q=1j.1i.2Z}8i.id=id;86[86.1g]=8i}}k.1t.7s=[];if(8q!=I&&86.1g>0){8q(86)}},al:u(e,o){if(!k.11.F)E;D 6e=I;D i=0;if(e.1i.el.1N()>0){24(i=e.1i.el.1N();i>0;i--){if(e.1i.el.K(i-1)!=k.11.F){if(!e.5V.b2){if((e.1i.el.K(i-1).1M.y+e.1i.el.K(i-1).1M.hb/2)>k.11.F.A.2q){6e=e.1i.el.K(i-1)}P{1r}}P{if((e.1i.el.K(i-1).1M.x+e.1i.el.K(i-1).1M.1C/2)>k.11.F.A.2v&&(e.1i.el.K(i-1).1M.y+e.1i.el.K(i-1).1M.hb/2)>k.11.F.A.2q){6e=e.1i.el.K(i-1)}}}}}if(6e&&k.1t.7u!=6e){k.1t.7u=6e;k(6e).h5(k.1t.1c.K(0))}P if(!6e&&(k.1t.7u!=S||k.1t.1c.K(0).31!=e)){k.1t.7u=S;k(e).1S(k.1t.1c.K(0))}k.1t.1c.K(0).14.19=\'2B\'},cT:u(e){if(k.11.F==S){E}e.1i.el.1E(u(){q.1M=k.23(k.1a.74(q),k.1a.7G(q))})},8x:u(s){D i;D h=\'\';D o={};if(s){if(k.1t.5L[s]){o[s]=[];k(\'#\'+s+\' .\'+k.1t.5L[s]).1E(u(){if(h.1g>0){h+=\'&\'}h+=s+\'[]=\'+k.1p(q,\'id\');o[s][o[s].1g]=k.1p(q,\'id\')})}P{24(a in s){if(k.1t.5L[s[a]]){o[s[a]]=[];k(\'#\'+s[a]+\' .\'+k.1t.5L[s[a]]).1E(u(){if(h.1g>0){h+=\'&\'}h+=s[a]+\'[]=\'+k.1p(q,\'id\');o[s[a]][o[s[a]].1g]=k.1p(q,\'id\')})}}}}P{24(i in k.1t.5L){o[i]=[];k(\'#\'+i+\' .\'+k.1t.5L[i]).1E(u(){if(h.1g>0){h+=\'&\'}h+=i+\'[]=\'+k.1p(q,\'id\');o[i][o[i].1g]=k.1p(q,\'id\')})}}E{7l:h,o:o}},fF:u(e){if(!e.dq){E}E q.1E(u(){if(!q.5V||!k(e).is(\'.\'+q.5V.3C))k(e).2R(q.5V.3C);k(e).7t(q.5V.A)})},4U:u(){E q.1E(u(){k(\'.\'+q.5V.3C).aS();k(q).dR();q.5V=S;q.fm=S})},2r:u(o){if(o.3C&&k.1a&&k.11&&k.1x){if(!k.1t.1c){k(\'2e\',1h).1S(\'<22 id="e5">&7k;</22>\');k.1t.1c=k(\'#e5\');k.1t.1c.K(0).14.19=\'1o\'}q.do({3C:o.3C,9J:o.9J?o.9J:I,a5:o.a5?o.a5:I,58:o.58?o.58:I,7x:o.7x||o.dC,7y:o.7y||o.fO,cQ:1b,2Z:o.2Z||o.ia,fx:o.fx?o.fx:I,46:o.46?1b:I,6I:o.6I?o.6I:\'cV\'});E q.1E(u(){D A={6N:o.6N?1b:I,ff:6P,1G:o.1G?2m(o.1G):I,6R:o.58?o.58:I,fx:o.fx?o.fx:I,44:1b,46:o.46?1b:I,3v:o.3v?o.3v:S,2p:o.2p?o.2p:S,4o:o.4o&&o.4o.1K==2A?o.4o:I,4m:o.4m&&o.4m.1K==2A?o.4m:I,3T:o.3T&&o.3T.1K==2A?o.3T:I,1O:/49|4j/.48(o.1O)?o.1O:I,6M:o.6M?T(o.6M)||0:I,2V:o.2V?o.2V:I};k(\'.\'+o.3C,q).7t(A);q.fm=1b;q.5V={3C:o.3C,6N:o.6N?1b:I,ff:6P,1G:o.1G?2m(o.1G):I,6R:o.58?o.58:I,fx:o.fx?o.fx:I,44:1b,46:o.46?1b:I,3v:o.3v?o.3v:S,2p:o.2p?o.2p:S,b2:o.b2?1b:I,A:A}})}}};k.fn.23({j3:k.1t.2r,f6:k.1t.fF,iS:k.1t.4U});k.iZ=k.1t.8x;k.2t={6O:S,7b:I,9m:S,6K:u(e){k.2t.7b=1b;k.2t.1Y(e,q,1b)},cq:u(e){if(k.2t.6O!=q)E;k.2t.7b=I;k.2t.2G(e,q)},1Y:u(e,el,7b){if(k.2t.6O!=S)E;if(!el){el=q}k.2t.6O=el;1M=k.23(k.1a.3w(el),k.1a.2o(el));8u=k(el);4g=8u.1p(\'4g\');3h=8u.1p(\'3h\');if(4g){k.2t.9m=4g;8u.1p(\'4g\',\'\');k(\'#eT\').3x(4g);if(3h)k(\'#bL\').3x(3h.4E(\'jh://\',\'\'));P k(\'#bL\').3x(\'\');1c=k(\'#8z\');if(el.4H.3l){1c.K(0).3l=el.4H.3l}P{1c.K(0).3l=\'\'}bo=k.1a.2o(1c.K(0));ga=7b&&el.4H.Y==\'bO\'?\'4D\':el.4H.Y;3m(ga){1e\'Q\':2q=1M.y-bo.hb;2v=1M.x;1r;1e\'O\':2q=1M.y;2v=1M.x-bo.1C;1r;1e\'2L\':2q=1M.y;2v=1M.x+1M.1C;1r;1e\'bO\':k(\'2e\').1J(\'3D\',k.2t.3D);1s=k.1a.4a(e);2q=1s.y+15;2v=1s.x+15;1r;ad:2q=1M.y+1M.hb;2v=1M.x;1r}1c.B({Q:2q+\'U\',O:2v+\'U\'});if(el.4H.54==I){1c.1Y()}P{1c.7f(el.4H.54)}if(el.4H.2Y)el.4H.2Y.1D(el);8u.1J(\'8B\',k.2t.2G).1J(\'5B\',k.2t.cq)}},3D:u(e){if(k.2t.6O==S){k(\'2e\').3q(\'3D\',k.2t.3D);E}1s=k.1a.4a(e);k(\'#8z\').B({Q:1s.y+15+\'U\',O:1s.x+15+\'U\'})},2G:u(e,el){if(!el){el=q}if(k.2t.7b!=1b&&k.2t.6O==el){k.2t.6O=S;k(\'#8z\').7a(1);k(el).1p(\'4g\',k.2t.9m).3q(\'8B\',k.2t.2G).3q(\'5B\',k.2t.cq);if(el.4H.3i)el.4H.3i.1D(el);k.2t.9m=S}},2r:u(M){if(!k.2t.1c){k(\'2e\').1S(\'<22 id="8z"><22 id="eT"></22><22 id="bL"></22></22>\');k(\'#8z\').B({Y:\'1P\',3I:6P,19:\'1o\'});k.2t.1c=1b}E q.1E(u(){if(k.1p(q,\'4g\')){q.4H={Y:/Q|4D|O|2L|bO/.48(M.Y)?M.Y:\'4D\',3l:M.3l?M.3l:I,54:M.54?M.54:I,2Y:M.2Y&&M.2Y.1K==2A?M.2Y:I,3i:M.3i&&M.3i.1K==2A?M.3i:I};D el=k(q);el.1J(\'9z\',k.2t.1Y);el.1J(\'6K\',k.2t.6K)}})}};k.fn.hO=k.2t.2r;k.84={bq:u(e){3K=e.7L||e.7K||-1;if(3K==9){if(1X.2k){1X.2k.bT=1b;1X.2k.c0=I}P{e.aP();e.aW()}if(q.b1){1h.6J.dZ().3g="\\t";q.dV=u(){q.6K();q.dV=S}}P if(q.aF){26=q.5q;2T=q.dN;q.2y=q.2y.hd(0,26)+"\\t"+q.2y.h8(2T);q.aF(26+1,26+1);q.6K()}E I}},4U:u(){E q.1E(u(){if(q.7P&&q.7P==1b){k(q).3q(\'7B\',k.84.bq);q.7P=I}})},2r:u(){E q.1E(u(){if(q.4Y==\'cf\'&&(!q.7P||q.7P==I)){k(q).1J(\'7B\',k.84.bq);q.7P=1b}})}};k.fn.23({j5:k.84.2r,hH:k.84.4U});k.1a={3w:u(e){D x=0;D y=0;D es=e.14;D bP=I;if(k(e).B(\'19\')==\'1o\'){D 5Y=es.3n;D 9q=es.Y;bP=1b;es.3n=\'2K\';es.19=\'2B\';es.Y=\'1P\'}D el=e;7d(el){x+=el.8t+(el.4Z&&!k.3a.7I?T(el.4Z.5b)||0:0);y+=el.8G+(el.4Z&&!k.3a.7I?T(el.4Z.4S)||0:0);el=el.dJ}el=e;7d(el&&el.4Y&&el.4Y.6c()!=\'2e\'){x-=el.3c||0;y-=el.3d||0;el=el.31}if(bP==1b){es.19=\'1o\';es.Y=9q;es.3n=5Y}E{x:x,y:y}},7G:u(el){D x=0,y=0;7d(el){x+=el.8t||0;y+=el.8G||0;el=el.dJ}E{x:x,y:y}},2o:u(e){D w=k.B(e,\'Z\');D h=k.B(e,\'W\');D 1C=0;D hb=0;D es=e.14;if(k(e).B(\'19\')!=\'1o\'){1C=e.4c;hb=e.5W}P{D 5Y=es.3n;D 9q=es.Y;es.3n=\'2K\';es.19=\'2B\';es.Y=\'1P\';1C=e.4c;hb=e.5W;es.19=\'1o\';es.Y=9q;es.3n=5Y}E{w:w,h:h,1C:1C,hb:hb}},74:u(el){E{1C:el.4c||0,hb:el.5W||0}},bm:u(e){D h,w,de;if(e){w=e.8W;h=e.8O}P{de=1h.5d;w=1X.d4||aa.d4||(de&&de.8W)||1h.2e.8W;h=1X.cB||aa.cB||(de&&de.8O)||1h.2e.8O}E{w:w,h:h}},6z:u(e){D t=0,l=0,w=0,h=0,iw=0,ih=0;if(e&&e.9N.6c()!=\'2e\'){t=e.3d;l=e.3c;w=e.d7;h=e.d2;iw=0;ih=0}P{if(1h.5d){t=1h.5d.3d;l=1h.5d.3c;w=1h.5d.d7;h=1h.5d.d2}P if(1h.2e){t=1h.2e.3d;l=1h.2e.3c;w=1h.2e.d7;h=1h.2e.d2}iw=aa.d4||1h.5d.8W||1h.2e.8W||0;ih=aa.cB||1h.5d.8O||1h.2e.8O||0}E{t:t,l:l,w:w,h:h,iw:iw,ih:ih}},cy:u(e,7N){D el=k(e);D t=el.B(\'5K\')||\'\';D r=el.B(\'5z\')||\'\';D b=el.B(\'5k\')||\'\';D l=el.B(\'5j\')||\'\';if(7N)E{t:T(t)||0,r:T(r)||0,b:T(b)||0,l:T(l)};P E{t:t,r:r,b:b,l:l}},aT:u(e,7N){D el=k(e);D t=el.B(\'5M\')||\'\';D r=el.B(\'5U\')||\'\';D b=el.B(\'5n\')||\'\';D l=el.B(\'4X\')||\'\';if(7N)E{t:T(t)||0,r:T(r)||0,b:T(b)||0,l:T(l)};P E{t:t,r:r,b:b,l:l}},6U:u(e,7N){D el=k(e);D t=el.B(\'4S\')||\'\';D r=el.B(\'5O\')||\'\';D b=el.B(\'5Q\')||\'\';D l=el.B(\'5b\')||\'\';if(7N)E{t:T(t)||0,r:T(r)||0,b:T(b)||0,l:T(l)||0};P E{t:t,r:r,b:b,l:l}},4a:u(2k){D x=2k.hT||(2k.gM+(1h.5d.3c||1h.2e.3c))||0;D y=2k.ki||(2k.iQ+(1h.5d.3d||1h.2e.3d))||0;E{x:x,y:y}},cI:u(4R,cx){cx(4R);4R=4R.7c;7d(4R){k.1a.cI(4R,cx);4R=4R.hQ}},h7:u(4R){k.1a.cI(4R,u(el){24(D 1p in el){if(2g el[1p]===\'u\'){el[1p]=S}}})},hV:u(el,1O){D 5l=k.1a.6z();D b6=k.1a.2o(el);if(!1O||1O==\'49\')k(el).B({Q:5l.t+((18.3r(5l.h,5l.ih)-5l.t-b6.hb)/2)+\'U\'});if(!1O||1O==\'4j\')k(el).B({O:5l.l+((18.3r(5l.w,5l.iw)-5l.l-b6.1C)/2)+\'U\'})},hW:u(el,dk){D 1Q=k(\'1T[@2J*="8X"]\',el||1h),8X;1Q.1E(u(){8X=q.2J;q.2J=dk;q.14.5E="9n:9w.9y.hE(2J=\'"+8X+"\')"})}};[].3J||(7F.hF.3J=u(v,n){n=(n==S)?0:n;D m=q.1g;24(D i=n;i<m;i++)if(q[i]==v)E i;E-1});',62,1293,'||||||||||||||||||||jQuery||||||this||||function||||||dragCfg|css|elm|var|return|dragged|easing|speed|false|callback|get|ss|options|iAuto|left|else|top|iResize|null|parseInt|px|oldStyle|height|slideshow|position|width||iDrag|new||style||||Math|display|iUtil|true|helper|subject|case|autoCFG|length|document|dropCfg|iEL|resizeOptions|carouselCfg|duration|interfaceFX|none|attr|sizes|break|pointer|iSort|type|ImageBox|queue|iDrop|iAutoscroller|slide|resizeElement|oC|wb|apply|each|fisheyeCfg|opacity|delta|newSizes|bind|constructor|custom|pos|size|axis|absolute|images|items|append|img|slideslinks|255|firstNum|window|show|container||complete|div|extend|for||start||cont|elsToScroll|100|loader|oR||body|elem|typeof|selectedItem|oldP|props|event|accordionCfg|parseFloat|field|getSize|containment|ny|build|relative|iTooltip|islideshow|nx|tp|slideCaption|value|newPosition|Function|block|selectHelper|step|border|itemWidth|hide|dequeue|timer|src|hidden|right|limit|nr|fractions|0px|PI|addClass|direction|end|overflow|cursorAt|result|parentData|onShow|onChange|to|parentNode|||||||||browser|iSlider|scrollLeft|scrollTop|scr|transferHelper|text|href|onHide|pre|selectdrug|className|switch|visibility|item|wrapper|unbind|max|nextslide|values|currentslide|handle|getPosition|html|newCoords|prevslide|iframe|iExpander|accept|mousemove|canvas|createElement|margins|onSlide|zIndex|indexOf|pressedKey|min|valueToAdd|multipleSeparator|pageSize|zones|highlighted|toggle|abs|onStop|dragElem|times|fadeDuration|diff|dhs|handlers||resizeDirection||vp|so|distance|ghosting||test|vertically|getPointer|startTop|offsetWidth|subjectValue|lastSuggestion|DropOutDirectiont|title|wrs|removeClass|horizontally|startLeft|out|onDrag|oP|onStart|nWidth|percent|down|ifxFirstDisplay|msie|iteration|ratio|clear|color|lastValue|slideCfg|fontSize|currentPointer|dimm|bottom|replace|up|prevImage|tooltipCFG|rel|els|fxCheckTag|context|nextImage|params|shs|fieldData|elToScroll|nodeEl|borderTopWidth|chunks|destroy|string|nHeight|paddingLeft|tagName|currentStyle||halign|slidePos|onclick|delay||containerW|from|helperclass|endLeft|endTop|borderLeftWidth|dragmoveBy|documentElement|dhe|newStyles|clonedEl|click|si|marginLeft|marginBottom|clientScroll|OpenClose|paddingBottom|empty|toWrite|selectionStart|overzone|toAdd|onDragModifier|holder|mousedown|animate|toDrag|cnt|marginRight|linksPosition|blur|getAttribute|hight|filter|sw|zoney|cos|slideshows|zonex|marginTop|collected|paddingTop|url|borderRightWidth|mouseup|borderBottomWidth|activeLinkClass|dragHandle|clearInterval|paddingRight|sortCfg|offsetHeight|prop|oldVisibility|styles||BlindDirection|point|fxh|nmp|old|post|currentPanel|onSelect|elementData|grid|pow|toLowerCase|animationHandler|cur|containerH|close|puff|getWidth|currentRel|imageEl|Expander|getHeight|iFisheye|random|newDimensions|itemHeight|reflections|sliders|selRange|wr|orig|margin|maxWidth|keyup|getScroll|captionText|totalImages|128|parseColor|curCSS|outerContainer|Scale|restore|tolerance|selection|focus|caption|snapDistance|revert|current|3000|captionPosition|hpc|onload|class|getBorder|setInterval|oldStyleAttr|rule|rgb|open|minLeft|ActiveXObject|oldDisplay|restoreStyle|getSizeLite||nw|0x||F0|fadeOut|focused|firstChild|while|cssRules|fadeIn|Date|minTop|backgroundColor|sc|nbsp|hash|captionEl|selectKeyHelper|selectCurrent|newTop|init|newLeft|changed|Draggable|inFrontOf|efx|139|onHover|onOut|getTime|np|keydown|split|radiusY|increment|Array|getPositionLite|selectClass|opera|onHighlight|keyCode|charCode|Object|toInteger|frameClass|hasTabsEnabled|zonew|user|zoneh|positionItems|onClick|oD|scrollIntoView|accordionPos|proximity|indic||data|containerSize|sin|iTTabs||ts|ImageBoxPrevImage|ImageBoxNextImage|imageSrc|newPos|maxHeight|minHeight|elS|activeClass|panels|maxBottom|maxRight|ser|move|opened|bounceout|animationInProgress|overlay|stop|reflectionSize|fnc|classname|insideParent|offsetLeft|jEl|nRy|pr|serialize|nRx|tooltipHelper|cssSides|mouseout|select|count|namedColors|padding|offsetTop|directionIncrement|parentEl|400|dir|expand|createTextNode|finishedPre|clientHeight|li|applyOn|content|contBorders|object|parentBorders|alpha|clientWidth|png|gallery|fontWeight|link|yproc|xproc|sx|parent|showImage|selectedone|imgs|onselect|sy|startDrag|cursor|captionClass|onselectstop|getElementById|linksClass|sh|ul|onActivate|isDroppable|nextEl|onDrop|oldTitle|progid|prevslideClass|prevEl|oldPosition|SliderContainer|Image|linkRel|selectKeyUp|selectKeyDown|DXImageTransform|inCache|Microsoft|mouseover|dragstop|diffX|211|nextslideClass|prot|auto|dEs|hidehelper|isDraggable|activeclass|unit|DoFold|unfold|nodeName|startTime|buildWrapper|prev|1px|oldColor|setTimeout|ScrollTo|st|sl|cssText|9999|next|destroyWrapper|opt|diffHeight|diffWidth|exec|hoverclass|image|blind|borderColor|sideEnd|self|key||default|2000|styleSheets|getValues|192|diffY|lnk|reflexions|checkhover|selectcheck|maxRotation|ImageBoxOuterContainer|gradient|panelHeight|childs|headers|ne|hideImage|minWidth|iIndex|itemsText|os|side|iCarousel|5625|1000|itemMinWidth|linksSeparator|setSelectionRange|protectRotation|positionContainer|posx|hoverClass|valToAdd|minchars|helperClass|source|nextImageEl|preventDefault|multiple|headerSelector|DraggableDestroy|getPadding|autofill|handleEl|stopPropagation|prevImageEl|getFieldValues|panelSelector|String|createTextRange|floats|lastSi|shrink|oPad|windowSize|paddingLeftSize|angle|paddingY|paddingX|RegExp|borderRightSize|floatVal|firstStep|pulse|Pulsate|Color|rotationSpeed|paddingBottomSize|remove|parseStyle|getClient|Number|helperSize|bounce|doTab||zoom|borderLeftSize|oBor|paddingRightSize|borderTopSize|paddingTopSize|stopAnim|pValue|borderBottomSize|extraWidth|restricted|autoSize|unselectable|SliderIteration|prepend|clearTimeout|isSlider|oneIsSortable|applyOnHover|tooltipURL|tabindex|draginit|mouse|restoreStyles|sliderSize|sliderPos|parentPos|cancelBubble|autocomplete|inputWidth|oldBorder|dragmove|clnt|sliderEl|returnValue|loaderWidth|idsa|letterSpacing|pause|getContainment|fade|snapToGrid|linear|10000|slideshowHolder|asin|cssSidesEnd|borderWidth|fitToContainer|TEXTAREA|entities|INPUT|spacer|writeItems|character|currentValue|paddings|169|oldFloat|borders|hidefocused|bouncein||modifyContainer|transparent|center|loadImage|func|getMargins|initialPosition|textAlign|innerHeight|Alpha|no|captionImages|closeEl|shake|prevTop|traverseDOM|Selectserialize|stopDrag|slider|ImageBoxCaption|ImageBoxIframe|300|ImageBoxOverlay|sortable|moveDrag|autoplay|measure|prevLeft|intersect|ImageBoxCurrentImage|selectstop|Shake|index|dragEl|keyPressed|scrollHeight|scroll|innerWidth|match|elPosition|scrollWidth|textImage|slideBor|jpg|captionSize|textImageFrom|visible||loaderHeight|ImageBoxCaptionImages||hoverItem|clickItem|emptyGIF||notColor|slideshowCaption|Droppable|goprev|childNodes|autocompleteHelper|autocompleteIframe|slidePad|fit|165|clientSize|||fontFamily|colorCssProps|elType|onhover|cssProps|expanderHelper|boxModel|itransferTo|keypress|moveStart|offsetParent|Width|selectstart|fxe|selectionEnd|checkCache|fontStyle|update|DroppableDestroy|remeasure|fontStretch|fontVariant|onblur|slideshowLoader|htmlEntities|wordSpacing|createRange|224|KhtmlUserSelect||closeHTML|on|sortHelper|245|userSelect|dragHelper|hrefAttr|dragstart|107|loaderSRC|highlight|slideshowPrevslide||gonext||styleFloat|frameborder|javascript|||relAttr|wid|scrolling||onslide|||listStyle|imageTypes|insertBefore|999|textDecoration|sqrt|140|230|maxy|240|ImageBoxContainer|doScroll|interval|set|dragmoveByKey|protect|ImageBoxCaptionText|144|ImageBoxLoader|off|checkdrop|isSelectable|hlt|30px|selectedclass|tooltipTitle|imagebox|shc|overlayOpacity|selRange2|slideshowNextSlide|gif|getSelectionStart|360|iAccordion|getElementsByTagName|iBounce|after|SortableAddItem|onResize|150|itemZIndex|grow|getHeightMinMax|borderTopUnit|selectcheckApply|borderRightUnit|zindex|fontUnit|togglehor|time|se|parte|easeout|isSortable||SlideInUp|fold|SlideOutUp|rgba|addColorStop|yfrac|containerMaxx|interfaceColorFX|containerMaxy||leftUnit|mousex||radiusX|check|getContext|xfrac|addItem|topUnit|fracH|cloneNode|togglever|paddingLeftUnit|borderBottomUnit|finish|onDragStop|onout|posy|isFunction|oldOverflow|directions|vertical|fracW|fakeAccordionClass|parts|fadeTo|inputValue|xml|selectstopApply|slideshowLinks|onDragStart|BlindUp|paddingTopUnit|500|trim|maxx|borderLeftUnit|paddingRightUnit|filteredPosition|BlindDown|paddingBottomUnit|horizontal|valign|find|ImageBoxClose|onselectstart|mozUserSelect|ondragstart|scale|110|globalCompositeOperation|bmp||drawImage|ondrop|password|quot||save|starty|jpeg|||number|startx|finishOpacity|hover|recallDroppables|flipv|finishx|destination|khtml|moz|lt|amp|pW|clientX|Accordion|translate|captiontext|elasticin|slideshowLink|fix|elasticout|resize|elasticboth|bounceboth|984375|9375|Selectable|30002|list|625|30001|nodeValue|before|100000|purgeEvents|substr|duplicate|moveEnd|||substring|success|param|par|array|Fisheye|name|POST|ajax|easeboth|location|fromHandler|collapse|MozUserSelect||ResizableDestroy|rotationTimer|fillRect|fill|WebKit|fillStyle|createLinearGradient|Resizable|navigator|appVersion|lineHeigt|alt|AlphaImageLoader|prototype|SliderGetValues|DisableTabs|Carousel|load|easein|IMG|200|Slider|ToolTip|wh|nextSibling|Autocomplete|SliderSetValues|pageX|float|centerEl|fixPNG|isNaN|dotted|dashed|stopAll|Left|outlineColor|Top|Right|Bottom|solid|double|selectorText|rules|onchange|SlideToggleRight|SlideOutRight||borderStyle||TransferTo||groove|ridge|inset|outset|borderTopColor||borderRightColor|olive|navy|orange||pink|203|maroon||magenta|182|193|lightyellow|lime|purple|red|outlineOffset|outlineWidth|borderBottomColor|borderLeftColor|lineHeight|loading|silver|white|yellow|Showing|100000000|SlideInRight|clientY|Highlight|SortableDestroy|CloseVertically|CloseHorizontally|FoldToggle|UnFold|SlideInDown|SlideToggleUp|SortSerialize|Fold|SwitchHorizontally|SwitchVertically|Sortable|scrollTo|EnableTabs|ScrollToAnchors|pt|Puff|OpenVertically|OpenHorizontally|Grow|Shrink|DropToggleRight|DropInRight|BlindToggleHorizontally|BlindRight|http|Bounce|120|BlindLeft|BlindToggleVertically|SlideToggleLeft|SlideOutLeft|toUpperCase|SlideInLeft|SlideToggleDown|SlideOutDown|DropOutLeft|DropInLeft|DropToggleLeft|DropOutRight|DropToggleUp|DropInUp|DropOutDown|DropInDown|DropToggleDown|DropOutUp|lightpink|textIndent|aqua|appendChild|azure|beige|220|last|cssFloat|first|ol|wrapEl|fxWrapper|black|imageLoaded|darkkhaki|darkgreen|189|183|darkmagenta|firstResize|darkgrey|brown|cyan|darkblue|darkcyan|table|form|col|tfoot|colgroup|th|header|thead|tbody|112|Autoexpand|tr|td|script|frame|input|pageY|textarea|button|w_|removeChild|frameset|option|optgroup|meta|darkolivegreen|blue|122|233|green|lightcyan|204|darkviolet|lightgreen|indigo|216|khaki|darksalmon|130|darkred|lightblue|148|173|215|238|fuchsia|gold|darkorchid|153|darkorange|lightgrey'.split('|'),0,{}))
bp-forums/bbpress/bb-login.php CHANGED
@@ -1,104 +1,148 @@
1
  <?php
2
- // Load bbPress.
3
- require('./bb-load.php');
4
 
5
- // Redirect to an SSL page if required.
 
 
 
6
  bb_ssl_redirect();
7
 
8
- // Get the referer.
9
- $ref = wp_get_referer();
10
- if ( !$re = $_POST['re'] ? $_POST['re'] : $_GET['re'] ) {
11
- $re = $ref;
12
- }
13
 
14
- // Grab the URL for comparison.
15
- $home_url = parse_url( bb_get_uri( null, null, BB_URI_CONTEXT_TEXT ) );
16
- $home_path = $home_url['path'];
17
 
18
- // Don't ever redirect to the register page or the password reset page.
19
- if ( !$re || false !== strpos( $re, $home_path . 'register.php' ) || false !== strpos( $re, $home_path . 'bb-reset-password.php' ) ) {
20
- $re = bb_get_uri( null, null, BB_URI_CONTEXT_HEADER );
21
- }
22
 
23
- // Don't cache this page at all.
24
- nocache_headers();
 
25
 
26
- // If this page was accessed using SSL, make sure the redirect is a full URL
27
- // so that we don't end up on an SSL page again (unless the whole site is
28
- // under SSL).
29
- if ( is_ssl() && 0 === strpos( $re, '/' ) ) {
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
30
  $re = bb_get_uri( $re , null, BB_URI_CONTEXT_HEADER );
31
- }
32
 
33
- // Logout requested.
34
- if ( isset( $_GET['logout'] ) ) {
35
- bb_logout();
36
- bb_safe_redirect( $re );
37
- exit;
38
  }
39
 
40
- // User is already logged in.
 
 
 
 
 
 
41
  if ( bb_is_user_logged_in() ) {
42
- bb_safe_redirect( $re );
43
- exit;
44
- }
45
 
46
- // Get the user from the login details.
47
- $user = bb_login( @$_POST['user_login'], @$_POST['password'], @$_POST['remember'] );
 
 
 
 
 
48
 
49
- // User logged in successfully.
50
- if ( $user && !is_wp_error( $user ) ) {
51
  bb_safe_redirect( $re );
52
  exit;
53
  }
54
 
55
- // Grab the error returned if there is one.
56
- if ( is_wp_error( $user ) ) {
57
- $bb_login_error =& $user;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
58
  } else {
59
  $bb_login_error = new WP_Error;
60
  }
61
 
62
- // Whether we allow login by email address or not.
63
- $email_login = bb_get_option( 'email_login' );
64
 
65
- // Find out if the user actually exists.
66
  $error_data = $bb_login_error->get_error_data();
67
- if ( isset( $error_data['unique'] ) && false === $error_data['unique'] ) {
 
 
68
  $user_exists = true;
69
- } else {
70
- $user_exists = isset( $_POST['user_login'] ) && $_POST['user_login'] && (bool) bb_get_user( $_POST['user_login'], array( 'by' => 'login' ) );
71
- }
72
- unset( $error_data );
73
 
 
74
  if ( 'post' == strtolower( $_SERVER['REQUEST_METHOD'] ) ) {
75
- // If the user doesn't exist then add that error.
76
- if ( !$user_exists ) {
77
- if ( isset( $_POST['user_login'] ) && $_POST['user_login'] ) {
 
78
  $bb_login_error->add( 'user_login', __( 'User does not exist.' ) );
79
  } else {
80
  $bb_login_error->add( 'user_login', $email_login ? __( 'Enter a username or email address.' ) : __( 'Enter a username.' ) );
81
  }
82
  }
83
 
84
- // If the password was wrong then add that error.
85
  if ( !$bb_login_error->get_error_code() ) {
86
  $bb_login_error->add( 'password', __( 'Incorrect password.' ) );
87
  }
88
  }
89
 
90
- // If trying to log in with email address, don't leak whether or not email address exists in the db.
91
- // is_email() is not perfect, usernames can be valid email addresses potentially.
92
- if ( $email_login && $bb_login_error->get_error_codes() && false !== is_email( $_POST['user_login'] ) ) {
 
 
 
93
  $bb_login_error = new WP_Error( 'user_login', __( 'Username and Password do not match.' ) );
94
- }
95
 
96
- // Sanitze variables for display.
97
- $user_login = esc_attr( sanitize_user( @$_POST['user_login'], true ) );
98
- $remember_checked = @$_POST['remember'] ? ' checked="checked"' : '';
99
- $re = esc_url( $re );
100
- $re = $redirect_to = esc_attr( $re );
101
 
102
- // Load the template.
103
  bb_load_template( 'login.php', array( 'user_exists', 'user_login', 'remember_checked', 'redirect_to', 're', 'bb_login_error' ) );
 
104
  exit;
 
 
1
  <?php
 
 
2
 
3
+ // Load bbPress
4
+ require( './bb-load.php' );
5
+
6
+ // SSL redirect if required
7
  bb_ssl_redirect();
8
 
9
+ // Don't cache this page at all
10
+ nocache_headers();
 
 
 
11
 
12
+ /** Look for redirection ******************************************************/
 
 
13
 
14
+ // Look for 'redirect_to'
15
+ if ( isset( $_REQUEST['redirect_to'] ) )
16
+ $re = $_REQUEST['redirect_to'];
 
17
 
18
+ // Look for 're'
19
+ if ( empty( $re ) && isset( $_REQUEST['re'] ) )
20
+ $re = $_REQUEST['re'];
21
 
22
+ // Use referer
23
+ if ( empty( $re ) )
24
+ $re = wp_get_referer();
25
+
26
+ // Don't redirect to register or password reset pages
27
+ if ( empty( $re ) ) {
28
+ // Grab home path and URL for comparison
29
+ $home_url = parse_url( bb_get_uri( null, null, BB_URI_CONTEXT_TEXT ) );
30
+ $home_path = $home_url['path'];
31
+
32
+ if ( false !== strpos( $re, $home_path . 'register.php' ) || false !== strpos( $re, $home_path . 'bb-reset-password.php' ) )
33
+ $re = bb_get_uri( null, null, BB_URI_CONTEXT_HEADER );
34
+ }
35
+
36
+ /**
37
+ * If this page was accessed using SSL, make sure the redirect is a full URL so
38
+ * that we don't end up on an SSL page again (unless the whole site is under SSL)
39
+ */
40
+ if ( is_ssl() && 0 === strpos( $re, '/' ) )
41
  $re = bb_get_uri( $re , null, BB_URI_CONTEXT_HEADER );
 
42
 
43
+ // Clean the redirection destination
44
+ if ( !empty( $re ) ) {
45
+ $re = esc_url( $re );
46
+ $re = esc_attr( $re );
47
+ $redirect_to = $re;
48
  }
49
 
50
+ // Fallback to site root
51
+ if ( empty( $re ) )
52
+ $re = bb_get_uri();
53
+
54
+ /** Handle logout *************************************************************/
55
+
56
+ // User is logged in
57
  if ( bb_is_user_logged_in() ) {
 
 
 
58
 
59
+ // Logout requested
60
+ if ( isset( $_GET['logout'] ) )
61
+ $_GET['action'] = 'logout';
62
+
63
+ // Check logout action
64
+ if ( isset( $_GET['action'] ) && 'logout' === $_GET['action'] )
65
+ bb_logout();
66
 
 
 
67
  bb_safe_redirect( $re );
68
  exit;
69
  }
70
 
71
+ /** Handle login **************************************************************/
72
+
73
+ // Do we allow login by email address
74
+ $email_login = bb_get_option( 'email_login' );
75
+
76
+ // Get the user from the login details
77
+ if ( empty( $_POST['log'] ) )
78
+ $_POST['log'] = !empty( $_POST['user_login'] ) ? $_POST['user_login'] : '';
79
+
80
+ if ( empty( $_POST['pwd'] ) )
81
+ $_POST['pwd'] = !empty( $_POST['password'] ) ? $_POST['password'] : '';
82
+
83
+ if ( empty( $_POST['rememberme'] ) )
84
+ $_POST['rememberme'] = !empty( $_POST['remember'] ) ? 1 : '';
85
+
86
+ // Attempt to log the user in
87
+ if ( $user = bb_login( @$_POST['log'], @$_POST['pwd'], @$_POST['rememberme'] ) ) {
88
+ if ( !is_wp_error( $user ) ) {
89
+ bb_safe_redirect( $re );
90
+ exit;
91
+ } else {
92
+ $bb_login_error =& $user;
93
+ }
94
+
95
+ // No login so prepare the error
96
  } else {
97
  $bb_login_error = new WP_Error;
98
  }
99
 
100
+ /** Handle errors *************************************************************/
 
101
 
102
+ // Get error data so we can provide feedback
103
  $error_data = $bb_login_error->get_error_data();
104
+
105
+ // Does user actually exist
106
+ if ( isset( $error_data['unique'] ) && false === $error_data['unique'] )
107
  $user_exists = true;
108
+ else
109
+ $user_exists = !empty( $_POST['log'] ) && (bool) bb_get_user( $_POST['log'], array( 'by' => 'login' ) );
 
 
110
 
111
+ // Check for errors on post method
112
  if ( 'post' == strtolower( $_SERVER['REQUEST_METHOD'] ) ) {
113
+
114
+ // If the user doesn't exist then add that error
115
+ if ( empty( $user_exists ) ) {
116
+ if ( !empty( $_POST['log'] ) ) {
117
  $bb_login_error->add( 'user_login', __( 'User does not exist.' ) );
118
  } else {
119
  $bb_login_error->add( 'user_login', $email_login ? __( 'Enter a username or email address.' ) : __( 'Enter a username.' ) );
120
  }
121
  }
122
 
123
+ // If the password was wrong then add that error
124
  if ( !$bb_login_error->get_error_code() ) {
125
  $bb_login_error->add( 'password', __( 'Incorrect password.' ) );
126
  }
127
  }
128
 
129
+ /**
130
+ * If trying to log in with email address, don't leak whether or not email
131
+ * address exists in the db. is_email() is not perfect. Usernames can be
132
+ * valid email addresses potentially.
133
+ */
134
+ if ( !empty( $email_login ) && $bb_login_error->get_error_codes() && false !== is_email( @$_POST['log'] ) )
135
  $bb_login_error = new WP_Error( 'user_login', __( 'Username and Password do not match.' ) );
 
136
 
137
+ /** Prepare for display *******************************************************/
138
+
139
+ // Sanitze variables for display
140
+ $remember_checked = @$_POST['rememberme'] ? ' checked="checked"' : '';
141
+ $user_login = esc_attr( sanitize_user( @$_POST['log'], true ) );
142
 
143
+ // Load the template
144
  bb_load_template( 'login.php', array( 'user_exists', 'user_login', 'remember_checked', 'redirect_to', 're', 'bb_login_error' ) );
145
+
146
  exit;
147
+
148
+ ?>
bp-forums/bbpress/bb-templates/kakumei-blue/style.css CHANGED
@@ -22,6 +22,8 @@ input#tagformsub:active { border-color: #001364; }
22
  .sticky { background: #adb9e1; }
23
  #thread li.pingback { background-color: #d8dcf2; border-color: #d8dcf2; }
24
  #thread li.pingback .threadpost { background-color: #d8dcf2; }
 
 
25
  #latest tr:hover, #forumlist tr:hover, #favorites tr:hover { background: #d8dcf2; }
26
  #profile-menu li a:hover { background: #d8dcf2; }
27
  a.prev.page-numbers:hover, a.next.page-numbers:hover { color: #001364; }
22
  .sticky { background: #adb9e1; }
23
  #thread li.pingback { background-color: #d8dcf2; border-color: #d8dcf2; }
24
  #thread li.pingback .threadpost { background-color: #d8dcf2; }
25
+ #topic-move input { color: #32689b; }
26
+ #topic-move input:hover { color: #001364; }
27
  #latest tr:hover, #forumlist tr:hover, #favorites tr:hover { background: #d8dcf2; }
28
  #profile-menu li a:hover { background: #d8dcf2; }
29
  a.prev.page-numbers:hover, a.next.page-numbers:hover { color: #001364; }
bp-forums/bbpress/bb-templates/kakumei/favorites.php CHANGED
@@ -29,7 +29,7 @@
29
  <td class="num"><?php topic_posts(); ?></td>
30
  <!-- <td class="num"><?php bb_topic_voices(); ?></td> -->
31
  <td class="num"><?php topic_last_poster(); ?></td>
32
- <td class="num"><a href="<?php topic_last_post_link(); ?>"><?php topic_time(); ?></a></td>
33
  <?php if ( bb_current_user_can( 'edit_favorites_of', $user_id ) ) : ?>
34
  <td class="num">[<?php user_favorites_link('', array('mid'=>'&times;'), $user_id); ?>]</td>
35
  <?php endif; ?>
29
  <td class="num"><?php topic_posts(); ?></td>
30
  <!-- <td class="num"><?php bb_topic_voices(); ?></td> -->
31
  <td class="num"><?php topic_last_poster(); ?></td>
32
+ <td class="num"><a href="<?php topic_last_post_link(); ?>" title="<?php topic_time(array('format'=>'datetime')); ?>"><?php topic_time(); ?></a></td>
33
  <?php if ( bb_current_user_can( 'edit_favorites_of', $user_id ) ) : ?>
34
  <td class="num">[<?php user_favorites_link('', array('mid'=>'&times;'), $user_id); ?>]</td>
35
  <?php endif; ?>
bp-forums/bbpress/bb-templates/kakumei/forum.php CHANGED
@@ -19,7 +19,7 @@
19
  <td class="num"><?php topic_posts(); ?></td>
20
  <!-- <td class="num"><?php bb_topic_voices(); ?></td> -->
21
  <td class="num"><?php topic_last_poster(); ?></td>
22
- <td class="num"><a href="<?php topic_last_post_link(); ?>"><?php topic_time(); ?></a></td>
23
  </tr>
24
  <?php endforeach; endif; ?>
25
 
@@ -29,7 +29,7 @@
29
  <td class="num"><?php topic_posts(); ?></td>
30
  <!-- <td class="num"><?php bb_topic_voices(); ?></td> -->
31
  <td class="num"><?php topic_last_poster(); ?></td>
32
- <td class="num"><a href="<?php topic_last_post_link(); ?>"><?php topic_time(); ?></a></td>
33
  </tr>
34
  <?php endforeach; endif; ?>
35
  </table>
19
  <td class="num"><?php topic_posts(); ?></td>
20
  <!-- <td class="num"><?php bb_topic_voices(); ?></td> -->
21
  <td class="num"><?php topic_last_poster(); ?></td>
22
+ <td class="num"><a href="<?php topic_last_post_link(); ?>" title="<?php topic_time(array('format'=>'datetime')); ?>"><?php topic_time(); ?></a></td>
23
  </tr>
24
  <?php endforeach; endif; ?>
25
 
29
  <td class="num"><?php topic_posts(); ?></td>
30
  <!-- <td class="num"><?php bb_topic_voices(); ?></td> -->
31
  <td class="num"><?php topic_last_poster(); ?></td>
32
+ <td class="num"><a href="<?php topic_last_post_link(); ?>" title="<?php topic_time(array('format'=>'datetime')); ?>"><?php topic_time(); ?></a></td>
33
  </tr>
34
  <?php endforeach; endif; ?>
35
  </table>
bp-forums/bbpress/bb-templates/kakumei/front-page.php CHANGED
@@ -27,7 +27,7 @@
27
  <td class="num"><?php topic_posts(); ?></td>
28
  <!-- <td class="num"><?php bb_topic_voices(); ?></td> -->
29
  <td class="num"><?php topic_last_poster(); ?></td>
30
- <td class="num"><a href="<?php topic_last_post_link(); ?>"><?php topic_time(); ?></a></td>
31
  </tr>
32
  <?php endforeach; endif; // $super_stickies ?>
33
 
@@ -37,7 +37,7 @@
37
  <td class="num"><?php topic_posts(); ?></td>
38
  <!-- <td class="num"><?php bb_topic_voices(); ?></td> -->
39
  <td class="num"><?php topic_last_poster(); ?></td>
40
- <td class="num"><a href="<?php topic_last_post_link(); ?>"><?php topic_time(); ?></a></td>
41
  </tr>
42
  <?php endforeach; endif; // $topics ?>
43
  </table>
27
  <td class="num"><?php topic_posts(); ?></td>
28
  <!-- <td class="num"><?php bb_topic_voices(); ?></td> -->
29
  <td class="num"><?php topic_last_poster(); ?></td>
30
+ <td class="num"><a href="<?php topic_last_post_link(); ?>" title="<?php topic_time(array('format'=>'datetime')); ?>"><?php topic_time(); ?></a></td>
31
  </tr>
32
  <?php endforeach; endif; // $super_stickies ?>
33
 
37
  <td class="num"><?php topic_posts(); ?></td>
38
  <!-- <td class="num"><?php bb_topic_voices(); ?></td> -->
39
  <td class="num"><?php topic_last_poster(); ?></td>
40
+ <td class="num"><a href="<?php topic_last_post_link(); ?>" title="<?php topic_time(array('format'=>'datetime')); ?>"><?php topic_time(); ?></a></td>
41
  </tr>
42
  <?php endforeach; endif; // $topics ?>
43
  </table>
bp-forums/bbpress/bb-templates/kakumei/post-form.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php if ( !bb_is_topic() ) : ?>
2
  <p id="post-form-title-container">
3
  <label for="topic"><?php _e('Title'); ?>
4
- <input name="topic" type="text" id="topic" size="50" maxlength="80" tabindex="1" />
5
  </label>
6
  </p>
7
  <?php endif; do_action( 'post_form_pre_post' ); ?>
@@ -11,7 +11,7 @@
11
  </label>
12
  </p>
13
  <p id="post-form-tags-container">
14
- <label for="tags-input"><?php printf(__('Tags (comma seperated)'), bb_get_tag_page_link()) ?>
15
  <input id="tags-input" name="tags" type="text" size="50" maxlength="100" value="<?php bb_tag_name(); ?>" tabindex="4" />
16
  </label>
17
  </p>
1
  <?php if ( !bb_is_topic() ) : ?>
2
  <p id="post-form-title-container">
3
  <label for="topic"><?php _e('Title'); ?>
4
+ <input name="topic" type="text" id="topic" size="50" maxlength="100" tabindex="1" />
5
  </label>
6
  </p>
7
  <?php endif; do_action( 'post_form_pre_post' ); ?>
11
  </label>
12
  </p>
13
  <p id="post-form-tags-container">
14
+ <label for="tags-input"><?php printf(__('Tags (comma separated)'), bb_get_tag_page_link()) ?>
15
  <input id="tags-input" name="tags" type="text" size="50" maxlength="100" value="<?php bb_tag_name(); ?>" tabindex="4" />
16
  </label>
17
  </p>
bp-forums/bbpress/bb-templates/kakumei/style.css CHANGED
@@ -644,7 +644,22 @@ a.rss-link {
644
  background-position: 0 50%;
645
  }
646
 
647
- #topic-move { margin-top: 1em; }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
648
 
649
  /* Other
650
  =================================== */
644
  background-position: 0 50%;
645
  }
646
 
647
+ #topic-move,
648
+ #topic-move fieldset,
649
+ #topic-move fieldset div {
650
+ display: inline;
651
+ }
652
+
653
+ #topic-move input {
654
+ font-family: inherit;
655
+ background: none;
656
+ border: none;
657
+ cursor: pointer;
658
+ color: #2e6e15;
659
+ font-size: 1em;
660
+ }
661
+
662
+ #topic-move input:hover { color: #006400; }
663
 
664
  /* Other
665
  =================================== */
bp-forums/bbpress/bb-templates/kakumei/tag-single.php CHANGED
@@ -21,7 +21,7 @@
21
  <td class="num"><?php topic_posts(); ?></td>
22
  <!-- <td class="num"><?php bb_topic_voices(); ?></td> -->
23
  <td class="num"><?php topic_last_poster(); ?></td>
24
- <td class="num"><a href="<?php topic_last_post_link(); ?>"><?php topic_time(); ?></a></td>
25
  </tr>
26
  <?php endforeach; ?>
27
  </table>
21
  <td class="num"><?php topic_posts(); ?></td>
22
  <!-- <td class="num"><?php bb_topic_voices(); ?></td> -->
23
  <td class="num"><?php topic_last_poster(); ?></td>
24
+ <td class="num"><a href="<?php topic_last_post_link(); ?>" title="<?php topic_time(array('format'=>'datetime')); ?>"><?php topic_time(); ?></a></td>
25
  </tr>
26
  <?php endforeach; ?>
27
  </table>
bp-forums/bbpress/bb-templates/kakumei/view.php CHANGED
@@ -19,7 +19,7 @@
19
  <td class="num"><?php topic_posts(); ?></td>
20
  <!-- <td class="num"><?php bb_topic_voices(); ?></td> -->
21
  <td class="num"><?php topic_last_poster(); ?></td>
22
- <td class="num"><a href="<?php topic_last_post_link(); ?>"><?php topic_time(); ?></a></td>
23
  </tr>
24
  <?php endforeach; endif; ?>
25
 
@@ -29,7 +29,7 @@
29
  <td class="num"><?php topic_posts(); ?></td>
30
  <!-- <td class="num"><?php bb_topic_voices(); ?></td> -->
31
  <td class="num"><?php topic_last_poster(); ?></td>
32
- <td class="num"><a href="<?php topic_last_post_link(); ?>"><?php topic_time(); ?></a></td>
33
  </tr>
34
  <?php endforeach; endif; ?>
35
  </table>
19
  <td class="num"><?php topic_posts(); ?></td>
20
  <!-- <td class="num"><?php bb_topic_voices(); ?></td> -->
21
  <td class="num"><?php topic_last_poster(); ?></td>
22
+ <td class="num"><a href="<?php topic_last_post_link(); ?>" title="<?php topic_time(array('format'=>'datetime')); ?>"><?php topic_time(); ?></a></td>
23
  </tr>
24
  <?php endforeach; endif; ?>
25
 
29
  <td class="num"><?php topic_posts(); ?></td>
30
  <!-- <td class="num"><?php bb_topic_voices(); ?></td> -->
31
  <td class="num"><?php topic_last_poster(); ?></td>
32
+ <td class="num"><a href="<?php topic_last_post_link(); ?>" title="<?php topic_time(array('format'=>'datetime')); ?>"><?php topic_time(); ?></a></td>
33
  </tr>
34
  <?php endforeach; endif; ?>
35
  </table>
bp-forums/bbpress/rss.php CHANGED
@@ -108,7 +108,7 @@ if ( !$bb_db_override ) {
108
  if ( !$posts = get_user_favorites( $user->ID ) ) {
109
  die();
110
  }
111
- $title = esc_html( sprintf( __( '%1$s &raquo; User Favorites: %2$s' ), bb_get_option( 'name' ), $user->user_login ) );
112
  $link = bb_get_profile_link($feed_id);
113
  $link_self = get_favorites_rss_link($feed_id);
114
  break;
108
  if ( !$posts = get_user_favorites( $user->ID ) ) {
109
  die();
110
  }
111
+ $title = esc_html( sprintf( __( '%1$s &raquo; User Favorites: %2$s' ), bb_get_option( 'name' ), $user->user_nicename ) );
112
  $link = bb_get_profile_link($feed_id);
113
  $link_self = get_favorites_rss_link($feed_id);
114
  break;
bp-forums/bp-forums-admin.php CHANGED
@@ -11,16 +11,17 @@ function bp_forums_bbpress_admin() {
11
  <div id="message" class="updated fade">
12
  <p><?php _e( 'Settings Saved.', 'buddypress' ) ?></p>
13
  </div>
14
- <?php endif; ?>
15
-
16
- <?php
17
 
18
  if ( isset( $_REQUEST['reinstall'] ) || !bp_forums_is_installed_correctly() ) {
19
  update_site_option( 'bb-config-location', false );
20
  bp_forums_bbpress_install_wizard();
21
- } else { ?>
22
- <p><?php printf( __( 'bbPress forum integration in BuddyPress has been set up correctly. If you are having problems you can <a href="%s" title="Reinstall bbPress">re-install</a>', 'buddypress' ), site_url( 'wp-admin/admin.php?page=bb-forums-setup&reinstall=1' ) ); ?>
 
 
23
  <p><?php _e( 'NOTE: The forums directory will only work if your bbPress tables are in the same database as your WordPress tables. If you are not using an existing bbPress install you can ignore this message.', 'buddypress' ) ?></p>
 
24
  <?php
25
  }
26
  ?>
@@ -29,7 +30,7 @@ function bp_forums_bbpress_admin() {
29
  }
30
 
31
  function bp_forums_bbpress_install_wizard() {
32
- $post_url = site_url( 'wp-admin/admin.php?page=bb-forums-setup' );
33
 
34
  switch( $_REQUEST['step'] ) {
35
  case 'existing':
@@ -67,7 +68,7 @@ function bp_forums_bbpress_install_wizard() {
67
  default:
68
  // Just write the contents to screen
69
  _e( 'A configuration file could not be created. No problem, but you will need to save the text shown below into a file named <code>bb-config.php</code> in the root directory of your WordPress installation before you can start using the forum functionality.', 'buddypress' );
70
- ?><code style="display:block; margin-top: 30px;"><pre><?php echo htmlspecialchars( $result ) ?></pre></code><?php
71
  break;
72
  }
73
  } else {
11
  <div id="message" class="updated fade">
12
  <p><?php _e( 'Settings Saved.', 'buddypress' ) ?></p>
13
  </div>
14
+ <?php endif;
 
 
15
 
16
  if ( isset( $_REQUEST['reinstall'] ) || !bp_forums_is_installed_correctly() ) {
17
  update_site_option( 'bb-config-location', false );
18
  bp_forums_bbpress_install_wizard();
19
+ } else {
20
+ $reinstall = network_admin_url( 'admin.php?page=bb-forums-setup&reinstall=1' ); ?>
21
+
22
+ <p><?php printf( __( 'bbPress forum integration in BuddyPress has been set up correctly. If you are having problems you can <a href="%s" title="Reinstall bbPress">re-install</a>', 'buddypress' ), $reinstall ); ?>
23
  <p><?php _e( 'NOTE: The forums directory will only work if your bbPress tables are in the same database as your WordPress tables. If you are not using an existing bbPress install you can ignore this message.', 'buddypress' ) ?></p>
24
+
25
  <?php
26
  }
27
  ?>
30
  }
31
 
32
  function bp_forums_bbpress_install_wizard() {
33
+ $post_url = network_admin_url( 'admin.php?page=bb-forums-setup' );
34
 
35
  switch( $_REQUEST['step'] ) {
36
  case 'existing':
68
  default:
69
  // Just write the contents to screen
70
  _e( 'A configuration file could not be created. No problem, but you will need to save the text shown below into a file named <code>bb-config.php</code> in the root directory of your WordPress installation before you can start using the forum functionality.', 'buddypress' );
71
+ ?><br /><textarea cols="110" rows="50" style="margin: 10px 0 50px 0;"><?php echo htmlspecialchars( $result ) ?></textarea><?php
72
  break;
73
  }
74
  } else {
bp-forums/bp-forums-bbpress.php CHANGED
@@ -141,7 +141,7 @@ class BPDB extends WPDB {
141
  var $db_servers = array();
142
 
143
  function BPDB( $dbuser, $dbpassword, $dbname, $dbhost ) {
144
- parent::WPDB( $dbuser, $dbpassword, $dbname, $dbhost );
145
 
146
  $args = func_get_args();
147
  $args = call_user_func_array( array( &$this, '_init' ), $args );
141
  var $db_servers = array();
142
 
143
  function BPDB( $dbuser, $dbpassword, $dbname, $dbhost ) {
144
+ parent::__construct( $dbuser, $dbpassword, $dbname, $dbhost );
145
 
146
  $args = func_get_args();
147
  $args = call_user_func_array( array( &$this, '_init' ), $args );
bp-friends.php CHANGED
@@ -61,7 +61,7 @@ function friends_check_installed() {
61
  if ( get_site_option( 'bp-friends-db-version' ) < BP_FRIENDS_DB_VERSION )
62
  friends_install();
63
  }
64
- add_action( 'admin_menu', 'friends_check_installed' );
65
 
66
  function friends_setup_nav() {
67
  global $bp;
61
  if ( get_site_option( 'bp-friends-db-version' ) < BP_FRIENDS_DB_VERSION )
62
  friends_install();
63
  }
64
+ add_action( is_multisite() ? 'network_admin_menu' : 'admin_menu', 'friends_check_installed' );
65
 
66
  function friends_setup_nav() {
67
  global $bp;
bp-groups.php CHANGED
@@ -116,7 +116,7 @@ function groups_check_installed() {
116
  if ( get_site_option( 'bp-groups-db-version' ) < BP_GROUPS_DB_VERSION )
117
  groups_install();
118
  }
119
- add_action( 'admin_menu', 'groups_check_installed' );
120
 
121
  function groups_setup_nav() {
122
  global $bp;
@@ -2170,10 +2170,21 @@ function groups_update_group_forum_post( $post_id, $post_text, $topic_id, $page
2170
  function groups_delete_group_forum_topic( $topic_id ) {
2171
  global $bp;
2172
 
 
 
 
2173
  if ( bp_forums_delete_topic( array( 'topic_id' => $topic_id ) ) ) {
2174
- /* Delete the activity stream item */
2175
- if ( function_exists( 'bp_activity_delete' ) ) {
 
 
 
2176
  bp_activity_delete( array( 'item_id' => $bp->groups->current_group->id, 'secondary_item_id' => $topic_id, 'component' => $bp->groups->id, 'type' => 'new_forum_topic' ) );
 
 
 
 
 
2177
  }
2178
 
2179
  do_action( 'groups_delete_group_forum_topic', $topic_id );
116
  if ( get_site_option( 'bp-groups-db-version' ) < BP_GROUPS_DB_VERSION )
117
  groups_install();
118
  }
119
+ add_action( is_multisite() ? 'network_admin_menu' : 'admin_menu', 'groups_check_installed' );
120
 
121
  function groups_setup_nav() {
122
  global $bp;
2170
  function groups_delete_group_forum_topic( $topic_id ) {
2171
  global $bp;
2172
 
2173
+ // Before deleting the thread, get the post ids so that their activity items can be deleted
2174
+ $posts = bp_forums_get_topic_posts( array( 'topic_id' => $topic_id, 'per_page' => -1 ) );
2175
+
2176
  if ( bp_forums_delete_topic( array( 'topic_id' => $topic_id ) ) ) {
2177
+ do_action( 'groups_before_delete_group_forum_topic', $topic_id );
2178
+
2179
+ // Delete the activity stream items
2180
+ if ( bp_is_active( 'activity' ) ) {
2181
+ // The activity item for the initial topic
2182
  bp_activity_delete( array( 'item_id' => $bp->groups->current_group->id, 'secondary_item_id' => $topic_id, 'component' => $bp->groups->id, 'type' => 'new_forum_topic' ) );
2183
+
2184
+ // The activity item for each post
2185
+ foreach ( (array)$posts as $post ) {
2186
+ bp_activity_delete( array( 'item_id' => $bp->groups->current_group->id, 'secondary_item_id' => $post->post_id, 'component' => $bp->groups->id, 'type' => 'new_forum_post' ) );
2187
+ }
2188
  }
2189
 
2190
  do_action( 'groups_delete_group_forum_topic', $topic_id );
bp-languages/buddypress.pot CHANGED
@@ -4,7 +4,7 @@ msgid ""
4
  msgstr ""
5
  "Project-Id-Version: BuddyPress \n"
6
  "Report-Msgid-Bugs-To: wp-polyglots@lists.automattic.com\n"
7
- "POT-Creation-Date: 2010-12-20 22:28:00+00:00\n"
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=UTF-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
@@ -154,7 +154,7 @@ msgid "Blog avatar"
154
  msgstr ""
155
 
156
  #: bp-blogs/bp-blogs-templatetags.php:256 bp-core/bp-core-templatetags.php:355
157
- #: bp-core/bp-core-templatetags.php:1327 bp-core/bp-core-classes.php:82
158
  #: bp-groups/bp-groups-widgets.php:119
159
  #: bp-themes/bp-default/groups/groups-loop.php:31
160
  #: bp-themes/bp-default/groups/single/group-header.php:31
@@ -446,15 +446,15 @@ msgstr ""
446
  msgid "Upload Failed! Error was: %s"
447
  msgstr ""
448
 
449
- #: bp-core/bp-core-filters.php:29
450
  msgid "noreply"
451
  msgstr ""
452
 
453
- #: bp-core/bp-core-filters.php:133 bp-core/bp-core-filters.php:157
454
  msgid "[User Set]"
455
  msgstr ""
456
 
457
- #: bp-core/bp-core-filters.php:177
458
  msgid ""
459
  "Thanks for registering! To complete the activation of your account and blog, please click the following link:\n"
460
  "\n"
@@ -467,11 +467,11 @@ msgid ""
467
  "%s"
468
  msgstr ""
469
 
470
- #: bp-core/bp-core-filters.php:178
471
  msgid "Activate %s"
472
  msgstr ""
473
 
474
- #: bp-core/bp-core-filters.php:209 bp-core/bp-core-signup.php:542
475
  msgid ""
476
  "Thanks for registering! To complete the activation of your account please click the following link:\n"
477
  "\n"
@@ -479,7 +479,7 @@ msgid ""
479
  "\n"
480
  msgstr ""
481
 
482
- #: bp-core/bp-core-filters.php:210 bp-core/bp-core-signup.php:543
483
  msgid "Activate Your Account"
484
  msgstr ""
485
 
@@ -598,7 +598,7 @@ msgstr ""
598
  msgid "Options"
599
  msgstr ""
600
 
601
- #: bp-core/bp-core-templatetags.php:736 bp-core.php:379 bp-xprofile.php:183
602
  #: bp-themes/bp-default/activity/post-form.php:41
603
  msgid "My Profile"
604
  msgstr ""
@@ -667,7 +667,7 @@ msgstr ""
667
  msgid "Groups"
668
  msgstr ""
669
 
670
- #: bp-core/bp-core-templatetags.php:1032 bp-forums/bp-forums-admin.php:159
671
  #: bp-themes/bp-default/header.php:68
672
  msgid "Forums"
673
  msgstr ""
@@ -676,11 +676,11 @@ msgstr ""
676
  msgid "Blogs"
677
  msgstr ""
678
 
679
- #: bp-core/bp-core-templatetags.php:1213
680
  msgid "Your Avatar"
681
  msgstr ""
682
 
683
- #: bp-core/bp-core-templatetags.php:1286
684
  msgid "a user"
685
  msgstr ""
686
 
@@ -850,7 +850,7 @@ msgstr ""
850
  msgid "Delete Account"
851
  msgstr ""
852
 
853
- #: bp-core/bp-core-settings.php:69 bp-core.php:312
854
  msgid "General Settings"
855
  msgstr ""
856
 
@@ -911,116 +911,116 @@ msgstr ""
911
  msgid "Delete My Account"
912
  msgstr ""
913
 
914
- #: bp-core.php:305 bp-core.php:306
915
  msgid "BuddyPress"
916
  msgstr ""
917
 
918
- #: bp-core.php:313
919
  msgid "Component Setup"
920
  msgstr ""
921
 
922
- #: bp-core.php:358 bp-xprofile.php:172
923
  msgid "Profile"
924
  msgstr ""
925
 
926
- #: bp-core.php:369 bp-groups/bp-groups-templatetags.php:419 bp-xprofile.php:177
927
  msgid "Public"
928
  msgstr ""
929
 
930
- #: bp-core.php:475
931
  msgid "User marked as spammer. Spam users are visible only to site admins."
932
  msgstr ""
933
 
934
- #: bp-core.php:477
935
  msgid "User removed as spammer."
936
  msgstr ""
937
 
938
- #: bp-core.php:511
939
  msgid "%s has been deleted from the system."
940
  msgstr ""
941
 
942
- #: bp-core.php:513
943
  msgid "There was an error deleting %s from the system. Please try again."
944
  msgstr ""
945
 
946
- #: bp-core.php:1416
947
  msgid "year"
948
  msgstr ""
949
 
950
- #: bp-core.php:1416
951
  msgid "years"
952
  msgstr ""
953
 
954
- #: bp-core.php:1417
955
  msgid "month"
956
  msgstr ""
957
 
958
- #: bp-core.php:1417
959
  msgid "months"
960
  msgstr ""
961
 
962
- #: bp-core.php:1418
963
  msgid "week"
964
  msgstr ""
965
 
966
- #: bp-core.php:1418
967
  msgid "weeks"
968
  msgstr ""
969
 
970
- #: bp-core.php:1419
971
  msgid "day"
972
  msgstr ""
973
 
974
- #: bp-core.php:1419
975
  msgid "days"
976
  msgstr ""
977
 
978
- #: bp-core.php:1420
979
  msgid "hour"
980
  msgstr ""
981
 
982
- #: bp-core.php:1420
983
  msgid "hours"
984
  msgstr ""
985
 
986
- #: bp-core.php:1421
987
  msgid "minute"
988
  msgstr ""
989
 
990
- #: bp-core.php:1421
991
  msgid "minutes"
992
  msgstr ""
993
 
994
- #: bp-core.php:1422
995
  msgid "second"
996
  msgstr ""
997
 
998
- #: bp-core.php:1422 bp-core.php:1474
999
  msgid "seconds"
1000
  msgstr ""
1001
 
1002
- #: bp-core.php:1441
1003
  msgid "sometime"
1004
  msgstr ""
1005
 
1006
- #: bp-core.php:1469
1007
  msgctxt "Separator in time since"
1008
  msgid ","
1009
  msgstr ""
1010
 
1011
- #: bp-core.php:1524
1012
  msgid "not recently active"
1013
  msgstr ""
1014
 
1015
- #: bp-core.php:2034
1016
  msgid "IMPORTANT: <a href=\"http://codex.buddypress.org/getting-started/upgrading-from-10x/\">Read this before attempting to update BuddyPress</a>"
1017
  msgstr ""
1018
 
1019
- #: bp-core.php:2063
1020
  msgid "<strong>BuddyPress is almost ready</strong>. You must <a href=\"%s\">update your permalink structure</a> to something other than the default for it to work."
1021
  msgstr ""
1022
 
1023
- #: bp-core.php:2072
1024
  msgid "<strong>BuddyPress is ready</strong>. You'll need to <a href='%s'>activate a BuddyPress compatible theme</a> to take advantage of all of the features. We've bundled a default theme, but you can always <a href='%s'>install some other compatible themes</a> or <a href='%s'>upgrade your existing WordPress theme</a>."
1025
  msgstr ""
1026
 
@@ -1208,19 +1208,19 @@ msgstr ""
1208
  msgid "There was an error removing that activity as a favorite, please try again."
1209
  msgstr ""
1210
 
1211
- #: bp-activity.php:699
1212
  msgid "%s posted an update:"
1213
  msgstr ""
1214
 
1215
- #: bp-activity.php:752
1216
  msgid "%s posted a new activity comment:"
1217
  msgstr ""
1218
 
1219
- #: bp-activity.php:967
1220
  msgid "Thumbnail"
1221
  msgstr ""
1222
 
1223
- #: bp-activity.php:1195
1224
  msgid "Posted an update"
1225
  msgstr ""
1226
 
@@ -1926,63 +1926,61 @@ msgstr ""
1926
  msgid "NOTE: The forums directory will only work if your bbPress tables are in the same database as your WordPress tables. If you are not using an existing bbPress install you can ignore this message."
1927
  msgstr ""
1928
 
1929
- #: bp-forums/bp-forums-admin.php:38
1930
  msgid "The bb-config.php file was not found at that location, please try again."
1931
  msgstr ""
1932
 
1933
- #: bp-forums/bp-forums-admin.php:41
1934
  msgid "Forums were set up correctly using your existing bbPress install!"
1935
  msgstr ""
1936
 
1937
- #: bp-forums/bp-forums-admin.php:42
1938
  msgid "BuddyPress will now use its internal copy of bbPress to run the forums on your site. If you wish, you can remove your old bbPress installation files, as long as you keep the bb-config.php file in the same location."
1939
  msgstr ""
1940
 
1941
- #: bp-forums/bp-forums-admin.php:47
1942
  msgid "Existing bbPress Installation"
1943
  msgstr ""
1944
 
1945
- #: bp-forums/bp-forums-admin.php:48
1946
  msgid "BuddyPress can make use of your existing bbPress install. Just provide the location of your <code>bb-config.php</code> file, and BuddyPress will do the rest."
1947
  msgstr ""
1948
 
1949
- #: bp-forums/bp-forums-admin.php:50 bp-forums/bp-forums-admin.php:78
1950
  msgid "Complete Installation"
1951
  msgstr ""
1952
 
1953
- #: bp-forums/bp-forums-admin.php:65
1954
  msgid "All done! Configuration settings have been saved to the file <code>bb-config.php</code> in the root of your WordPress install."
1955
  msgstr ""
1956
 
1957
- #. Just write the contents to screen
1958
-
1959
- #: bp-forums/bp-forums-admin.php:69
1960
  msgid "A configuration file could not be created. No problem, but you will need to save the text shown below into a file named <code>bb-config.php</code> in the root directory of your WordPress installation before you can start using the forum functionality."
1961
  msgstr ""
1962
 
1963
- #: bp-forums/bp-forums-admin.php:75
1964
  msgid "New bbPress Installation"
1965
  msgstr ""
1966
 
1967
- #: bp-forums/bp-forums-admin.php:76
1968
  msgid ""
1969
  "You've decided to set up a new installation of bbPress for forum management in BuddyPress. This is very simple and is usually just a one click\n"
1970
  "\t\t\t\tprocess. When you're ready, hit the link below."
1971
  msgstr ""
1972
 
1973
- #: bp-forums/bp-forums-admin.php:86
1974
  msgid "bbPress files were not found. To install the forums component you must download a copy of bbPress and make sure it is in the folder: \"%s\""
1975
  msgstr ""
1976
 
1977
- #: bp-forums/bp-forums-admin.php:90
1978
  msgid "Forums in BuddyPress make use of a bbPress installation to function. You can choose to either let BuddyPress set up a new bbPress install, or use an already existing bbPress install. Please choose one of the options below."
1979
  msgstr ""
1980
 
1981
- #: bp-forums/bp-forums-admin.php:92
1982
  msgid "Set up a new bbPress installation"
1983
  msgstr ""
1984
 
1985
- #: bp-forums/bp-forums-admin.php:93
1986
  msgid "Use an existing bbPress installation"
1987
  msgstr ""
1988
 
@@ -2180,7 +2178,7 @@ msgstr ""
2180
  msgid "Group invite accepted"
2181
  msgstr ""
2182
 
2183
- #: bp-groups.php:306 bp-groups.php:1774 bp-groups.php:2479
2184
  msgid "%s joined the group %s"
2185
  msgstr ""
2186
 
4
  msgstr ""
5
  "Project-Id-Version: BuddyPress \n"
6
  "Report-Msgid-Bugs-To: wp-polyglots@lists.automattic.com\n"
7
+ "POT-Creation-Date: 2011-06-24 20:31:00+00:00\n"
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=UTF-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
154
  msgstr ""
155
 
156
  #: bp-blogs/bp-blogs-templatetags.php:256 bp-core/bp-core-templatetags.php:355
157
+ #: bp-core/bp-core-templatetags.php:1352 bp-core/bp-core-classes.php:82
158
  #: bp-groups/bp-groups-widgets.php:119
159
  #: bp-themes/bp-default/groups/groups-loop.php:31
160
  #: bp-themes/bp-default/groups/single/group-header.php:31
446
  msgid "Upload Failed! Error was: %s"
447
  msgstr ""
448
 
449
+ #: bp-core/bp-core-filters.php:63
450
  msgid "noreply"
451
  msgstr ""
452
 
453
+ #: bp-core/bp-core-filters.php:167 bp-core/bp-core-filters.php:191
454
  msgid "[User Set]"
455
  msgstr ""
456
 
457
+ #: bp-core/bp-core-filters.php:211
458
  msgid ""
459
  "Thanks for registering! To complete the activation of your account and blog, please click the following link:\n"
460
  "\n"
467
  "%s"
468
  msgstr ""
469
 
470
+ #: bp-core/bp-core-filters.php:212
471
  msgid "Activate %s"
472
  msgstr ""
473
 
474
+ #: bp-core/bp-core-filters.php:243 bp-core/bp-core-signup.php:542
475
  msgid ""
476
  "Thanks for registering! To complete the activation of your account please click the following link:\n"
477
  "\n"
479
  "\n"
480
  msgstr ""
481
 
482
+ #: bp-core/bp-core-filters.php:244 bp-core/bp-core-signup.php:543
483
  msgid "Activate Your Account"
484
  msgstr ""
485
 
598
  msgid "Options"
599
  msgstr ""
600
 
601
+ #: bp-core/bp-core-templatetags.php:736 bp-core.php:383 bp-xprofile.php:183
602
  #: bp-themes/bp-default/activity/post-form.php:41
603
  msgid "My Profile"
604
  msgstr ""
667
  msgid "Groups"
668
  msgstr ""
669
 
670
+ #: bp-core/bp-core-templatetags.php:1032 bp-forums/bp-forums-admin.php:160
671
  #: bp-themes/bp-default/header.php:68
672
  msgid "Forums"
673
  msgstr ""
676
  msgid "Blogs"
677
  msgstr ""
678
 
679
+ #: bp-core/bp-core-templatetags.php:1225
680
  msgid "Your Avatar"
681
  msgstr ""
682
 
683
+ #: bp-core/bp-core-templatetags.php:1311
684
  msgid "a user"
685
  msgstr ""
686
 
850
  msgid "Delete Account"
851
  msgstr ""
852
 
853
+ #: bp-core/bp-core-settings.php:69 bp-core.php:316
854
  msgid "General Settings"
855
  msgstr ""
856
 
911
  msgid "Delete My Account"
912
  msgstr ""
913
 
914
+ #: bp-core.php:309 bp-core.php:310
915
  msgid "BuddyPress"
916
  msgstr ""
917
 
918
+ #: bp-core.php:317
919
  msgid "Component Setup"
920
  msgstr ""
921
 
922
+ #: bp-core.php:362 bp-xprofile.php:172
923
  msgid "Profile"
924
  msgstr ""
925
 
926
+ #: bp-core.php:373 bp-groups/bp-groups-templatetags.php:419 bp-xprofile.php:177
927
  msgid "Public"
928
  msgstr ""
929
 
930
+ #: bp-core.php:479
931
  msgid "User marked as spammer. Spam users are visible only to site admins."
932
  msgstr ""
933
 
934
+ #: bp-core.php:481
935
  msgid "User removed as spammer."
936
  msgstr ""
937
 
938
+ #: bp-core.php:515
939
  msgid "%s has been deleted from the system."
940
  msgstr ""
941
 
942
+ #: bp-core.php:517
943
  msgid "There was an error deleting %s from the system. Please try again."
944
  msgstr ""
945
 
946
+ #: bp-core.php:1420
947
  msgid "year"
948
  msgstr ""
949
 
950
+ #: bp-core.php:1420
951
  msgid "years"
952
  msgstr ""
953
 
954
+ #: bp-core.php:1421
955
  msgid "month"
956
  msgstr ""
957
 
958
+ #: bp-core.php:1421
959
  msgid "months"
960
  msgstr ""
961
 
962
+ #: bp-core.php:1422
963
  msgid "week"
964
  msgstr ""
965
 
966
+ #: bp-core.php:1422
967
  msgid "weeks"
968
  msgstr ""
969
 
970
+ #: bp-core.php:1423
971
  msgid "day"
972
  msgstr ""
973
 
974
+ #: bp-core.php:1423
975
  msgid "days"
976
  msgstr ""
977
 
978
+ #: bp-core.php:1424
979
  msgid "hour"
980
  msgstr ""
981
 
982
+ #: bp-core.php:1424
983
  msgid "hours"
984
  msgstr ""
985
 
986
+ #: bp-core.php:1425
987
  msgid "minute"
988
  msgstr ""
989
 
990
+ #: bp-core.php:1425
991
  msgid "minutes"
992
  msgstr ""
993
 
994
+ #: bp-core.php:1426
995
  msgid "second"
996
  msgstr ""
997
 
998
+ #: bp-core.php:1426 bp-core.php:1478
999
  msgid "seconds"
1000
  msgstr ""
1001
 
1002
+ #: bp-core.php:1445
1003
  msgid "sometime"
1004
  msgstr ""
1005
 
1006
+ #: bp-core.php:1473
1007
  msgctxt "Separator in time since"
1008
  msgid ","
1009
  msgstr ""
1010
 
1011
+ #: bp-core.php:1528
1012
  msgid "not recently active"
1013
  msgstr ""
1014
 
1015
+ #: bp-core.php:2038
1016
  msgid "IMPORTANT: <a href=\"http://codex.buddypress.org/getting-started/upgrading-from-10x/\">Read this before attempting to update BuddyPress</a>"
1017
  msgstr ""
1018
 
1019
+ #: bp-core.php:2067
1020
  msgid "<strong>BuddyPress is almost ready</strong>. You must <a href=\"%s\">update your permalink structure</a> to something other than the default for it to work."
1021
  msgstr ""
1022
 
1023
+ #: bp-core.php:2076
1024
  msgid "<strong>BuddyPress is ready</strong>. You'll need to <a href='%s'>activate a BuddyPress compatible theme</a> to take advantage of all of the features. We've bundled a default theme, but you can always <a href='%s'>install some other compatible themes</a> or <a href='%s'>upgrade your existing WordPress theme</a>."
1025
  msgstr ""
1026
 
1208
  msgid "There was an error removing that activity as a favorite, please try again."
1209
  msgstr ""
1210
 
1211
+ #: bp-activity.php:700
1212
  msgid "%s posted an update:"
1213
  msgstr ""
1214
 
1215
+ #: bp-activity.php:753
1216
  msgid "%s posted a new activity comment:"
1217
  msgstr ""
1218
 
1219
+ #: bp-activity.php:968
1220
  msgid "Thumbnail"
1221
  msgstr ""
1222
 
1223
+ #: bp-activity.php:1196
1224
  msgid "Posted an update"
1225
  msgstr ""
1226
 
1926
  msgid "NOTE: The forums directory will only work if your bbPress tables are in the same database as your WordPress tables. If you are not using an existing bbPress install you can ignore this message."
1927
  msgstr ""
1928
 
1929
+ #: bp-forums/bp-forums-admin.php:39
1930
  msgid "The bb-config.php file was not found at that location, please try again."
1931
  msgstr ""
1932
 
1933
+ #: bp-forums/bp-forums-admin.php:42
1934
  msgid "Forums were set up correctly using your existing bbPress install!"
1935
  msgstr ""
1936
 
1937
+ #: bp-forums/bp-forums-admin.php:43
1938
  msgid "BuddyPress will now use its internal copy of bbPress to run the forums on your site. If you wish, you can remove your old bbPress installation files, as long as you keep the bb-config.php file in the same location."
1939
  msgstr ""
1940
 
1941
+ #: bp-forums/bp-forums-admin.php:48
1942
  msgid "Existing bbPress Installation"
1943
  msgstr ""
1944
 
1945
+ #: bp-forums/bp-forums-admin.php:49
1946
  msgid "BuddyPress can make use of your existing bbPress install. Just provide the location of your <code>bb-config.php</code> file, and BuddyPress will do the rest."
1947
  msgstr ""
1948
 
1949
+ #: bp-forums/bp-forums-admin.php:51 bp-forums/bp-forums-admin.php:79
1950
  msgid "Complete Installation"
1951
  msgstr ""
1952
 
1953
+ #: bp-forums/bp-forums-admin.php:66
1954
  msgid "All done! Configuration settings have been saved to the file <code>bb-config.php</code> in the root of your WordPress install."
1955
  msgstr ""
1956
 
1957
+ #: bp-forums/bp-forums-admin.php:70
 
 
1958
  msgid "A configuration file could not be created. No problem, but you will need to save the text shown below into a file named <code>bb-config.php</code> in the root directory of your WordPress installation before you can start using the forum functionality."
1959
  msgstr ""
1960
 
1961
+ #: bp-forums/bp-forums-admin.php:76
1962
  msgid "New bbPress Installation"
1963
  msgstr ""
1964
 
1965
+ #: bp-forums/bp-forums-admin.php:77
1966
  msgid ""
1967
  "You've decided to set up a new installation of bbPress for forum management in BuddyPress. This is very simple and is usually just a one click\n"
1968
  "\t\t\t\tprocess. When you're ready, hit the link below."
1969
  msgstr ""
1970
 
1971
+ #: bp-forums/bp-forums-admin.php:87
1972
  msgid "bbPress files were not found. To install the forums component you must download a copy of bbPress and make sure it is in the folder: \"%s\""
1973
  msgstr ""
1974
 
1975
+ #: bp-forums/bp-forums-admin.php:91
1976
  msgid "Forums in BuddyPress make use of a bbPress installation to function. You can choose to either let BuddyPress set up a new bbPress install, or use an already existing bbPress install. Please choose one of the options below."
1977
  msgstr ""
1978
 
1979
+ #: bp-forums/bp-forums-admin.php:93
1980
  msgid "Set up a new bbPress installation"
1981
  msgstr ""
1982
 
1983
+ #: bp-forums/bp-forums-admin.php:94
1984
  msgid "Use an existing bbPress installation"
1985
  msgstr ""
1986
 
2178
  msgid "Group invite accepted"
2179
  msgstr ""
2180
 
2181
+ #: bp-groups.php:306 bp-groups.php:1774 bp-groups.php:2490
2182
  msgid "%s joined the group %s"
2183
  msgstr ""
2184
 
bp-loader.php CHANGED
@@ -4,13 +4,12 @@ Plugin Name: BuddyPress
4
  Plugin URI: http://buddypress.org
5
  Description: Social networking in a box. Build a social network for your company, school, sports team or niche community all based on the power and flexibility of WordPress.
6
  Author: The BuddyPress Community
7
- Version: 1.2.7
8
  Author URI: http://buddypress.org/community/members/
9
- Site Wide Only: true
10
  Network: true
11
  */
12
 
13
- define( 'BP_VERSION', '1.2.7' );
14
 
15
  /***
16
  * This file will load in each BuddyPress component based on which
4
  Plugin URI: http://buddypress.org
5
  Description: Social networking in a box. Build a social network for your company, school, sports team or niche community all based on the power and flexibility of WordPress.
6
  Author: The BuddyPress Community
7
+ Version: 1.2.9
8
  Author URI: http://buddypress.org/community/members/
 
9
  Network: true
10
  */
11
 
12
+ define( 'BP_VERSION', '1.2.9' );
13
 
14
  /***
15
  * This file will load in each BuddyPress component based on which
bp-messages.php CHANGED
@@ -96,7 +96,7 @@ function messages_check_installed() {
96
  if ( get_site_option( 'bp-messages-db-version' ) < BP_MESSAGES_DB_VERSION )
97
  messages_install();
98
  }
99
- add_action( 'admin_menu', 'messages_check_installed' );
100
 
101
  function messages_setup_nav() {
102
  global $bp;
96
  if ( get_site_option( 'bp-messages-db-version' ) < BP_MESSAGES_DB_VERSION )
97
  messages_install();
98
  }
99
+ add_action( is_multisite() ? 'network_admin_menu' : 'admin_menu', 'messages_check_installed' );
100
 
101
  function messages_setup_nav() {
102
  global $bp;
bp-messages/js/autocomplete/jquery.bgiframe.min.js CHANGED
@@ -1,10 +1,6 @@
1
- /* Copyright (c) 2006 Brandon Aaron (http://brandonaaron.net)
2
- * Dual licensed under the MIT (http://www.opensource.org/licenses/mit-license.php)
3
- * and GPL (http://www.opensource.org/licenses/gpl-license.php) licenses.
4
  *
5
- * $LastChangedDate: 2007-07-22 01:45:56 +0200 (Son, 22 Jul 2007) $
6
- * $Rev: 2447 $
7
- *
8
- * Version 2.1.1
9
  */
10
- (function($){$.fn.bgIframe=$.fn.bgiframe=function(s){if($.browser.msie&&/6.0/.test(navigator.userAgent)){s=$.extend({top:'auto',left:'auto',width:'auto',height:'auto',opacity:true,src:'javascript:false;'},s||{});var prop=function(n){return n&&n.constructor==Number?n+'px':n;},html='<iframe class="bgiframe"frameborder="0"tabindex="-1"src="'+s.src+'"'+'style="display:block;position:absolute;z-index:-1;'+(s.opacity!==false?'filter:Alpha(Opacity=\'0\');':'')+'top:'+(s.top=='auto'?'expression(((parseInt(this.parentNode.currentStyle.borderTopWidth)||0)*-1)+\'px\')':prop(s.top))+';'+'left:'+(s.left=='auto'?'expression(((parseInt(this.parentNode.currentStyle.borderLeftWidth)||0)*-1)+\'px\')':prop(s.left))+';'+'width:'+(s.width=='auto'?'expression(this.parentNode.offsetWidth+\'px\')':prop(s.width))+';'+'height:'+(s.height=='auto'?'expression(this.parentNode.offsetHeight+\'px\')':prop(s.height))+';'+'"/>';return this.each(function(){if($('> iframe.bgiframe',this).length==0)this.insertBefore(document.createElement(html),this.firstChild);});}return this;};})(jQuery);
1
+ /* Copyright (c) 2010 Brandon Aaron (http://brandonaaron.net)
2
+ * Licensed under the MIT License (license.bgiframe.txt).
 
3
  *
4
+ * Version 2.1.2
 
 
 
5
  */
6
+ (function(a){a.fn.bgiframe=(a.browser.msie&&/msie 6\.0/i.test(navigator.userAgent)?function(d){d=a.extend({top:"auto",left:"auto",width:"auto",height:"auto",opacity:true,src:"javascript:false;"},d);var c='<iframe class="bgiframe"frameborder="0"tabindex="-1"src="'+d.src+'"style="display:block;position:absolute;z-index:-1;'+(d.opacity!==false?"filter:Alpha(Opacity='0');":"")+"top:"+(d.top=="auto"?"expression(((parseInt(this.parentNode.currentStyle.borderTopWidth)||0)*-1)+'px')":b(d.top))+";left:"+(d.left=="auto"?"expression(((parseInt(this.parentNode.currentStyle.borderLeftWidth)||0)*-1)+'px')":b(d.left))+";width:"+(d.width=="auto"?"expression(this.parentNode.offsetWidth+'px')":b(d.width))+";height:"+(d.height=="auto"?"expression(this.parentNode.offsetHeight+'px')":b(d.height))+';"/>';return this.each(function(){if(a(this).children("iframe.bgiframe").length===0){this.insertBefore(document.createElement(c),this.firstChild)}})}:function(){return this});a.fn.bgIframe=a.fn.bgiframe;function b(c){return c&&c.constructor===Number?c+"px":c}})(jQuery);
bp-messages/js/autocomplete/license.bgiframe.txt ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ Copyright 2010, Brandon Aaron (http://brandonaaron.net/)
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining
4
+ a copy of this software and associated documentation files (the
5
+ "Software"), to deal in the Software without restriction, including
6
+ without limitation the rights to use, copy, modify, merge, publish,
7
+ distribute, sublicense, and/or sell copies of the Software, and to
8
+ permit persons to whom the Software is furnished to do so, subject to
9
+ the following conditions:
10
+
11
+ The above copyright notice and this permission notice shall be
12
+ included in all copies or substantial portions of the Software.
13
+
14
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
15
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
bp-themes/bp-default/_inc/global.js CHANGED
@@ -21,7 +21,7 @@ jq(document).ready( function() {
21
  /* @mention Compose Scrolling */
22
  if ( jq.query.get('r') ) {
23
  if ( jq('textarea#whats-new').length ) {
24
- jq.scrollTo( jq('textarea#whats-new'), 500, { offset:-125, easing:'easeout' } );
25
  jq('textarea#whats-new').focus();
26
  }
27
  }
@@ -39,14 +39,14 @@ jq(document).ready( function() {
39
 
40
  form.children().each( function() {
41
  if ( jq.nodeName(this, "textarea") || jq.nodeName(this, "input") )
42
- jq(this).attr( 'disabled', 'disabled' );
43
  });
44
 
45
  jq( 'form#' + form.attr('id') + ' span.ajax-loader' ).show();
46
 
47
  /* Remove any errors */
48
  jq('div.error').remove();
49
- button.attr('disabled','disabled');
50
 
51
  /* Default POST values */
52
  var object = '';
@@ -72,14 +72,14 @@ jq(document).ready( function() {
72
 
73
  form.children().each( function() {
74
  if ( jq.nodeName(this, "textarea") || jq.nodeName(this, "input") )
75
- jq(this).attr( 'disabled', '' );
76
  });
77
 
78
  /* Check for errors and append if found. */
79
  if ( response[0] + response[1] == '-1' ) {
80
  form.prepend( response.substr( 2, response.length ) );
81
  jq( 'form#' + form.attr('id') + ' div.error').hide().fadeIn( 200 );
82
- button.attr("disabled", '');
83
  } else {
84
  if ( 0 == jq("ul.activity-list").length ) {
85
  jq("div.error").slideUp(100).remove();
@@ -94,7 +94,7 @@ jq(document).ready( function() {
94
  jq("textarea#whats-new").val('');
95
 
96
  /* Re-enable the submit button after 8 seconds. */
97
- setTimeout( function() { button.attr("disabled", ''); }, 8000 );
98
  }
99
  });
100
 
@@ -300,7 +300,7 @@ jq(document).ready( function() {
300
  form.addClass('root');
301
 
302
  form.slideDown( 200 );
303
- jq.scrollTo( form, 500, { offset:-100, easing:'easeout' } );
304
  jq('#ac-form-' + ids[2] + ' textarea').focus();
305
 
306
  return false;
@@ -339,7 +339,7 @@ jq(document).ready( function() {
339
  /* Check for errors and append if found. */
340
  if ( response[0] + response[1] == '-1' ) {
341
  form.append( response.substr( 2, response.length ) ).hide().fadeIn( 200 );
342
- target.attr("disabled", '');
343
  } else {
344
  form.fadeOut( 200,
345
  function() {
@@ -361,7 +361,7 @@ jq(document).ready( function() {
361
  jq('li#activity-' + form_id[2] + ' a.acomment-reply span').html( Number( jq('li#activity-' + form_id[2] + ' a.acomment-reply span').html() ) + 1 );
362
 
363
  /* Re-enable the submit button after 5 seconds. */
364
- setTimeout( function() { target.attr("disabled", ''); }, 5000 );
365
  }
366
  });
367
 
@@ -612,7 +612,7 @@ jq(document).ready( function() {
612
 
613
  var friend_id = jq(this).val();
614
 
615
- if ( jq(this).attr('checked') == true )
616
  var friend_action = 'invite';
617
  else
618
  var friend_action = 'uninvite';
@@ -664,7 +664,7 @@ jq(document).ready( function() {
664
  {
665
  jq('.ajax-loader').toggle();
666
  jq('#friend-list li#uid-' + friend_id).remove();
667
- jq('#invite-list input#f-' + friend_id).attr('checked', false);
668
  });
669
 
670
  return false;
@@ -824,7 +824,7 @@ jq(document).ready( function() {
824
  }).mouseout( function() {
825
  jq(this).removeClass('over');
826
  });
827
-
828
  jq('body#bp-default table.zebra tbody tr:odd').addClass('alt');
829
 
830
  jq('div.message-box').each( function(i) {
@@ -1054,7 +1054,7 @@ function bp_init_activity() {
1054
  jq.cookie( 'bp-activity-oldestpage', 1, {path: '/'} );
1055
 
1056
  if ( null != jq.cookie('bp-activity-filter') && jq('#activity-filter-select').length )
1057
- jq('#activity-filter-select select option[value=' + jq.cookie('bp-activity-filter') + ']').attr( 'selected', 'selected' );
1058
 
1059
  /* Activity Tab Set */
1060
  if ( null != jq.cookie('bp-activity-scope') && jq('div.activity-type-tabs').length ) {
@@ -1069,7 +1069,7 @@ function bp_init_activity() {
1069
  function bp_init_objects(objects) {
1070
  jq(objects).each( function(i) {
1071
  if ( null != jq.cookie('bp-' + objects[i] + '-filter') && jq('li#' + objects[i] + '-order-select select').length )
1072
- jq('li#' + objects[i] + '-order-select select option[value=' + jq.cookie('bp-' + objects[i] + '-filter') + ']').attr( 'selected', 'selected' );
1073
 
1074
  if ( null != jq.cookie('bp-' + objects[i] + '-scope') && jq('div.' + objects[i]).length ) {
1075
  jq('div.item-list-tabs li').each( function() {
@@ -1102,7 +1102,7 @@ function bp_filter_request( object, filter, scope, target, search_terms, page, e
1102
  });
1103
  jq('div.item-list-tabs li#' + object + '-' + scope + ', div.item-list-tabs#object-nav li.current').addClass('selected');
1104
  jq('div.item-list-tabs li.selected').addClass('loading');
1105
- jq('div.item-list-tabs select option[value=' + filter + ']').attr( 'selected', 'selected' );
1106
 
1107
  if ( 'friends' == object )
1108
  object = 'members';
@@ -1144,7 +1144,7 @@ function bp_activity_request(scope, filter) {
1144
  /* Set the correct selected nav and filter */
1145
  jq('li#activity-' + scope + ', div.item-list-tabs li.current').addClass('selected');
1146
  jq('div#object-nav.item-list-tabs li.selected, div.activity-type-tabs li.selected').addClass('loading');
1147
- jq('#activity-filter-select select option[value=' + filter + ']').attr( 'selected', 'selected' );
1148
 
1149
  /* Reload the activity stream based on the selection */
1150
  jq('.widget_bp_activity_widget h2 span.ajax-loader').show();
@@ -1250,10 +1250,12 @@ function clear(container) {
1250
 
1251
  /* ScrollTo plugin - just inline and minified */
1252
  ;(function(d){var k=d.scrollTo=function(a,i,e){d(window).scrollTo(a,i,e)};k.defaults={axis:'xy',duration:parseFloat(d.fn.jquery)>=1.3?0:1};k.window=function(a){return d(window)._scrollable()};d.fn._scrollable=function(){return this.map(function(){var a=this,i=!a.nodeName||d.inArray(a.nodeName.toLowerCase(),['iframe','#document','html','body'])!=-1;if(!i)return a;var e=(a.contentWindow||a).document||a.ownerDocument||a;return d.browser.safari||e.compatMode=='BackCompat'?e.body:e.documentElement})};d.fn.scrollTo=function(n,j,b){if(typeof j=='object'){b=j;j=0}if(typeof b=='function')b={onAfter:b};if(n=='max')n=9e9;b=d.extend({},k.defaults,b);j=j||b.speed||b.duration;b.queue=b.queue&&b.axis.length>1;if(b.queue)j/=2;b.offset=p(b.offset);b.over=p(b.over);return this._scrollable().each(function(){var q=this,r=d(q),f=n,s,g={},u=r.is('html,body');switch(typeof f){case'number':case'string':if(/^([+-]=)?\d+(\.\d+)?(px|%)?$/.test(f)){f=p(f);break}f=d(f,this);case'object':if(f.is||f.style)s=(f=d(f)).offset()}d.each(b.axis.split(''),function(a,i){var e=i=='x'?'Left':'Top',h=e.toLowerCase(),c='scroll'+e,l=q[c],m=k.max(q,i);if(s){g[c]=s[h]+(u?0:l-r.offset()[h]);if(b.margin){g[c]-=parseInt(f.css('margin'+e))||0;g[c]-=parseInt(f.css('border'+e+'Width'))||0}g[c]+=b.offset[h]||0;if(b.over[h])g[c]+=f[i=='x'?'width':'height']()*b.over[h]}else{var o=f[h];g[c]=o.slice&&o.slice(-1)=='%'?parseFloat(o)/100*m:o}if(/^\d+$/.test(g[c]))g[c]=g[c]<=0?0:Math.min(g[c],m);if(!a&&b.queue){if(l!=g[c])t(b.onAfterFirst);delete g[c]}});t(b.onAfter);function t(a){r.animate(g,j,b.easing,a&&function(){a.call(this,n,b)})}}).end()};k.max=function(a,i){var e=i=='x'?'Width':'Height',h='scroll'+e;if(!d(a).is('html,body'))return a[h]-d(a)[e.toLowerCase()]();var c='client'+e,l=a.ownerDocument.documentElement,m=a.ownerDocument.body;return Math.max(l[h],m[h])-Math.min(l[c],m[c])};function p(a){return typeof a=='object'?a:{top:a,left:a}}})(jQuery);
1253
- jQuery.extend({easing:{easein:function(x,t,b,c,d){return c*(t/=d)*t+b},easeinout:function(x,t,b,c,d){if(t<d/2)return 2*c*t*t/(d*d)+b;var ts=t-d/2;return-2*c*ts*ts/(d*d)+2*c*ts/d+c/2+b},easeout:function(x,t,b,c,d){return-c*t*t/(d*d)+2*c*t/d+b},expoin:function(x,t,b,c,d){var flip=1;if(c<0){flip*=-1;c*=-1}return flip*(Math.exp(Math.log(c)/d*t))+b},expoout:function(x,t,b,c,d){var flip=1;if(c<0){flip*=-1;c*=-1}return flip*(-Math.exp(-Math.log(c)/d*(t-d))+c+1)+b},expoinout:function(x,t,b,c,d){var flip=1;if(c<0){flip*=-1;c*=-1}if(t<d/2)return flip*(Math.exp(Math.log(c/2)/(d/2)*t))+b;return flip*(-Math.exp(-2*Math.log(c/2)/d*(t-d))+c+1)+b},bouncein:function(x,t,b,c,d){return c-jQuery.easing['bounceout'](x,d-t,0,c,d)+b},bounceout:function(x,t,b,c,d){if((t/=d)<(1/2.75)){return c*(7.5625*t*t)+b}else if(t<(2/2.75)){return c*(7.5625*(t-=(1.5/2.75))*t+.75)+b}else if(t<(2.5/2.75)){return c*(7.5625*(t-=(2.25/2.75))*t+.9375)+b}else{return c*(7.5625*(t-=(2.625/2.75))*t+.984375)+b}},bounceinout:function(x,t,b,c,d){if(t<d/2)return jQuery.easing['bouncein'](x,t*2,0,c,d)*.5+b;return jQuery.easing['bounceout'](x,t*2-d,0,c,d)*.5+c*.5+b},elasin:function(x,t,b,c,d){var s=1.70158;var p=0;var a=c;if(t==0)return b;if((t/=d)==1)return b+c;if(!p)p=d*.3;if(a<Math.abs(c)){a=c;var s=p/4}else var s=p/(2*Math.PI)*Math.asin(c/a);return-(a*Math.pow(2,10*(t-=1))*Math.sin((t*d-s)*(2*Math.PI)/p))+b},elasout:function(x,t,b,c,d){var s=1.70158;var p=0;var a=c;if(t==0)return b;if((t/=d)==1)return b+c;if(!p)p=d*.3;if(a<Math.abs(c)){a=c;var s=p/4}else var s=p/(2*Math.PI)*Math.asin(c/a);return a*Math.pow(2,-10*t)*Math.sin((t*d-s)*(2*Math.PI)/p)+c+b},elasinout:function(x,t,b,c,d){var s=1.70158;var p=0;var a=c;if(t==0)return b;if((t/=d/2)==2)return b+c;if(!p)p=d*(.3*1.5);if(a<Math.abs(c)){a=c;var s=p/4}else var s=p/(2*Math.PI)*Math.asin(c/a);if(t<1)return-.5*(a*Math.pow(2,10*(t-=1))*Math.sin((t*d-s)*(2*Math.PI)/p))+b;return a*Math.pow(2,-10*(t-=1))*Math.sin((t*d-s)*(2*Math.PI)/p)*.5+c+b},backin:function(x,t,b,c,d){var s=1.70158;return c*(t/=d)*t*((s+1)*t-s)+b},backout:function(x,t,b,c,d){var s=1.70158;return c*((t=t/d-1)*t*((s+1)*t+s)+1)+b},backinout:function(x,t,b,c,d){var s=1.70158;if((t/=d/2)<1)return c/2*(t*t*(((s*=(1.525))+1)*t-s))+b;return c/2*((t-=2)*t*(((s*=(1.525))+1)*t+s)+2)+b},linear:function(x,t,b,c,d){return c*t/d+b}}});
 
 
1254
 
1255
  /* jQuery Cookie plugin */
1256
  jQuery.cookie=function(name,value,options){if(typeof value!='undefined'){options=options||{};if(value===null){value='';options.expires=-1;}var expires='';if(options.expires&&(typeof options.expires=='number'||options.expires.toUTCString)){var date;if(typeof options.expires=='number'){date=new Date();date.setTime(date.getTime()+(options.expires*24*60*60*1000));}else{date=options.expires;}expires='; expires='+date.toUTCString();}var path=options.path?'; path='+(options.path):'';var domain=options.domain?'; domain='+(options.domain):'';var secure=options.secure?'; secure':'';document.cookie=[name,'=',encodeURIComponent(value),expires,path,domain,secure].join('');}else{var cookieValue=null;if(document.cookie&&document.cookie!=''){var cookies=document.cookie.split(';');for(var i=0;i<cookies.length;i++){var cookie=jQuery.trim(cookies[i]);if(cookie.substring(0,name.length+1)==(name+'=')){cookieValue=decodeURIComponent(cookie.substring(name.length+1));break;}}}return cookieValue;}};
1257
 
1258
  /* jQuery querystring plugin */
1259
- eval(function(p,a,c,k,e,d){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--){d[e(c)]=k[c]||e(c)}k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1};while(c--){if(k[c]){p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c])}}return p}('M 6(A){4 $11=A.11||\'&\';4 $V=A.V===r?r:j;4 $1p=A.1p===r?\'\':\'[]\';4 $13=A.13===r?r:j;4 $D=$13?A.D===j?"#":"?":"";4 $15=A.15===r?r:j;v.1o=M 6(){4 f=6(o,t){8 o!=1v&&o!==x&&(!!t?o.1t==t:j)};4 14=6(1m){4 m,1l=/\\[([^[]*)\\]/g,T=/^([^[]+)(\\[.*\\])?$/.1r(1m),k=T[1],e=[];19(m=1l.1r(T[2]))e.u(m[1]);8[k,e]};4 w=6(3,e,7){4 o,y=e.1b();b(I 3!=\'X\')3=x;b(y===""){b(!3)3=[];b(f(3,L)){3.u(e.h==0?7:w(x,e.z(0),7))}n b(f(3,1a)){4 i=0;19(3[i++]!=x);3[--i]=e.h==0?7:w(3[i],e.z(0),7)}n{3=[];3.u(e.h==0?7:w(x,e.z(0),7))}}n b(y&&y.T(/^\\s*[0-9]+\\s*$/)){4 H=1c(y,10);b(!3)3=[];3[H]=e.h==0?7:w(3[H],e.z(0),7)}n b(y){4 H=y.B(/^\\s*|\\s*$/g,"");b(!3)3={};b(f(3,L)){4 18={};1w(4 i=0;i<3.h;++i){18[i]=3[i]}3=18}3[H]=e.h==0?7:w(3[H],e.z(0),7)}n{8 7}8 3};4 C=6(a){4 p=d;p.l={};b(a.C){v.J(a.Z(),6(5,c){p.O(5,c)})}n{v.J(1u,6(){4 q=""+d;q=q.B(/^[?#]/,\'\');q=q.B(/[;&]$/,\'\');b($V)q=q.B(/[+]/g,\' \');v.J(q.Y(/[&;]/),6(){4 5=1e(d.Y(\'=\')[0]||"");4 c=1e(d.Y(\'=\')[1]||"");b(!5)8;b($15){b(/^[+-]?[0-9]+\\.[0-9]*$/.1d(c))c=1A(c);n b(/^[+-]?[0-9]+$/.1d(c))c=1c(c,10)}c=(!c&&c!==0)?j:c;b(c!==r&&c!==j&&I c!=\'1g\')c=c;p.O(5,c)})})}8 p};C.1H={C:j,1G:6(5,1f){4 7=d.Z(5);8 f(7,1f)},1h:6(5){b(!f(5))8 d.l;4 K=14(5),k=K[0],e=K[1];4 3=d.l[k];19(3!=x&&e.h!=0){3=3[e.1b()]}8 I 3==\'1g\'?3:3||""},Z:6(5){4 3=d.1h(5);b(f(3,1a))8 v.1E(j,{},3);n b(f(3,L))8 3.z(0);8 3},O:6(5,c){4 7=!f(c)?x:c;4 K=14(5),k=K[0],e=K[1];4 3=d.l[k];d.l[k]=w(3,e.z(0),7);8 d},w:6(5,c){8 d.N().O(5,c)},1s:6(5){8 d.O(5,x).17()},1z:6(5){8 d.N().1s(5)},1j:6(){4 p=d;v.J(p.l,6(5,7){1y p.l[5]});8 p},1F:6(Q){4 D=Q.B(/^.*?[#](.+?)(?:\\?.+)?$/,"$1");4 S=Q.B(/^.*?[?](.+?)(?:#.+)?$/,"$1");8 M C(Q.h==S.h?\'\':S,Q.h==D.h?\'\':D)},1x:6(){8 d.N().1j()},N:6(){8 M C(d)},17:6(){6 F(G){4 R=I G=="X"?f(G,L)?[]:{}:G;b(I G==\'X\'){6 1k(o,5,7){b(f(o,L))o.u(7);n o[5]=7}v.J(G,6(5,7){b(!f(7))8 j;1k(R,5,F(7))})}8 R}d.l=F(d.l);8 d},1B:6(){8 d.N().17()},1D:6(){4 i=0,U=[],W=[],p=d;4 16=6(E){E=E+"";b($V)E=E.B(/ /g,"+");8 1C(E)};4 1n=6(1i,5,7){b(!f(7)||7===r)8;4 o=[16(5)];b(7!==j){o.u("=");o.u(16(7))}1i.u(o.P(""))};4 F=6(R,k){4 12=6(5){8!k||k==""?[5].P(""):[k,"[",5,"]"].P("")};v.J(R,6(5,7){b(I 7==\'X\')F(7,12(5));n 1n(W,12(5),7)})};F(d.l);b(W.h>0)U.u($D);U.u(W.P($11));8 U.P("")}};8 M C(1q.S,1q.D)}}(v.1o||{});',62,106,'|||target|var|key|function|value|return|||if|val|this|tokens|is||length||true|base|keys||else||self||false|||push|jQuery|set|null|token|slice|settings|replace|queryObject|hash|str|build|orig|index|typeof|each|parsed|Array|new|copy|SET|join|url|obj|search|match|queryString|spaces|chunks|object|split|get||separator|newKey|prefix|parse|numbers|encode|COMPACT|temp|while|Object|shift|parseInt|test|decodeURIComponent|type|number|GET|arr|EMPTY|add|rx|path|addFields|query|suffix|location|exec|REMOVE|constructor|arguments|undefined|for|empty|delete|remove|parseFloat|compact|encodeURIComponent|toString|extend|load|has|prototype'.split('|'),0,{}))
21
  /* @mention Compose Scrolling */
22
  if ( jq.query.get('r') ) {
23
  if ( jq('textarea#whats-new').length ) {
24
+ jq.scrollTo( jq('textarea#whats-new'), 500, { offset:-125, easing:'easeOutQuad' } );
25
  jq('textarea#whats-new').focus();
26
  }
27
  }
39
 
40
  form.children().each( function() {
41
  if ( jq.nodeName(this, "textarea") || jq.nodeName(this, "input") )
42
+ jq(this).prop( 'disabled', true );
43
  });
44
 
45
  jq( 'form#' + form.attr('id') + ' span.ajax-loader' ).show();
46
 
47
  /* Remove any errors */
48
  jq('div.error').remove();
49
+ button.prop('disabled', true);
50
 
51
  /* Default POST values */
52
  var object = '';
72
 
73
  form.children().each( function() {
74
  if ( jq.nodeName(this, "textarea") || jq.nodeName(this, "input") )
75
+ jq(this).prop( 'disabled', false );
76
  });
77
 
78
  /* Check for errors and append if found. */
79
  if ( response[0] + response[1] == '-1' ) {
80
  form.prepend( response.substr( 2, response.length ) );
81
  jq( 'form#' + form.attr('id') + ' div.error').hide().fadeIn( 200 );
82
+ button.prop("disabled", false);
83
  } else {
84
  if ( 0 == jq("ul.activity-list").length ) {
85
  jq("div.error").slideUp(100).remove();
94
  jq("textarea#whats-new").val('');
95
 
96
  /* Re-enable the submit button after 8 seconds. */
97
+ setTimeout( function() { button.prop("disabled", false); }, 8000 );
98
  }
99
  });
100
 
300
  form.addClass('root');
301
 
302
  form.slideDown( 200 );
303
+ jq.scrollTo( form, 500, { offset:-100, easing:'easeOutQuad' } );
304
  jq('#ac-form-' + ids[2] + ' textarea').focus();
305
 
306
  return false;
339
  /* Check for errors and append if found. */
340
  if ( response[0] + response[1] == '-1' ) {
341
  form.append( response.substr( 2, response.length ) ).hide().fadeIn( 200 );
342
+ target.prop("disabled", false);
343
  } else {
344
  form.fadeOut( 200,
345
  function() {
361
  jq('li#activity-' + form_id[2] + ' a.acomment-reply span').html( Number( jq('li#activity-' + form_id[2] + ' a.acomment-reply span').html() ) + 1 );
362
 
363
  /* Re-enable the submit button after 5 seconds. */
364
+ setTimeout( function() { target.prop("disabled", false); }, 5000 );
365
  }
366
  });
367
 
612
 
613
  var friend_id = jq(this).val();
614
 
615
+ if ( jq(this).prop('checked') == true )
616
  var friend_action = 'invite';
617
  else
618
  var friend_action = 'uninvite';
664
  {
665
  jq('.ajax-loader').toggle();
666
  jq('#friend-list li#uid-' + friend_id).remove();
667
+ jq('#invite-list input#f-' + friend_id).prop('checked', false);
668
  });
669
 
670
  return false;
824
  }).mouseout( function() {
825
  jq(this).removeClass('over');
826
  });
827
+
828
  jq('body#bp-default table.zebra tbody tr:odd').addClass('alt');
829
 
830
  jq('div.message-box').each( function(i) {
1054
  jq.cookie( 'bp-activity-oldestpage', 1, {path: '/'} );
1055
 
1056
  if ( null != jq.cookie('bp-activity-filter') && jq('#activity-filter-select').length )
1057
+ jq('#activity-filter-select select option[value="' + jq.cookie('bp-activity-filter') + '"]').prop( 'selected', true );
1058
 
1059
  /* Activity Tab Set */
1060
  if ( null != jq.cookie('bp-activity-scope') && jq('div.activity-type-tabs').length ) {
1069
  function bp_init_objects(objects) {
1070
  jq(objects).each( function(i) {
1071
  if ( null != jq.cookie('bp-' + objects[i] + '-filter') && jq('li#' + objects[i] + '-order-select select').length )
1072
+ jq('li#' + objects[i] + '-order-select select option[value="' + jq.cookie('bp-' + objects[i] + '-filter') + '"]').prop( 'selected', true );
1073
 
1074
  if ( null != jq.cookie('bp-' + objects[i] + '-scope') && jq('div.' + objects[i]).length ) {
1075
  jq('div.item-list-tabs li').each( function() {
1102
  });
1103
  jq('div.item-list-tabs li#' + object + '-' + scope + ', div.item-list-tabs#object-nav li.current').addClass('selected');
1104
  jq('div.item-list-tabs li.selected').addClass('loading');
1105
+ jq('div.item-list-tabs select option[value="' + filter + '"]').prop( 'selected', true );
1106
 
1107
  if ( 'friends' == object )
1108
  object = 'members';
1144
  /* Set the correct selected nav and filter */
1145
  jq('li#activity-' + scope + ', div.item-list-tabs li.current').addClass('selected');
1146
  jq('div#object-nav.item-list-tabs li.selected, div.activity-type-tabs li.selected').addClass('loading');
1147
+ jq('#activity-filter-select select option[value="' + filter + '"]').prop( 'selected', true );
1148
 
1149
  /* Reload the activity stream based on the selection */
1150
  jq('.widget_bp_activity_widget h2 span.ajax-loader').show();
1250
 
1251
  /* ScrollTo plugin - just inline and minified */
1252
  ;(function(d){var k=d.scrollTo=function(a,i,e){d(window).scrollTo(a,i,e)};k.defaults={axis:'xy',duration:parseFloat(d.fn.jquery)>=1.3?0:1};k.window=function(a){return d(window)._scrollable()};d.fn._scrollable=function(){return this.map(function(){var a=this,i=!a.nodeName||d.inArray(a.nodeName.toLowerCase(),['iframe','#document','html','body'])!=-1;if(!i)return a;var e=(a.contentWindow||a).document||a.ownerDocument||a;return d.browser.safari||e.compatMode=='BackCompat'?e.body:e.documentElement})};d.fn.scrollTo=function(n,j,b){if(typeof j=='object'){b=j;j=0}if(typeof b=='function')b={onAfter:b};if(n=='max')n=9e9;b=d.extend({},k.defaults,b);j=j||b.speed||b.duration;b.queue=b.queue&&b.axis.length>1;if(b.queue)j/=2;b.offset=p(b.offset);b.over=p(b.over);return this._scrollable().each(function(){var q=this,r=d(q),f=n,s,g={},u=r.is('html,body');switch(typeof f){case'number':case'string':if(/^([+-]=)?\d+(\.\d+)?(px|%)?$/.test(f)){f=p(f);break}f=d(f,this);case'object':if(f.is||f.style)s=(f=d(f)).offset()}d.each(b.axis.split(''),function(a,i){var e=i=='x'?'Left':'Top',h=e.toLowerCase(),c='scroll'+e,l=q[c],m=k.max(q,i);if(s){g[c]=s[h]+(u?0:l-r.offset()[h]);if(b.margin){g[c]-=parseInt(f.css('margin'+e))||0;g[c]-=parseInt(f.css('border'+e+'Width'))||0}g[c]+=b.offset[h]||0;if(b.over[h])g[c]+=f[i=='x'?'width':'height']()*b.over[h]}else{var o=f[h];g[c]=o.slice&&o.slice(-1)=='%'?parseFloat(o)/100*m:o}if(/^\d+$/.test(g[c]))g[c]=g[c]<=0?0:Math.min(g[c],m);if(!a&&b.queue){if(l!=g[c])t(b.onAfterFirst);delete g[c]}});t(b.onAfter);function t(a){r.animate(g,j,b.easing,a&&function(){a.call(this,n,b)})}}).end()};k.max=function(a,i){var e=i=='x'?'Width':'Height',h='scroll'+e;if(!d(a).is('html,body'))return a[h]-d(a)[e.toLowerCase()]();var c='client'+e,l=a.ownerDocument.documentElement,m=a.ownerDocument.body;return Math.max(l[h],m[h])-Math.min(l[c],m[c])};function p(a){return typeof a=='object'?a:{top:a,left:a}}})(jQuery);
1253
+
1254
+ /* jQuery Easing Plugin, v1.3 - http://gsgd.co.uk/sandbox/jquery/easing/ */
1255
+ 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}});
1256
 
1257
  /* jQuery Cookie plugin */
1258
  jQuery.cookie=function(name,value,options){if(typeof value!='undefined'){options=options||{};if(value===null){value='';options.expires=-1;}var expires='';if(options.expires&&(typeof options.expires=='number'||options.expires.toUTCString)){var date;if(typeof options.expires=='number'){date=new Date();date.setTime(date.getTime()+(options.expires*24*60*60*1000));}else{date=options.expires;}expires='; expires='+date.toUTCString();}var path=options.path?'; path='+(options.path):'';var domain=options.domain?'; domain='+(options.domain):'';var secure=options.secure?'; secure':'';document.cookie=[name,'=',encodeURIComponent(value),expires,path,domain,secure].join('');}else{var cookieValue=null;if(document.cookie&&document.cookie!=''){var cookies=document.cookie.split(';');for(var i=0;i<cookies.length;i++){var cookie=jQuery.trim(cookies[i]);if(cookie.substring(0,name.length+1)==(name+'=')){cookieValue=decodeURIComponent(cookie.substring(name.length+1));break;}}}return cookieValue;}};
1259
 
1260
  /* jQuery querystring plugin */
1261
+ eval(function(p,a,c,k,e,d){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--){d[e(c)]=k[c]||e(c)}k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1};while(c--){if(k[c]){p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c])}}return p}('M 6(A){4 $11=A.11||\'&\';4 $V=A.V===r?r:j;4 $1p=A.1p===r?\'\':\'[]\';4 $13=A.13===r?r:j;4 $D=$13?A.D===j?"#":"?":"";4 $15=A.15===r?r:j;v.1o=M 6(){4 f=6(o,t){8 o!=1v&&o!==x&&(!!t?o.1t==t:j)};4 14=6(1m){4 m,1l=/\\[([^[]*)\\]/g,T=/^([^[]+)(\\[.*\\])?$/.1r(1m),k=T[1],e=[];19(m=1l.1r(T[2]))e.u(m[1]);8[k,e]};4 w=6(3,e,7){4 o,y=e.1b();b(I 3!=\'X\')3=x;b(y===""){b(!3)3=[];b(f(3,L)){3.u(e.h==0?7:w(x,e.z(0),7))}n b(f(3,1a)){4 i=0;19(3[i++]!=x);3[--i]=e.h==0?7:w(3[i],e.z(0),7)}n{3=[];3.u(e.h==0?7:w(x,e.z(0),7))}}n b(y&&y.T(/^\\s*[0-9]+\\s*$/)){4 H=1c(y,10);b(!3)3=[];3[H]=e.h==0?7:w(3[H],e.z(0),7)}n b(y){4 H=y.B(/^\\s*|\\s*$/g,"");b(!3)3={};b(f(3,L)){4 18={};1w(4 i=0;i<3.h;++i){18[i]=3[i]}3=18}3[H]=e.h==0?7:w(3[H],e.z(0),7)}n{8 7}8 3};4 C=6(a){4 p=d;p.l={};b(a.C){v.J(a.Z(),6(5,c){p.O(5,c)})}n{v.J(1u,6(){4 q=""+d;q=q.B(/^[?#]/,\'\');q=q.B(/[;&]$/,\'\');b($V)q=q.B(/[+]/g,\' \');v.J(q.Y(/[&;]/),6(){4 5=1e(d.Y(\'=\')[0]||"");4 c=1e(d.Y(\'=\')[1]||"");b(!5)8;b($15){b(/^[+-]?[0-9]+\\.[0-9]*$/.1d(c))c=1A(c);n b(/^[+-]?[0-9]+$/.1d(c))c=1c(c,10)}c=(!c&&c!==0)?j:c;b(c!==r&&c!==j&&I c!=\'1g\')c=c;p.O(5,c)})})}8 p};C.1H={C:j,1G:6(5,1f){4 7=d.Z(5);8 f(7,1f)},1h:6(5){b(!f(5))8 d.l;4 K=14(5),k=K[0],e=K[1];4 3=d.l[k];19(3!=x&&e.h!=0){3=3[e.1b()]}8 I 3==\'1g\'?3:3||""},Z:6(5){4 3=d.1h(5);b(f(3,1a))8 v.1E(j,{},3);n b(f(3,L))8 3.z(0);8 3},O:6(5,c){4 7=!f(c)?x:c;4 K=14(5),k=K[0],e=K[1];4 3=d.l[k];d.l[k]=w(3,e.z(0),7);8 d},w:6(5,c){8 d.N().O(5,c)},1s:6(5){8 d.O(5,x).17()},1z:6(5){8 d.N().1s(5)},1j:6(){4 p=d;v.J(p.l,6(5,7){1y p.l[5]});8 p},1F:6(Q){4 D=Q.B(/^.*?[#](.+?)(?:\\?.+)?$/,"$1");4 S=Q.B(/^.*?[?](.+?)(?:#.+)?$/,"$1");8 M C(Q.h==S.h?\'\':S,Q.h==D.h?\'\':D)},1x:6(){8 d.N().1j()},N:6(){8 M C(d)},17:6(){6 F(G){4 R=I G=="X"?f(G,L)?[]:{}:G;b(I G==\'X\'){6 1k(o,5,7){b(f(o,L))o.u(7);n o[5]=7}v.J(G,6(5,7){b(!f(7))8 j;1k(R,5,F(7))})}8 R}d.l=F(d.l);8 d},1B:6(){8 d.N().17()},1D:6(){4 i=0,U=[],W=[],p=d;4 16=6(E){E=E+"";b($V)E=E.B(/ /g,"+");8 1C(E)};4 1n=6(1i,5,7){b(!f(7)||7===r)8;4 o=[16(5)];b(7!==j){o.u("=");o.u(16(7))}1i.u(o.P(""))};4 F=6(R,k){4 12=6(5){8!k||k==""?[5].P(""):[k,"[",5,"]"].P("")};v.J(R,6(5,7){b(I 7==\'X\')F(7,12(5));n 1n(W,12(5),7)})};F(d.l);b(W.h>0)U.u($D);U.u(W.P($11));8 U.P("")}};8 M C(1q.S,1q.D)}}(v.1o||{});',62,106,'|||target|var|key|function|value|return|||if|val|this|tokens|is||length||true|base|keys||else||self||false|||push|jQuery|set|null|token|slice|settings|replace|queryObject|hash|str|build|orig|index|typeof|each|parsed|Array|new|copy|SET|join|url|obj|search|match|queryString|spaces|chunks|object|split|get||separator|newKey|prefix|parse|numbers|encode|COMPACT|temp|while|Object|shift|parseInt|test|decodeURIComponent|type|number|GET|arr|EMPTY|add|rx|path|addFields|query|suffix|location|exec|REMOVE|constructor|arguments|undefined|for|empty|delete|remove|parseFloat|compact|encodeURIComponent|toString|extend|load|has|prototype'.split('|'),0,{}))
bp-themes/bp-default/style.css CHANGED
@@ -2,7 +2,7 @@
2
  Theme Name: BuddyPress Default
3
  Theme URI: http://buddypress.org/extend/themes/
4
  Description: The default theme for BuddyPress.
5
- Version: 1.2.7
6
  Author: BuddyPress.org
7
  Author URI: http://buddypress.org
8
  Tags: buddypress, two-columns, custom-header, white, blue
2
  Theme Name: BuddyPress Default
3
  Theme URI: http://buddypress.org/extend/themes/
4
  Description: The default theme for BuddyPress.
5
+ Version: 1.2.9
6
  Author: BuddyPress.org
7
  Author URI: http://buddypress.org
8
  Tags: buddypress, two-columns, custom-header, white, blue
bp-xprofile.php CHANGED
@@ -151,7 +151,7 @@ function xprofile_add_admin_menu() {
151
  if ( get_site_option( 'bp-xprofile-db-version' ) < BP_XPROFILE_DB_VERSION )
152
  xprofile_install();
153
  }
154
- add_action( 'admin_menu', 'xprofile_add_admin_menu' );
155
 
156
  /**
157
  * xprofile_setup_nav()
151
  if ( get_site_option( 'bp-xprofile-db-version' ) < BP_XPROFILE_DB_VERSION )
152
  xprofile_install();
153
  }
154
+ add_action( is_multisite() ? 'network_admin_menu' : 'admin_menu', 'xprofile_add_admin_menu' );
155
 
156
  /**
157
  * xprofile_setup_nav()
bp-xprofile/bp-xprofile-cssjs.php CHANGED
@@ -1,16 +1,25 @@
1
  <?php
2
 
3
  function xprofile_add_admin_css() {
4
- wp_enqueue_style( 'xprofile-admin-css', BP_PLUGIN_URL . '/bp-xprofile/admin/css/admin.css' );
 
 
 
 
 
5
  }
6
- add_action( 'admin_menu', 'xprofile_add_admin_css' );
7
 
8
  function xprofile_add_admin_js() {
9
- if ( strpos( $_GET['page'], 'bp-profile-setup' ) !== false ) {
 
 
 
 
10
  wp_enqueue_script( array( "jquery-ui-sortable" ) );
11
  wp_enqueue_script( 'xprofile-admin-js', BP_PLUGIN_URL . '/bp-xprofile/admin/js/admin.js', array( 'jquery' ) );
12
  }
13
  }
14
- add_action( 'admin_menu', 'xprofile_add_admin_js', 1 );
15
 
16
  ?>
1
  <?php
2
 
3
  function xprofile_add_admin_css() {
4
+ // If this is WP 3.1+ and multisite is enabled, only load on the Network Admin
5
+ if ( is_multisite() && function_exists( 'is_network_admin' ) && ! is_network_admin() )
6
+ return false;
7
+
8
+ if ( !empty( $_GET['page'] ) && strpos( $_GET['page'], 'bp-profile-setup' ) !== false )
9
+ wp_enqueue_style( 'xprofile-admin-css', BP_PLUGIN_URL . '/bp-xprofile/admin/css/admin.css' );
10
  }
11
+ add_action( is_multisite() ? 'network_admin_menu' : 'admin_menu', 'xprofile_add_admin_css' );
12
 
13
  function xprofile_add_admin_js() {
14
+ // If this is WP 3.1+ and multisite is enabled, only load on the Network Admin
15
+ if ( is_multisite() && function_exists( 'is_network_admin' ) && ! is_network_admin() )
16
+ return false;
17
+
18
+ if ( !empty( $_GET['page'] ) && strpos( $_GET['page'], 'bp-profile-setup' ) !== false ) {
19
  wp_enqueue_script( array( "jquery-ui-sortable" ) );
20
  wp_enqueue_script( 'xprofile-admin-js', BP_PLUGIN_URL . '/bp-xprofile/admin/js/admin.js', array( 'jquery' ) );
21
  }
22
  }
23
+ add_action( is_multisite() ? 'network_admin_menu' : 'admin_menu', 'xprofile_add_admin_js', 1 );
24
 
25
  ?>
bp-xprofile/bp-xprofile-filters.php CHANGED
@@ -14,6 +14,9 @@ add_filter( 'bp_get_the_profile_field_value', 'wpautop' );
14
  add_filter( 'bp_get_the_profile_field_value', 'make_clickable' );
15
  add_filter( 'bp_get_the_profile_field_value', 'force_balance_tags' );
16
 
 
 
 
17
  add_filter( 'bp_get_the_profile_field_value', 'stripslashes' );
18
  add_filter( 'bp_get_the_profile_field_edit_value', 'stripslashes' );
19
  add_filter( 'bp_get_the_profile_field_name', 'stripslashes' );
14
  add_filter( 'bp_get_the_profile_field_value', 'make_clickable' );
15
  add_filter( 'bp_get_the_profile_field_value', 'force_balance_tags' );
16
 
17
+ add_filter( 'bp_get_the_profile_field_edit_value', 'force_balance_tags' );
18
+ add_filter( 'bp_get_the_profile_field_edit_value', 'esc_html' );
19
+
20
  add_filter( 'bp_get_the_profile_field_value', 'stripslashes' );
21
  add_filter( 'bp_get_the_profile_field_edit_value', 'stripslashes' );
22
  add_filter( 'bp_get_the_profile_field_name', 'stripslashes' );
bp-xprofile/bp-xprofile-templatetags.php CHANGED
@@ -315,9 +315,9 @@ function bp_the_profile_field_edit_value() {
315
  $field->data->value = $_POST['field_' . $field->id];
316
  }
317
 
318
- $field->data->value = bp_unserialize_profile_field( $field->data->value );
319
 
320
- return apply_filters( 'bp_get_the_profile_field_edit_value', esc_html( $field->data->value ) );
321
  }
322
 
323
  function bp_the_profile_field_type() {
@@ -521,7 +521,7 @@ function bp_the_profile_field_options( $args = '' ) {
521
  break;
522
  }
523
 
524
- apply_filters( 'bp_get_the_profile_field_datebox', $html, $day, $month, $year, $default_select );
525
 
526
  break;
527
  }
315
  $field->data->value = $_POST['field_' . $field->id];
316
  }
317
 
318
+ $field_value = isset( $field->data->value ) ? bp_unserialize_profile_field( $field->data->value ) : '';
319
 
320
+ return apply_filters( 'bp_get_the_profile_field_edit_value', $field_value, $field->type, $field->id );
321
  }
322
 
323
  function bp_the_profile_field_type() {
521
  break;
522
  }
523
 
524
+ $html = apply_filters( 'bp_get_the_profile_field_datebox', $html, $day, $month, $year, $default_select );
525
 
526
  break;
527
  }
license.txt CHANGED
@@ -1,280 +1,281 @@
1
- GNU GENERAL PUBLIC LICENSE
2
- Version 2, June 1991
3
-
4
- Copyright (C) 1989, 1991 Free Software Foundation, Inc.
5
- 675 Mass Ave, Cambridge, MA 02139, USA
6
- Everyone is permitted to copy and distribute verbatim copies
7
- of this license document, but changing it is not allowed.
8
-
9
- Preamble
10
-
11
- The licenses for most software are designed to take away your
12
- freedom to share and change it. By contrast, the GNU General Public
13
- License is intended to guarantee your freedom to share and change free
14
- software--to make sure the software is free for all its users. This
15
- General Public License applies to most of the Free Software
16
- Foundation's software and to any other program whose authors commit to
17
- using it. (Some other Free Software Foundation software is covered by
18
- the GNU Library General Public License instead.) You can apply it to
19
- your programs, too.
20
-
21
- When we speak of free software, we are referring to freedom, not
22
- price. Our General Public Licenses are designed to make sure that you
23
- have the freedom to distribute copies of free software (and charge for
24
- this service if you wish), that you receive source code or can get it
25
- if you want it, that you can change the software or use pieces of it
26
- in new free programs; and that you know you can do these things.
27
-
28
- To protect your rights, we need to make restrictions that forbid
29
- anyone to deny you these rights or to ask you to surrender the rights.
30
- These restrictions translate to certain responsibilities for you if you
31
- distribute copies of the software, or if you modify it.
32
-
33
- For example, if you distribute copies of such a program, whether
34
- gratis or for a fee, you must give the recipients all the rights that
35
- you have. You must make sure that they, too, receive or can get the
36
- source code. And you must show them these terms so they know their
37
- rights.
38
-
39
- We protect your rights with two steps: (1) copyright the software, and
40
- (2) offer you this license which gives you legal permission to copy,
41
- distribute and/or modify the software.
42
-
43
- Also, for each author's protection and ours, we want to make certain
44
- that everyone understands that there is no warranty for this free
45
- software. If the software is modified by someone else and passed on, we
46
- want its recipients to know that what they have is not the original, so
47
- that any problems introduced by others will not reflect on the original
48
- authors' reputations.
49
-
50
- Finally, any free program is threatened constantly by software
51
- patents. We wish to avoid the danger that redistributors of a free
52
- program will individually obtain patent licenses, in effect making the
53
- program proprietary. To prevent this, we have made it clear that any
54
- patent must be licensed for everyone's free use or not licensed at all.
55
-
56
- The precise terms and conditions for copying, distribution and
57
- modification follow.
58
-
59
- GNU GENERAL PUBLIC LICENSE
60
- TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
61
-
62
- 0. This License applies to any program or other work which contains
63
- a notice placed by the copyright holder saying it may be distributed
64
- under the terms of this General Public License. The "Program", below,
65
- refers to any such program or work, and a "work based on the Program"
66
- means either the Program or any derivative work under copyright law:
67
- that is to say, a work containing the Program or a portion of it,
68
- either verbatim or with modifications and/or translated into another
69
- language. (Hereinafter, translation is included without limitation in
70
- the term "modification".) Each licensee is addressed as "you".
71
-
72
- Activities other than copying, distribution and modification are not
73
- covered by this License; they are outside its scope. The act of
74
- running the Program is not restricted, and the output from the Program
75
- is covered only if its contents constitute a work based on the
76
- Program (independent of having been made by running the Program).
77
- Whether that is true depends on what the Program does.
78
-
79
- 1. You may copy and distribute verbatim copies of the Program's
80
- source code as you receive it, in any medium, provided that you
81
- conspicuously and appropriately publish on each copy an appropriate
82
- copyright notice and disclaimer of warranty; keep intact all the
83
- notices that refer to this License and to the absence of any warranty;
84
- and give any other recipients of the Program a copy of this License
85
- along with the Program.
86
-
87
- You may charge a fee for the physical act of transferring a copy, and
88
- you may at your option offer warranty protection in exchange for a fee.
89
-
90
- 2. You may modify your copy or copies of the Program or any portion
91
- of it, thus forming a work based on the Program, and copy and
92
- distribute such modifications or work under the terms of Section 1
93
- above, provided that you also meet all of these conditions:
94
-
95
- a) You must cause the modified files to carry prominent notices
96
- stating that you changed the files and the date of any change.
97
-
98
- b) You must cause any work that you distribute or publish, that in
99
- whole or in part contains or is derived from the Program or any
100
- part thereof, to be licensed as a whole at no charge to all third
101
- parties under the terms of this License.
102
-
103
- c) If the modified program normally reads commands interactively
104
- when run, you must cause it, when started running for such
105
- interactive use in the most ordinary way, to print or display an
106
- announcement including an appropriate copyright notice and a
107
- notice that there is no warranty (or else, saying that you provide
108
- a warranty) and that users may redistribute the program under
109
- these conditions, and telling the user how to view a copy of this
110
- License. (Exception: if the Program itself is interactive but
111
- does not normally print such an announcement, your work based on
112
- the Program is not required to print an announcement.)
113
-
114
- These requirements apply to the modified work as a whole. If
115
- identifiable sections of that work are not derived from the Program,
116
- and can be reasonably considered independent and separate works in
117
- themselves, then this License, and its terms, do not apply to those
118
- sections when you distribute them as separate works. But when you
119
- distribute the same sections as part of a whole which is a work based
120
- on the Program, the distribution of the whole must be on the terms of
121
- this License, whose permissions for other licensees extend to the
122
- entire whole, and thus to each and every part regardless of who wrote it.
123
- Thus, it is not the intent of this section to claim rights or contest
124
- your rights to work written entirely by you; rather, the intent is to
125
- exercise the right to control the distribution of derivative or
126
- collective works based on the Program.
127
-
128
- In addition, mere aggregation of another work not based on the Program
129
- with the Program (or with a work based on the Program) on a volume of
130
- a storage or distribution medium does not bring the other work under
131
- the scope of this License.
132
-
133
- 3. You may copy and distribute the Program (or a work based on it,
134
- under Section 2) in object code or executable form under the terms of
135
- Sections 1 and 2 above provided that you also do one of the following:
136
-
137
- a) Accompany it with the complete corresponding machine-readable
138
- source code, which must be distributed under the terms of Sections
139
- 1 and 2 above on a medium customarily used for software interchange; or,
140
-
141
- b) Accompany it with a written offer, valid for at least three
142
- years, to give any third party, for a charge no more than your
143
- cost of physically performing source distribution, a complete
144
- machine-readable copy of the corresponding source code, to be
145
- distributed under the terms of Sections 1 and 2 above on a medium
146
- customarily used for software interchange; or,
147
-
148
- c) Accompany it with the information you received as to the offer
149
- to distribute corresponding source code. (This alternative is
150
- allowed only for noncommercial distribution and only if you
151
- received the program in object code or executable form with such
152
- an offer, in accord with Subsection b above.)
153
-
154
- The source code for a work means the preferred form of the work for
155
- making modifications to it. For an executable work, complete source
156
- code means all the source code for all modules it contains, plus any
157
- associated interface definition files, plus the scripts used to
158
- control compilation and installation of the executable. However, as a
159
- special exception, the source code distributed need not include
160
- anything that is normally distributed (in either source or binary
161
- form) with the major components (compiler, kernel, and so on) of the
162
- operating system on which the executable runs, unless that component
163
- itself accompanies the executable.
164
-
165
- If distribution of executable or object code is made by offering
166
- access to copy from a designated place, then offering equivalent
167
- access to copy the source code from the same place counts as
168
- distribution of the source code, even though third parties are not
169
- compelled to copy the source along with the object code.
170
-
171
- 4. You may not copy, modify, sublicense, or distribute the Program
172
- except as expressly provided under this License. Any attempt
173
- otherwise to copy, modify, sublicense or distribute the Program is
174
- void, and will automatically terminate your rights under this License.
175
- However, parties who have received copies, or rights, from you under
176
- this License will not have their licenses terminated so long as such
177
- parties remain in full compliance.
178
-
179
- 5. You are not required to accept this License, since you have not
180
- signed it. However, nothing else grants you permission to modify or
181
- distribute the Program or its derivative works. These actions are
182
- prohibited by law if you do not accept this License. Therefore, by
183
- modifying or distributing the Program (or any work based on the
184
- Program), you indicate your acceptance of this License to do so, and
185
- all its terms and conditions for copying, distributing or modifying
186
- the Program or works based on it.
187
-
188
- 6. Each time you redistribute the Program (or any work based on the
189
- Program), the recipient automatically receives a license from the
190
- original licensor to copy, distribute or modify the Program subject to
191
- these terms and conditions. You may not impose any further
192
- restrictions on the recipients' exercise of the rights granted herein.
193
- You are not responsible for enforcing compliance by third parties to
194
- this License.
195
-
196
- 7. If, as a consequence of a court judgment or allegation of patent
197
- infringement or for any other reason (not limited to patent issues),
198
- conditions are imposed on you (whether by court order, agreement or
199
- otherwise) that contradict the conditions of this License, they do not
200
- excuse you from the conditions of this License. If you cannot
201
- distribute so as to satisfy simultaneously your obligations under this
202
- License and any other pertinent obligations, then as a consequence you
203
- may not distribute the Program at all. For example, if a patent
204
- license would not permit royalty-free redistribution of the Program by
205
- all those who receive copies directly or indirectly through you, then
206
- the only way you could satisfy both it and this License would be to
207
- refrain entirely from distribution of the Program.
208
-
209
- If any portion of this section is held invalid or unenforceable under
210
- any particular circumstance, the balance of the section is intended to
211
- apply and the section as a whole is intended to apply in other
212
- circumstances.
213
-
214
- It is not the purpose of this section to induce you to infringe any
215
- patents or other property right claims or to contest validity of any
216
- such claims; this section has the sole purpose of protecting the
217
- integrity of the free software distribution system, which is
218
- implemented by public license practices. Many people have made
219
- generous contributions to the wide range of software distributed
220
- through that system in reliance on consistent application of that
221
- system; it is up to the author/donor to decide if he or she is willing
222
- to distribute software through any other system and a licensee cannot
223
- impose that choice.
224
-
225
- This section is intended to make thoroughly clear what is believed to
226
- be a consequence of the rest of this License.
227
-
228
- 8. If the distribution and/or use of the Program is restricted in
229
- certain countries either by patents or by copyrighted interfaces, the
230
- original copyright holder who places the Program under this License
231
- may add an explicit geographical distribution limitation excluding
232
- those countries, so that distribution is permitted only in or among
233
- countries not thus excluded. In such case, this License incorporates
234
- the limitation as if written in the body of this License.
235
-
236
- 9. The Free Software Foundation may publish revised and/or new versions
237
- of the General Public License from time to time. Such new versions will
238
- be similar in spirit to the present version, but may differ in detail to
239
- address new problems or concerns.
240
-
241
- Each version is given a distinguishing version number. If the Program
242
- specifies a version number of this License which applies to it and "any
243
- later version", you have the option of following the terms and conditions
244
- either of that version or of any later version published by the Free
245
- Software Foundation. If the Program does not specify a version number of
246
- this License, you may choose any version ever published by the Free Software
247
- Foundation.
248
-
249
- 10. If you wish to incorporate parts of the Program into other free
250
- programs whose distribution conditions are different, write to the author
251
- to ask for permission. For software which is copyrighted by the Free
252
- Software Foundation, write to the Free Software Foundation; we sometimes
253
- make exceptions for this. Our decision will be guided by the two goals
254
- of preserving the free status of all derivatives of our free software and
255
- of promoting the sharing and reuse of software generally.
256
-
257
- NO WARRANTY
258
-
259
- 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
260
- FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
261
- OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
262
- PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
263
- OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
264
- MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
265
- TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
266
- PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
267
- REPAIR OR CORRECTION.
268
-
269
- 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
270
- WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
271
- REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
272
- INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
273
- OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
274
- TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
275
- YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
276
- PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
277
- POSSIBILITY OF SUCH DAMAGES.
278
-
279
- END OF TERMS AND CONDITIONS
280
-
 
1
+ GNU GENERAL PUBLIC LICENSE
2
+ Version 2, June 1991
3
+
4
+ Copyright (C) 1989, 1991 Free Software Foundation, Inc.
5
+ 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
6
+
7
+ Everyone is permitted to copy and distribute verbatim copies
8
+ of this license document, but changing it is not allowed.
9
+
10
+ Preamble
11
+
12
+ The licenses for most software are designed to take away your
13
+ freedom to share and change it. By contrast, the GNU General Public
14
+ License is intended to guarantee your freedom to share and change free
15
+ software--to make sure the software is free for all its users. This
16
+ General Public License applies to most of the Free Software
17
+ Foundation's software and to any other program whose authors commit to
18
+ using it. (Some other Free Software Foundation software is covered by
19
+ the GNU Library General Public License instead.) You can apply it to
20
+ your programs, too.
21
+
22
+ When we speak of free software, we are referring to freedom, not
23
+ price. Our General Public Licenses are designed to make sure that you
24
+ have the freedom to distribute copies of free software (and charge for
25
+ this service if you wish), that you receive source code or can get it
26
+ if you want it, that you can change the software or use pieces of it
27
+ in new free programs; and that you know you can do these things.
28
+
29
+ To protect your rights, we need to make restrictions that forbid
30
+ anyone to deny you these rights or to ask you to surrender the rights.
31
+ These restrictions translate to certain responsibilities for you if you
32
+ distribute copies of the software, or if you modify it.
33
+
34
+ For example, if you distribute copies of such a program, whether
35
+ gratis or for a fee, you must give the recipients all the rights that
36
+ you have. You must make sure that they, too, receive or can get the
37
+ source code. And you must show them these terms so they know their
38
+ rights.
39
+
40
+ We protect your rights with two steps: (1) copyright the software, and
41
+ (2) offer you this license which gives you legal permission to copy,
42
+ distribute and/or modify the software.
43
+
44
+ Also, for each author's protection and ours, we want to make certain
45
+ that everyone understands that there is no warranty for this free
46
+ software. If the software is modified by someone else and passed on, we
47
+ want its recipients to know that what they have is not the original, so
48
+ that any problems introduced by others will not reflect on the original
49
+ authors' reputations.
50
+
51
+ Finally, any free program is threatened constantly by software
52
+ patents. We wish to avoid the danger that redistributors of a free
53
+ program will individually obtain patent licenses, in effect making the
54
+ program proprietary. To prevent this, we have made it clear that any
55
+ patent must be licensed for everyone's free use or not licensed at all.
56
+
57
+ The precise terms and conditions for copying, distribution and
58
+ modification follow.
59
+
60
+ GNU GENERAL PUBLIC LICENSE
61
+ TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
62
+
63
+ 0. This License applies to any program or other work which contains
64
+ a notice placed by the copyright holder saying it may be distributed
65
+ under the terms of this General Public License. The "Program", below,
66
+ refers to any such program or work, and a "work based on the Program"
67
+ means either the Program or any derivative work under copyright law:
68
+ that is to say, a work containing the Program or a portion of it,
69
+ either verbatim or with modifications and/or translated into another
70
+ language. (Hereinafter, translation is included without limitation in
71
+ the term "modification".) Each licensee is addressed as "you".
72
+
73
+ Activities other than copying, distribution and modification are not
74
+ covered by this License; they are outside its scope. The act of
75
+ running the Program is not restricted, and the output from the Program
76
+ is covered only if its contents constitute a work based on the
77
+ Program (independent of having been made by running the Program).
78
+ Whether that is true depends on what the Program does.
79
+
80
+ 1. You may copy and distribute verbatim copies of the Program's
81
+ source code as you receive it, in any medium, provided that you
82
+ conspicuously and appropriately publish on each copy an appropriate
83
+ copyright notice and disclaimer of warranty; keep intact all the
84
+ notices that refer to this License and to the absence of any warranty;
85
+ and give any other recipients of the Program a copy of this License
86
+ along with the Program.
87
+
88
+ You may charge a fee for the physical act of transferring a copy, and
89
+ you may at your option offer warranty protection in exchange for a fee.
90
+
91
+ 2. You may modify your copy or copies of the Program or any portion
92
+ of it, thus forming a work based on the Program, and copy and
93
+ distribute such modifications or work under the terms of Section 1
94
+ above, provided that you also meet all of these conditions:
95
+
96
+ a) You must cause the modified files to carry prominent notices
97
+ stating that you changed the files and the date of any change.
98
+
99
+ b) You must cause any work that you distribute or publish, that in
100
+ whole or in part contains or is derived from the Program or any
101
+ part thereof, to be licensed as a whole at no charge to all third
102
+ parties under the terms of this License.
103
+
104
+ c) If the modified program normally reads commands interactively
105
+ when run, you must cause it, when started running for such
106
+ interactive use in the most ordinary way, to print or display an
107
+ announcement including an appropriate copyright notice and a
108
+ notice that there is no warranty (or else, saying that you provide
109
+ a warranty) and that users may redistribute the program under
110
+ these conditions, and telling the user how to view a copy of this
111
+ License. (Exception: if the Program itself is interactive but
112
+ does not normally print such an announcement, your work based on
113
+ the Program is not required to print an announcement.)
114
+
115
+ These requirements apply to the modified work as a whole. If
116
+ identifiable sections of that work are not derived from the Program,
117
+ and can be reasonably considered independent and separate works in
118
+ themselves, then this License, and its terms, do not apply to those
119
+ sections when you distribute them as separate works. But when you
120
+ distribute the same sections as part of a whole which is a work based
121
+ on the Program, the distribution of the whole must be on the terms of
122
+ this License, whose permissions for other licensees extend to the
123
+ entire whole, and thus to each and every part regardless of who wrote it.
124
+ Thus, it is not the intent of this section to claim rights or contest
125
+ your rights to work written entirely by you; rather, the intent is to
126
+ exercise the right to control the distribution of derivative or
127
+ collective works based on the Program.
128
+
129
+ In addition, mere aggregation of another work not based on the Program
130
+ with the Program (or with a work based on the Program) on a volume of
131
+ a storage or distribution medium does not bring the other work under
132
+ the scope of this License.
133
+
134
+ 3. You may copy and distribute the Program (or a work based on it,
135
+ under Section 2) in object code or executable form under the terms of
136
+ Sections 1 and 2 above provided that you also do one of the following:
137
+
138
+ a) Accompany it with the complete corresponding machine-readable
139
+ source code, which must be distributed under the terms of Sections
140
+ 1 and 2 above on a medium customarily used for software interchange; or,
141
+
142
+ b) Accompany it with a written offer, valid for at least three
143
+ years, to give any third party, for a charge no more than your
144
+ cost of physically performing source distribution, a complete
145
+ machine-readable copy of the corresponding source code, to be
146
+ distributed under the terms of Sections 1 and 2 above on a medium
147
+ customarily used for software interchange; or,
148
+
149
+ c) Accompany it with the information you received as to the offer
150
+ to distribute corresponding source code. (This alternative is
151
+ allowed only for noncommercial distribution and only if you
152
+ received the program in object code or executable form with such
153
+ an offer, in accord with Subsection b above.)
154
+
155
+ The source code for a work means the preferred form of the work for
156
+ making modifications to it. For an executable work, complete source
157
+ code means all the source code for all modules it contains, plus any
158
+ associated interface definition files, plus the scripts used to
159
+ control compilation and installation of the executable. However, as a
160
+ special exception, the source code distributed need not include
161
+ anything that is normally distributed (in either source or binary
162
+ form) with the major components (compiler, kernel, and so on) of the
163
+ operating system on which the executable runs, unless that component
164
+ itself accompanies the executable.
165
+
166
+ If distribution of executable or object code is made by offering
167
+ access to copy from a designated place, then offering equivalent
168
+ access to copy the source code from the same place counts as
169
+ distribution of the source code, even though third parties are not
170
+ compelled to copy the source along with the object code.
171
+
172
+ 4. You may not copy, modify, sublicense, or distribute the Program
173
+ except as expressly provided under this License. Any attempt
174
+ otherwise to copy, modify, sublicense or distribute the Program is
175
+ void, and will automatically terminate your rights under this License.
176
+ However, parties who have received copies, or rights, from you under
177
+ this License will not have their licenses terminated so long as such
178
+ parties remain in full compliance.
179
+
180
+ 5. You are not required to accept this License, since you have not
181
+ signed it. However, nothing else grants you permission to modify or
182
+ distribute the Program or its derivative works. These actions are
183
+ prohibited by law if you do not accept this License. Therefore, by
184
+ modifying or distributing the Program (or any work based on the
185
+ Program), you indicate your acceptance of this License to do so, and
186
+ all its terms and conditions for copying, distributing or modifying
187
+ the Program or works based on it.
188
+
189
+ 6. Each time you redistribute the Program (or any work based on the
190
+ Program), the recipient automatically receives a license from the
191
+ original licensor to copy, distribute or modify the Program subject to
192
+ these terms and conditions. You may not impose any further
193
+ restrictions on the recipients' exercise of the rights granted herein.
194
+ You are not responsible for enforcing compliance by third parties to
195
+ this License.
196
+
197
+ 7. If, as a consequence of a court judgment or allegation of patent
198
+ infringement or for any other reason (not limited to patent issues),
199
+ conditions are imposed on you (whether by court order, agreement or
200
+ otherwise) that contradict the conditions of this License, they do not
201
+ excuse you from the conditions of this License. If you cannot
202
+ distribute so as to satisfy simultaneously your obligations under this
203
+ License and any other pertinent obligations, then as a consequence you
204
+ may not distribute the Program at all. For example, if a patent
205
+ license would not permit royalty-free redistribution of the Program by
206
+ all those who receive copies directly or indirectly through you, then
207
+ the only way you could satisfy both it and this License would be to
208
+ refrain entirely from distribution of the Program.
209
+
210
+ If any portion of this section is held invalid or unenforceable under
211
+ any particular circumstance, the balance of the section is intended to
212
+ apply and the section as a whole is intended to apply in other
213
+ circumstances.
214
+
215
+ It is not the purpose of this section to induce you to infringe any
216
+ patents or other property right claims or to contest validity of any
217
+ such claims; this section has the sole purpose of protecting the
218
+ integrity of the free software distribution system, which is
219
+ implemented by public license practices. Many people have made
220
+ generous contributions to the wide range of software distributed
221
+ through that system in reliance on consistent application of that
222
+ system; it is up to the author/donor to decide if he or she is willing
223
+ to distribute software through any other system and a licensee cannot
224
+ impose that choice.
225
+
226
+ This section is intended to make thoroughly clear what is believed to
227
+ be a consequence of the rest of this License.
228
+
229
+ 8. If the distribution and/or use of the Program is restricted in
230
+ certain countries either by patents or by copyrighted interfaces, the
231
+ original copyright holder who places the Program under this License
232
+ may add an explicit geographical distribution limitation excluding
233
+ those countries, so that distribution is permitted only in or among
234
+ countries not thus excluded. In such case, this License incorporates
235
+ the limitation as if written in the body of this License.
236
+
237
+ 9. The Free Software Foundation may publish revised and/or new versions
238
+ of the General Public License from time to time. Such new versions will
239
+ be similar in spirit to the present version, but may differ in detail to
240
+ address new problems or concerns.
241
+
242
+ Each version is given a distinguishing version number. If the Program
243
+ specifies a version number of this License which applies to it and "any
244
+ later version", you have the option of following the terms and conditions
245
+ either of that version or of any later version published by the Free
246
+ Software Foundation. If the Program does not specify a version number of
247
+ this License, you may choose any version ever published by the Free Software
248
+ Foundation.
249
+
250
+ 10. If you wish to incorporate parts of the Program into other free
251
+ programs whose distribution conditions are different, write to the author
252
+ to ask for permission. For software which is copyrighted by the Free
253
+ Software Foundation, write to the Free Software Foundation; we sometimes
254
+ make exceptions for this. Our decision will be guided by the two goals
255
+ of preserving the free status of all derivatives of our free software and
256
+ of promoting the sharing and reuse of software generally.
257
+
258
+ NO WARRANTY
259
+
260
+ 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
261
+ FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
262
+ OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
263
+ PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
264
+ OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
265
+ MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
266
+ TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
267
+ PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
268
+ REPAIR OR CORRECTION.
269
+
270
+ 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
271
+ WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
272
+ REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
273
+ INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
274
+ OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
275
+ TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
276
+ YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
277
+ PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
278
+ POSSIBILITY OF SUCH DAMAGES.
279
+
280
+ END OF TERMS AND CONDITIONS
281
+
readme.txt CHANGED
@@ -1,9 +1,9 @@
1
  === Plugin Name ===
2
  Contributors: apeatling, johnjamesjacoby, MrMaz, DJPaul, boonebgorges
3
  Tags: buddypress, social networking, activity, profiles, messaging, friends, groups, forums, microblogging, twitter, facebook, mingle, social, community, networks, networking, cms
4
- Requires at least: 3.0
5
- Tested up to: 3.0.3
6
- Stable tag: 1.2.7
7
 
8
  == Description ==
9
 
@@ -61,7 +61,7 @@ BuddyPress also includes support for discussion forums. Each group created on yo
61
 
62
  Of course! First install and activate BuddyPress, then download and activate the <a href="http://wordpress.org/extend/plugins/bp-template-pack/">template extension pack</a>. This plugin will run you through the process step-by-step.
63
 
64
- Be sure to also try out the default theme bundled with BuddyPress. It provides all the awesome features of a standard WordPress blog, but also integrates the BuddyPress features both seamlessly and beautfully. It's also really easy to modify with custom header support, widget support and via a <a href="http://codex.buddypress.org/how-to-guides/building-a-buddypress-child-theme/">child theme</a>.
65
 
66
  = Will this work on standard WordPress and WordPress MU? =
67
 
@@ -95,7 +95,7 @@ BuddyPress subversion trunk can be found at: http://svn.buddypress.org/trunk/
95
 
96
  == Languages ==
97
 
98
- BuddyPress is available in more than 20 languages. For more information about BuddyPress in your language please select a langauge site from the list below. Is your language missing? Please send a message to the <a href="http://lists.automattic.com/mailman/listinfo/wp-polyglots">WP-Polygots</a> mailing list and request for your language to be set up.
99
 
100
  * <a href="http://br.buddypress.org/">Brasil</a>
101
  * <a href="http://ca.buddypress.org/">Català</a>
@@ -117,12 +117,15 @@ BuddyPress is available in more than 20 languages. For more information about Bu
117
  * <a href="http://ko.buddypress.org/">한국어</a>
118
  * <a href="http://tw.buddypress.org/">正體中文</a>
119
 
120
- The <a href="http://i18n.svn.buddypress.org/">BuddyPress langauge file repository</a> includes some language that have not yet set up a localization site.
121
 
122
  == Upgrade Notice ==
123
 
124
- = 1.2.7 =
125
- Fixes over 10 bugs.
 
 
 
126
 
127
  == Changelog ==
128
 
1
  === Plugin Name ===
2
  Contributors: apeatling, johnjamesjacoby, MrMaz, DJPaul, boonebgorges
3
  Tags: buddypress, social networking, activity, profiles, messaging, friends, groups, forums, microblogging, twitter, facebook, mingle, social, community, networks, networking, cms
4
+ Requires at least: 3.2
5
+ Tested up to: 3.2
6
+ Stable tag: 1.2.9
7
 
8
  == Description ==
9
 
61
 
62
  Of course! First install and activate BuddyPress, then download and activate the <a href="http://wordpress.org/extend/plugins/bp-template-pack/">template extension pack</a>. This plugin will run you through the process step-by-step.
63
 
64
+ Be sure to also try out the default theme bundled with BuddyPress. It provides all the awesome features of a standard WordPress blog, but also integrates the BuddyPress features both seamlessly and beautifully. It's also really easy to modify with custom header support, widget support and via a <a href="http://codex.buddypress.org/how-to-guides/building-a-buddypress-child-theme/">child theme</a>.
65
 
66
  = Will this work on standard WordPress and WordPress MU? =
67
 
95
 
96
  == Languages ==
97
 
98
+ BuddyPress is available in more than 20 languages. For more information about BuddyPress in your language please select a language site from the list below. Is your language missing? Please send a message to the <a href="http://lists.automattic.com/mailman/listinfo/wp-polyglots">WP-Polygots</a> mailing list and request for your language to be set up.
99
 
100
  * <a href="http://br.buddypress.org/">Brasil</a>
101
  * <a href="http://ca.buddypress.org/">Català</a>
117
  * <a href="http://ko.buddypress.org/">한국어</a>
118
  * <a href="http://tw.buddypress.org/">正體中文</a>
119
 
120
+ The <a href="http://i18n.svn.buddypress.org/">BuddyPress language file repository</a> includes some language that have not yet set up a localization site.
121
 
122
  == Upgrade Notice ==
123
 
124
+ = 1.2.9 =
125
+ Compatibility with WordPress 3.2
126
+
127
+ = 1.2.8 =
128
+ Compatibility with WordPress 3.1
129
 
130
  == Changelog ==
131
 
screenshot-1.gif ADDED
Binary file
screenshot-2.gif ADDED
Binary file
screenshot-3.gif ADDED
Binary file
screenshot-4.gif ADDED
Binary file
screenshot-5.gif ADDED
Binary file
screenshot-6.gif ADDED
Binary file
screenshot-7.gif ADDED
Binary file