Didier Guillion a dit:
Ouaip, j'avais ecrit une bétise et je l'ai effacée...
Je pense qu'il doit y avoir une possiblité de recupérer la liste des applications de l'avant vers l'arriere.
Cordialement
Bonjours
C'est possible, je vien de faire une recherche et voila ce que j'ai trouvé.
On doit faire plus simple.
Le script:
-- Inversion de la liste des process
-- Mise en mémoire des process visibles
tell application "Finder"
set processListVis to (name of (every application process whose visible is true) as list)
end tell
-- Trouvé sur Internet
-- Première fenêtre dans le bon ordre
choose from list ASCII_Sort(the processListVis)
-- Deuxième fenêtre avec l'ordre inversé
choose from list the reverse of ASCII_Sort(the processListVis)
-- Ces 2 lignes normalement sont commandés par des boutons pour changer
-- le sens d'affichage.
on ASCII_Sort(my_list)
set the index_list to {}
set the sorted_list to {}
repeat (the number of items in my_list) times
set the low_item to ""
repeat with i from 1 to (number of items in my_list)
if i is not in the index_list then
set this_item to item i of my_list as text
if the low_item is "" then
set the low_item to this_item
set the low_item_index to i
else if this_item comes before the low_item then
set the low_item to this_item
set the low_item_index to i
end if
end if
end repeat
set the end of sorted_list to the low_item
set the end of the index_list to the low_item_index
end repeat
return the sorted_list
end ASCII_Sort
Si je comprend bien, c'est choose from qui créer la fenêtre alors j'ai pas perdu mon temps à trouver une solution.
A modifier suivant les besoins.
@+