Kaydet (Commit) b40068d5 authored tarafından Noel Grandin's avatar Noel Grandin

loplugin:unusedmethods

Change-Id: I73de303f93b3557881dbb84d6d11d89f193da010
Reviewed-on: https://gerrit.libreoffice.org/61868
Tested-by: Jenkins
Reviewed-by: 's avatarNoel Grandin <noel.grandin@collabora.co.uk>
üst 6d37ae12
......@@ -56,9 +56,6 @@ public:
bool IsOutliner() const
{ return bool( nControlBits & EEControlBits::OUTLINER ); }
bool IsOutliner2() const
{ return bool( nControlBits & EEControlBits::OUTLINER2 ); }
bool DoNotUseColors() const
{ return bool( nControlBits & EEControlBits::NOCOLORS ); }
......
......@@ -92,33 +92,14 @@ public:
virtual Size GetOptimalSize() const override;
virtual void Resize() override;
/** Returns true, if the control is not in "don't care" state. */
bool HasRotation() const;
/** Sets the control to "don't care" state. */
void SetNoRotation();
/** Returns the current rotation angle in 1/100 degrees. */
sal_Int32 GetRotation() const;
/** Sets the rotation to the passed value (in 1/100 degrees). */
void SetRotation( sal_Int32 nAngle );
/** Links the passed numeric edit field to the control (bi-directional).
* nDecimalPlaces:
* field value is unsign given decimal places
* default is 0 which means field values are in degrees,
* 2 means 100th of degree
*/
void SetLinkedField( NumericField* pField, sal_Int32 nDecimalPlaces = 0);
/** The passed handler is called whenever the rotation value changes. */
void SetModifyHdl( const Link<DialControl*,void>& rLink );
/** Save value for later comparison */
void SaveValue();
/** Compare value with the saved value */
bool IsValueModified();
protected:
struct DialControl_Impl
{
......
......@@ -69,14 +69,10 @@ OUString GetTableColName(sal_Int32 col);
OUString GetUnderlineName(enumXFUnderline type);
OUString GetReliefName(enumXFRelief type);
OUString GetCrossoutName(enumXFCrossout type);
OUString GetTransformName(enumXFTransform type);
OUString GetEmphasizeName(enumXFEmphasize type);
OUString GetTextDirName(enumXFTextDir dir);
OUString GetFrameXPos(enumXFFrameXPos pos);
......
......@@ -152,22 +152,6 @@ OUString GetUnderlineName(enumXFUnderline type)
return OUString();
}
OUString GetReliefName(enumXFRelief type)
{
switch(type)
{
case enumXFReliefEngraved:
return OUString("engraved");
break;
case enumXFReliefEmbossed:
return OUString("embossed");
break;
default:
break;
}
return OUString();
}
OUString GetCrossoutName(enumXFCrossout type)
{
switch(type)
......@@ -214,27 +198,6 @@ OUString GetTransformName(enumXFTransform type)
return OUString();
}
OUString GetEmphasizeName(enumXFEmphasize type)
{
switch(type) {
case enumXFEmphasizeDot:
return OUString("dot");
break;
case enumXFEmphasizeCircle:
return OUString("circle");
break;
case enumXFEmphasizeDisc:
return OUString("disc");
break;
case enumXFEmphasizeAccent:
return OUString("accent");
break;
default:
break;
}
return OUString();
}
OUString GetTextDirName(enumXFTextDir dir)
{
switch(dir)
......
......@@ -350,22 +350,6 @@ void DialControl::LoseFocus()
Control::LoseFocus();
}
bool DialControl::HasRotation() const
{
return !mpImpl->mbNoRot;
}
void DialControl::SetNoRotation()
{
if( !mpImpl->mbNoRot )
{
mpImpl->mbNoRot = true;
InvalidateControl();
if( mpImpl->mpLinkField )
mpImpl->mpLinkField->SetText( "" );
}
}
sal_Int32 DialControl::GetRotation() const
{
return mpImpl->mnAngle;
......@@ -381,26 +365,6 @@ void DialControl::SetRotation( sal_Int32 nAngle )
SetRotation( nAngle, false );
}
void DialControl::SetLinkedField( NumericField* pField, sal_Int32 nDecimalPlaces )
{
mpImpl->mnLinkedFieldValueMultiplyer = 100 / std::pow(10.0, double(nDecimalPlaces));
// remove modify handler from old linked field
if( mpImpl->mpLinkField )
{
NumericField& rField = *mpImpl->mpLinkField;
rField.SetModifyHdl( Link<Edit&,void>() );
}
// remember the new linked field
mpImpl->mpLinkField = pField;
// set modify handler at new linked field
if( mpImpl->mpLinkField )
{
NumericField& rField = *mpImpl->mpLinkField;
rField.SetModifyHdl( LINK( this, DialControl, LinkedFieldModifyHdl ) );
}
}
IMPL_LINK_NOARG( DialControl, LinkedFieldModifyHdl, Edit&, void )
{
LinkedFieldModifyHdl();
......@@ -413,16 +377,6 @@ void DialControl::LinkedFieldModifyHdl()
}
void DialControl::SaveValue()
{
mpImpl->mnInitialAngle = mpImpl->mnAngle;
}
bool DialControl::IsValueModified()
{
return mpImpl->mnInitialAngle != mpImpl->mnAngle;
}
void DialControl::SetModifyHdl( const Link<DialControl*,void>& rLink )
{
mpImpl->maModifyHdl = rLink;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment