From 0fc3d4883f4c200047c515c8ebe5090013979938 Mon Sep 17 00:00:00 2001 From: wmayer Date: Mon, 26 Apr 2021 11:12:51 +0200 Subject: [PATCH] Image: remove some more deprecated Py2 code --- src/Mod/Image/Gui/Command.cpp | 4 ---- 1 file changed, 4 deletions(-) diff --git a/src/Mod/Image/Gui/Command.cpp b/src/Mod/Image/Gui/Command.cpp index 41ea5fbb2d..d64cfcea79 100644 --- a/src/Mod/Image/Gui/Command.cpp +++ b/src/Mod/Image/Gui/Command.cpp @@ -80,11 +80,7 @@ void CmdImageOpen::activated(int iMsg) s = Base::Tools::escapeEncodeFilename(s); // load the file with the module Command::doCommand(Command::Gui, "import Image, ImageGui"); -#if PY_MAJOR_VERSION < 3 - Command::doCommand(Command::Gui, "ImageGui.open(unicode(\"%s\",\"utf-8\"))", (const char*)s.toUtf8()); -#else Command::doCommand(Command::Gui, "ImageGui.open(\"%s\",\"utf-8\")", (const char*)s.toUtf8()); -#endif } catch (const Base::PyException& e){ // Usually thrown if the file is invalid somehow