Skip to content

Commit

Permalink
Empty function removal (#3477)
Browse files Browse the repository at this point in the history
* [cleanup] Remove empty function `FindInFilesDialog::DoSetFileMask()`

* [cleanup] Remove empty function `CompilerLocatorMSYS2::AddTool`

* [cleanup] Remove empty function `GotoAnythingDlg::UpdateLastSearch()` and commented code

* [cleanup] Remove empty function `Project::UpgradeBuildSystem()`

* [cleanup] Remove empty function `wxTerminalCtrl::SendTab()`

* [cleanup] Remove empty function `wxcSettings::ShowNagDialogIfNeeded()`
  • Loading branch information
Jarod42 authored Oct 8, 2024
1 parent bf3c78c commit 68a98bb
Show file tree
Hide file tree
Showing 13 changed files with 1 addition and 51 deletions.
4 changes: 0 additions & 4 deletions LiteEditor/findinfilesdlg.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -164,8 +164,6 @@ FindInFilesDialog::FindInFilesDialog(wxWindow* parent, wxWindow* handler)
m_checkBoxFollowSymlinks->SetValue(!(m_data.files_scanner_flags & clFilesScanner::SF_DONT_FOLLOW_SYMLINKS));
m_checkBoxIncludeHiddenFolders->SetValue(!(m_data.files_scanner_flags & clFilesScanner::SF_EXCLUDE_HIDDEN_DIRS));

// Set the file mask
DoSetFileMask();
SetName("FindInFilesDialog");
CallAfter(&FindInFilesDialog::DoSelectAll);

Expand All @@ -178,8 +176,6 @@ FindInFilesDialog::FindInFilesDialog(wxWindow* parent, wxWindow* handler)

FindInFilesDialog::~FindInFilesDialog() { SaveFindReplaceData(); }

void FindInFilesDialog::DoSetFileMask() {}

void FindInFilesDialog::DoSearchReplace()
{
SearchData data = DoGetSearchData();
Expand Down
1 change: 0 additions & 1 deletion LiteEditor/findinfilesdlg.h
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@ class FindInFilesDialog : public FindInFilesDialogBase
void DoSearchReplace();
SearchData DoGetSearchData();
void DoSaveOpenFiles();
void DoSetFileMask();
void DoAddProjectFiles(const wxString& projectName, wxArrayString& files);
void DoSelectAll();

Expand Down
2 changes: 0 additions & 2 deletions Plugin/CompilerLocator/CompilerLocatorMSYS2.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -145,8 +145,6 @@ CompilerPtr CompilerLocatorMSYS2::Locate(const wxString& folder)
return nullptr;
}

void CompilerLocatorMSYS2::AddTool(const wxString& tool_name, const wxString& value) {}

wxFileName CompilerLocatorMSYS2::GetFileName(const wxString& bin_dir, const wxString& fullname) const
{
wxFileName tool(bin_dir, fullname);
Expand Down
1 change: 0 additions & 1 deletion Plugin/CompilerLocator/CompilerLocatorMSYS2.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ class WXDLLIMPEXP_SDK CompilerLocatorMSYS2 : public ICompilerLocator
wxString m_repository;

protected:
void AddTool(const wxString& tool_name, const wxString& value);
wxFileName GetFileName(const wxString& bin_dir, const wxString& fullname) const;

CompilerLocatorMSYS2();
Expand Down
3 changes: 0 additions & 3 deletions Plugin/GotoAnythingDlg.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ GotoAnythingDlg::GotoAnythingDlg(wxWindow* parent, const std::vector<clGotoEntry
, m_allEntries(entries)
{
DoPopulate(m_allEntries);
CallAfter(&GotoAnythingDlg::UpdateLastSearch);

::clSetDialogBestSizeAndPosition(this);
}
Expand Down Expand Up @@ -90,8 +89,6 @@ void GotoAnythingDlg::OnIdle(wxIdleEvent& e)
ApplyFilter();
}

void GotoAnythingDlg::UpdateLastSearch() {}

void GotoAnythingDlg::ApplyFilter()
{
// Create a list the matches the typed text
Expand Down
14 changes: 1 addition & 13 deletions Plugin/GotoAnythingDlg.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,6 @@

#include <vector>

// class WXDLLIMPEXP_SDK GotoAnythingItemData
// {
// public:
// wxString m_desc;
// GotoAnythingItemData(const wxString& desc)
// : m_desc(desc)
// {
// }
// ~GotoAnythingItemData() {}
// };
//
class WXDLLIMPEXP_SDK GotoAnythingDlg : public GotoAnythingBaseDlg
{
const std::vector<clGotoEntry>& m_allEntries;
Expand All @@ -28,10 +17,9 @@ class WXDLLIMPEXP_SDK GotoAnythingDlg : public GotoAnythingBaseDlg

protected:
virtual void OnItemActivated(wxDataViewEvent& event);
// GotoAnythingItemData* GetSelectedItemData();

void DoPopulate(const std::vector<clGotoEntry>& entries, const std::vector<int>& indexes = std::vector<int>());
void DoExecuteActionAndClose();
void UpdateLastSearch();
void ApplyFilter();

public:
Expand Down
6 changes: 0 additions & 6 deletions Plugin/project.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -140,10 +140,6 @@ bool Project::Load(const wxString& path)
bool saveNeeded = false;
if (GetVersionNumber() < CURRENT_WORKSPACE_VERSION) {
saveNeeded = true;
#if 0
// upgrade the build configurations to support the new Default build system
UpgradeBuildSystem();
#endif
}

// Make sure that the project version matches the latest version
Expand Down Expand Up @@ -2420,5 +2416,3 @@ long Project::GetVersionNumber() const
}
return nVersion;
}

void Project::UpgradeBuildSystem() {}
3 changes: 0 additions & 3 deletions Plugin/project.h
Original file line number Diff line number Diff line change
Expand Up @@ -342,9 +342,6 @@ class WXDLLIMPEXP_SDK Project

clProjectFolder::Ptr_t GetRootFolder();

/// Upgrade the project settings to match the new builder system
void UpgradeBuildSystem();

public:
/**
* @brief return list of files that are excluded from *any* build configuration
Expand Down
2 changes: 0 additions & 2 deletions Plugin/wxTerminalCtrl/wxTerminalCtrl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -263,8 +263,6 @@ void wxTerminalCtrl::Logout()
#endif
}

void wxTerminalCtrl::SendTab() {}

void wxTerminalCtrl::OnWorkspaceLoaded(clWorkspaceEvent& event)
{
event.Skip(); // allways skip this event
Expand Down
5 changes: 0 additions & 5 deletions Plugin/wxTerminalCtrl/wxTerminalCtrl.h
Original file line number Diff line number Diff line change
Expand Up @@ -101,11 +101,6 @@ class WXDLLIMPEXP_SDK wxTerminalCtrl : public wxPanel
*/
void GenerateCtrlC();

/**
* @brief send TAB char to the terminal
*/
void SendTab();

/**
* @brief clear the display (Ctrl-L)
*/
Expand Down
2 changes: 0 additions & 2 deletions wxcrafter/src/wxc_settings.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -134,8 +134,6 @@ JSONElement wxcSettings::GetCustomControlsAsJSON(const wxArrayString& controls)
return arr;
}

void wxcSettings::ShowNagDialogIfNeeded() {}

// ----------------------------------------------------------------------
// CustomControlTemplate
// ----------------------------------------------------------------------
Expand Down
1 change: 0 additions & 1 deletion wxcrafter/src/wxc_settings.h
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,6 @@ class wxcSettings
}
}

void ShowNagDialogIfNeeded();
void SetInitCompleted(bool initCompleted) { this->m_initCompleted = initCompleted; }
bool IsInitCompleted() const { return m_initCompleted; }

Expand Down
8 changes: 0 additions & 8 deletions wxcrafter/src/wxguicraft_main_view.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3053,11 +3053,6 @@ void GUICraftMainPanel::OnAuiPaneInfoChanged(wxPropertyGridEvent& event)

void GUICraftMainPanel::DoGenerateCode(bool silent)
{
// Show the nag dialog if needed
if(!silent) {
wxcSettings::Get().ShowNagDialogIfNeeded();
}

if(!wxcProjectMetadata::Get().GetGenerateCPPCode() && !wxcProjectMetadata::Get().GetGenerateXRC()) {
if(silent) {
return;
Expand Down Expand Up @@ -3256,9 +3251,6 @@ void GUICraftMainPanel::DoGenerateCode(bool silent)

void GUICraftMainPanel::BatchGenerate(const wxArrayString& files)
{
// SHow the nag dialog if needed
wxcSettings::Get().ShowNagDialogIfNeeded();

wxArrayString projectsGenerated;
wxArrayString wxcpFiles;

Expand Down

0 comments on commit 68a98bb

Please sign in to comment.