[f-spot: 4/40] wip
- From: Stephane Delcroix <sdelcroix src gnome org>
- To: svn-commits-list gnome org
- Subject: [f-spot: 4/40] wip
- Date: Wed, 24 Jun 2009 09:48:02 +0000 (UTC)
commit a65db78c2c089ef4ef3ff104e37dca8a7ac5ee03
Author: Stephane Delcroix <stephane delcroix org>
Date: Wed Jun 17 16:45:14 2009 +0200
wip
src/ImageLoader.cs | 5 +++++
src/Imaging/JpegFile.cs | 2 ++
src/PhotoImageView.cs | 7 +++----
3 files changed, 10 insertions(+), 4 deletions(-)
---
diff --git a/src/ImageLoader.cs b/src/ImageLoader.cs
index 7a9a388..2d699b8 100644
--- a/src/ImageLoader.cs
+++ b/src/ImageLoader.cs
@@ -72,6 +72,11 @@ namespace FSpot {
public bool Prepared {
get { return prepared; }
}
+
+ PixbufOrientation pixbuf_orientation;
+ public PixbufOrientation PixbufOrientation {
+ get { return pixbuf_orientation; }
+ }
#endregion
#region event handlers
diff --git a/src/Imaging/JpegFile.cs b/src/Imaging/JpegFile.cs
index f54fadf..c513d38 100644
--- a/src/Imaging/JpegFile.cs
+++ b/src/Imaging/JpegFile.cs
@@ -271,7 +271,9 @@ namespace FSpot {
System.Console.WriteLine ("error checking orientation");
}
#else
+Console.WriteLine (">>>");
Exif.ExifEntry e = this.ExifData.GetContents (Exif.Ifd.Zero).Lookup (Exif.Tag.Orientation);
+Console.WriteLine ("<<<");
if (e != null) {
ushort [] value = e.GetDataUShort ();
diff --git a/src/PhotoImageView.cs b/src/PhotoImageView.cs
index 0df8535..c957915 100644
--- a/src/PhotoImageView.cs
+++ b/src/PhotoImageView.cs
@@ -83,7 +83,7 @@ namespace FSpot.Widgets {
public void HandleOrientationChanged (object sender, EventArgs e)
{
- Reload ();
+ PixbufOrientation = Accelerometer.GetViewOrientation (PixbufOrientation);
}
public void Reload ()
@@ -139,9 +139,8 @@ namespace FSpot.Widgets {
return;
Gdk.Pixbuf prev = this.Pixbuf;
- Gdk.Pixbuf next = loader.Pixbuf;
-
- this.Pixbuf = next;
+ this.Pixbuf = loader.Pixbuf;
+ PixbufOrientation = Accelerometer.GetViewOrientation (loader.PixbufOrientation);
if (prev != null)
prev.Dispose ();
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]