From 36238693e44f029b2043cb372288a79e3cc9c3b1 Mon Sep 17 00:00:00 2001 From: Nikolay Pultsin Date: Mon, 28 Feb 2011 16:02:14 +0300 Subject: [PATCH] hide keyboard call --- TODO.CustomCatalog | 1 - .../android/fbreader/network/AddCustomCatalogActivity.java | 6 ++++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/TODO.CustomCatalog b/TODO.CustomCatalog index 538bb4a49..47360a95c 100644 --- a/TODO.CustomCatalog +++ b/TODO.CustomCatalog @@ -1,2 +1 @@ -* hide keyboard after catalog info loading * start FBReader in new task diff --git a/src/org/geometerplus/android/fbreader/network/AddCustomCatalogActivity.java b/src/org/geometerplus/android/fbreader/network/AddCustomCatalogActivity.java index f622671d2..56c4b13fd 100644 --- a/src/org/geometerplus/android/fbreader/network/AddCustomCatalogActivity.java +++ b/src/org/geometerplus/android/fbreader/network/AddCustomCatalogActivity.java @@ -26,6 +26,7 @@ import android.content.Intent; import android.net.Uri; import android.os.Bundle; import android.view.View; +import android.view.inputmethod.InputMethodManager; import android.widget.Button; import android.widget.TextView; @@ -64,6 +65,11 @@ public class AddCustomCatalogActivity extends Activity { setupButton( R.id.add_custom_catalog_ok_button, "ok", new View.OnClickListener() { public void onClick(View view) { + final InputMethodManager imm = + (InputMethodManager)getSystemService(INPUT_METHOD_SERVICE); + imm.hideSoftInputFromWindow(findViewById(R.id.add_custom_catalog_url).getWindowToken(), 0); + imm.hideSoftInputFromWindow(findViewById(R.id.add_custom_catalog_title).getWindowToken(), 0); + imm.hideSoftInputFromWindow(findViewById(R.id.add_custom_catalog_summary).getWindowToken(), 0); onOkButton(); } }