diff options
author | Steve Yin <steve_y@apache.org> | 2013-12-02 15:54:29 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2013-12-02 16:41:08 +0000 |
commit | b41332475783c31136673fb44cf4c411bb0148f8 (patch) | |
tree | 39ba57867ed6ae3f39e60c38180f800542067b49 /sc/source/ui/view/preview.cxx | |
parent | ditch _TPHFEDIT_CXX foo (diff) | |
download | core-b41332475783c31136673fb44cf4c411bb0148f8.tar.gz core-b41332475783c31136673fb44cf4c411bb0148f8.zip |
Integrate branch of IAccessible2
Conflicts:
everything
Change-Id: I3d8cf956f511a0d953a1cefe83b6ef987806da25
Diffstat (limited to 'sc/source/ui/view/preview.cxx')
-rw-r--r-- | sc/source/ui/view/preview.cxx | 23 |
1 files changed, 21 insertions, 2 deletions
diff --git a/sc/source/ui/view/preview.cxx b/sc/source/ui/view/preview.cxx index a5f77ea955fa..fbbf67a52642 100644 --- a/sc/source/ui/view/preview.cxx +++ b/sc/source/ui/view/preview.cxx @@ -1470,11 +1470,30 @@ void ScPreview::LoseFocus() com::sun::star::uno::Reference<com::sun::star::accessibility::XAccessible> ScPreview::CreateAccessible() { + com::sun::star::uno::Reference<com::sun::star::accessibility::XAccessible> xAcc= GetAccessible(sal_False); + if (xAcc.is()) + { + return xAcc; + } + ScAccessibleDocumentPagePreview* pAccessible = new ScAccessibleDocumentPagePreview( GetAccessibleParentWindow()->GetAccessible(), pViewShell ); - com::sun::star::uno::Reference < com::sun::star::accessibility::XAccessible > xAccessible = pAccessible; + + xAcc = pAccessible; + SetAccessible(xAcc); pAccessible->Init(); - return xAccessible; + return xAcc; +} + +// MT: Removed Windows::SwitchView() introduced with IA2 CWS. +// There are other notifications for this when the active view has chnaged, so please update the code to use that event mechanism +void ScPreview::SwitchView() +{ + ScAccessibleDocumentBase* pAccDoc = static_cast<ScAccessibleDocumentBase*>(GetAccessible(sal_False).get()); + if (pAccDoc) + { + pAccDoc->SwitchViewFireFocus(); + } } void ScPreview::DragMove( long nDragMovePos, sal_uInt16 nFlags ) |