if {$email == "self"} {
+ set defaultfiles [glob -nocomplain -directory [file
join skins default displaypic] *.png]
+ set l [llength $defaultfiles]
set cachefiles [glob -nocomplain -directory [file
join $HOME displaypic] *.dat]
+ set files [concat $defaultfiles $cachefiles]
set pic_in_use ""
Doesn't this mean the dpbrowser now always shows the amsn-dps too when only
asked for the dps of "self" (the logged in account) ? I don't think this is
good as it was not designed herefore. If I want to view my own pictures
only there's no way anymore. It should be coded so dpbrowser can be asked
to also show the amsn-dps but not by default when asked for the dps of
"self" I think. That's how I coded it back then.
Friendly greetings,
Karel.
2007/1/8, [EMAIL PROTECTED] <[EMAIL PROTECTED]>:
Revision: 7727
http://svn.sourceforge.net/amsn/?rev=7727&view=rev
Author: vivia
Date: 2007-01-08 06:55:56 -0800 (Mon, 08 Jan 2007)
Log Message:
-----------
Default Display Pictures are back.. thanx Cristofaro
Modified Paths:
--------------
trunk/amsn/utils/dpbrowser/dpbrowser.tcl
Modified: trunk/amsn/utils/dpbrowser/dpbrowser.tcl
===================================================================
--- trunk/amsn/utils/dpbrowser/dpbrowser.tcl 2007-01-08 11:26:06 UTC
(rev 7726)
+++ trunk/amsn/utils/dpbrowser/dpbrowser.tcl 2007-01-08 14:55:56 UTC
(rev 7727)
@@ -61,11 +61,15 @@
set dps_per_row $options(-width)
if {$email == "self"} {
+ set defaultfiles [glob -nocomplain -directory
[file join skins default displaypic] *.png]
+ set l [llength $defaultfiles]
set cachefiles [glob -nocomplain -directory [file
join $HOME displaypic] *.dat]
+ set files [concat $defaultfiles $cachefiles]
set pic_in_use ""
} else {
- set cachefiles [glob -nocomplain -directory [file
join $HOME displaypic cache] *.dat]
+ set files [glob -nocomplain -directory [file join
$HOME displaypic cache] *.dat]
set pic_in_use [::abook::getContactData $email
displaypicfile ""]
+ set l -1
}
#TODO: put in order of time
# use: [file atime $file] (the last acces time in seconds from a
fixed point > not available on FAT)
@@ -80,7 +84,8 @@
set email ""
}
- foreach file $cachefiles {
+ set j 0
+ foreach file $files {
#exclude the image the user is currently
using
if { $options(-picinuse) != "no" ||
[string first $pic_in_use $file] == -1 } {
set fd [open $file]
@@ -112,8 +117,14 @@
# bind $entry.img <Enter>
"showtooltip %X %Y [filenoext $file].png"
# bind $entry.img <Leave>
"showtooltip %X %Y [filenoext $file].png"
- label $entry.text -text [lindex
$greps 1] -bg $color
+ if { $j < $l } {
+ label $entry.text -bg
$color
+ } else {
+ label $entry.text -text
[lindex $greps 1] -bg $color
+ }
+ status_log "Image $file; Label
[lindex $greps 1]"
+
pack $entry.img $entry.text -side
top
grid $entry \
-row [expr {$i /
$dps_per_row}] -column [expr {$i % $dps_per_row}] \
@@ -123,6 +134,7 @@
}
close $fd
}
+ incr j
}
if {$i == 0} {
This was sent by the SourceForge.net collaborative development platform,
the world's largest Open Source development site.
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share
your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Amsn-commits mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/amsn-commits
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Amsn-devel mailing list
Amsn-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/amsn-devel