X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fentry.cpp;h=523fea5cc945f8a6bf6b321990c74ff449ee63d1;hb=aba0416fb73e17d068b30ff163c2fedcb0254da2;hp=efb4b45c57d354ca4f11b453ff567fe58d108421;hpb=9b29612d1cde85fee9b3f011e86a5cabe5dbcce3;p=libs%2Fgltk.git diff --git a/source/entry.cpp b/source/entry.cpp index efb4b45..523fea5 100644 --- a/source/entry.cpp +++ b/source/entry.cpp @@ -52,7 +52,9 @@ void Entry::key_press(unsigned key, unsigned, wchar_t ch) if(edit_pos>0) text.erase(--edit_pos, 1); } - else + else if(key==Input::KEY_ENTER) + signal_enter.emit(); + else if(ch>=' ') { text.insert(edit_pos, Codecs::encode(Codecs::ustring(1, ch))); ++edit_pos;