summaryrefslogtreecommitdiff
path: root/framework/inc
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2015-04-15 09:36:39 +0200
committerNoel Grandin <noelgrandin@gmail.com>2015-04-17 07:21:08 +0000
commita7b7c64afc523cfd9ff4e724b3efbec6567fc1c8 (patch)
tree52fd05ef3292f3dab172864cbc3be96a8d44a9d0 /framework/inc
parentadd7eeb7dbd0eefa0c5ae5430490864079add801 (diff)
convert SCRIPTTYPE_ constants to scoped enum
Change-Id: I5be3980ac865162d8d7626556ca47eca4b0ee433 Reviewed-on: https://gerrit.libreoffice.org/15344 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'framework/inc')
-rw-r--r--framework/inc/helper/mischelper.hxx11
-rw-r--r--framework/inc/uielement/langselectionmenucontroller.hxx8
2 files changed, 7 insertions, 12 deletions
diff --git a/framework/inc/helper/mischelper.hxx b/framework/inc/helper/mischelper.hxx
index 406de7ae2529..6868237e9fc4 100644
--- a/framework/inc/helper/mischelper.hxx
+++ b/framework/inc/helper/mischelper.hxx
@@ -38,11 +38,6 @@
#include <set>
-// flags for script types in use within selection
-#define LS_SCRIPT_LATIN 0x0001
-#define LS_SCRIPT_ASIAN 0x0002
-#define LS_SCRIPT_COMPLEX 0x0004
-
namespace framework
{
@@ -79,9 +74,9 @@ enum LangMenuIDs
MID_LANG_PARA_MORE,
};
-inline bool IsScriptTypeMatchingToLanguage( sal_Int16 nScriptType, LanguageType nLang )
+inline bool IsScriptTypeMatchingToLanguage( SvtScriptType nScriptType, LanguageType nLang )
{
- return 0 != (nScriptType & SvtLanguageOptions::GetScriptTypeOfLanguage( nLang ));
+ return bool(nScriptType & SvtLanguageOptions::GetScriptTypeOfLanguage( nLang ));
}
inline void RetrieveTypeNameFromResourceURL( const OUString& aResourceURL, OUString& aType, OUString& aName )
@@ -135,7 +130,7 @@ FWI_DLLPUBLIC OUString RetrieveLabelFromCommand( const OUString& aCmdURL
FWI_DLLPUBLIC void FillLangItems( std::set< OUString > &rLangItems,
const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame > &rxFrame,
const LanguageGuessingHelper & rLangGuessHelper,
- sal_Int16 nScriptType,
+ SvtScriptType nScriptType,
const OUString & rCurLang,
const OUString & rKeyboardLang,
const OUString & rGuessedTextLang );
diff --git a/framework/inc/uielement/langselectionmenucontroller.hxx b/framework/inc/uielement/langselectionmenucontroller.hxx
index 38246ecea298..8a0f46b06a22 100644
--- a/framework/inc/uielement/langselectionmenucontroller.hxx
+++ b/framework/inc/uielement/langselectionmenucontroller.hxx
@@ -84,10 +84,10 @@ namespace framework
::com::sun::star::uno::Reference< ::com::sun::star::frame::XDispatch > m_xMenuDispatch_Font;
OUString m_aMenuCommandURL_CharDlgForParagraph;
::com::sun::star::uno::Reference< ::com::sun::star::frame::XDispatch > m_xMenuDispatch_CharDlgForParagraph;
- OUString m_aCurLang;
- sal_Int16 m_nScriptType;
- OUString m_aKeyboardLang;
- OUString m_aGuessedTextLang;
+ OUString m_aCurLang;
+ SvtScriptType m_nScriptType;
+ OUString m_aKeyboardLang;
+ OUString m_aGuessedTextLang;
LanguageGuessingHelper m_aLangGuessHelper;
void fillPopupMenu( com::sun::star::uno::Reference< com::sun::star::awt::XPopupMenu >& rPopupMenu, const Mode rMode );