[pLog-svn] r530 - in plog/trunk: js/htmlarea js/ui templates/admin

oscar at devel.plogworld.net oscar at devel.plogworld.net
Fri Dec 17 17:14:19 GMT 2004


Author: oscar
Date: 2004-12-17 17:14:18 +0000 (Fri, 17 Dec 2004)
New Revision: 530

Modified:
   plog/trunk/js/htmlarea/htmlarea-plog-resourcelist.js
   plog/trunk/js/ui/common.js
   plog/trunk/templates/admin/resourcelist.template
Log:
started the redesign of this little page, following the same kind of color scheme design used everywhere else. Looking good :)


Modified: plog/trunk/js/htmlarea/htmlarea-plog-resourcelist.js
===================================================================
--- plog/trunk/js/htmlarea/htmlarea-plog-resourcelist.js	2004-12-17 16:35:31 UTC (rev 529)
+++ plog/trunk/js/htmlarea/htmlarea-plog-resourcelist.js	2004-12-17 17:14:18 UTC (rev 530)
@@ -88,7 +88,7 @@
   }	
   else {
 		addText( parent.opener.document.newPost.postExtendedText, albumLink );
-  }	
+  }
 }
 
 // ------
@@ -101,7 +101,7 @@
 function resourceListWindowInit() {
 // if we use this method, the dialog will be resized to its full size and I don't like that...
 //__dlg_init();
-window.resizeTo(400,400);
+//window.resizeTo(400,400);
 };
 
 function addHtmlareaLink(dest, blogId, type, resourceName, resourceDesc, preview) {

Modified: plog/trunk/js/ui/common.js
===================================================================
--- plog/trunk/js/ui/common.js	2004-12-17 16:35:31 UTC (rev 529)
+++ plog/trunk/js/ui/common.js	2004-12-17 17:14:18 UTC (rev 530)
@@ -19,13 +19,13 @@
 function resource_list_window( type ) {
 	// type == 1 => intro text
 	// type == 2 => extended text
-	HelpWin = window.open( 'admin.php?op=resourceList&mode='+type,'ResourceListWindow','scrollbars=yes,resizable=yes,toolbar=no,height=500,width=400');
+	HelpWin = window.open( '?op=resourceList&mode='+type,'ResourceListWindow','scrollbars=yes,resizable=yes,toolbar=no,height=600,width=350');
 
 }
 
 function userPictureSelectWindow()
 {
-	UserPicture = window.open( '?op=userPictureSelect', 'UserPictureSelect','scrollbars=yes,resizable=yes,toolbar=no,height=500,width=400');
+	UserPicture = window.open( '?op=userPictureSelect', 'UserPictureSelect','scrollbars=yes,resizable=yes,toolbar=no,height=600,width=400');
 }
 
 /**

Modified: plog/trunk/templates/admin/resourcelist.template
===================================================================
--- plog/trunk/templates/admin/resourcelist.template	2004-12-17 16:35:31 UTC (rev 529)
+++ plog/trunk/templates/admin/resourcelist.template	2004-12-17 17:14:18 UTC (rev 530)
@@ -10,52 +10,82 @@
   <script type="text/javascript">
    var plogBaseUrl = '{$baseurl}';
   </script>
+  <style>{literal}
+   html,body {
+    margin           : 0px;
+    padding          : 0px;
+    background       : #FFFFFF;
+   }
+   #container
+   {
+    width            : 300px;
+    text-align       : left;
+    margin-left      : auto;
+    margin-right     : auto;
+   }
+.info
+{
+    margin-bottom    : 10px;
+    width            : 285px;
+}
+#list_action_bar
+{
+    width            : 285px;
+    padding          : 4px;
+}
+  {/literal}</style>
  </head>
- <body onLoad="resourceListWindowInit();">
+<body onLoad="resourceListWindowInit();" style="">
  <div id="container">
- <h3>{$locale->tr("resources")}</h3>
-{assign var="counter" value=0} 
-<table width="100%">
-<tr>
-{if $album}
-{assign var="counter" value="`$counter+1`"}
- <td align="center" valign="center">
-  <a href="admin.php?op=resourceList&amp;albumId={$album->getParentId()}&amp;mode={$destination}">
-   <img src="imgs/folder.gif" border="0" alt="Parent" />&nbsp;<br/>..</a>
- </td>
-{/if}
-{foreach from=$albums item=resalbum}
- <td align="center" valign="center">
-  <a href="admin.php?op=resourceList&amp;albumId={$resalbum->getId()}&amp;mode={$destination}">
-   <img src="imgs/folder.gif" border="0" alt="folder" /><br/>{$resalbum->getName()}</a><br/>
-  {if $htmlarea}
-    <a href="javascript:addHtmlareaAlbumLink({$destination},{$blog->getId()},{$resalbum->getId()},'{$resalbum->getName()|escape:"javascript"}','{$resalbum->getDescription()|escape:"javascript"}',false);">{$locale->tr("add_album")}</a><br/>
-  {else}
-    <a href="javascript:addAlbumLink({$destination},{$blog->getId()},{$resalbum->getId()},'{$resalbum->getName()|escape:"javascript"}','{$resalbum->getDescription()|escape:"javascript"}',false);">{$locale->tr("add_album")}</a><br/>
+<table class="info">
+ <thead>
+  <th style="width:200px";>{$locale->tr("resource")}</th>
+  <th style="width:85px;">{$locale->tr("actions")}</th>
+ </thead>  
+ <tbody>
+  {if $album}
+   <tr class="{cycle values="odd,even"}">
+    <td>
+     <a href="admin.php?op=resourceList&amp;albumId={$album->getParentId()}&amp;mode={$destination}">
+     <img src="imgs/icon_folder-72.png" border="0" alt="Parent" />&nbsp;<br/>..</a>
+    </td>
+    <td>&nbsp;</td>
+   </tr>
   {/if}
- </td>
-  {assign var="counter" value="`$counter+1`"} 
-  {if $counter%2 == 0}
+  {foreach from=$albums item=resalbum}
+   <tr class="{cycle values="odd,even"}">
+    <td>
+     <a href="admin.php?op=resourceList&amp;albumId={$resalbum->getId()}&amp;mode={$destination}">
+     <img src="imgs/icon_folder-72.png" border="0" alt="folder" /><br/>{$resalbum->getName()}</a><br/>
+    </td>
+    <td>
+     {if $htmlarea}
+      <a href="javascript:addHtmlareaAlbumLink({$destination},{$blog->getId()},{$resalbum->getId()},'{$resalbum->getName()|escape:"javascript"}','{$resalbum->getDescription()|escape:"javascript"}',false);">{$locale->tr("add_album")}</a><br/>
+    {else}
+      <a href="javascript:addAlbumLink({$destination},{$blog->getId()},{$resalbum->getId()},'{$resalbum->getName()|escape:"javascript"}','{$resalbum->getDescription()|escape:"javascript"}',false);">{$locale->tr("add_album")}</a><br/>
+  {/if}
+   </td>
    </tr>
-   <tr>
- {/if} 
 {/foreach}
 {foreach from=$resources item=resource}
- <td align="center" valign="center">
+<tr class="{cycle values="odd,even"}">
+ <td>
   {if $resource->hasPreview()}
    <img src="{$url->resourcePreviewLink($resource)}" alt="Preview" />
   {else}
    {if $resource->isSound()}
-    <img alt="Sound" src="imgs/sound.gif" height="64" width="64" style="border:0px;" />
+    <img alt="Sound" src="imgs/icon_sound-48.png" height="48" width="48" style="border:0px;" />
    {elseif $resource->isVideo()}
-    <img alt="Video" src="imgs/video.gif" height="64" width="64" style="border:0px;" />
+    <img alt="Video" src="imgs/icon_video-48.png" height="48" width="48" style="border:0px;" />
    {elseif $resource->isZip()}
-    <img alt="Zip" src="imgs/compressed.gif" height="64" width="64" style="border:0px;" />   
+    <img alt="Zip" src="imgs/icon_compressed-48.png" height="48" width="48" style="border:0px;" />   
    {else}
-    <img alt="File" src="imgs/file.gif" height="64" width="64" style="border:0px;" />
+    <img alt="File" src="imgs/icon_file-48.png" height="48" width="48" style="border:0px;" />
    {/if}	
   {/if}
-  <a target="_blank" href="{$url->resourceLink($resource)}"><br/>{$resource->getFileName()}</a><br/>
+  <a target="_blank" href="{$url->resourceLink($resource)}"><br/>{$resource->getFileName()}</a>
+  </td>
+  <td>
   {if $htmlarea}
   <a href="javascript:addHtmlareaLink({$destination}, {$blog->getId()}, {$resource->getResourceType()}, '{$resource->getFileName()|escape:"javascript"}', '{$resource->getDescription()|escape:"javascript"}', false);">{$locale->tr("add_resource")}</a><br/> 
   {else}
@@ -69,20 +99,17 @@
    <a href="javascript:addResourceLink({$destination}, {$blog->getId()}, {$resource->getResourceType()}, '{$resource->getFileName()|escape:"javascript"}', '{$resource->getDescription()|escape:"javascript"}', true);">{$locale->tr("add_resource_preview")}</a><br/>
    {/if}
   {/if}
-   {assign var="counter" value="`$counter+1`"} 
  </td>
-  {if $counter%2 == 0}
-   </tr>
-   <tr>
-  {/if} 
 {/foreach}
+</tbody>
 </table>
-<hr/>
-{if $htmlarea}
-  <a href="javascript:onCancel()">{$locale->tr("close_window")}</a>
-{else}
-  <a href="javascript:window.close()">{$locale->tr("close_window")}</a>
-{/if}
+<div id="list_action_bar">
+  {if $htmlarea}
+    <a href="javascript:onCancel()">{$locale->tr("close_window")}</a>
+  {else}
+    <a href="javascript:window.close()">{$locale->tr("close_window")}</a>
+  {/if}
 </div>
+</div>
 </body>
 </html>




More information about the pLog-svn mailing list