MCPcopy Create free account
hub / github.com/SeleniumHQ/selenium / GetAvailableEngines

Method GetAvailableEngines

cpp/imehandler/linux/src/ibushandler.cpp:133–155  ·  view source on GitHub ↗

* Returns the names of all the available engines in the system. */

Source from the content-addressed store, hash-verified

131 * Returns the names of all the available engines in the system.
132 */
133std::vector<std::string> IBusHandler::GetAvailableEngines() const {
134 std::vector<std::string> loaded_engines;
135
136 if (! ibus_available_) {
137 return loaded_engines;
138 }
139
140 GList* engines = ibus_bus_list_engines(bus_);
141 if (engines == NULL) {
142 // No engines available.
143 return loaded_engines;
144 }
145
146 for (GList* engine = g_list_first(engines); engine != NULL ;
147 engine = g_list_next(engine)) {
148 IBusEngineDesc* desc = IBUS_ENGINE_DESC (engine->data);
149 loaded_engines.push_back(desc->name);
150 g_object_unref(desc);
151 }
152
153 g_list_free(engines);
154 return loaded_engines;
155}
156
157/*
158 * Returns the names of all the preloaded engines.

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected