Question about the InputMethodContextFactoryOzone replacement

30 views
Skip to first unread message

Benjamin Dupont (bedupont)

unread,
May 28, 2014, 10:20:23 AM5/28/14
to ozon...@chromium.org

Hi,

 

I’m working on a Chromium portage on Linux STBs. We use our own ozone platform (not the DRI one) which is ported on our abstraction hardware layer.

 

Our previous implementation worked fine until this patch:

https://chromium.googlesource.com/chromium/chromium/+/4ac168b2ab94c742f87860001f82c939c6789449

 

Before this patch, our OzonePlatform overrode:

 virtual gfx::SurfaceFactoryOzone* GetSurfaceFactoryOzone() OVERRIDE;
 
virtual ui::EventFactoryOzone* GetEventFactoryOzone() OVERRIDE;
 
virtual ui::InputMethodContextFactoryOzone* GetInputMethodContextFactoryOzone() OVERRIDE;
 
virtual ui::CursorFactoryOzone* GetCursorFactoryOzone() OVERRIDE;

 

If we just delete the InputMethodContextFactoryOzone then at runtime we have:

[1654:1654:0101/014145:2505118645:FATAL:input_method_auralinux.cc(25)] Check failed: LinuxInputMethodContextFactory::instance(). This failure was likely caused because ui::InitializeInputMethod(ForTesting) was not called before instantiating this class.

 

In ui/base/ime/input_method_initializer.cc a function is called (InitializeInputMethod) but it initializes the input method only for ChromeOs.

 

Since this commit, how should we proceed to create this ‘mandatory’ instance ?

Could we still use your own EventFactory?

 

Thanks and regards,

                Benjamin.

 

Sadrul Chowdhury

unread,
May 28, 2014, 10:29:19 AM5/28/14
to Benjamin Dupont (bedupont), ozon...@chromium.org
You can create a FakeInputMethodContextFactory and use LinuxInputMethodContextFactory::SetInstance() to set it during platform initialization. (you may need to UI_BASE_EXPORT FakeInputMethodContextFactory; if you do, please send us a patch).

Sadrul
Reply all
Reply to author
Forward
0 new messages