|
From: <ara...@us...> - 2006-10-22 11:43:45
|
Revision: 35
http://svn.sourceforge.net/easybox-mod/?rev=35&view=rev
Author: aragornis
Date: 2006-10-22 04:43:24 -0700 (Sun, 22 Oct 2006)
Log Message:
-----------
Optimisation des modifs de bedelaitre sur la gestion des disques
Modified Paths:
--------------
trunk/module/_explorateur/index1.php
trunk/skin/simple/dossier/Thumbs.db
trunk/skin/simple/explorateur.tpl
Added Paths:
-----------
trunk/skin/simple/dossier/diskoptical.gif
Modified: trunk/module/_explorateur/index1.php
===================================================================
--- trunk/module/_explorateur/index1.php 2006-10-22 11:22:56 UTC (rev 34)
+++ trunk/module/_explorateur/index1.php 2006-10-22 11:43:24 UTC (rev 35)
@@ -34,12 +34,6 @@
$rep = $rep_default;
}
-// BDE - 18/10/2006 - Modification dans la gestion des disques
-// On sauvegarde le r\x82pertoire demand\x82 pour v\x82rifier plus tard si c'est
-// un rechargement de disques
-$rep_reload=$rep;
-// Fin Modif
-
//--seulement pour linux
if($rep=="") {
$rep = "/";
@@ -54,15 +48,11 @@
$min = 0;
}
-// BDE - 18/10/2006 - Modification dans la gestion des disques
-// Si l'on est en train de recharger la liste des fichiers
-// Alors, on recharge le r\x82pertoire en cours
-if ($rep_reload=="reload")
-{
- $rep_copy = get_variable('previousrep');
- $rep = get_variable('previousrep');
-}
-// Fin Modif
+// Rechargement des disques
+if ($_GET['reload']=="1"){
+ save_variable('disques', serialize(DISQUES()));
+}
+
//Ajout dans la base de donn\xE9e pour les retours
if($extension==$ini[explorateur][ext]){
save_variable('lastexpl', 'explorateur');
@@ -193,14 +183,7 @@
$fichiers = FICHIERS();
-// BDE - 18/10/2006 - Modification dans la gestion des disques
-// Si il faut recharger la liste des disques, on le fait ici ...
-if ($rep_reload=="reload")
-{
- save_variable('disques', serialize(DISQUES()));
-}
-// Fin Modif
-$smarty->assign('DISQUES',DISQUES());//unserialize(get_variable('disques')));
+$smarty->assign('DISQUES',unserialize(get_variable('disques')));//unserialize(get_variable('disques')));
$smarty->assign('T_rep',$fichiers[0]);
$smarty->assign('T_file',$fichiers[1]);
Modified: trunk/skin/simple/dossier/Thumbs.db
===================================================================
(Binary files differ)
Added: trunk/skin/simple/dossier/diskoptical.gif
===================================================================
(Binary files differ)
Property changes on: trunk/skin/simple/dossier/diskoptical.gif
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Modified: trunk/skin/simple/explorateur.tpl
===================================================================
--- trunk/skin/simple/explorateur.tpl 2006-10-22 11:22:56 UTC (rev 34)
+++ trunk/skin/simple/explorateur.tpl 2006-10-22 11:43:24 UTC (rev 35)
@@ -1 +1 @@
-{assign var=rep_encoded value=$REP|urlencode}
{section name=disques loop=$DISQUES}
{if $smarty.section.disques.first}
<table cellspacing="2" align="center" width="498" valign="middle"><tr valign="middle">
{/if}
<td valign="middle"><img src="{$SKIN_REP}dossier/{$DISQUES[disques].gif}.gif" width="16" height="16"><font size='1'><a href="{$PAGE_EXPLO}?directory={$DISQUES[disques].path|urlencode}&mode={$MODE}">{$DISQUES[disques].lettre|strtolower}</a></font></td>
{if $smarty.section.disques.last}
</tr></table>
{/if}
{/section}
{section name=path loop=$CHEMIN_REP}
{if $smarty.section.path.first}
<center><font size="1">
{/if}
<a href="{$PAGE_EXPLO}?directory={$CHEMIN_REP[path].0}&mode={$MODE}">{$CHEMIN_REP[path].1|strip_delimiters}/</a>
{if $smarty.section.path.last}
</font></center>
{/if}
{/section}
{if $AFF_CDDA}
<a href="playdb.php?type=cdda&disque={$LETTRE_CDDA}">Lire {$LETTRE_CDDA}: en tant que cd</a>
{/if}
{assign var=NUM_ROW_AFFICH value=15}
<table width="498" cellpadding="0" cellspacing="0" align="center" valign="middle">
{if $PLAYREP OR $AFF_FAVORIS}
<tr><td colspan="2"><center>
{/if}
{if $PLAYREP}
<img src="{$SKIN_REP}dossier/rep_all.gif" border="0" width="20" height="20"><a href="{$PAGE_LECT_REP}?toplay={$REP|urlencode}&type=playrep"> {$PLAYREP_TEXT|default:"Lire le r\xE9pertoire complet"}</a>
{/if}
{if $PLAYREP AND $AFF_FAVORIS}
-
{/if}
{if $AFF_FAVORIS}
<img src="{$SKIN_REP}dossier/favoris.gif" width="20" height="20"> <a href="{$RACINE_REP}module/favoris/index1.php?ajout={$REP|urlencode}&nom={$REP}">Ajouter aux favoris</a>
{/if}
{if $PLAYREP OR $AFF_FAVORIS}
</center></td></tr>
{/if}
{if $MIN!=0}
{assign var=temp value=$MIN-$NUM_ROW_AFFICH|max:0}
<tr><td colspan="2"><img src="{$INTERFACE_REP}btn_vert.gif" border="0"> <a href="{$PAGE_EXPLO}?start={$MIN-$NUM_ROW_AFFICH|max:0}&directory={$REP|urlencode}&mode={$MODE}"><font size=2>Pr\xE9c\xE9dent</font></a> <a href="{$PAGE_EXPLO}?start=0&directory={$REP|urlencode}&mode={$MODE}"><font size=2>D\xE9but du r\xE9pertoire</font></a></td></tr>
{attribbouton touche="green" lien="$PAGE_EXPLO?start=$temp&directory=$rep_encoded&mode=$MODE"}
{/if}
{if $Nb_rep_path >='2' AND $MIN==0}
{assign var=temp value=$REP|dirname|realpath|urlencode}
<tr><td colspan="2"><img src="{$INTERFACE_REP}btn_jaune.gif" border="0"> <a focused href="{$PAGE_EXPLO}?directory={$REP|dirname|realpath|urlencode}&mode={$MODE}">Dossier parent</a></td></tr>
{attribbouton touche="yellow" lien="$PAGE_EXPLO?directory=$temp&mode=$MODE"}
{elseif $Nb_rep_path >='2'}
{assign var=temp value=$REP|dirname|realpath|urlencode}
{attribbouton touche="yellow" lien="$PAGE_EXPLO?directory=$temp&mode=$MODE"}
{/if}
{section name=files loop=$T_affich max=$NUM_ROW_AFFICH start=$MIN}
{if $T_affich[files]|in_array:$T_rep}
{assign var="rep_a_affich" value=$REP|cat:'/'|cat:$T_affich[files]}
<tr><td colspan="2"><img src="{$SKIN_REP}dossier/folder.gif"> <font size="1"><a {if $smarty.section.disques.first==1}focused {/if}href="{$PAGE_EXPLO}?directory={$rep_a_affich|realpath|urlencode}&mode={$MODE}">{$T_affich[files]|truncate:55|strip_delimiters}</a></font></td></tr>
{else}
<tr><td><img src="{$SKIN_REP}dossier/{$ICONE_FICHIER}" width="16" height="16"> <font size="1"><a {if $smarty.section.disques.first==1}focused {/if}href="{$PAGE_LECT}?{$OPT_LIENS}toplay_file={$T_affich[files]|urlencode}&toplay_rep={$REP|urlencode}">{$T_affich[files]|strip_delimiters|truncate:52}</a>
</font></td><td width="35">
{if $AFF_INFO}
{assign var="nb" value=$T_affich[files]|strrpos:"."}
<a href="fichefilm.php?start={$MIN}&comeback=expl&film={$T_affich[files]|substr:0:$nb|urlencode}&fichier={$REP|cat:'/'|cat:$T_affich[files]|realpath|urlencode}"><font size="1">info</font></a>
{/if}
</td></tr>
{/if}
{/section}
{assign var=N_affich value=$T_affich|@count}
{assign var=N_affich_reste value=$NUM_ROW_AFFICH|max:15}
{if $MIN+$smarty.section.files.total<count($T_affich)}
<tr><td colspan="2"><img src="{$INTERFACE_REP}btn_bleu.gif" border="0"> <a href="{$PAGE_EXPLO}?start={$MIN+$smarty.section.files.total}&directory={$REP|urlencode}&mode={$MODE}"><font size=2>Suivant</font></a> - <font size=2><a href="{$PAGE_EXPLO}?start={$N_affich-$smarty.section.files.total}&directory={$REP|urlencode}&mode={$MODE}">Fin du r\xE9pertoire</a> - Page {$MIN/$NUM_ROW_AFFICH+1|ceil} / {$N_affich/$NUM_ROW_AFFICH|ceil}</font></td></tr>
{assign var=temp value=$MIN+$smarty.section.files.total}
{attribbouton touche="blue" lien="$PAGE_EXPLO?start=$temp&directory=$rep_encoded&mode=$MODE"}
{else}
<tr><td colspan="2"><font size=2>Page {$MIN/$NUM_ROW_AFFICH+1|ceil} / {$N_affich/$NUM_ROW_AFFICH|ceil}</font></td></tr>
{/if}
</table>
{$FOOTER}
\ No newline at end of file
+{assign var=rep_encoded value=$REP|urlencode}
{section name=disques loop=$DISQUES}
{if $smarty.section.disques.first}
<table cellspacing="2" align="center" width="498" valign="middle"><tr valign="middle">
{/if}
{if $DISQUES[disques].path == 'reload'}
<td valign="middle"><img src="{$SKIN_REP}dossier/{$DISQUES[disques].gif}.gif" width="16" height="16"><font size='1'><a href="{$PAGE_EXPLO}?directory={$REP|urlencode}&mode={$MODE}&reload=1&start={$MIN}">Rafra\xEEchir</a></font></td>
{else}
<td valign="middle"><img src="{$SKIN_REP}dossier/{$DISQUES[disques].gif}.gif" width="16" height="16"><font size='1'><a href="{$PAGE_EXPLO}?directory={$DISQUES[disques].path|urlencode}&mode={$MODE}">{$DISQUES[disques].lettre|strtolower}</a></font></td>
{/if}
{if $smarty.section.disques.last}
</tr></table>
{/if}
{/section}
{section name=path loop=$CHEMIN_REP}
{if $smarty.section.path.first}
<center><font size="1">
{/if}
<a href="{$PAGE_EXPLO}?directory={$CHEMIN_REP[path].0}&mode={$MODE}">{$CHEMIN_REP[path].1|strip_delimiters}/</a>
{if $smarty.section.path.last}
</font></center>
{/if}
{/section}
{if $AFF_CDDA}
<a href="playdb.php?type=cdda&disque={$LETTRE_CDDA}">Lire {$LETTRE_CDDA}: en tant que cd</a>
{/if}
{assign var=NUM_ROW_AFFICH value=15}
<table width="498" cellpadding="0" cellspacing="0" align="center" valign="middle">
{if $PLAYREP OR $AFF_FAVORIS}
<tr><td colspan="2"><center>
{/if}
{if $PLAYREP}
<img src="{$SKIN_REP}dossier/rep_all.gif" border="0" width="20" height="20"><a href="{$PAGE_LECT_REP}?toplay={$REP|urlencode}&type=playrep"> {$PLAYREP_TEXT|default:"Lire le r\xE9pertoire complet"}</a>
{/if}
{if $PLAYREP AND $AFF_FAVORIS}
-
{/if}
{if $AFF_FAVORIS}
<img src="{$SKIN_REP}dossier/favoris.gif" width="20" height="20"> <a href="{$RACINE_REP}module/favoris/index1.php?ajout={$REP|urlencode}&nom={$REP}">Ajouter aux favoris</a>
{/if}
{if $PLAYREP OR $AFF_FAVORIS}
</center></td></tr>
{/if}
{if $MIN!=0}
{assign var=temp value=$MIN-$NUM_ROW_AFFICH|max:0}
<tr><td colspan="2"><img src="{$INTERFACE_REP}btn_vert.gif" border="0"> <a href="{$PAGE_EXPLO}?start={$MIN-$NUM_ROW_AFFICH|max:0}&directory={$REP|urlencode}&mode={$MODE}"><font size=2>Pr\xE9c\xE9dent</font></a> <a href="{$PAGE_EXPLO}?start=0&directory={$REP|urlencode}&mode={$MODE}"><font size=2>D\xE9but du r\xE9pertoire</font></a></td></tr>
{attribbouton touche="green" lien="$PAGE_EXPLO?start=$temp&directory=$rep_encoded&mode=$MODE"}
{/if}
{if $Nb_rep_path >='2' AND $MIN==0}
{assign var=temp value=$REP|dirname|realpath|urlencode}
<tr><td colspan="2"><img src="{$INTERFACE_REP}btn_jaune.gif" border="0"> <a focused href="{$PAGE_EXPLO}?directory={$REP|dirname|realpath|urlencode}&mode={$MODE}">Dossier parent</a></td></tr>
{attribbouton touche="yellow" lien="$PAGE_EXPLO?directory=$temp&mode=$MODE"}
{elseif $Nb_rep_path >='2'}
{assign var=temp value=$REP|dirname|realpath|urlencode}
{attribbouton touche="yellow" lien="$PAGE_EXPLO?directory=$temp&mode=$MODE"}
{/if}
{section name=files loop=$T_affich max=$NUM_ROW_AFFICH start=$MIN}
{if $T_affich[files]|in_array:$T_rep}
{assign var="rep_a_affich" value=$REP|cat:'/'|cat:$T_affich[files]}
<tr><td colspan="2"><img src="{$SKIN_REP}dossier/folder.gif"> <font size="1"><a {if $smarty.section.disques.first==1}focused {/if}href="{$PAGE_EXPLO}?directory={$rep_a_affich|realpath|urlencode}&mode={$MODE}">{$T_affich[files]|truncate:55|strip_delimiters}</a></font></td></tr>
{else}
<tr><td><img src="{$SKIN_REP}dossier/{$ICONE_FICHIER}" width="16" height="16"> <font size="1"><a {if $smarty.section.disques.first==1}focused {/if}href="{$PAGE_LECT}?{$OPT_LIENS}toplay_file={$T_affich[files]|urlencode}&toplay_rep={$REP|urlencode}">{$T_affich[files]|strip_delimiters|truncate:52}</a>
</font></td><td width="35">
{if $AFF_INFO}
{assign var="nb" value=$T_affich[files]|strrpos:"."}
<a href="fichefilm.php?start={$MIN}&comeback=expl&film={$T_affich[files]|substr:0:$nb|urlencode}&fichier={$REP|cat:'/'|cat:$T_affich[files]|realpath|urlencode}"><font size="1">info</font></a>
{/if}
</td></tr>
{/if}
{/section}
{assign var=N_affich value=$T_affich|@count}
{assign var=N_affich_reste value=$NUM_ROW_AFFICH|max:15}
{if $MIN+$smarty.section.files.total<count($T_affich)}
<tr><td colspan="2"><img src="{$INTERFACE_REP}btn_bleu.gif" border="0"> <a href="{$PAGE_EXPLO}?start={$MIN+$smarty.section.files.total}&directory={$REP|urlencode}&mode={$MODE}"><font size=2>Suivant</font></a> - <font size=2><a href="{$PAGE_EXPLO}?start={$N_affich-$smarty.section.files.total}&directory={$REP|urlencode}&mode={$MODE}">Fin du r\xE9pertoire</a> - Page {$MIN/$NUM_ROW_AFFICH+1|ceil} / {$N_affich/$NUM_ROW_AFFICH|ceil}</font></td></tr>
{assign var=temp value=$MIN+$smarty.section.files.total}
{attribbouton touche="blue" lien="$PAGE_EXPLO?start=$temp&directory=$rep_encoded&mode=$MODE"}
{else}
<tr><td colspan="2"><font size=2>Page {$MIN/$NUM_ROW_AFFICH+1|ceil} / {$N_affich/$NUM_ROW_AFFICH|ceil}</font></td></tr>
{/if}
</table>
{$FOOTER}
\ No newline at end of file
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|