mirror of
https://github.com/aseprite/aseprite.git
synced 2025-01-04 08:46:09 +00:00
Fix Screenshot command compilation when ENABLE_STEAM is undefined
This commit is contained in:
parent
d46f771820
commit
6290f18742
@ -116,8 +116,8 @@ void ScreenshotCommand::onExecute(Context* ctx)
|
||||
if (params().srgb())
|
||||
cmd::convert_color_profile(spr, gfx::ColorSpace::MakeSRGB());
|
||||
|
||||
if (params().steam()) {
|
||||
#ifdef ENABLE_STEAM
|
||||
if (params().steam()) {
|
||||
if (auto steamAPI = steam::SteamAPI::instance()) {
|
||||
// Get image again (cmd::convert_color_profile() might have changed it)
|
||||
img = cel->image();
|
||||
@ -141,8 +141,8 @@ void ScreenshotCommand::onExecute(Context* ctx)
|
||||
if (steamAPI->writeScreenshot(&rgbBuffer[0], rgbBuffer.size(), w*scale, h*scale))
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
#endif
|
||||
|
||||
if (params().save()) {
|
||||
save_document(ctx, doc.get());
|
||||
@ -156,9 +156,12 @@ void ScreenshotCommand::onExecute(Context* ctx)
|
||||
std::string ScreenshotCommand::onGetFriendlyName() const
|
||||
{
|
||||
std::string name;
|
||||
#ifdef ENABLE_STEAM
|
||||
if (params().steam())
|
||||
name = Strings::commands_Screenshot_Steam();
|
||||
else if (params().save())
|
||||
else
|
||||
#endif
|
||||
if (params().save())
|
||||
name = Strings::commands_Screenshot_Save();
|
||||
else
|
||||
name = Strings::commands_Screenshot_Open();
|
||||
|
Loading…
Reference in New Issue
Block a user