mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-23 06:09:50 -06:00
Pass strings by const reference where possible
This commit is contained in:
@ -293,7 +293,7 @@ void PostProcessingShaderConfiguration::ReloadShader()
|
||||
m_current_shader = "";
|
||||
}
|
||||
|
||||
void PostProcessingShaderConfiguration::SetOptionf(std::string option, int index, float value)
|
||||
void PostProcessingShaderConfiguration::SetOptionf(const std::string& option, int index, float value)
|
||||
{
|
||||
auto it = m_options.find(option);
|
||||
|
||||
@ -302,7 +302,7 @@ void PostProcessingShaderConfiguration::SetOptionf(std::string option, int index
|
||||
m_any_options_dirty = true;
|
||||
}
|
||||
|
||||
void PostProcessingShaderConfiguration::SetOptioni(std::string option, int index, s32 value)
|
||||
void PostProcessingShaderConfiguration::SetOptioni(const std::string& option, int index, s32 value)
|
||||
{
|
||||
auto it = m_options.find(option);
|
||||
|
||||
@ -311,7 +311,7 @@ void PostProcessingShaderConfiguration::SetOptioni(std::string option, int index
|
||||
m_any_options_dirty = true;
|
||||
}
|
||||
|
||||
void PostProcessingShaderConfiguration::SetOptionb(std::string option, bool value)
|
||||
void PostProcessingShaderConfiguration::SetOptionb(const std::string& option, bool value)
|
||||
{
|
||||
auto it = m_options.find(option);
|
||||
|
||||
|
@ -68,9 +68,9 @@ public:
|
||||
const ConfigurationOption& GetOption(const std::string& option) { return m_options[option]; }
|
||||
|
||||
// For updating option's values
|
||||
void SetOptionf(std::string option, int index, float value);
|
||||
void SetOptioni(std::string option, int index, s32 value);
|
||||
void SetOptionb(std::string option, bool value);
|
||||
void SetOptionf(const std::string& option, int index, float value);
|
||||
void SetOptioni(const std::string& option, int index, s32 value);
|
||||
void SetOptionb(const std::string& option, bool value);
|
||||
|
||||
private:
|
||||
bool m_any_options_dirty;
|
||||
|
Reference in New Issue
Block a user