[pdfmod] Fix crash I recently introduced in DnD to open doc



commit 1377d7d70118ebbe85c92b282befe7d4c924fb99
Author: Gabriel Burt <gabriel burt gmail com>
Date:   Thu Sep 9 10:17:36 2010 -0500

    Fix crash I recently introduced in DnD to open doc

 src/PdfMod/Gui/DocumentIconView.cs |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/src/PdfMod/Gui/DocumentIconView.cs b/src/PdfMod/Gui/DocumentIconView.cs
index c9e8041..9f4579c 100644
--- a/src/PdfMod/Gui/DocumentIconView.cs
+++ b/src/PdfMod/Gui/DocumentIconView.cs
@@ -207,7 +207,7 @@ namespace PdfMod.Gui
         protected override bool OnDragMotion (Gdk.DragContext context, int x, int y, uint time_)
         {
             // Scroll if within 20 pixels of the top or bottom
-            var parent = Parent as Gtk.ScrolledWindow;
+            var parent = Parent.Parent as Gtk.ScrolledWindow;
             if (y < 20) {
                 parent.Vadjustment.Value -= 30;
             } else if ((parent.Allocation.Height - y) < 20) {



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