Here is first draft of ported module to Drupal 7
Works for me at first look

Comments

good_man’s picture

Status: Patch (to be ported) » Needs work

Thanks a lot for your work, I didn't manage to get it into cvs version (what tag you run the patch against?), note the spaces and tabs and follow Drupal coding standards, also you generated the patch using `cvs diff` or `diff` ? better use `cvs diff -up > patch_name.patch`.

+++ custom/scrollable_content/scrollable_content.info	2011-02-04 16:06:50.000000000 +0300
@@ -1,13 +1,11 @@
+;dependencies[] = jquery_update

no need for this anymore, D7 already uses jQuery 1.4

+++ custom/scrollable_content/scrollable_content.info	2011-02-04 16:06:50.000000000 +0300
@@ -1,13 +1,11 @@
+; configure =

should put the config url.

+++ custom/scrollable_content/scrollable_content.module	2011-02-04 17:58:04.000000000 +0300
@@ -38,21 +38,24 @@
+function scrollable_content_block_info() {
       $blocks[0]['info'] = t('Scrollable Content');
       return $blocks;
+}

extra indentation spaces.

+++ custom/scrollable_content/scrollable_content.module	2011-02-04 17:58:04.000000000 +0300
@@ -38,21 +38,24 @@
       $form = scrollable_content_form('var');
       foreach ($form as $fieldset) {
         foreach ($fieldset as $key => $val) {
@@ -61,15 +64,20 @@

@@ -61,15 +64,20 @@
           }
         }
       }

also extra indentation spaces.

+++ custom/scrollable_content/scrollable_content.module	2011-02-04 17:58:04.000000000 +0300
@@ -61,15 +64,20 @@
+    $block = array();
+    $field = 'content_types';

we use two spaces in Drupal Coding Standards.

+++ custom/scrollable_content/scrollable_content.module	2011-02-04 17:58:04.000000000 +0300
@@ -80,8 +88,8 @@
+	'theme_name', 'vertical');

tab, use spaces in your editor to replace tabs.

+++ custom/scrollable_content/scrollable_content.module	2011-02-04 17:58:04.000000000 +0300
@@ -102,7 +110,7 @@
+    $defaults[$names['vertical']] = 0;

extra spaces

+++ custom/scrollable_content/scrollable_content.module	2011-02-04 17:58:04.000000000 +0300
@@ -244,7 +252,7 @@
+	'#field_prefix' => '<strong>' . variable_get('file_public_path', conf_path() . '/files') . '/' . '</strong>',

use spaces instead of tab.

+++ custom/scrollable_content/scrollable_content.module	2011-02-04 17:58:04.000000000 +0300
@@ -406,15 +414,13 @@
+	} elseif (function_exists('imagecache_presets')) {

no images cache anymore in D7, it's image style and included in core.

+++ custom/scrollable_content/scrollable_content.module	2011-02-04 17:58:04.000000000 +0300
@@ -406,15 +414,13 @@
+	} else {

spaces

+++ custom/scrollable_content/scrollable_content.module	2011-02-04 17:58:04.000000000 +0300
@@ -674,18 +682,22 @@
+	attach: function (context, settings) {' . PHP_EOL;
+    //$js .= 'console.log( $("#scrollable_content_' . $options['items'] . '" ));';
+
+    $js .= '$( "#scrollable_content_' . $options['items'] . '", context ).once( "", function() {
+    $(this).scrollable({
+	keyboard: ' . $options['keyboard'] . ',
+	mousewheel: ' . $options['mousewheel'] . ',
+	circular: ' . $options['circular'] . ',
+	speed: ' . $options['speed'] . ', ';

lots of tabs, and better replace inline javascript with Drupal.behaviors.settings array

+++ custom/scrollable_content/scrollable_content.module	2011-02-04 17:58:04.000000000 +0300
@@ -674,18 +682,22 @@
+    ¶

tab

+++ custom/scrollable_content/scrollable_content.module	2011-02-04 17:58:04.000000000 +0300
@@ -708,9 +720,10 @@
+	} // attach

tab

Powered by Dreditor.

good_man’s picture

Status: Needs work » Fixed

Ported and now in dev. version, report bugs in separate issue(s).

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.