diff options
-rw-r--r-- | sc/source/ui/inc/cellsh.hxx | 3 | ||||
-rw-r--r-- | sc/source/ui/view/cellsh.cxx | 3 | ||||
-rw-r--r-- | sc/source/ui/view/cellsh1.cxx | 26 |
3 files changed, 5 insertions, 27 deletions
diff --git a/sc/source/ui/inc/cellsh.hxx b/sc/source/ui/inc/cellsh.hxx index 20cea7d49c3d..b7cc54f5b7ef 100644 --- a/sc/source/ui/inc/cellsh.hxx +++ b/sc/source/ui/inc/cellsh.hxx @@ -33,6 +33,7 @@ #include "shellids.hxx" #include <sfx2/module.hxx> #include <svx/svdmark.hxx> +#include <unotools/caserotate.hxx> #include <tools/link.hxx> #include "formatsh.hxx" #include "address.hxx" @@ -72,7 +73,7 @@ private: DECL_LINK( ClipboardChanged, TransferableDataHelper* ); DECL_LINK( DialogClosed, AbstractScLinkedAreaDlg* ); - sal_uInt32 nF3ShiftCounter; + RotateTransliteration m_aRotateCase; public: diff --git a/sc/source/ui/view/cellsh.cxx b/sc/source/ui/view/cellsh.cxx index a7ec42c615c5..209fff0eae38 100644 --- a/sc/source/ui/view/cellsh.cxx +++ b/sc/source/ui/view/cellsh.cxx @@ -86,8 +86,7 @@ SFX_IMPL_INTERFACE(ScCellShell, ScFormatShell , ScResId(SCSTR_CELLSHELL) ) ScCellShell::ScCellShell(ScViewData* pData) : ScFormatShell(pData), pImpl( new CellShell_Impl() ), - bPastePossible(false), - nF3ShiftCounter(0) + bPastePossible(false) { SetHelpId(HID_SCSHELL_CELLSH); SetName(String::CreateFromAscii(RTL_CONSTASCII_STRINGPARAM("Cell"))); diff --git a/sc/source/ui/view/cellsh1.cxx b/sc/source/ui/view/cellsh1.cxx index fc81ed555e28..730af70e1f5a 100644 --- a/sc/source/ui/view/cellsh1.cxx +++ b/sc/source/ui/view/cellsh1.cxx @@ -2094,30 +2094,8 @@ void ScCellShell::ExecuteTrans( SfxRequest& rReq ) void ScCellShell::ExecuteRotateTrans( SfxRequest& rReq ) { - using namespace ::com::sun::star::i18n; - { - sal_uInt32 nMode = 0; - - if( rReq.GetSlot() == SID_TRANSLITERATE_ROTATE_CASE ) { - switch ( nF3ShiftCounter ) { - case 0: - nMode = TransliterationModulesExtra::TITLE_CASE; - break; - case 1: - nMode = TransliterationModules_LOWERCASE_UPPERCASE; - break; - case 2: - nMode = TransliterationModules_UPPERCASE_LOWERCASE; - nF3ShiftCounter = -1; - break; - } - - if ( nMode ) - GetViewData()->GetView()->TransliterateText( nMode ); - - nF3ShiftCounter++; - } - } + if( rReq.GetSlot() == SID_TRANSLITERATE_ROTATE_CASE ) + GetViewData()->GetView()->TransliterateText( m_aRotateCase.getNextMode() ); } void ScCellShell::ExecuteExternalSource( |