From 2a40a776a1c606fb5153639497de74b354c181dc Mon Sep 17 00:00:00 2001
From: Andrei Mateescu <andrei@xns.ro>
Date: Tue, 27 Sep 2011 00:55:30 +0300
Subject: [PATCH] Issue #1291428: Add a 'full' view mode and use it for
 file/%file pages.

---
 file_entity.module    |    4 ++++
 file_entity.pages.inc |    2 +-
 2 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/file_entity.module b/file_entity.module
index a10ddc9..b629a7e 100644
--- a/file_entity.module
+++ b/file_entity.module
@@ -198,6 +198,10 @@ function file_entity_entity_info_alter(&$entity_info) {
   $entity_info['file']['fieldable'] = TRUE;
   $entity_info['file']['entity keys']['bundle'] = 'type';
   $entity_info['file']['bundles'] = array();
+  $entity_info['file']['view modes']['full'] = array(
+    'label' => t('File view page'),
+    'custom settings' => FALSE,
+  );
   foreach (file_info_file_types() as $type => $info) {
     $info += array(
       // Provide a default administration path for Field UI, but not if 'admin'
diff --git a/file_entity.pages.inc b/file_entity.pages.inc
index cbaddae..2931fa7 100644
--- a/file_entity.pages.inc
+++ b/file_entity.pages.inc
@@ -20,7 +20,7 @@ function file_entity_view_page($file) {
   }
 
   drupal_set_title($file->filename);
-  return file_view($file, 'media_original');
+  return file_view($file, 'full');
 }
 
 /**
-- 
1.7.6.msysgit.0

