I set the Ok key on the soft keyboard of Android when I click on the edittext shown below:
<EditText android:id="@+id/rlMP3SeekContainer" android:layout_width="0dp" android:layout_height="40dp" android:layout_weight="1" android:background="@drawable/text_rougea" android:singleLine="true" android:imeOptions="actionDone" android:ems="10" android:hint="@string/hint_deezer_search" android:paddingLeft="@dimen/eight_dp" android:paddingRight="@dimen/eight_dp" android:textColor="@color/black" android:textColorHint="@color/gray_text" android:textSize="@dimen/twelve_sp" />
When the keyboard appears, I want the user to do something by pressing the ok button. but how can I override the ok button on the keyboard to do what I want.
source share