mirror of
https://github.com/moparisthebest/keepass2android
synced 2024-12-22 15:08:50 -05:00
intermediary (still search suggestions)
This commit is contained in:
parent
59014bde22
commit
1f62797b78
@ -95,7 +95,7 @@ namespace keepass2android
|
||||
{
|
||||
get { return App.Kp2a.GetDb().CanWrite && ((this.Group.ParentGroup != null) || App.Kp2a.GetDb().DatabaseFormat.CanHaveEntriesInRootGroup); }
|
||||
}
|
||||
|
||||
/*
|
||||
public override bool OnCreateOptionsMenu(IMenu menu)
|
||||
{
|
||||
// Inflate the menu; this adds items to the action bar if it is present.
|
||||
@ -117,24 +117,10 @@ namespace keepass2android
|
||||
searchView.SetSearchableInfo(searchManager.GetSearchableInfo(ComponentName));
|
||||
// searchView.setIconifiedByDefault(false); // Do not iconify the widget; expand it by default
|
||||
|
||||
var search_src_text = searchView.FindViewById(keepass2android.Resource.Id.search_src_text);
|
||||
|
||||
try
|
||||
{
|
||||
var autoCompleteTextView = search_src_text.JavaCast< Android.Support.V7.Widget.SearchView.SearchAutoComplete>();
|
||||
if (autoCompleteTextView != null) {
|
||||
autoCompleteTextView.SetDropDownBackgroundResource(keepass2android.Resource.Drawable.search_dropdown_light);
|
||||
}
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
Android.Util.Log.Debug ("e", e.ToString());
|
||||
}
|
||||
|
||||
|
||||
return base.OnCreateOptionsMenu(menu);
|
||||
}
|
||||
|
||||
*/
|
||||
protected override void OnCreate (Bundle savedInstanceState)
|
||||
{
|
||||
base.OnCreate (savedInstanceState);
|
||||
|
@ -392,10 +392,9 @@ namespace keepass2android
|
||||
return true;
|
||||
}
|
||||
}
|
||||
/*
|
||||
|
||||
public override bool OnCreateOptionsMenu(IMenu menu) {
|
||||
return base.OnCreateOptionsMenu(menu);
|
||||
|
||||
|
||||
MenuInflater inflater = MenuInflater;
|
||||
inflater.Inflate(Resource.Menu.group, menu);
|
||||
var searchManager = (SearchManager) GetSystemService(SearchService);
|
||||
@ -406,6 +405,23 @@ namespace keepass2android
|
||||
searchView.SetSearchableInfo(searchManager.GetSearchableInfo(ComponentName));
|
||||
searchView.SetOnSuggestionListener(new SuggestionListener(searchView.SuggestionsAdapter, this, searchItem));
|
||||
searchView.SetOnQueryTextListener(new OnQueryTextListener(this));
|
||||
|
||||
/*
|
||||
var search_src_text = searchView.FindViewById(Resource.Id.search_src_text);
|
||||
|
||||
try
|
||||
{
|
||||
var autoCompleteTextView = search_src_text.JavaCast< Android.Support.V7.Widget.SearchView.SearchAutoComplete>();
|
||||
if (autoCompleteTextView != null) {
|
||||
autoCompleteTextView.SetDropDownBackgroundResource(keepass2android.Resource.Drawable.search_dropdown_light);
|
||||
|
||||
}
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
Android.Util.Log.Debug ("e", e.ToString());
|
||||
}*/
|
||||
|
||||
|
||||
var item = menu.FindItem(Resource.Id.menu_sync);
|
||||
if (item != null)
|
||||
@ -415,9 +431,12 @@ namespace keepass2android
|
||||
else
|
||||
item.SetVisible(true);
|
||||
}
|
||||
//return true;
|
||||
|
||||
|
||||
return base.OnCreateOptionsMenu(menu);
|
||||
|
||||
}
|
||||
*/
|
||||
|
||||
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user