aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHeshan <heshan@heidisoft.com>2011-03-05 09:15:54 +0530
committerHeshan <heshan@heidisoft.com>2011-03-05 09:15:54 +0530
commitf1b598ecbcc28304aa33d98d6c42ab29af1c2b42 (patch)
treef0ce361227b4dd257a23c3f496ac341effbca797
parent72f7b7109d1cdf3ec1f5fb022170dedc8c9dc5e1 (diff)
downloadvideo-f1b598ecbcc28304aa33d98d6c42ab29af1c2b42.tar.gz
video-f1b598ecbcc28304aa33d98d6c42ab29af1c2b42.tar.bz2
Adding lazyload for the .info file and preset has been added and completed the admin settings for the presets
-rw-r--r--.cvsignore6
-rw-r--r--includes/preset.inc19
-rw-r--r--video.admin.inc10
-rw-r--r--video.info9
4 files changed, 22 insertions, 22 deletions
diff --git a/.cvsignore b/.cvsignore
deleted file mode 100644
index a383a9b..0000000
--- a/.cvsignore
+++ /dev/null
@@ -1,6 +0,0 @@
-.git
-.DS_Store_1
-.cvsignore_1
-.DS_Store
-.gitignore
-.project
diff --git a/includes/preset.inc b/includes/preset.inc
index e06b9f6..30ea6ac 100644
--- a/includes/preset.inc
+++ b/includes/preset.inc
@@ -24,15 +24,18 @@ class video_preset {
$form = array();
$presets = video_preset_get_presets();
if (count($presets) == 0) {
- return $form['video_preset'] = array(
- '#markup' => t('No Features were found. Please use the !create_link link to create
- a new Feature module, or upload an existing Feature to your modules directory.',
- array('!create_link' => l(t('Create Feature'), 'admin/structure/features/create'))),
+ $form['video_preset'] = array(
+ '#markup' => t('No Preset were found. Please use the !create_link link to create
+ a new Video Preset, or upload an existing Feature to your modules directory.',
+ array('!create_link' => l(t('Create Video Preset'), 'admin/structure/video/add'))),
+ '#prefix' => '<div id="preset-checkboxes">',
+ '#suffix' => '</div>',
);
+ return $form;
}
$preset = array();
foreach ($presets as $id => $value) {
- $preset[$id] = $value['name'];
+ $preset[$id] = $value['name'] . ' ' . l(t('edit'), ('admin/structure/video/preset/' . $value['name']));
// $help[] = $value['name'] . ' - ' . $value['description'] . ' ' . l(t('edit'), preset_get_preset_path('video', $value['name']));
}
@@ -41,7 +44,11 @@ class video_preset {
'#title' => t('Video transcode presets'),
'#options' => $preset,
'#default_value' => variable_get('video_preset', array()),
-// '#description' => t('!list', array('!list' => theme('item_list', array('items' => $help)))),
+ '#description' => t('Please use the !manage_link link to manage
+ Video Presets. Use the !create_link link to create
+ a new Video Preset, or upload an existing Feature to your modules directory.',
+ array('!manage_link' => l(t('Manage Video Preset'), 'admin/structure/video'),
+ '!create_link' => l(t('Create Video Preset'), 'admin/structure/video/add'))),
'#prefix' => '<div id="preset-checkboxes">',
'#suffix' => '</div>',
);
diff --git a/video.admin.inc b/video.admin.inc
index 9598156..0f55dea 100644
--- a/video.admin.inc
+++ b/video.admin.inc
@@ -1,6 +1,5 @@
<?php
-
/**
* @file
* Provides the administration settings for the Video Drupal module.
@@ -11,7 +10,6 @@
* @return <type>
*/
function video_transcoder_admin_settings() {
- module_load_include('inc', 'video', '/includes/transcoder');
$transcoder = new video_transcoder;
$form = $transcoder->admin_settings();
return system_settings_form($form);
@@ -28,17 +26,15 @@ function video_transcoder_admin_settings_validate($form, &$form_state) {
// add vallidations by trnacoder interface
$transcoder = $form_state['values']['video_convertor'];
- module_load_include('inc', 'video', '/includes/transcoder');
$transcoder = new video_transcoder($transcoder);
$transcoder->admin_settings_validate($form, $form_state);
}
/**
- * Video transcoder admin settings
+ * Video preset admin settings
* @return <type>
*/
function video_preset_admin_settings() {
- module_load_include('inc', 'video', '/includes/preset');
$preset = new video_preset();
$form = $preset->admin_settings();
return system_settings_form($form);
@@ -127,7 +123,6 @@ function video_players_admin_settings() {
* @return <type>
*/
function video_metadata_admin_settings() {
- module_load_include('inc', 'video', '/includes/metadata');
$metadata = new video_metadata;
$form = $metadata->admin_settings();
return system_settings_form($form);
@@ -136,7 +131,6 @@ function video_metadata_admin_settings() {
function video_metadata_admin_settings_validate($form, &$form_state) {
// add vallidations by metadata interface
$metadata = $form_state['values']['video_metadata'];
- module_load_include('inc', 'video', '/includes/metadata');
$metadata = new video_metadata($metadata);
$metadata->admin_settings_validate($form, $form_state);
}
@@ -167,7 +161,6 @@ function video_cron_admin_settings() {
* @return <type>
*/
function video_filesystem_admin_settings() {
- module_load_include('inc', 'video', '/includes/filesystem');
$filesystem = new video_filesystem;
$form = $filesystem->admin_settings();
return system_settings_form($form);
@@ -176,7 +169,6 @@ function video_filesystem_admin_settings() {
function video_filesystem_admin_settings_validate($form, &$form_state) {
// add vallidations by metadata interface
$filesystem = $form_state['values']['video_filesystem'];
- module_load_include('inc', 'video', '/includes/filesystem');
$filesystem = new video_filesystem($filesystem);
$filesystem->admin_settings_validate($form, $form_state);
} \ No newline at end of file
diff --git a/video.info b/video.info
index 8e3dc9b..873c99d 100644
--- a/video.info
+++ b/video.info
@@ -11,4 +11,11 @@ files[] = video.theme.inc
files[] = video_formatter.inc
files[] = video_schedular.inc
files[] = video.field.inc
-files[] = includes/video.preset.inc \ No newline at end of file
+files[] = includes/video.preset.inc
+# Including class files to lazyload
+files[] = includes/conversion.inc
+files[] = includes/filesystem.inc
+files[] = includes/metadata.inc
+files[] = includes/preset.inc
+files[] = includes/transcoder.inc
+files[] = includes/video_helper.inc \ No newline at end of file