loplugin:unusedmethods unused return value in basctl
Change-Id: I23590020acbb9a6760edd755affa121a572aaea5
This commit is contained in:
parent
aae44c09d3
commit
1b26a4eb4b
@ -363,36 +363,36 @@ bool ModulWindow::BasicExecute()
|
||||
return bDone;
|
||||
}
|
||||
|
||||
bool ModulWindow::CompileBasic()
|
||||
void ModulWindow::CompileBasic()
|
||||
{
|
||||
CheckCompileBasic();
|
||||
|
||||
return XModule().Is() && xModule->IsCompiled();
|
||||
XModule().Is() && xModule->IsCompiled();
|
||||
}
|
||||
|
||||
bool ModulWindow::BasicRun()
|
||||
void ModulWindow::BasicRun()
|
||||
{
|
||||
aStatus.nBasicFlags = 0;
|
||||
return BasicExecute();
|
||||
BasicExecute();
|
||||
}
|
||||
|
||||
bool ModulWindow::BasicStepOver()
|
||||
void ModulWindow::BasicStepOver()
|
||||
{
|
||||
aStatus.nBasicFlags = SbDEBUG_STEPINTO | SbDEBUG_STEPOVER;
|
||||
return BasicExecute();
|
||||
BasicExecute();
|
||||
}
|
||||
|
||||
|
||||
bool ModulWindow::BasicStepInto()
|
||||
void ModulWindow::BasicStepInto()
|
||||
{
|
||||
aStatus.nBasicFlags = SbDEBUG_STEPINTO;
|
||||
return BasicExecute();
|
||||
BasicExecute();
|
||||
}
|
||||
|
||||
bool ModulWindow::BasicStepOut()
|
||||
void ModulWindow::BasicStepOut()
|
||||
{
|
||||
aStatus.nBasicFlags = SbDEBUG_STEPOUT;
|
||||
return BasicExecute();
|
||||
BasicExecute();
|
||||
}
|
||||
|
||||
|
||||
@ -403,10 +403,8 @@ void ModulWindow::BasicStop()
|
||||
aStatus.bIsRunning = false;
|
||||
}
|
||||
|
||||
bool ModulWindow::LoadBasic()
|
||||
void ModulWindow::LoadBasic()
|
||||
{
|
||||
bool bDone = false;
|
||||
|
||||
Reference< uno::XComponentContext > xContext( ::comphelper::getProcessComponentContext() );
|
||||
Reference < XFilePicker3 > xFP = FilePicker::createWithMode(xContext, TemplateDescription::FILEOPEN_SIMPLE);
|
||||
|
||||
@ -438,20 +436,15 @@ bool ModulWindow::LoadBasic()
|
||||
sal_uLong nError = aMedium.GetError();
|
||||
if ( nError )
|
||||
ErrorHandler::HandleError( nError );
|
||||
else
|
||||
bDone = true;
|
||||
}
|
||||
else
|
||||
ScopedVclPtrInstance<MessageDialog>::Create(this, IDE_RESSTR(RID_STR_COULDNTREAD))->Execute();
|
||||
}
|
||||
return bDone;
|
||||
}
|
||||
|
||||
|
||||
bool ModulWindow::SaveBasicSource()
|
||||
void ModulWindow::SaveBasicSource()
|
||||
{
|
||||
bool bDone = false;
|
||||
|
||||
Reference< uno::XComponentContext > xContext( ::comphelper::getProcessComponentContext() );
|
||||
Reference < XFilePicker3 > xFP = FilePicker::createWithMode(xContext, TemplateDescription::FILESAVE_AUTOEXTENSION_PASSWORD);
|
||||
|
||||
@ -484,21 +477,17 @@ bool ModulWindow::SaveBasicSource()
|
||||
sal_uLong nError = aMedium.GetError();
|
||||
if ( nError )
|
||||
ErrorHandler::HandleError( nError );
|
||||
else
|
||||
bDone = true;
|
||||
}
|
||||
else
|
||||
ScopedVclPtrInstance<MessageDialog>::Create(this, IDEResId(RID_STR_COULDNTWRITE))->Execute();
|
||||
}
|
||||
|
||||
return bDone;
|
||||
}
|
||||
|
||||
bool ModulWindow::ImportDialog()
|
||||
void ModulWindow::ImportDialog()
|
||||
{
|
||||
const ScriptDocument& rDocument = GetDocument();
|
||||
OUString aLibName = GetLibName();
|
||||
return implImportDialog( this, aCurPath, rDocument, aLibName );
|
||||
implImportDialog( this, aCurPath, rDocument, aLibName );
|
||||
}
|
||||
|
||||
bool ModulWindow::ToggleBreakPoint( sal_uLong nLine )
|
||||
@ -559,7 +548,7 @@ void ModulWindow::UpdateBreakPoint( const BreakPoint& rBrk )
|
||||
}
|
||||
|
||||
|
||||
bool ModulWindow::BasicToggleBreakPoint()
|
||||
void ModulWindow::BasicToggleBreakPoint()
|
||||
{
|
||||
AssertValidEditEngine();
|
||||
|
||||
@ -567,16 +556,12 @@ bool ModulWindow::BasicToggleBreakPoint()
|
||||
aSel.GetStart().GetPara()++; // Basic lines start at 1!
|
||||
aSel.GetEnd().GetPara()++;
|
||||
|
||||
bool bNewBreakPoint = false;
|
||||
|
||||
for ( sal_uInt32 nLine = aSel.GetStart().GetPara(); nLine <= aSel.GetEnd().GetPara(); ++nLine )
|
||||
{
|
||||
if ( ToggleBreakPoint( nLine ) )
|
||||
bNewBreakPoint = true;
|
||||
ToggleBreakPoint( nLine );
|
||||
}
|
||||
|
||||
aXEditorWindow->GetBrkWindow().Invalidate();
|
||||
return bNewBreakPoint;
|
||||
}
|
||||
|
||||
|
||||
|
@ -152,7 +152,7 @@ public:
|
||||
void InitScrollBars();
|
||||
|
||||
void ForceSyntaxTimeout();
|
||||
bool SetSourceInBasic();
|
||||
void SetSourceInBasic();
|
||||
|
||||
bool CanModify() { return ImpCanModify(); }
|
||||
|
||||
@ -246,7 +246,7 @@ public:
|
||||
virtual void dispose() override;
|
||||
|
||||
void AddWatch( const OUString& rVName );
|
||||
bool RemoveSelectedWatch();
|
||||
void RemoveSelectedWatch();
|
||||
void UpdateWatches( bool bBasicStopped = false );
|
||||
};
|
||||
|
||||
@ -351,13 +351,13 @@ public:
|
||||
void SetSbModule( SbModule* pModule ) { xModule = pModule; }
|
||||
OUString GetSbModuleName();
|
||||
|
||||
bool CompileBasic();
|
||||
bool BasicRun();
|
||||
bool BasicStepOver();
|
||||
bool BasicStepInto();
|
||||
bool BasicStepOut();
|
||||
void CompileBasic();
|
||||
void BasicRun();
|
||||
void BasicStepOver();
|
||||
void BasicStepInto();
|
||||
void BasicStepOut();
|
||||
void BasicStop();
|
||||
bool BasicToggleBreakPoint();
|
||||
void BasicToggleBreakPoint();
|
||||
void BasicToggleBreakPointEnabled();
|
||||
void ManageBreakPoints();
|
||||
void UpdateBreakPoint( const BreakPoint& rBrk );
|
||||
@ -367,9 +367,9 @@ public:
|
||||
long BasicBreakHdl( StarBASIC* pBasic );
|
||||
void AssertValidEditEngine();
|
||||
|
||||
bool LoadBasic();
|
||||
bool SaveBasicSource();
|
||||
bool ImportDialog();
|
||||
void LoadBasic();
|
||||
void SaveBasicSource();
|
||||
void ImportDialog();
|
||||
|
||||
void EditMacro( const OUString& rMacroName );
|
||||
|
||||
|
@ -929,9 +929,8 @@ void EditorWindow::LoseFocus()
|
||||
Window::LoseFocus();
|
||||
}
|
||||
|
||||
bool EditorWindow::SetSourceInBasic()
|
||||
void EditorWindow::SetSourceInBasic()
|
||||
{
|
||||
bool bChanged = false;
|
||||
if ( pEditEngine && pEditEngine->IsModified()
|
||||
&& !GetEditView()->IsReadOnly() ) // Added for #i60626, otherwise
|
||||
// any read only bug in the text engine could lead to a crash later
|
||||
@ -939,10 +938,8 @@ bool EditorWindow::SetSourceInBasic()
|
||||
if ( !StarBASIC::IsRunning() ) // Not at runtime!
|
||||
{
|
||||
rModulWindow.UpdateModule();
|
||||
bChanged = true;
|
||||
}
|
||||
}
|
||||
return bChanged;
|
||||
}
|
||||
|
||||
// Returns the position of the last character of any of the following
|
||||
@ -1763,7 +1760,7 @@ void WatchWindow::AddWatch( const OUString& rVName )
|
||||
UpdateWatches();
|
||||
}
|
||||
|
||||
bool WatchWindow::RemoveSelectedWatch()
|
||||
void WatchWindow::RemoveSelectedWatch()
|
||||
{
|
||||
SvTreeListEntry* pEntry = aTreeListBox->GetCurEntry();
|
||||
if ( pEntry )
|
||||
@ -1776,10 +1773,7 @@ bool WatchWindow::RemoveSelectedWatch()
|
||||
aXEdit->SetText( OUString() );
|
||||
if ( !aTreeListBox->GetEntryCount() )
|
||||
aRemoveWatchButton->Disable();
|
||||
return true;
|
||||
}
|
||||
else
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
|
@ -675,10 +675,8 @@ void DialogWindow::UpdateBrowser()
|
||||
rLayout.UpdatePropertyBrowser();
|
||||
}
|
||||
|
||||
bool DialogWindow::SaveDialog()
|
||||
void DialogWindow::SaveDialog()
|
||||
{
|
||||
bool bDone = false;
|
||||
|
||||
Reference< XComponentContext > xContext( comphelper::getProcessComponentContext() );
|
||||
Reference < XFilePicker3 > xFP = FilePicker::createWithMode(xContext, TemplateDescription::FILESAVE_AUTOEXTENSION_PASSWORD);
|
||||
|
||||
@ -733,7 +731,6 @@ bool DialogWindow::SaveDialog()
|
||||
if (! nRead)
|
||||
break;
|
||||
}
|
||||
bDone = true;
|
||||
|
||||
// With resource?
|
||||
Reference< beans::XPropertySet > xDialogModelPropSet( xDialogModel, UNO_QUERY );
|
||||
@ -832,8 +829,6 @@ bool DialogWindow::SaveDialog()
|
||||
else
|
||||
ScopedVclPtrInstance<MessageDialog>::Create(this, IDE_RESSTR(RID_STR_COULDNTWRITE))->Execute();
|
||||
}
|
||||
|
||||
return bDone;
|
||||
}
|
||||
|
||||
std::vector< lang::Locale > implGetLanguagesOnlyContainedInFirstSeq
|
||||
@ -1211,11 +1206,11 @@ bool implImportDialog( vcl::Window* pWin, const OUString& rCurPath, const Script
|
||||
}
|
||||
|
||||
|
||||
bool DialogWindow::ImportDialog()
|
||||
void DialogWindow::ImportDialog()
|
||||
{
|
||||
const ScriptDocument& rDocument = GetDocument();
|
||||
OUString aLibName = GetLibName();
|
||||
return implImportDialog( this, aCurPath, rDocument, aLibName );
|
||||
implImportDialog( this, aCurPath, rDocument, aLibName );
|
||||
}
|
||||
|
||||
DlgEdModel& DialogWindow::GetModel() const
|
||||
|
@ -160,19 +160,6 @@ EntryDescriptor::EntryDescriptor (
|
||||
EntryDescriptor::~EntryDescriptor()
|
||||
{ }
|
||||
|
||||
bool EntryDescriptor::operator == (EntryDescriptor const& rDesc) const
|
||||
{
|
||||
return
|
||||
m_aDocument == rDesc.m_aDocument &&
|
||||
m_eLocation == rDesc.m_eLocation &&
|
||||
m_aLibName == rDesc.m_aLibName &&
|
||||
m_aLibSubName == rDesc.m_aLibSubName &&
|
||||
m_aName == rDesc.m_aName &&
|
||||
m_aMethodName == rDesc.m_aMethodName &&
|
||||
m_eType == rDesc.m_eType;
|
||||
}
|
||||
|
||||
|
||||
// TreeListBox
|
||||
|
||||
|
||||
|
@ -1447,9 +1447,9 @@ namespace basctl
|
||||
}
|
||||
|
||||
|
||||
bool ScriptDocument::saveDocument( const Reference< XStatusIndicator >& _rxStatusIndicator ) const
|
||||
void ScriptDocument::saveDocument( const Reference< XStatusIndicator >& _rxStatusIndicator ) const
|
||||
{
|
||||
return m_pImpl->saveDocument( _rxStatusIndicator );
|
||||
m_pImpl->saveDocument( _rxStatusIndicator );
|
||||
}
|
||||
|
||||
|
||||
|
@ -88,9 +88,8 @@ DlgEdFunc::~DlgEdFunc()
|
||||
{
|
||||
}
|
||||
|
||||
bool DlgEdFunc::MouseButtonDown( const MouseEvent& )
|
||||
void DlgEdFunc::MouseButtonDown( const MouseEvent& )
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
bool DlgEdFunc::MouseButtonUp( const MouseEvent& )
|
||||
@ -99,9 +98,8 @@ bool DlgEdFunc::MouseButtonUp( const MouseEvent& )
|
||||
return true;
|
||||
}
|
||||
|
||||
bool DlgEdFunc::MouseMove( const MouseEvent& )
|
||||
void DlgEdFunc::MouseMove( const MouseEvent& )
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
bool DlgEdFunc::KeyInput( const KeyEvent& rKEvt )
|
||||
@ -342,10 +340,10 @@ DlgEdFuncInsert::~DlgEdFuncInsert()
|
||||
rParent.GetView().SetEditMode();
|
||||
}
|
||||
|
||||
bool DlgEdFuncInsert::MouseButtonDown( const MouseEvent& rMEvt )
|
||||
void DlgEdFuncInsert::MouseButtonDown( const MouseEvent& rMEvt )
|
||||
{
|
||||
if( !rMEvt.IsLeft() )
|
||||
return true;
|
||||
return;
|
||||
|
||||
SdrView& rView = rParent.GetView();
|
||||
vcl::Window& rWindow = rParent.GetWindow();
|
||||
@ -377,8 +375,6 @@ bool DlgEdFuncInsert::MouseButtonDown( const MouseEvent& rMEvt )
|
||||
if ( rView.IsMarkedHit(aPos, nHitLog) && rParent.GetMode() != DlgEditor::READONLY )
|
||||
rParent.ShowProperties();
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
bool DlgEdFuncInsert::MouseButtonUp( const MouseEvent& rMEvt )
|
||||
@ -413,7 +409,7 @@ bool DlgEdFuncInsert::MouseButtonUp( const MouseEvent& rMEvt )
|
||||
}
|
||||
}
|
||||
|
||||
bool DlgEdFuncInsert::MouseMove( const MouseEvent& rMEvt )
|
||||
void DlgEdFuncInsert::MouseMove( const MouseEvent& rMEvt )
|
||||
{
|
||||
SdrView& rView = rParent.GetView();
|
||||
vcl::Window& rWindow = rParent.GetWindow();
|
||||
@ -429,8 +425,6 @@ bool DlgEdFuncInsert::MouseMove( const MouseEvent& rMEvt )
|
||||
}
|
||||
|
||||
rWindow.SetPointer( rView.GetPreferredPointer( aPos, &rWindow, nHitLog ) );
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
DlgEdFuncSelect::DlgEdFuncSelect (DlgEditor& rParent_) :
|
||||
@ -443,7 +437,7 @@ DlgEdFuncSelect::~DlgEdFuncSelect()
|
||||
{
|
||||
}
|
||||
|
||||
bool DlgEdFuncSelect::MouseButtonDown( const MouseEvent& rMEvt )
|
||||
void DlgEdFuncSelect::MouseButtonDown( const MouseEvent& rMEvt )
|
||||
{
|
||||
// get view from parent
|
||||
SdrView& rView = rParent.GetView();
|
||||
@ -501,8 +495,6 @@ bool DlgEdFuncSelect::MouseButtonDown( const MouseEvent& rMEvt )
|
||||
if ( rView.IsMarkedHit(aMDPos, nHitLog) && rParent.GetMode() != DlgEditor::READONLY )
|
||||
rParent.ShowProperties();
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
bool DlgEdFuncSelect::MouseButtonUp( const MouseEvent& rMEvt )
|
||||
@ -539,7 +531,7 @@ bool DlgEdFuncSelect::MouseButtonUp( const MouseEvent& rMEvt )
|
||||
return true;
|
||||
}
|
||||
|
||||
bool DlgEdFuncSelect::MouseMove( const MouseEvent& rMEvt )
|
||||
void DlgEdFuncSelect::MouseMove( const MouseEvent& rMEvt )
|
||||
{
|
||||
SdrView& rView = rParent.GetView();
|
||||
vcl::Window& rWindow = rParent.GetWindow();
|
||||
@ -558,8 +550,6 @@ bool DlgEdFuncSelect::MouseMove( const MouseEvent& rMEvt )
|
||||
}
|
||||
|
||||
rWindow.SetPointer( rView.GetPreferredPointer( aPnt, &rWindow, nHitLog ) );
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
} // namespace basctl
|
||||
|
@ -1672,9 +1672,8 @@ awt::DeviceInfo DlgEdForm::getDeviceInfo() const
|
||||
|
||||
return aDeviceInfo;
|
||||
}
|
||||
bool DlgEdObj::MakeDataAware( const Reference< frame::XModel >& xModel )
|
||||
void DlgEdObj::MakeDataAware( const Reference< frame::XModel >& xModel )
|
||||
{
|
||||
bool bRes = false;
|
||||
// Need to flesh this out, currently we will only support data-aware controls for calc
|
||||
// and only handle a subset of functionality e.g. linked-cell and cell range data source. Of course later
|
||||
// we need to disambiguate for writer ( and others ? ) and also support the generic form (db) bindings
|
||||
@ -1707,10 +1706,7 @@ bool DlgEdObj::MakeDataAware( const Reference< frame::XModel >& xModel )
|
||||
Reference< form::binding::XListEntrySource > xSource( xFac->createInstanceWithArguments( "com.sun.star.table.CellRangeListSource", aArgs ), UNO_QUERY );
|
||||
xListEntrySink->setListEntrySource( xSource );
|
||||
}
|
||||
if ( xListEntrySink.is() || xBindable.is() )
|
||||
bRes = true;
|
||||
}
|
||||
return bRes;
|
||||
}
|
||||
} // namespace basctl
|
||||
|
||||
|
@ -93,8 +93,8 @@ public:
|
||||
bool RenameDialog( const OUString& rNewName );
|
||||
void DisableBrowser();
|
||||
void UpdateBrowser();
|
||||
bool SaveDialog();
|
||||
bool ImportDialog();
|
||||
void SaveDialog();
|
||||
void ImportDialog();
|
||||
|
||||
virtual OUString GetTitle() override;
|
||||
virtual EntryDescriptor CreateEntryDescriptor() override;
|
||||
|
@ -141,8 +141,6 @@ public:
|
||||
);
|
||||
virtual ~EntryDescriptor ();
|
||||
|
||||
bool operator == (EntryDescriptor const& rDesc) const;
|
||||
|
||||
ScriptDocument const& GetDocument() const { return m_aDocument; }
|
||||
|
||||
LibraryLocation GetLocation() const { return m_eLocation; }
|
||||
|
@ -42,9 +42,9 @@ public:
|
||||
explicit DlgEdFunc (DlgEditor& rParent);
|
||||
virtual ~DlgEdFunc();
|
||||
|
||||
virtual bool MouseButtonDown( const MouseEvent& rMEvt );
|
||||
virtual void MouseButtonDown( const MouseEvent& rMEvt );
|
||||
virtual bool MouseButtonUp( const MouseEvent& rMEvt );
|
||||
virtual bool MouseMove( const MouseEvent& rMEvt );
|
||||
virtual void MouseMove( const MouseEvent& rMEvt );
|
||||
bool KeyInput( const KeyEvent& rKEvt );
|
||||
};
|
||||
|
||||
@ -58,9 +58,9 @@ public:
|
||||
explicit DlgEdFuncInsert (DlgEditor& rParent);
|
||||
virtual ~DlgEdFuncInsert ();
|
||||
|
||||
virtual bool MouseButtonDown( const MouseEvent& rMEvt ) override;
|
||||
virtual void MouseButtonDown( const MouseEvent& rMEvt ) override;
|
||||
virtual bool MouseButtonUp( const MouseEvent& rMEvt ) override;
|
||||
virtual bool MouseMove( const MouseEvent& rMEvt ) override;
|
||||
virtual void MouseMove( const MouseEvent& rMEvt ) override;
|
||||
};
|
||||
|
||||
|
||||
@ -76,9 +76,9 @@ public:
|
||||
explicit DlgEdFuncSelect (DlgEditor& rParent);
|
||||
virtual ~DlgEdFuncSelect ();
|
||||
|
||||
virtual bool MouseButtonDown( const MouseEvent& rMEvt ) override;
|
||||
virtual void MouseButtonDown( const MouseEvent& rMEvt ) override;
|
||||
virtual bool MouseButtonUp( const MouseEvent& rMEvt ) override;
|
||||
virtual bool MouseMove( const MouseEvent& rMEvt ) override;
|
||||
virtual void MouseMove( const MouseEvent& rMEvt ) override;
|
||||
};
|
||||
|
||||
|
||||
|
@ -128,7 +128,7 @@ public:
|
||||
void SAL_CALL _elementRemoved( const css::container::ContainerEvent& Event ) throw(css::uno::RuntimeException);
|
||||
|
||||
virtual void SetLayer(SdrLayerID nLayer) override;
|
||||
bool MakeDataAware( const css::uno::Reference< css::frame::XModel >& xModel );
|
||||
void MakeDataAware( const css::uno::Reference< css::frame::XModel >& xModel );
|
||||
};
|
||||
|
||||
|
||||
|
@ -457,7 +457,7 @@ namespace basctl
|
||||
@precond
|
||||
<code>isApplication</code> returns <FALSE/>
|
||||
*/
|
||||
bool saveDocument(
|
||||
void saveDocument(
|
||||
const css::uno::Reference< css::task::XStatusIndicator >& _rxStatusIndicator
|
||||
) const;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user