mark all local functions as static

This commit is contained in:
degasus
2014-07-08 14:29:26 +02:00
parent 3ff1c538ee
commit 22e1aa5bb4
93 changed files with 260 additions and 251 deletions

View File

@ -23,6 +23,7 @@
#include "Common/Common.h"
#include "Common/StringUtil.h"
#include "Common/SymbolDB.h"
#include "Core/Host.h"
#include "Core/DSP/DSPCore.h"
#include "Core/HW/DSPLLE/DSPDebugInterface.h"
#include "Core/HW/DSPLLE/DSPSymbols.h"

View File

@ -241,7 +241,7 @@ void CMemoryWindow::OnHostMessage(wxCommandEvent& event)
}
}
void DumpArray(const std::string& filename, const u8* data, size_t length)
static void DumpArray(const std::string& filename, const u8* data, size_t length)
{
if (data)
{

View File

@ -829,7 +829,7 @@ void CFrame::OnGameListCtrl_ItemActivated(wxListEvent& WXUNUSED (event))
}
}
bool IsHotkey(wxKeyEvent &event, int Id)
static bool IsHotkey(wxKeyEvent &event, int Id)
{
return (event.GetKeyCode() != WXK_NONE &&
event.GetKeyCode() == SConfig::GetInstance().m_LocalCoreStartupParameter.iHotkey[Id] &&

View File

@ -183,7 +183,7 @@ static int CompareGameListItems(const GameListItem* iso1, const GameListItem* is
return 0;
}
bool operator < (const GameListItem &one, const GameListItem &other)
static bool operator < (const GameListItem &one, const GameListItem &other)
{
return CompareGameListItems(&one, &other) < 0;
}
@ -394,7 +394,7 @@ void CGameListCtrl::Update()
SetFocus();
}
wxString NiceSizeFormat(u64 _size)
static wxString NiceSizeFormat(u64 _size)
{
// Return a pretty filesize string from byte count.
// e.g. 1134278 -> "1.08 MiB"
@ -472,7 +472,7 @@ void CGameListCtrl::InsertItemInReportView(long _Index)
SetItemData(_Index, ItemIndex);
}
wxColour blend50(const wxColour& c1, const wxColour& c2)
static wxColour blend50(const wxColour& c1, const wxColour& c2)
{
unsigned char r,g,b,a;
r = c1.Red()/2 + c2.Red()/2;
@ -658,7 +658,7 @@ const GameListItem *CGameListCtrl::GetISO(size_t index) const
}
CGameListCtrl *caller;
int wxCALLBACK wxListCompare(wxIntPtr item1, wxIntPtr item2, wxIntPtr sortData)
static int wxCALLBACK wxListCompare(wxIntPtr item1, wxIntPtr item2, wxIntPtr sortData)
{
// return 1 if item1 > item2
// return -1 if item1 < item2

View File

@ -39,6 +39,7 @@
#include "Core/ConfigManager.h"
#include "Core/Core.h"
#include "Core/CoreParameter.h"
#include "Core/Host.h"
#include "Core/Movie.h"
#include "Core/HW/Wiimote.h"

View File

@ -54,7 +54,7 @@ const u8 hdr[] = {
0x00,0x00,0x00,0x00
};
wxBitmap wxBitmapFromMemoryRGBA(const unsigned char* data, u32 width, u32 height)
static wxBitmap wxBitmapFromMemoryRGBA(const unsigned char* data, u32 width, u32 height)
{
u32 stride = (4*width);

View File

@ -59,7 +59,7 @@ static NetPlayClient* netplay_client = nullptr;
extern CFrame* main_frame;
NetPlayDiag *NetPlayDiag::npd = nullptr;
std::string BuildGameName(const GameListItem& game)
static std::string BuildGameName(const GameListItem& game)
{
// Lang needs to be consistent
auto const lang = 0;
@ -74,7 +74,7 @@ std::string BuildGameName(const GameListItem& game)
return name + " (" + game.GetUniqueID() + ")";
}
void FillWithGameNames(wxListBox* game_lbox, const CGameListCtrl& game_list)
static void FillWithGameNames(wxListBox* game_lbox, const CGameListCtrl& game_list)
{
for (u32 i = 0 ; auto game = game_list.GetISO(i); ++i)
game_lbox->Append(StrToWxStr(BuildGameName(*game)));

View File

@ -150,7 +150,7 @@ wxString shader_errors_desc = wxTRANSLATE("Usually if shader compilation fails,
// Search for available resolutions - TODO: Move to Common?
wxArrayString GetListOfResolutions()
static wxArrayString GetListOfResolutions()
{
wxArrayString retlist;
retlist.Add("Auto");