[xiph-cvs] cvs commit: snatch snatch.pl

Monty xiphmont at xiph.org
Wed Nov 7 19:55:14 PST 2001



xiphmont    01/11/07 19:55:14

  Modified:    .        snatch.pl
  Log:
  Incremental commit

Revision  Changes    Path
1.8       +19 -10    snatch/snatch.pl

Index: snatch.pl
===================================================================
RCS file: /usr/local/cvsroot/snatch/snatch.pl,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- snatch.pl	2001/11/08 03:41:49	1.7
+++ snatch.pl	2001/11/08 03:55:13	1.8
@@ -181,6 +181,9 @@
 $toplevel->optionAdd("$Xname*Entry.relief",  "sunken",20);
 $toplevel->optionAdd("$Xname*Entry.borderWidth",  2,20);
 
+$toplevel->optionAdd("$Xname*ListBox.background",  "#ffffff",20);
+$toplevel->optionAdd("$Xname*ListBox.relief",  "sunken",20);
+$toplevel->optionAdd("$Xname*ListBox.borderWidth",  1,20);
 $toplevel->optionAdd("$Xname*ListFrame.background",  "#ffffff",20);
 $toplevel->optionAdd("$Xname*ListRowOdd.background",  "#dfffe7",20);
 $toplevel->optionAdd("$Xname*ListRowEven.background",  "#ffffff",20);
@@ -1092,7 +1095,7 @@
                           "2001","Dec","12","Tues","12:00","2 hours","rtsp://blah7")->
                               place(-x=>5,-y=>5,-relheight=>1.0,-relwidth=>1.0,
                                     -width=>-$timerw_delete->reqwidth()-15,
-				    -height=>-$timerw_quit->reqheight()-30,
+				    -height=>-10,
                                     -bordermode=>outside);
     
     $minwidth=500;
@@ -1213,23 +1216,29 @@
 
 sub yview{
     my$this=shift;
-    
+    my$moveto_p=shift;
+    my$moveto=shift;
+
     my$paneheight=$this->{pane}->height();
     my$listheight=$this->{window}->height();
 
-    my$first=-$this->{window}->y()/$listheight;
-    my$second=(-$this->{window}->y()+$paneheight)/$listheight;
+    if($moveto_p=~/moveto/){
+	my$y=int($moveto*$listheight);
+	$y=$listheight-$paneheight if($y+$paneheight>$listheight);
+	$y=0 if($y<0);
 
-    print "$first $second\n";
-    ($first,$second);
-
+	$this->{window}->place(-y=>-$y);
+	$this->{scrollbar}->set($this->yview());
+    }else{
+	my$first=-$this->{window}->y()/$listheight;
+	my$second=(-$this->{window}->y()+$paneheight)/$listheight;
+    
+	($first,$second);
+    }
 }
 
 sub resize{
     my$this=shift;
-
-    print "resize\n";
-    
     $this->{scrollbar}->set($this->yview());
 }
 # eg

--- >8 ----
List archives:  http://www.xiph.org/archives/
Ogg project homepage: http://www.xiph.org/ogg/
To unsubscribe from this list, send a message to 'cvs-request at xiph.org'
containing only the word 'unsubscribe' in the body.  No subject is needed.
Unsubscribe messages sent to the list will be ignored/filtered.



More information about the commits mailing list