summaryrefslogtreecommitdiff
path: root/sc/source/ui/view/tabvwsh4.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'sc/source/ui/view/tabvwsh4.cxx')
-rw-r--r--sc/source/ui/view/tabvwsh4.cxx70
1 files changed, 68 insertions, 2 deletions
diff --git a/sc/source/ui/view/tabvwsh4.cxx b/sc/source/ui/view/tabvwsh4.cxx
index 8f041791e80b..5021e7effdbd 100644
--- a/sc/source/ui/view/tabvwsh4.cxx
+++ b/sc/source/ui/view/tabvwsh4.cxx
@@ -93,6 +93,9 @@
#include "sc.hrc" //CHINA001
#include "scabstdlg.hxx" //CHINA001
#include "externalrefmgr.hxx"
+//IAccessibility2 Implementation 2009-----
+#include <svx/fmpage.hxx>
+//-----IAccessibility2 Implementation 2009
void ActivateOlk( ScViewData* pViewData );
void DeActivateOlk( ScViewData* pViewData );
@@ -112,7 +115,9 @@ sal_uInt16 ScTabViewShell::nInsObjCtrlState = SID_INSERT_DIAGRAM;
void __EXPORT ScTabViewShell::Activate(sal_Bool bMDI)
{
SfxViewShell::Activate(bMDI);
-
+//IAccessibility2 Implementation 2009-----
+ bIsActive = sal_True;
+//-----IAccessibility2 Implementation 2009
// hier kein GrabFocus, sonst gibt's Probleme wenn etwas inplace editiert wird!
if ( bMDI )
@@ -240,7 +245,9 @@ void __EXPORT ScTabViewShell::Deactivate(sal_Bool bMDI)
}
SfxViewShell::Deactivate(bMDI);
-
+//IAccessibility2 Implementation 2009-----
+ bIsActive = sal_False;
+//-----IAccessibility2 Implementation 2009
ScInputHandler* pHdl = SC_MOD()->GetInputHdl(this);
if( bMDI )
@@ -1479,6 +1486,52 @@ sal_Bool ScTabViewShell::TabKeyInput(const KeyEvent& rKEvt)
}
}
+//IAccessibility2 Implementation 2009-----
+ // use Ctrl+Alt+Shift+arrow keys to move the cursor in cells
+ // while keeping the last selection
+ if ( !bUsed && bAlt && bControl && bShift)
+ {
+ sal_uInt16 nSlotId = 0;
+ switch (nCode)
+ {
+ case KEY_UP:
+ nSlotId = SID_CURSORUP;
+ break;
+ case KEY_DOWN:
+ nSlotId = SID_CURSORDOWN;
+ break;
+ case KEY_LEFT:
+ nSlotId = SID_CURSORLEFT;
+ break;
+ case KEY_RIGHT:
+ nSlotId = SID_CURSORRIGHT;
+ break;
+ case KEY_PAGEUP:
+ nSlotId = SID_CURSORPAGEUP;
+ break;
+ case KEY_PAGEDOWN:
+ nSlotId = SID_CURSORPAGEDOWN;
+ break;
+ case KEY_HOME:
+ nSlotId = SID_CURSORHOME;
+ break;
+ case KEY_END:
+ nSlotId = SID_CURSOREND;
+ break;
+ default:
+ nSlotId = 0;
+ break;
+ }
+ if ( nSlotId )
+ {
+ sal_uInt16 nMode = GetLockedModifiers();
+ LockModifiers(KEY_MOD1);
+ GetViewData()->GetDispatcher().Execute( nSlotId, SFX_CALLMODE_SLOT | SFX_CALLMODE_RECORD );
+ LockModifiers(nMode);
+ bUsed = sal_True;
+ }
+ }
+//-----IAccessibility2 Implementation 2009
if (bHideCursor)
ShowAllCursors();
@@ -1554,6 +1607,9 @@ void ScTabViewShell::Construct( sal_uInt8 nForceDesignMode )
ScDocument* pDoc = pDocSh->GetDocument();
bReadOnly = pDocSh->IsReadOnly();
+//IAccessibility2 Implementation 2009-----
+ bIsActive = sal_False;
+//-----IAccessibility2 Implementation 2009
SetName( String::CreateFromAscii(RTL_CONSTASCII_STRINGPARAM("View")) ); // fuer SBX
Color aColBlack( COL_BLACK );
@@ -1979,3 +2035,13 @@ void ScTabViewShell::GetTbxState( SfxItemSet& rSet )
+//IAccessibility2 Implementation 2009-----
+const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface > & ScTabViewShell::GetForms() const
+{
+ if( !pFormShell || !pFormShell->GetCurPage() ){
+ static ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface > aRef;
+ return aRef;
+ }
+ return pFormShell->GetCurPage()->GetForms();
+}
+//-----IAccessibility2 Implementation 2009