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

loplugin:unusedmethods

Change-Id: I6f976ba8f792d2cee34859e9258798351eed8b1d
Reviewed-on: https://gerrit.libreoffice.org/52636Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarNoel Grandin <noel.grandin@collabora.co.uk>
üst 3edfbb08
...@@ -833,66 +833,6 @@ uno::Reference < embed::XEmbeddedObject > EmbeddedObjectContainer::CopyAndGetEmb ...@@ -833,66 +833,6 @@ uno::Reference < embed::XEmbeddedObject > EmbeddedObjectContainer::CopyAndGetEmb
return xResult; return xResult;
} }
void EmbeddedObjectContainer::MoveEmbeddedObject( EmbeddedObjectContainer& rSrc, const uno::Reference < embed::XEmbeddedObject >& xObj, OUString& rName )
{
// get the object name before(!) it is assigned to a new storage
uno::Reference < embed::XEmbedPersist > xPersist( xObj, uno::UNO_QUERY );
OUString aName;
if ( xPersist.is() )
aName = xPersist->getEntryName();
// now move the object to the new container; the returned name is the new persist name in this container
bool bRet;
try
{
bRet = InsertEmbeddedObject( xObj, rName );
if ( bRet )
TryToCopyGraphReplacement( rSrc, aName, rName );
}
catch (const uno::Exception&)
{
SAL_WARN( "comphelper.container", "Failed to insert embedded object into storage!" );
bRet = false;
}
if ( bRet )
{
// now remove the object from the former container
bRet = false;
EmbeddedObjectContainerNameMap::iterator aEnd = rSrc.pImpl->maObjectContainer.end();
for( EmbeddedObjectContainerNameMap::iterator aIter = rSrc.pImpl->maObjectContainer.begin();
aIter != aEnd;
++aIter )
{
if ( aIter->second == xObj )
{
rSrc.pImpl->maObjectContainer.erase( aIter );
bRet = true;
break;
}
}
SAL_WARN_IF( !bRet, "comphelper.container", "Object not found for removal!" );
if ( xPersist.is() )
{
// now it's time to remove the storage from the container storage
try
{
if ( xPersist.is() )
rSrc.pImpl->mxStorage->removeElement( aName );
}
catch (const uno::Exception&)
{
SAL_WARN( "comphelper.container", "Failed to remove object from storage!" );
bRet = false;
}
}
// rSrc.RemoveGraphicStream( aName );
}
}
// #i119941, bKeepToTempStorage: use to specify whether store the removed object to temporary storage+ // #i119941, bKeepToTempStorage: use to specify whether store the removed object to temporary storage+
void EmbeddedObjectContainer::RemoveEmbeddedObject( const OUString& rName, bool bKeepToTempStorage ) void EmbeddedObjectContainer::RemoveEmbeddedObject( const OUString& rName, bool bKeepToTempStorage )
{ {
......
...@@ -414,11 +414,6 @@ OutputDevice* Outliner::GetRefDevice() const ...@@ -414,11 +414,6 @@ OutputDevice* Outliner::GetRefDevice() const
return pEditEngine->GetRefDevice(); return pEditEngine->GetRefDevice();
} }
sal_uLong Outliner::GetTextHeight( sal_Int32 nParagraph ) const
{
return pEditEngine->GetTextHeight(nParagraph );
}
tools::Rectangle Outliner::GetParaBounds( sal_Int32 nParagraph ) const tools::Rectangle Outliner::GetParaBounds( sal_Int32 nParagraph ) const
{ {
return pEditEngine->GetParaBounds(nParagraph ); return pEditEngine->GetParaBounds(nParagraph );
...@@ -429,11 +424,6 @@ Point Outliner::GetDocPos( const Point& rPaperPos ) const ...@@ -429,11 +424,6 @@ Point Outliner::GetDocPos( const Point& rPaperPos ) const
return pEditEngine->GetDocPos( rPaperPos ); return pEditEngine->GetDocPos( rPaperPos );
} }
Point Outliner::GetDocPosTopLeft( sal_Int32 nParagraph )
{
return pEditEngine->GetDocPosTopLeft( nParagraph );
}
bool Outliner::IsTextPos( const Point& rPaperPos, sal_uInt16 nBorder ) bool Outliner::IsTextPos( const Point& rPaperPos, sal_uInt16 nBorder )
{ {
return IsTextPos( rPaperPos, nBorder, nullptr ); return IsTextPos( rPaperPos, nBorder, nullptr );
......
...@@ -129,9 +129,6 @@ public: ...@@ -129,9 +129,6 @@ public:
EmbeddedObjectContainer& rSrc, const css::uno::Reference <css::embed::XEmbeddedObject>& xObj, OUString& rName, EmbeddedObjectContainer& rSrc, const css::uno::Reference <css::embed::XEmbeddedObject>& xObj, OUString& rName,
const OUString& rSrcShellID, const OUString& rDestShellID ); const OUString& rSrcShellID, const OUString& rDestShellID );
// move an embedded object from one container to another one
void MoveEmbeddedObject( EmbeddedObjectContainer& rSrc, const css::uno::Reference < css::embed::XEmbeddedObject >&, OUString& );
// remove an embedded object from the container and from the storage; if object can't be closed // remove an embedded object from the container and from the storage; if object can't be closed
// #i119941, bKeepToTempStorage: use to specify whether store the removed object to temporary storage+ // #i119941, bKeepToTempStorage: use to specify whether store the removed object to temporary storage+
void RemoveEmbeddedObject( const OUString& rName, bool bKeepToTempStorage = true); void RemoveEmbeddedObject( const OUString& rName, bool bKeepToTempStorage = true);
......
...@@ -930,9 +930,7 @@ public: ...@@ -930,9 +930,7 @@ public:
OutputDevice* GetRefDevice() const; OutputDevice* GetRefDevice() const;
sal_uLong GetTextHeight() const; sal_uLong GetTextHeight() const;
sal_uLong GetTextHeight( sal_Int32 nParagraph ) const;
tools::Rectangle GetParaBounds( sal_Int32 nParagraph ) const; tools::Rectangle GetParaBounds( sal_Int32 nParagraph ) const;
Point GetDocPosTopLeft( sal_Int32 nParagraph );
Point GetDocPos( const Point& rPaperPos ) const; Point GetDocPos( const Point& rPaperPos ) const;
bool IsTextPos( const Point& rPaperPos, sal_uInt16 nBorder ); bool IsTextPos( const Point& rPaperPos, sal_uInt16 nBorder );
bool IsTextPos( const Point& rPaperPos, sal_uInt16 nBorder, bool* pbBulletPos ); bool IsTextPos( const Point& rPaperPos, sal_uInt16 nBorder, bool* pbBulletPos );
......
...@@ -108,7 +108,6 @@ class SVT_DLLPUBLIC URLBox ...@@ -108,7 +108,6 @@ class SVT_DLLPUBLIC URLBox
std::unique_ptr<weld::ComboBoxText> m_xWidget; std::unique_ptr<weld::ComboBoxText> m_xWidget;
SVT_DLLPRIVATE bool ProcessKey( const vcl::KeyCode& rCode );
DECL_DLLPRIVATE_LINK( TryAutoComplete, Timer*, void); DECL_DLLPRIVATE_LINK( TryAutoComplete, Timer*, void);
SVT_DLLPRIVATE void UpdatePicklistForSmartProtocol_Impl(); SVT_DLLPRIVATE void UpdatePicklistForSmartProtocol_Impl();
DECL_DLLPRIVATE_LINK( ChangedHdl, weld::ComboBoxText&, void); DECL_DLLPRIVATE_LINK( ChangedHdl, weld::ComboBoxText&, void);
...@@ -124,27 +123,13 @@ public: ...@@ -124,27 +123,13 @@ public:
void Clear() { m_xWidget->clear(); } void Clear() { m_xWidget->clear(); }
void connect_entry_activate(const Link<weld::ComboBoxText&, void>& rLink) { m_xWidget->connect_entry_activate(rLink); } void connect_entry_activate(const Link<weld::ComboBoxText&, void>& rLink) { m_xWidget->connect_entry_activate(rLink); }
void append_text(const OUString& rStr) { m_xWidget->append_text(rStr); } void append_text(const OUString& rStr) { m_xWidget->append_text(rStr); }
OUString get_text(int nIndex) { return m_xWidget->get_text(nIndex); }
void select_entry_region(int nStartPos, int nEndPos) { m_xWidget->select_entry_region(nStartPos, nEndPos); }
void EnableAutocomplete() { m_xWidget->set_entry_completion(true); } void EnableAutocomplete() { m_xWidget->set_entry_completion(true); }
void SetBaseURL( const OUString& rURL );
const OUString& GetBaseURL() const { return aBaseURL; }
void SetOnlyDirectories( bool bDir );
INetProtocol GetSmartProtocol() const { return eSmartProtocol; } INetProtocol GetSmartProtocol() const { return eSmartProtocol; }
void SetSmartProtocol( INetProtocol eProt );
OUString GetURL(); OUString GetURL();
void DisableHistory();
void UpdatePickList( );
static OUString ParseSmart( const OUString& aText, const OUString& aBaseURL ); static OUString ParseSmart( const OUString& aText, const OUString& aBaseURL );
void SetFilter(const OUString& _sFilter);
void SetPlaceHolder( const OUString& sPlaceHolder )
{ aPlaceHolder = sPlaceHolder; }
const OUString& GetPlaceHolder() { return aPlaceHolder; }
bool MatchesPlaceHolder( const OUString& sToMatch ) const bool MatchesPlaceHolder( const OUString& sToMatch ) const
{ return ( !aPlaceHolder.isEmpty() ) && ( aPlaceHolder == sToMatch ); } { return ( !aPlaceHolder.isEmpty() ) && ( aPlaceHolder == sToMatch ); }
}; };
......
...@@ -114,7 +114,6 @@ public: ...@@ -114,7 +114,6 @@ public:
SdrLayerAdmin(const SdrLayerAdmin& rSrcLayerAdmin); SdrLayerAdmin(const SdrLayerAdmin& rSrcLayerAdmin);
~SdrLayerAdmin(); ~SdrLayerAdmin();
SdrLayerAdmin& operator=(const SdrLayerAdmin& rSrcLayerAdmin); SdrLayerAdmin& operator=(const SdrLayerAdmin& rSrcLayerAdmin);
void SetParent(SdrLayerAdmin* pNewParent) { pParent=pNewParent; }
void SetModel(SdrModel* pNewModel); void SetModel(SdrModel* pNewModel);
void InsertLayer(SdrLayer* pLayer, sal_uInt16 nPos) void InsertLayer(SdrLayer* pLayer, sal_uInt16 nPos)
{ {
......
...@@ -51,7 +51,6 @@ private: ...@@ -51,7 +51,6 @@ private:
private: private:
SVX_DLLPRIVATE void Connect_Impl(); SVX_DLLPRIVATE void Connect_Impl();
SVX_DLLPRIVATE void Disconnect_Impl(); SVX_DLLPRIVATE void Disconnect_Impl();
SVX_DLLPRIVATE void Reconnect_Impl();
SVX_DLLPRIVATE void AddListeners_Impl(); SVX_DLLPRIVATE void AddListeners_Impl();
SVX_DLLPRIVATE void RemoveListeners_Impl(); SVX_DLLPRIVATE void RemoveListeners_Impl();
SVX_DLLPRIVATE void GetObjRef_Impl(); SVX_DLLPRIVATE void GetObjRef_Impl();
......
...@@ -67,8 +67,6 @@ public: ...@@ -67,8 +67,6 @@ public:
virtual void dispose() = 0; virtual void dispose() = 0;
virtual void modelChanged( SdrModel* pNewModel ) = 0;
protected: protected:
~SvxShapeMaster() {} ~SvxShapeMaster() {}
}; };
......
...@@ -1679,17 +1679,4 @@ uno::Sequence< OUString > SAL_CALL SdUnoEventsAccess::getSupportedServiceNames( ...@@ -1679,17 +1679,4 @@ uno::Sequence< OUString > SAL_CALL SdUnoEventsAccess::getSupportedServiceNames(
return aStr; return aStr;
} }
void SdXShape::modelChanged( SdrModel* pNewModel )
{
if( pNewModel )
{
uno::Reference< uno::XInterface > xModel( pNewModel->getUnoModel() );
mpModel = SdXImpressDocument::getImplementation( xModel );
}
else
{
mpModel = nullptr;
}
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
...@@ -72,7 +72,6 @@ public: ...@@ -72,7 +72,6 @@ public:
virtual bool queryAggregation( const css::uno::Type & rType, css::uno::Any& aAny ) override; virtual bool queryAggregation( const css::uno::Type & rType, css::uno::Any& aAny ) override;
virtual void dispose() override; virtual void dispose() override;
virtual void modelChanged( SdrModel* pNewModel ) override;
// XInterface // XInterface
virtual css::uno::Any SAL_CALL queryInterface( const css::uno::Type & rType ) override; virtual css::uno::Any SAL_CALL queryInterface( const css::uno::Type & rType ) override;
......
...@@ -2056,31 +2056,6 @@ URLBox::~URLBox() ...@@ -2056,31 +2056,6 @@ URLBox::~URLBox()
} }
} }
void URLBox::UpdatePickList( )
{
if (pCtx.is())
{
pCtx->Stop();
pCtx->join();
pCtx.clear();
}
OUString sText = m_xWidget->get_active_text();
if (!sText.isEmpty())
{
pCtx = new MatchContext_Impl( this, sText );
pCtx->launch();
}
}
void URLBox::SetSmartProtocol( INetProtocol eProt )
{
if ( eSmartProtocol != eProt )
{
eSmartProtocol = eProt;
UpdatePicklistForSmartProtocol_Impl();
}
}
void URLBox::UpdatePicklistForSmartProtocol_Impl() void URLBox::UpdatePicklistForSmartProtocol_Impl()
{ {
m_xWidget->clear(); m_xWidget->clear();
...@@ -2165,13 +2140,6 @@ IMPL_LINK_NOARG(URLBox, FocusOutHdl, weld::Widget&, void) ...@@ -2165,13 +2140,6 @@ IMPL_LINK_NOARG(URLBox, FocusOutHdl, weld::Widget&, void)
} }
} }
void URLBox::SetOnlyDirectories( bool bDir )
{
bOnlyDirectories = bDir;
if (bOnlyDirectories)
m_xWidget->clear();
}
OUString URLBox::GetURL() OUString URLBox::GetURL()
{ {
// wait for end of autocompletion // wait for end of autocompletion
...@@ -2250,28 +2218,4 @@ OUString URLBox::GetURL() ...@@ -2250,28 +2218,4 @@ OUString URLBox::GetURL()
return aObj.GetMainURL( INetURLObject::DecodeMechanism::NONE ); return aObj.GetMainURL( INetURLObject::DecodeMechanism::NONE );
} }
void URLBox::DisableHistory()
{
bHistoryDisabled = true;
UpdatePicklistForSmartProtocol_Impl();
}
void URLBox::SetBaseURL( const OUString& rURL )
{
::osl::MutexGuard aGuard( theSvtMatchContextMutex::get() );
// Reset match lists
pImpl->aCompletions.clear();
pImpl->aURLs.clear();
aBaseURL = rURL;
}
void URLBox::SetFilter(const OUString& _sFilter)
{
pImpl->m_aFilters.clear();
FilterMatch::createWildCardFilterList(_sFilter,pImpl->m_aFilters);
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
...@@ -931,12 +931,6 @@ void SdrOle2Obj::CheckFileLink_Impl() ...@@ -931,12 +931,6 @@ void SdrOle2Obj::CheckFileLink_Impl()
} }
} }
void SdrOle2Obj::Reconnect_Impl()
{
DBG_ASSERT( mpImpl->mbConnected, "Assigned unconnected object?!" );
Connect_Impl();
}
void SdrOle2Obj::Connect_Impl() void SdrOle2Obj::Connect_Impl()
{ {
if(!mpImpl->aPersistName.isEmpty() ) if(!mpImpl->aPersistName.isEmpty() )
......
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