[prev in list] [next in list] [prev in thread] [next in thread]
List: gallery-checkins
Subject: [Gallery-checkins] CVS: gallery2/modules/core/classes Gallery.class,1.35,1.36 GalleryLayout.class,1.
From: Bharat Mediratta <bharat () users ! sourceforge ! net>
Date: 2002-10-29 7:14:16
[Download RAW message or body]
Update of /cvsroot/gallery/gallery2/modules/core/classes
In directory usw-pr-cvs1:/tmp/cvs-serv17238/modules/core/classes
Modified Files:
Gallery.class GalleryLayout.class GalleryModule.class
GalleryTheme.class
Log Message:
* Fleshed out the comment details code as a test case for how module details will
work. Now we display the 3 most recent comments when viewing the item, and
provide a link to the rest of them.
* Added ThinFrame to the theme code
Index: Gallery.class
===================================================================
RCS file: /cvsroot/gallery/gallery2/modules/core/classes/Gallery.class,v
retrieving revision 1.35
retrieving revision 1.36
diff -u -r1.35 -r1.36
--- Gallery.class 28 Oct 2002 18:51:03 -0000 1.35
+++ Gallery.class 29 Oct 2002 07:14:13 -0000 1.36
@@ -931,7 +931,7 @@
$this->_smarty->register_function('gallery' . $method, 'galleryTemplateCallback');
}
- foreach (array('LightFrame', 'HeavyFrame', 'ThreeDFrame',
+ foreach (array('ThinFrame', 'LightFrame', 'HeavyFrame', 'ThreeDFrame',
'SmallestFont', 'SmallerFont', 'SmallFont',
'BigFont', 'BiggerFont', 'BiggestFont',
'SuccessFontColor', 'WarningFontColor', 'ErrorFontColor',
Index: GalleryLayout.class
===================================================================
RCS file: /cvsroot/gallery/gallery2/modules/core/classes/GalleryLayout.class,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- GalleryLayout.class 28 Oct 2002 18:51:03 -0000 1.7
+++ GalleryLayout.class 29 Oct 2002 07:14:14 -0000 1.8
@@ -226,21 +226,17 @@
/**
* Call getItemDetails on every active module
*
- * @param mixed object GalleryItem a target item, or array of object GalleryItem
+ * @param object GalleryItem a target item
* @param array key => value parameters provided by the
* parent view -- the module can augment or override these.
* @return array object GalleryStatus a status code
* array ('itemId' => array('moduleName' => html, ...))
*/
- function _getModuleItemDetails($items, $urlParams) {
+ function _getModuleItemDetails($item, $urlParams) {
global $gallery;
GalleryProfiler::start('GalleryLayout::_getModuleItemDetails');
- if (!is_array($items)) {
- $items = array($items);
- }
-
/* Load the module list */
list ($ret, $moduleStatus) = $gallery->getModuleStatus();
if ($ret->isError()) {
@@ -258,15 +254,14 @@
return array($ret->wrap(__FILE__, __LINE__), null);
}
- list ($ret, $moduleDetails) =
- $module->getItemDetails($items, $urlParams);
+ list ($ret, $itemDetails[$moduleName]) =
+ $module->getItemDetails($item, $urlParams);
if ($ret->isError()) {
return array($ret->wrap(__FILE__, __LINE__), null);
}
- /* Refactor into: array[itemId][moduleName][links] */
- foreach ($moduleDetails as $itemId => $html) {
- $itemDetails[$itemId][$moduleName] = $html;
+ if (empty($itemDetails[$moduleName])) {
+ unset($itemDetails[$moduleName]);
}
}
Index: GalleryModule.class
===================================================================
RCS file: /cvsroot/gallery/gallery2/modules/core/classes/GalleryModule.class,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -r1.8 -r1.9
--- GalleryModule.class 26 Oct 2002 08:13:27 -0000 1.8
+++ GalleryModule.class 29 Oct 2002 07:14:14 -0000 1.9
@@ -251,7 +251,7 @@
/**
* Return module-specific details content about the item
*
- * @param mixed object GalleryItem a target item, or array of object GalleryItem
+ * @param mixed object GalleryItem a target item
* @param array key => value parameters provided by the
* parent view -- the module can augment or override these.
* @return array object GalleryStatus a status code
Index: GalleryTheme.class
===================================================================
RCS file: /cvsroot/gallery/gallery2/modules/core/classes/GalleryTheme.class,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- GalleryTheme.class 28 Oct 2002 18:51:04 -0000 1.3
+++ GalleryTheme.class 29 Oct 2002 07:14:14 -0000 1.4
@@ -191,6 +191,17 @@
}
/**
+ * Return the given content inside a thin themed frame
+ *
+ * @param array key => value attributes
+ * @param string content to go inside the block
+ * @return HTML content
+ */
+ function thinFrame($params, $content) {
+ return $content;
+ }
+
+ /**
* Return the given content inside a light themed frame
*
* @param array key => value attributes
-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
__[ g a l l e r y - c h e c k i n s ]_________________________
[ list info/archive --> http://gallery.sf.net/lists.php ]
[ gallery info/FAQ/download --> http://gallery.sf.net ]
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic