mirror of
https://gitlab.futo.org/keyboard/latinime.git
synced 2024-09-28 14:54:30 +01:00
Initialize CandidateView in setInputView
When keyboard theme has been switched, input view will be replaced with new theme one and current CandidateView will get stale. The CandidateView must be reseted in setInputView. Change-Id: I36fd14280572d2d367cfef549d7705b3b321ba3e
This commit is contained in:
parent
f4c9e9d359
commit
6c4add55f9
@ -482,12 +482,16 @@ public class LatinIME extends InputMethodServiceCompatWrapper implements Keyboar
|
||||
|
||||
@Override
|
||||
public View onCreateInputView() {
|
||||
final View inputView = mKeyboardSwitcher.onCreateInputView();
|
||||
mCandidateViewContainer = inputView.findViewById(R.id.candidates_container);
|
||||
mCandidateView = (CandidateView) inputView.findViewById(R.id.candidates);
|
||||
return mKeyboardSwitcher.onCreateInputView();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setInputView(View view) {
|
||||
super.setInputView(view);
|
||||
mCandidateViewContainer = view.findViewById(R.id.candidates_container);
|
||||
mCandidateView = (CandidateView) view.findViewById(R.id.candidates);
|
||||
mCandidateView.setService(this);
|
||||
mCandidateStripHeight = (int)mResources.getDimension(R.dimen.candidate_strip_height);
|
||||
return inputView;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
Loading…
x
Reference in New Issue
Block a user