MCPcopy Create free account
hub / github.com/OpenTTD/OpenTTD / MakeAsdfgKeys

Function MakeAsdfgKeys

src/osk_gui.cpp:283–293  ·  view source on GitHub ↗

Construct the asdfg row keys. */

Source from the content-addressed store, hash-verified

281
282/** Construct the asdfg row keys. */
283static std::unique_ptr<NWidgetBase> MakeAsdfgKeys()
284{
285 std::unique_ptr<NWidgetHorizontal> hor = std::make_unique<NWidgetHorizontalLTR>();
286 hor->SetPIP(0, INTER_KEY_SPACE, 0);
287
288 AddKey(hor, KEY_PADDING, 4, WWT_IMGBTN, WID_OSK_CAPS, WidgetData{.sprite = SPR_OSK_CAPS});
289 for (WidgetID widnum = WID_OSK_ASDFG_FIRST; widnum <= WID_OSK_ASDFG_LAST; widnum++) {
290 AddKey(hor, KEY_PADDING, 2, WWT_PUSHBTN, widnum, {});
291 }
292 return hor;
293}
294
295/** Construct the zxcvb row keys. */
296static std::unique_ptr<NWidgetBase> MakeZxcvbKeys()

Callers

nothing calls this directly

Calls 2

AddKeyFunction · 0.85
SetPIPMethod · 0.80

Tested by

no test coverage detected