summaryrefslogtreecommitdiff
path: root/sc/source/ui/inc/AccessibleSpreadsheet.hxx
diff options
context:
space:
mode:
authorSteve Yin <steve_y@apache.org>2013-12-02 15:54:29 +0000
committerCaolán McNamara <caolanm@redhat.com>2013-12-02 16:41:08 +0000
commitb41332475783c31136673fb44cf4c411bb0148f8 (patch)
tree39ba57867ed6ae3f39e60c38180f800542067b49 /sc/source/ui/inc/AccessibleSpreadsheet.hxx
parent23fdf75cd6e6cb37bfeac08f503a15d07d9beda9 (diff)
Integrate branch of IAccessible2
Conflicts: everything Change-Id: I3d8cf956f511a0d953a1cefe83b6ef987806da25
Diffstat (limited to 'sc/source/ui/inc/AccessibleSpreadsheet.hxx')
-rw-r--r--sc/source/ui/inc/AccessibleSpreadsheet.hxx57
1 files changed, 57 insertions, 0 deletions
diff --git a/sc/source/ui/inc/AccessibleSpreadsheet.hxx b/sc/source/ui/inc/AccessibleSpreadsheet.hxx
index 132f7e0eb090..56749beda960 100644
--- a/sc/source/ui/inc/AccessibleSpreadsheet.hxx
+++ b/sc/source/ui/inc/AccessibleSpreadsheet.hxx
@@ -26,6 +26,9 @@
#include <vector>
+#include "rangelst.hxx"
+#include <map>
+
class ScMyAddress : public ScAddress
{
public:
@@ -232,6 +235,15 @@ public:
const ::com::sun::star::uno::Reference<
::com::sun::star::accessibility::XAccessibleEventListener>& xListener)
throw (com::sun::star::uno::RuntimeException);
+ //===== XAccessibleTableSelection ============================================
+ virtual sal_Bool SAL_CALL selectRow( sal_Int32 row )
+ throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::uno::RuntimeException) ;
+ virtual sal_Bool SAL_CALL selectColumn( sal_Int32 column )
+ throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::uno::RuntimeException) ;
+ virtual sal_Bool SAL_CALL unselectRow( sal_Int32 row )
+ throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::uno::RuntimeException) ;
+ virtual sal_Bool SAL_CALL unselectColumn( sal_Int32 column )
+ throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::uno::RuntimeException) ;
protected:
/// Return the object's current bounding box relative to the desktop.
@@ -272,6 +284,51 @@ private:
ScDocument* GetDocument(ScTabViewShell* pViewShell);
Rectangle GetVisArea(ScTabViewShell* pViewShell, ScSplitPos eSplitPos);
Rectangle GetVisCells(const Rectangle& rVisArea);
+ typedef std::vector<ScMyAddress> VEC_MYADDR;
+
+ typedef std::map<ScMyAddress,com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible > >
+ MAP_ADDR_XACC;
+ MAP_ADDR_XACC m_mapSelectionSend;
+ void RemoveSelection(ScMarkData &refScMarkData);
+ sal_Bool IsSameMarkCell();
+ void CommitFocusCell(const ScAddress &aNewCell);
+public:
+ void FireFirstCellFocus();
+private:
+ sal_Bool m_bFormulaMode;
+ sal_Bool m_bFormulaLastMode;
+ ScAddress m_aFormulaActiveCell;
+ MAP_ADDR_XACC m_mapFormulaSelectionSend;
+ VEC_MYADDR m_vecFormulaLastMyAddr;
+ ScAccessibleCell* m_pAccFormulaCell;
+ sal_uInt16 m_nMinX;
+ sal_uInt16 m_nMaxX;
+ sal_Int32 m_nMinY;
+ sal_Int32 m_nMaxY;
+ sal_Int32 GetRowAll() const { return m_nMaxY - m_nMinY + 1 ; }
+ sal_uInt16 GetColAll() const { return m_nMaxX - m_nMinX + 1; }
+ void NotifyRefMode();
+ void RemoveFormulaSelection(sal_Bool bRemoveAll =sal_False);
+ sal_Bool CheckChildIndex(sal_Int32)const ;
+ ScAddress GetChildIndexAddress(sal_Int32) const;
+ sal_Int32 GetAccessibleIndexFormula( sal_Int32 nRow, sal_Int32 nColumn );
+ sal_Bool GetFormulaCurrentFocusCell(ScAddress &addr);
+public:
+ sal_Bool IsScAddrFormulaSel (const ScAddress &addr) const ;
+ sal_Bool IsFormulaMode() ;
+ ::com::sun::star::uno::Reference < ::com::sun::star::accessibility::XAccessible > GetActiveCell();
+ ScRange m_aLastWithInMarkRange;
+ OUString m_strCurCellValue;
+ ScRangeList m_LastMarkedRanges;
+ typedef std::vector<ScRange*> VEC_RANGE;
+ VEC_RANGE m_vecTempRange;
+ typedef std::pair<sal_uInt16,sal_uInt16> PAIR_COL;
+ typedef std::vector<PAIR_COL> VEC_COL;
+ VEC_COL m_vecTempCol;
+ ScMyAddress CalcScAddressFromRangeList(ScRangeList *pMarkedRanges,sal_Int32 nSelectedChildIndex);
+ sal_Bool CalcScRangeDifferenceMax(ScRange *pSrc,ScRange *pDest,int nMax,VEC_MYADDR &vecRet,int &nSize);
+ sal_Bool CalcScRangeListDifferenceMax(ScRangeList *pSrc,ScRangeList *pDest,int nMax,VEC_MYADDR &vecRet);
+ OUString m_strOldTabName;
};
#endif