more similar handling of InputSequenceChecker as in other places
Change-Id: Ia6efc0eda03dac87c73e720d08f320ce3fc6ce4a
This commit is contained in:
@@ -86,6 +86,8 @@ private:
|
|||||||
Link maUpdateDataHdl;
|
Link maUpdateDataHdl;
|
||||||
Link maAutocompleteHdl;
|
Link maAutocompleteHdl;
|
||||||
|
|
||||||
|
css::uno::Reference < css::i18n::XExtendedInputSequenceChecker > mxISC;
|
||||||
|
|
||||||
DECL_DLLPRIVATE_LINK( ImplUpdateDataHdl, void* );
|
DECL_DLLPRIVATE_LINK( ImplUpdateDataHdl, void* );
|
||||||
|
|
||||||
SAL_DLLPRIVATE bool ImplTruncateToMaxLen( OUString&, sal_Int32 nSelectionLen ) const;
|
SAL_DLLPRIVATE bool ImplTruncateToMaxLen( OUString&, sal_Int32 nSelectionLen ) const;
|
||||||
@@ -112,7 +114,7 @@ private:
|
|||||||
SAL_DLLPRIVATE void ImplCopy( ::com::sun::star::uno::Reference< ::com::sun::star::datatransfer::clipboard::XClipboard >& rxClipboard );
|
SAL_DLLPRIVATE void ImplCopy( ::com::sun::star::uno::Reference< ::com::sun::star::datatransfer::clipboard::XClipboard >& rxClipboard );
|
||||||
SAL_DLLPRIVATE void ImplPaste( ::com::sun::star::uno::Reference< ::com::sun::star::datatransfer::clipboard::XClipboard >& rxClipboard );
|
SAL_DLLPRIVATE void ImplPaste( ::com::sun::star::uno::Reference< ::com::sun::star::datatransfer::clipboard::XClipboard >& rxClipboard );
|
||||||
SAL_DLLPRIVATE long ImplGetTextYPosition() const;
|
SAL_DLLPRIVATE long ImplGetTextYPosition() const;
|
||||||
SAL_DLLPRIVATE ::com::sun::star::uno::Reference < ::com::sun::star::i18n::XExtendedInputSequenceChecker > ImplGetInputSequenceChecker() const;
|
SAL_DLLPRIVATE ::com::sun::star::uno::Reference < ::com::sun::star::i18n::XExtendedInputSequenceChecker > ImplGetInputSequenceChecker();
|
||||||
SAL_DLLPRIVATE ::com::sun::star::uno::Reference < ::com::sun::star::i18n::XBreakIterator > ImplGetBreakIterator() const;
|
SAL_DLLPRIVATE ::com::sun::star::uno::Reference < ::com::sun::star::i18n::XBreakIterator > ImplGetBreakIterator() const;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
@@ -104,6 +104,7 @@ private:
|
|||||||
|
|
||||||
::com::sun::star::lang::Locale maLocale;
|
::com::sun::star::lang::Locale maLocale;
|
||||||
::com::sun::star::uno::Reference< ::com::sun::star::i18n::XBreakIterator > mxBreakIterator;
|
::com::sun::star::uno::Reference< ::com::sun::star::i18n::XBreakIterator > mxBreakIterator;
|
||||||
|
css::uno::Reference < css::i18n::XExtendedInputSequenceChecker > mxISC;
|
||||||
|
|
||||||
Rectangle maInvalidRect;
|
Rectangle maInvalidRect;
|
||||||
Range maInvalidRange;
|
Range maInvalidRange;
|
||||||
@@ -159,7 +160,7 @@ protected:
|
|||||||
// gets not exported. First and seconf parameter swapped to have a different signatur.
|
// gets not exported. First and seconf parameter swapped to have a different signatur.
|
||||||
SAL_DLLPRIVATE TextPaM ImpInsertText( sal_Unicode c, const TextSelection& rSel, sal_Bool bOverwrite = sal_False, sal_Bool bIsUserInput = sal_False );
|
SAL_DLLPRIVATE TextPaM ImpInsertText( sal_Unicode c, const TextSelection& rSel, sal_Bool bOverwrite = sal_False, sal_Bool bIsUserInput = sal_False );
|
||||||
// some other new functions needed that must not be exported to remain compatible
|
// some other new functions needed that must not be exported to remain compatible
|
||||||
SAL_DLLPRIVATE ::com::sun::star::uno::Reference < ::com::sun::star::i18n::XExtendedInputSequenceChecker > GetInputSequenceChecker() const;
|
SAL_DLLPRIVATE ::com::sun::star::uno::Reference < ::com::sun::star::i18n::XExtendedInputSequenceChecker > GetInputSequenceChecker();
|
||||||
SAL_DLLPRIVATE sal_Bool IsInputSequenceCheckingRequired( sal_Unicode c, const TextSelection& rCurSel ) const;
|
SAL_DLLPRIVATE sal_Bool IsInputSequenceCheckingRequired( sal_Unicode c, const TextSelection& rCurSel ) const;
|
||||||
|
|
||||||
// broadcast or adjust selections
|
// broadcast or adjust selections
|
||||||
|
@@ -834,18 +834,14 @@ uno::Reference < i18n::XBreakIterator > Edit::ImplGetBreakIterator() const
|
|||||||
}
|
}
|
||||||
// -----------------------------------------------------------------------
|
// -----------------------------------------------------------------------
|
||||||
|
|
||||||
uno::Reference < i18n::XExtendedInputSequenceChecker > Edit::ImplGetInputSequenceChecker() const
|
uno::Reference < i18n::XExtendedInputSequenceChecker > Edit::ImplGetInputSequenceChecker()
|
||||||
{
|
{
|
||||||
//!! since we don't want to become incompatible in the next minor update
|
if ( !mxISC.is() )
|
||||||
//!! where this code will get integrated into, xISC will be a local
|
|
||||||
//!! variable instead of a class member!
|
|
||||||
uno::Reference < i18n::XExtendedInputSequenceChecker > xISC;
|
|
||||||
// if ( !xISC.is() )
|
|
||||||
{
|
{
|
||||||
uno::Reference< uno::XComponentContext > xContext = ::comphelper::getProcessComponentContext();
|
mxISC = i18n::InputSequenceChecker::create(
|
||||||
xISC = i18n::InputSequenceChecker::create(xContext);
|
::comphelper::getProcessComponentContext() );
|
||||||
}
|
}
|
||||||
return xISC;
|
return mxISC;
|
||||||
}
|
}
|
||||||
|
|
||||||
// -----------------------------------------------------------------------
|
// -----------------------------------------------------------------------
|
||||||
|
@@ -628,15 +628,14 @@ void TextEngine::ImpRemoveParagraph( sal_uLong nPara )
|
|||||||
ImpParagraphRemoved( nPara );
|
ImpParagraphRemoved( nPara );
|
||||||
}
|
}
|
||||||
|
|
||||||
uno::Reference < i18n::XExtendedInputSequenceChecker > TextEngine::GetInputSequenceChecker() const
|
uno::Reference < i18n::XExtendedInputSequenceChecker > TextEngine::GetInputSequenceChecker()
|
||||||
{
|
{
|
||||||
uno::Reference < i18n::XExtendedInputSequenceChecker > xISC;
|
if ( !mxISC.is() )
|
||||||
// if ( !xISC.is() )
|
|
||||||
{
|
{
|
||||||
uno::Reference< uno::XComponentContext > xContext = ::comphelper::getProcessComponentContext();
|
mxISC = i18n::InputSequenceChecker::create(
|
||||||
xISC = i18n::InputSequenceChecker::create(xContext);
|
::comphelper::getProcessComponentContext() );
|
||||||
}
|
}
|
||||||
return xISC;
|
return mxISC;
|
||||||
}
|
}
|
||||||
|
|
||||||
sal_Bool TextEngine::IsInputSequenceCheckingRequired( sal_Unicode c, const TextSelection& rCurSel ) const
|
sal_Bool TextEngine::IsInputSequenceCheckingRequired( sal_Unicode c, const TextSelection& rCurSel ) const
|
||||||
|
Reference in New Issue
Block a user