Commit e7b944ad authored by 神楽坂玲奈's avatar 神楽坂玲奈

os卡图路径读取 中文路径支持

parent b98c98b3
......@@ -10,9 +10,8 @@ class Card
PicPath = if RUBY_PLATFORM["win"] || RUBY_PLATFORM["ming"]
require 'win32/registry'
ospicpath = Win32::Registry::HKEY_CURRENT_USER.open('Software\OCGSOFT\Cards'){|reg|reg['Path']} rescue ''
p ospicpath.encoding
ospicpath.force_encoding "GBK"
p ospicpath.encode "UTF-8"
ospicpath.encode "UTF-8"
else
'' #其他操作系统卡图存放位置标准尚未制定。
end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment