[cheese/cheese-vala] Some fixes for vala 0.7.5



commit a31f6714396cf98aa21cbcfca6c4e40479600c83
Author: Jaap A. Haitsma <jaap haitsma org>
Date:   Mon Aug 3 07:33:12 2009 +0200

    Some fixes for vala 0.7.5

 src/cheese-flash.vala      |    4 ++--
 src/cheese-thumb-view.vala |    6 +++---
 2 files changed, 5 insertions(+), 5 deletions(-)
---
diff --git a/src/cheese-flash.vala b/src/cheese-flash.vala
index 7ed7612..2bc388e 100644
--- a/src/cheese-flash.vala
+++ b/src/cheese-flash.vala
@@ -31,13 +31,13 @@ public class Cheese.Flash : GLib.Object {
 	const uint FLASH_DURATION = 250;
 
 	/* The factor which defines how much the flash fades per frame */
-	const float FLASH_FADE_FACTOR = 0.95;
+	const float FLASH_FADE_FACTOR = 0.95f;
 
 	/* How many frames per second */
 	const uint FLASH_ANIMATION_RATE = 50;
 
 	/* When to consider the flash finished so we can stop fading */
-	const float FLASH_LOW_THRESHOLD = 0.01;
+	const float FLASH_LOW_THRESHOLD = 0.01f;
 
 	Gtk.Window window;
 	uint flash_timeout_tag;
diff --git a/src/cheese-thumb-view.vala b/src/cheese-thumb-view.vala
index 280bf4c..a88d16a 100644
--- a/src/cheese-thumb-view.vala
+++ b/src/cheese-thumb-view.vala
@@ -51,7 +51,7 @@ public class Cheese.ThumbView : IconView {
 		set_size_request (-1, THUMB_VIEW_HEIGHT);
 
 		var dir = File.new_for_path (media_dir);
-		dir_monitor = FileMonitor.directory (dir, 0, null); 
+		dir_monitor = dir.monitor_directory (0, null); 
 		dir_monitor.changed += on_file_changed;
 		set_pixbuf_column (0);
 		set_columns (int.MAX);
@@ -121,8 +121,8 @@ public class Cheese.ThumbView : IconView {
 			return;
 		}
 
-		var mtime = new TimeVal ();
-		file_info.get_modification_time (mtime);
+		TimeVal mtime;
+		file_info.get_modification_time (out mtime);
 		
 		var uri = file.get_uri();
 		var mime_type = file_info.get_content_type ();



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]