From cd355d137ff231091774b87050ffd5ec76d9ef4d Mon Sep 17 00:00:00 2001 From: Fabio Varesano Date: Sun, 14 Jan 2007 14:59:06 +0000 Subject: Let's prepare for video upload status bar. --- plugins/video_upload/video_upload.js | 12 ++++++++++++ plugins/video_upload/video_upload.module | 14 ++++++++++++++ 2 files changed, 26 insertions(+) create mode 100644 plugins/video_upload/video_upload.js (limited to 'plugins') diff --git a/plugins/video_upload/video_upload.js b/plugins/video_upload/video_upload.js new file mode 100644 index 0000000..0fd80c1 --- /dev/null +++ b/plugins/video_upload/video_upload.js @@ -0,0 +1,12 @@ +// $Id$ +/** + * @file + * Javascript functions for busy status on video uploads + * + * TODO: Support AJAX Uploads :-) + * + * @author Fabio Varesano +*/ + + + diff --git a/plugins/video_upload/video_upload.module b/plugins/video_upload/video_upload.module index f22327b..55d72d7 100644 --- a/plugins/video_upload/video_upload.module +++ b/plugins/video_upload/video_upload.module @@ -133,6 +133,8 @@ function video_upload_nodeapi(&$node, $op, $teaser) { function video_upload_form_alter($form_id, &$form) { if($form_id == 'video_node_form' && isset($form['video']) && user_access('upload video files')) { + + theme('video_upload_get_script'); //get node object from form $node = $form['#node']; @@ -352,3 +354,15 @@ function _video_upload_check_settings() { return true; } + + + +/** + * Import the video_upload.js script + */ +function theme_video_upload_get_script() { + drupal_add_js(drupal_get_path('module', 'video_upload') . '/video_upload.js'); +} + + + -- cgit v1.2.3