Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master' into fcitx
Browse files Browse the repository at this point in the history
  • Loading branch information
Fcitx Bot committed Jan 7, 2025
2 parents 4b72547 + c935190 commit aa829ea
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 6 deletions.
11 changes: 11 additions & 0 deletions src/engine/engine.gyp
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,17 @@
],
'dependencies': [
'minimal_converter',
'<(mozc_oss_src_dir)/base/absl.gyp:absl_status',
'<(mozc_oss_src_dir)/base/absl.gyp:absl_strings',
'<(mozc_oss_src_dir)/base/base.gyp:base',
'<(mozc_oss_src_dir)/converter/converter.gyp:converter',
'<(mozc_oss_src_dir)/dictionary/dictionary_base.gyp:pos_matcher',
'<(mozc_oss_src_dir)/dictionary/dictionary_base.gyp:user_dictionary',
'<(mozc_oss_src_dir)/engine/engine_base.gyp:modules',
'<(mozc_oss_src_dir)/prediction/prediction.gyp:prediction',
'<(mozc_oss_src_dir)/protocol/protocol.gyp:commands_proto',
'<(mozc_oss_src_dir)/protocol/protocol.gyp:user_dictionary_storage_proto',
'<(mozc_oss_src_dir)/rewriter/rewriter.gyp:rewriter',
],
},
{
Expand Down
2 changes: 1 addition & 1 deletion src/unix/emacs/mozc.el
Original file line number Diff line number Diff line change
Expand Up @@ -345,7 +345,7 @@ EVENT is the last input event, which is usually passed by the command loop."
((mozc-protobuf-get output 'consumed)
(let ((result (mozc-protobuf-get output 'result))
(preedit (mozc-protobuf-get output 'preedit))
(candidates (mozc-protobuf-get output 'candidates)))
(candidates (mozc-protobuf-get output 'candidate-window)))
(if (not (or result preedit))
(mozc-clean-up-changes-on-buffer) ; nothing to show
(when result ; Insert the result first.
Expand Down
9 changes: 5 additions & 4 deletions src/unix/emacs/mozc_emacs_helper_lib.cc
Original file line number Diff line number Diff line change
Expand Up @@ -200,10 +200,11 @@ void PrintMessage(const protobuf::Message &message,
// Normalizes a symbol with the following rules:
// - all alphabets are converted to lowercase
// - underscore('_') is converted to dash('-')
std::string NormalizeSymbol(std::string symbol) {
Util::LowerString(&symbol);
std::replace(symbol.begin(), symbol.end(), '_', '-');
return symbol;
std::string NormalizeSymbol(absl::string_view symbol) {
std::string normalized(symbol);
Util::LowerString(&normalized);
std::replace(normalized.begin(), normalized.end(), '_', '-');
return normalized;
}

// Returns a quoted string as a string literal in S-expression.
Expand Down
2 changes: 1 addition & 1 deletion src/unix/emacs/mozc_emacs_helper_lib.h
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ void PrintMessage(const mozc::protobuf::Message &message,
// Normalizes a symbol with the following rule:
// - all alphabets are converted to lowercase
// - underscore('_') is converted to dash('-')
std::string NormalizeSymbol(std::string symbol);
std::string NormalizeSymbol(absl::string_view symbol);

// Returns a quoted string as a string literal in S-expression.
// - double-quote is converted to backslash + double-quote
Expand Down

0 comments on commit aa829ea

Please sign in to comment.