[aseprite] 166/196: Fix open in folder on Linux
Tobias Hansen
thansen at moszumanska.debian.org
Wed Apr 20 18:50:16 UTC 2016
This is an automated email from the git hooks/post-receive script.
thansen pushed a commit to branch master
in repository aseprite.
commit 519f11e81d1a06730bf37bb5da7cb0e18abde064
Author: David Capello <davidcapello at gmail.com>
Date: Mon Apr 11 13:00:39 2016 -0300
Fix open in folder on Linux
---
src/base/launcher.cpp | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/src/base/launcher.cpp b/src/base/launcher.cpp
index 734902b..fd1541a 100644
--- a/src/base/launcher.cpp
+++ b/src/base/launcher.cpp
@@ -1,5 +1,5 @@
// Aseprite Base Library
-// Copyright (c) 2001-2013, 2015 David Capello
+// Copyright (c) 2001-2016 David Capello
//
// This file is released under the terms of the MIT license.
// Read LICENSE.txt for more information.
@@ -121,8 +121,10 @@ bool open_folder(const std::string& _file)
#else
- int ret;
- ret = std::system(("xdg-open \"" + file + "\"").c_str());
+ if (!base::is_directory(file))
+ file = base::get_file_path(file);
+
+ int ret = std::system(("xdg-open \"" + file + "\"").c_str());
return (ret == 0);
#endif
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/aseprite.git
More information about the Pkg-games-commits
mailing list