[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-core-devel
Subject:    [PATCH] KDateTable::contentsMousePressedEvent()
From:       Jason Harris <jharris () 30doradus ! org>
Date:       2002-09-18 1:07:09
[Download RAW message or body]

Hello,

I've noticed that when I click on a date in a KDatePicker, it selects the date 
directly below the clicked date.  The attached patch fixes it, but I'm not 
familiar enough with the code to know if such a simple fix is OK.  Please 
test and commit, if it checks out.

thanks,
Jason
-- 
Jason Harris
jharris@30doradus.org

["kdatetbl.diff" (text/x-diff)]

Index: kdatetbl.cpp
===================================================================
RCS file: /home/kde/kdelibs/kdeui/kdatetbl.cpp,v
retrieving revision 1.48
diff -u -3 -p -r1.48 kdatetbl.cpp
--- kdatetbl.cpp        2002/08/30 09:35:59     1.48
+++ kdatetbl.cpp        2002/09/18 01:03:23
@@ -311,7 +311,7 @@ KDateTable::contentsMousePressEvent(QMou
   QPoint mouseCoord;
   // -----
   mouseCoord = e->pos();
-  row=rowAt(mouseCoord.y());
+  row=rowAt(mouseCoord.y())-1;
   col=columnAt(mouseCoord.x());
   if(row<0 || col<0)
     { // the user clicked on the frame of the table


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic