[Libreoffice-commits] core.git: editeng/inc editeng/source include/editeng

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Wed Dec 5 12:10:54 UTC 2018


 editeng/inc/edtspell.hxx            |    2 +-
 editeng/source/editeng/edtspell.cxx |    2 --
 editeng/source/items/textitem.cxx   |   10 ----------
 include/editeng/fontitem.hxx        |    2 --
 4 files changed, 1 insertion(+), 15 deletions(-)

New commits:
commit 4d725e38b5cb53d039dfb6db0940c91ce62ce746
Author:     Noel Grandin <noel.grandin at collabora.co.uk>
AuthorDate: Wed Dec 5 11:05:19 2018 +0200
Commit:     Noel Grandin <noel.grandin at collabora.co.uk>
CommitDate: Wed Dec 5 13:10:29 2018 +0100

    loplugin:singlevalfields in editeng
    
    Change-Id: I369090dd2da59e9227d633ff8390518d38769db1
    Reviewed-on: https://gerrit.libreoffice.org/64603
    Tested-by: Jenkins
    Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>

diff --git a/editeng/inc/edtspell.hxx b/editeng/inc/edtspell.hxx
index 82ed2f618e9d..53565fd71d9e 100644
--- a/editeng/inc/edtspell.hxx
+++ b/editeng/inc/edtspell.hxx
@@ -62,7 +62,7 @@ public:
  */
 class WrongList
 {
-    static size_t Valid;
+    static constexpr size_t Valid = std::numeric_limits<size_t>::max();
 
     std::vector<editeng::MisspellRange> maRanges;
     size_t mnInvalidStart;
diff --git a/editeng/source/editeng/edtspell.cxx b/editeng/source/editeng/edtspell.cxx
index db235d41d7d5..63b402ffad53 100644
--- a/editeng/source/editeng/edtspell.cxx
+++ b/editeng/source/editeng/edtspell.cxx
@@ -154,8 +154,6 @@ void EditSpellWrapper::CheckSpellTo()
     }
 }
 
-size_t WrongList::Valid = std::numeric_limits<size_t>::max();
-
 WrongList::WrongList() : mnInvalidStart(0), mnInvalidEnd(Valid) {}
 
 void WrongList::SetRanges( const std::vector<editeng::MisspellRange>& rRanges )
diff --git a/editeng/source/items/textitem.cxx b/editeng/source/items/textitem.cxx
index 483e83f657f7..69246c19d3aa 100644
--- a/editeng/source/items/textitem.cxx
+++ b/editeng/source/items/textitem.cxx
@@ -99,8 +99,6 @@
 using namespace ::com::sun::star;
 using namespace ::com::sun::star::text;
 
-bool SvxFontItem::bEnableStoreUnicodeNames = false;
-
 SfxPoolItem* SvxFontItem::CreateDefault() {return new SvxFontItem(0);}
 SfxPoolItem* SvxPostureItem::CreateDefault() { return new SvxPostureItem(ITALIC_NONE, 0);}
 SfxPoolItem* SvxWeightItem::CreateDefault() {return new SvxWeightItem(WEIGHT_NORMAL, 0);}
@@ -345,14 +343,6 @@ SvStream& SvxFontItem::Store( SvStream& rStrm , sal_uInt16 /*nItemVersion*/ ) co
     rStrm.WriteUniOrByteString(aStoreFamilyName, rStrm.GetStreamCharSet());
     rStrm.WriteUniOrByteString(GetStyleName(), rStrm.GetStreamCharSet());
 
-    // catch for EditEngine, only set while creating clipboard stream.
-    if ( bEnableStoreUnicodeNames )
-    {
-        rStrm.WriteUInt32( STORE_UNICODE_MAGIC_MARKER );
-        rStrm.WriteUniOrByteString( aStoreFamilyName, RTL_TEXTENCODING_UNICODE );
-        rStrm.WriteUniOrByteString( GetStyleName(), RTL_TEXTENCODING_UNICODE );
-    }
-
     return rStrm;
 }
 
diff --git a/include/editeng/fontitem.hxx b/include/editeng/fontitem.hxx
index 224ebf682002..3a226dfd3e3f 100644
--- a/include/editeng/fontitem.hxx
+++ b/include/editeng/fontitem.hxx
@@ -36,8 +36,6 @@ class EDITENG_DLLPUBLIC SvxFontItem : public SfxPoolItem
     FontPitch ePitch;
     rtl_TextEncoding eTextEncoding;
 
-    static bool bEnableStoreUnicodeNames;
-
 public:
     static SfxPoolItem* CreateDefault();
 


More information about the Libreoffice-commits mailing list