Update of /cvsroot/audacity/audacity-src/src/widgets
In directory 23jxhf1.ch3.sourceforge.com:/tmp/cvs-serv16993

Modified Files:
        Grid.cpp 
Log Message:
Fix object location.

Index: Grid.cpp
===================================================================
RCS file: /cvsroot/audacity/audacity-src/src/widgets/Grid.cpp,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -d -r1.14 -r1.15
--- Grid.cpp    6 Jun 2009 19:08:26 -0000       1.14
+++ Grid.cpp    7 Jun 2009 03:01:57 -0000       1.15
@@ -669,19 +669,18 @@
 wxAccStatus GridAx::GetLocation(wxRect & rect, int elementId)
 {
    wxRect r;
+   int row;
+   int col;
 
-   if (elementId == wxACC_SELF) {
-      wxRect r = mGrid->GetGridCornerLabelWindow()->GetRect();
-      rect = mGrid->GetRect();
-      rect.x -= r.width;
-      rect.y -= r.height;
+   if (GetRowCol(elementId, row, col)) {
+      rect = mGrid->CellToRect(row, col);
+      
rect.SetPosition(mGrid->GetGridWindow()->ClientToScreen(rect.GetPosition()));
    }
    else {
-      rect = mGrid->CellToRect(mGrid->GetGridCursorRow(), 
mGrid->GetGridCursorCol());
+      rect = mGrid->GetRect();
+      rect.SetPosition(mGrid->GetParent()->ClientToScreen(rect.GetPosition()));
    }
 
-   
rect.SetPosition(mGrid->GetGridWindow()->ClientToScreen(rect.GetPosition()));
-
    return wxACC_OK;
 }
 


------------------------------------------------------------------------------
OpenSolaris 2009.06 is a cutting edge operating system for enterprises 
looking to deploy the next generation of Solaris that includes the latest 
innovations from Sun and the OpenSource community. Download a copy and 
enjoy capabilities such as Networking, Storage and Virtualization. 
Go to: http://p.sf.net/sfu/opensolaris-get
_______________________________________________
Audacity-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/audacity-cvs

Reply via email to