mirror of
https://forgejo.xatacraft.ru/Sunshine/mkxp-sunshine.git
synced 2026-08-19 21:39:57 +00:00
Fixed SunshineBinding amammama
This commit is contained in:
parent
c90326ffbd
commit
65b26c85e3
2 changed files with 11 additions and 10 deletions
|
|
@ -4,9 +4,10 @@
|
|||
void SunshineBindingInit(){
|
||||
printf("[SunshineBindingInit] Initializing Sunshine binding\n");
|
||||
VALUE module = rb_define_module("Sunshine");
|
||||
|
||||
rb_define_const(module, "SDLVersion", INT2NUM(SDL_VERSION));
|
||||
|
||||
printf("[SunshineBindingInit] SDL version: %u\n", SDL_VERSION);
|
||||
rb_define_const(module, "SDLVersion_major", INT2NUM(SDL_MAJOR_VERSION));
|
||||
rb_define_const(module, "SDLVersion_minor", INT2NUM(SDL_MINOR_VERSION));
|
||||
rb_define_const(module, "SDLVersion_micro", INT2NUM(SDL_MICRO_VERSION));
|
||||
//SDL_MAJOR_VERSION, SDL_MINOR_VERSION, SDL_MICRO_VERSION
|
||||
printf("[SunshineBindingInit] SDL version: %i.%i.%i\n", SDL_MAJOR_VERSION, SDL_MINOR_VERSION, SDL_MICRO_VERSION);
|
||||
printf("[SunshineBindingInit] Done\n");
|
||||
}
|
||||
|
|
|
|||
|
|
@ -158,7 +158,7 @@
|
|||
}
|
||||
configFile.close();
|
||||
} else {
|
||||
Debug() << "[desktopEnvironmentInit]FATAL: Cannot find desktop configuration!";
|
||||
Debug() << "[desktopEnvironmentInit] FATAL: Cannot find desktop configuration!";
|
||||
desktop = "kde_error";
|
||||
}
|
||||
} else {
|
||||
|
|
@ -250,7 +250,7 @@ end:
|
|||
}
|
||||
path = "/Wallpaper/" + nameFix + ".png";
|
||||
|
||||
Debug() << "[wallpaperSet]Setting wallpaper to " << path;
|
||||
Debug() << "[wallpaperSet] Setting wallpaper to " << path;
|
||||
|
||||
#ifdef __APPLE__
|
||||
if (!isCached) {
|
||||
|
|
@ -348,7 +348,7 @@ end:
|
|||
"'";
|
||||
Debug() << "[wallpaperSet] Wallpaper command:" << command.str();
|
||||
int result = system(command.str().c_str());
|
||||
Debug() << "[wallpaperSet ]Result:" << result;
|
||||
Debug() << "[wallpaperSet ] Result:" << result;
|
||||
} else {
|
||||
std::ifstream srcHint(gameDirStr + path);
|
||||
std::ofstream dstHint(fallbackPath);
|
||||
|
|
@ -470,12 +470,12 @@ RB_METHOD(wallpaperReset){
|
|||
"}" <<
|
||||
"}" <<
|
||||
"'";
|
||||
Debug() << "[wallpaperReset]Reset wallpaper command:" << command.str();
|
||||
Debug() << "[wallpaperReset] Reset wallpaper command:" << command.str();
|
||||
int result = system(command.str().c_str());
|
||||
Debug() << "[wallpaperReset]Reset result:" << result;
|
||||
Debug() << "[wallpaperReset] Reset result:" << result;
|
||||
} else {
|
||||
if (remove(fallbackPath.c_str()) != 0) {
|
||||
Debug() << "[wallpaperReset]Failed to delete:" << fallbackPath;
|
||||
Debug() << "[wallpaperReset] Failed to delete:" << fallbackPath;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Reference in a new issue