style: Rename some variables

This commit is contained in:
[ ] 2022-09-28 12:29:33 +09:00
parent 7c3108327b
commit dc46514d7e
3 changed files with 7 additions and 7 deletions

View File

@ -34,7 +34,7 @@ public:
std::vector<std::unique_ptr<SMonitor>> m_vMonitors;
bool m_bIPCEnabled = true;
std::string explicitConfigPath;
std::string m_szExplicitConfigPath;
void removeOldHyprpaperImages();
void preloadAllWallpapersFromConfig();

View File

@ -4,17 +4,17 @@
CConfigManager::CConfigManager() {
// init the entire thing
std::string CONFIGPATH;
if (g_pHyprpaper->explicitConfigPath == "") {
std::string configPath;
if (g_pHyprpaper->m_szExplicitConfigPath == "") {
const char *const ENVHOME = getenv("HOME");
CONFIGPATH = ENVHOME + (std::string) "/.config/hypr/hyprpaper.conf";
configPath = ENVHOME + (std::string) "/.config/hypr/hyprpaper.conf";
}
else {
CONFIGPATH = g_pHyprpaper->explicitConfigPath;
configPath = g_pHyprpaper->m_szExplicitConfigPath;
}
std::ifstream ifs;
ifs.open(CONFIGPATH);
ifs.open(configPath);
if (!ifs.good()) {
Debug::log(CRIT, "Hyprpaper was not provided a config!");

View File

@ -21,7 +21,7 @@ int main(int argc, char** argv, char** envp) {
// starts
g_pHyprpaper = std::make_unique<CHyprpaper>();
g_pHyprpaper->explicitConfigPath = configPath;
g_pHyprpaper->m_szExplicitConfigPath = configPath;
g_pHyprpaper->init();
return 0;