11#include " hallelujah.h"
22#include < algorithm>
33#include < cctype>
4- #include < fcitx-utils/standardpath .h>
4+ #include < fcitx-utils/standardpaths .h>
55#include < fcitx/candidatelist.h>
66#include < fcitx/inputpanel.h>
77#include < fmt/format.h>
@@ -286,8 +286,8 @@ void HallelujahEngine::reset(const InputMethodEntry &,
286286}
287287
288288void HallelujahEngine::loadTrie () {
289- const auto &sp = fcitx::StandardPath ::global ();
290- std::string trie_path = sp.locate (fcitx::StandardPath::Type ::Data,
289+ const auto &sp = fcitx::StandardPaths ::global ();
290+ std::string trie_path = sp.locate (fcitx::StandardPathsType ::Data,
291291 " hallelujah/google_227800_words.bin" );
292292 if (trie_path.empty ()) {
293293 throw std::runtime_error (" Failed to load google_227800_words.bin" );
@@ -296,9 +296,9 @@ void HallelujahEngine::loadTrie() {
296296}
297297
298298void HallelujahEngine::loadWords () {
299- const auto &sp = fcitx::StandardPath ::global ();
299+ const auto &sp = fcitx::StandardPaths ::global ();
300300 std::string words_path =
301- sp.locate (fcitx::StandardPath::Type ::Data, " hallelujah/words.json" );
301+ sp.locate (fcitx::StandardPathsType ::Data, " hallelujah/words.json" );
302302 if (words_path.empty ()) {
303303 throw std::runtime_error (" Failed to load words.json" );
304304 }
@@ -335,9 +335,9 @@ void HallelujahEngine::loadWords() {
335335}
336336
337337void HallelujahEngine::loadPinyin () {
338- const auto &sp = fcitx::StandardPath ::global ();
338+ const auto &sp = fcitx::StandardPaths ::global ();
339339 std::string pinyin_path =
340- sp.locate (fcitx::StandardPath::Type ::Data, " hallelujah/cedict.json" );
340+ sp.locate (fcitx::StandardPathsType ::Data, " hallelujah/cedict.json" );
341341 if (pinyin_path.empty ()) {
342342 throw std::runtime_error (" Failed to load cedict.json" );
343343 }
0 commit comments