summaryrefslogtreecommitdiff
path: root/toolkit/source/controls/grid
diff options
context:
space:
mode:
authorFrank Schoenheit [fs] <frank.schoenheit@oracle.com>2011-01-11 14:00:09 +0100
committerFrank Schoenheit [fs] <frank.schoenheit@oracle.com>2011-01-11 14:00:09 +0100
commit0bbace39b3f04c82ec8d38ef6aedef7d14fcafc4 (patch)
treec6917b1344c6d02366b35428ce36279c4556aa4d /toolkit/source/controls/grid
parente73cc303e5201dc04c61a30572b80d3da13a2699 (diff)
gridsort: XGridControl: add methods to retrieve the current row/col
Diffstat (limited to 'toolkit/source/controls/grid')
-rw-r--r--toolkit/source/controls/grid/gridcontrol.cxx14
-rw-r--r--toolkit/source/controls/grid/gridcontrol.hxx4
2 files changed, 17 insertions, 1 deletions
diff --git a/toolkit/source/controls/grid/gridcontrol.cxx b/toolkit/source/controls/grid/gridcontrol.cxx
index 70afcc5c3a13..28a203b81c03 100644
--- a/toolkit/source/controls/grid/gridcontrol.cxx
+++ b/toolkit/source/controls/grid/gridcontrol.cxx
@@ -347,6 +347,20 @@ sal_Bool SAL_CALL UnoGridControl::setModel( const Reference< XControlModel >& i_
}
//----------------------------------------------------------------------------------------------------------------------
+::sal_Int32 SAL_CALL UnoGridControl::getCurrentColumn( ) throw (RuntimeException)
+{
+ Reference< XGridControl > const xGrid ( getPeer(), UNO_QUERY_THROW );
+ return xGrid->getCurrentColumn();
+}
+
+//----------------------------------------------------------------------------------------------------------------------
+::sal_Int32 SAL_CALL UnoGridControl::getCurrentRow( ) throw (RuntimeException)
+{
+ Reference< XGridControl > const xGrid ( getPeer(), UNO_QUERY_THROW );
+ return xGrid->getCurrentRow();
+}
+
+//----------------------------------------------------------------------------------------------------------------------
::sal_Int32 SAL_CALL UnoGridControl::getMinSelectionIndex() throw (::com::sun::star::uno::RuntimeException)
{
return Reference< XGridControl >( getPeer(), UNO_QUERY_THROW )->getMinSelectionIndex();
diff --git a/toolkit/source/controls/grid/gridcontrol.hxx b/toolkit/source/controls/grid/gridcontrol.hxx
index 6dfc5d71e639..cf832cb80705 100644
--- a/toolkit/source/controls/grid/gridcontrol.hxx
+++ b/toolkit/source/controls/grid/gridcontrol.hxx
@@ -97,8 +97,10 @@ public:
sal_Bool SAL_CALL setModel( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XControlModel >& rxModel ) throw(::com::sun::star::uno::RuntimeException);
// ::com::sun::star::awt::grid::XGridControl
- virtual ::sal_Int32 SAL_CALL getRowAtPoint(::sal_Int32 x, ::sal_Int32 y) throw (::com::sun::star::uno::RuntimeException);
virtual ::sal_Int32 SAL_CALL getColumnAtPoint(::sal_Int32 x, ::sal_Int32 y) throw (::com::sun::star::uno::RuntimeException);
+ virtual ::sal_Int32 SAL_CALL getRowAtPoint(::sal_Int32 x, ::sal_Int32 y) throw (::com::sun::star::uno::RuntimeException);
+ virtual ::sal_Int32 SAL_CALL getCurrentColumn( ) throw (::com::sun::star::uno::RuntimeException);
+ virtual ::sal_Int32 SAL_CALL getCurrentRow( ) throw (::com::sun::star::uno::RuntimeException);
// ::com::sun::star::awt::grid::XGridSelection
virtual ::sal_Int32 SAL_CALL getMinSelectionIndex() throw (::com::sun::star::uno::RuntimeException);