[Libreoffice-commits] core.git: include/svx svx/source
Noel Grandin (via logerrit)
logerrit at kemper.freedesktop.org
Wed Jul 24 12:40:13 UTC 2019
include/svx/DescriptionGenerator.hxx | 13 ---
svx/source/accessibility/DescriptionGenerator.cxx | 76 ----------------------
2 files changed, 1 insertion(+), 88 deletions(-)
New commits:
commit ba031cc41321c7817c5b23e0b5378e532f7e1dea
Author: Noel Grandin <noel.grandin at collabora.co.uk>
AuthorDate: Wed Jul 24 11:57:52 2019 +0200
Commit: Noel Grandin <noel.grandin at collabora.co.uk>
CommitDate: Wed Jul 24 14:38:59 2019 +0200
remove unused accessibility::DescriptionGenerator::PropertyType::FillStyle
Change-Id: I20005ad23088d41262ff988eac2132918db56ab8
Reviewed-on: https://gerrit.libreoffice.org/76236
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>
diff --git a/include/svx/DescriptionGenerator.hxx b/include/svx/DescriptionGenerator.hxx
index 8d3010ea5b94..7769a25dbe6a 100644
--- a/include/svx/DescriptionGenerator.hxx
+++ b/include/svx/DescriptionGenerator.hxx
@@ -44,8 +44,7 @@ public:
enum class PropertyType {
Color,
Integer,
- String,
- FillStyle
+ String
};
/** Creates a new description generator with an empty description
@@ -165,16 +164,6 @@ private:
*/
SVX_DLLPRIVATE void AddString (const OUString& sPropertyName,
const OUString& sLocalizedName, sal_uInt16 nWhichId);
-
- /** Add a property value formatted as fill style to the description
- string. If the fill style is <const>HATCH</const>,
- <const>GRADIENT</const>, or <const>BITMAP</const>, then the of the
- hatch, gradient, or bitmap is appended as well.
- @param sPropertyName
- Name of the property. Usually this will be "FillStyle".
- */
- SVX_DLLPRIVATE void AddFillStyle (const OUString& sPropertyName,
- const OUString& sLocalizedName);
};
diff --git a/svx/source/accessibility/DescriptionGenerator.cxx b/svx/source/accessibility/DescriptionGenerator.cxx
index cefe8e104fcc..ff5bb21f20eb 100644
--- a/svx/source/accessibility/DescriptionGenerator.cxx
+++ b/svx/source/accessibility/DescriptionGenerator.cxx
@@ -169,9 +169,6 @@ void DescriptionGenerator::AddProperty (const OUString& sPropertyName,
case PropertyType::String:
AddString (sPropertyName, sLocalizedName, nWhichId);
break;
- case PropertyType::FillStyle:
- AddFillStyle (sPropertyName, sLocalizedName);
- break;
}
}
}
@@ -266,79 +263,6 @@ void DescriptionGenerator::AddString (const OUString& sPropertyName,
}
-void DescriptionGenerator::AddFillStyle (const OUString& sPropertyName,
- const OUString& sLocalizedName)
-{
- msDescription.append(sLocalizedName);
- msDescription.append('=');
-
- try
- {
- if (mxSet.is())
- {
- uno::Any aValue = mxSet->getPropertyValue (sPropertyName);
- drawing::FillStyle aFillStyle;
- aValue >>= aFillStyle;
-
- // Get the fill style name from the resource.
- OUString sFillStyleName;
- {
- SolarMutexGuard aGuard;
- switch (aFillStyle)
- {
- case drawing::FillStyle_NONE:
- sFillStyleName = SvxResId(RID_SVXSTR_A11Y_FILLSTYLE_NONE);
- break;
- case drawing::FillStyle_SOLID:
- sFillStyleName = SvxResId(RID_SVXSTR_A11Y_FILLSTYLE_SOLID);
- break;
- case drawing::FillStyle_GRADIENT:
- sFillStyleName = SvxResId(RID_SVXSTR_A11Y_FILLSTYLE_GRADIENT);
- break;
- case drawing::FillStyle_HATCH:
- sFillStyleName = SvxResId(RID_SVXSTR_A11Y_FILLSTYLE_HATCH);
- break;
- case drawing::FillStyle_BITMAP:
- sFillStyleName = SvxResId(RID_SVXSTR_A11Y_FILLSTYLE_BITMAP);
- break;
- default:
- break;
- }
- }
- msDescription.append (sFillStyleName);
-
- // Append the appropriate properties.
- switch (aFillStyle)
- {
- case drawing::FillStyle_NONE:
- break;
- case drawing::FillStyle_SOLID:
- AddProperty ("FillColor", PropertyType::Color, SIP_XA_FILLCOLOR);
- break;
- case drawing::FillStyle_GRADIENT:
- AddProperty ("FillGradientName", PropertyType::String, SIP_XA_FILLGRADIENT,
- XATTR_FILLGRADIENT);
- break;
- case drawing::FillStyle_HATCH:
- AddProperty ("FillColor", PropertyType::Color, SIP_XA_FILLCOLOR);
- AddProperty ("FillHatchName", PropertyType::String, SIP_XA_FILLHATCH,
- XATTR_FILLHATCH);
- break;
- case drawing::FillStyle_BITMAP:
- AddProperty ("FillBitmapName", PropertyType::String, SIP_XA_FILLBITMAP,
- XATTR_FILLBITMAP);
- break;
- default:
- break;
- }
- }
- }
- catch (const css::beans::UnknownPropertyException &)
- {
- msDescription.append ("<unknown>");
- }
-}
-
} // end of namespace accessibility
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
More information about the Libreoffice-commits
mailing list