src/events/SDL_keyboard.c
changeset 5414 130cdb16fa93
parent 5262 b530ef003506
child 5535 96594ac5fd1a
equal deleted inserted replaced
5413:64c0e474c459 5414:130cdb16fa93
   788     if (SDL_GetEventState(SDL_TEXTINPUT) == SDL_ENABLE) {
   788     if (SDL_GetEventState(SDL_TEXTINPUT) == SDL_ENABLE) {
   789         SDL_Event event;
   789         SDL_Event event;
   790         event.text.type = SDL_TEXTINPUT;
   790         event.text.type = SDL_TEXTINPUT;
   791         event.text.windowID = keyboard->focus ? keyboard->focus->id : 0;
   791         event.text.windowID = keyboard->focus ? keyboard->focus->id : 0;
   792         SDL_utf8strlcpy(event.text.text, text, SDL_arraysize(event.text.text));
   792         SDL_utf8strlcpy(event.text.text, text, SDL_arraysize(event.text.text));
   793         event.text.windowID = keyboard->focus ? keyboard->focus->id : 0;
       
   794         posted = (SDL_PushEvent(&event) > 0);
   793         posted = (SDL_PushEvent(&event) > 0);
   795     }
   794     }
   796     return (posted);
   795     return (posted);
   797 }
   796 }
   798 
   797