窗口已经聚焦 - 无视com.android.internal.view的聚焦增益 [英] window already focused - ignoring focus gain of com.android.internal.view

查看:201
本文介绍了窗口已经聚焦 - 无视com.android.internal.view的聚焦增益的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经看到了很多的解决方案,这一点,但没有对我的作品!我两个previous场合面对这个问题,我只是恢复到我的备份code为它工作。我从来没有发现故障原因。有人说,它只是一个警告,所以你可以忽略它。但我不能够从一个目标切换到另一个。这是确切的情况 - 我已经从那里我补充一下的菜单。所以,当我点击菜单,然后单击添加项目,它不会做任何事情!只是给出了这样的警告,并保持在同一屏幕上。所以,我坚持! 任何人都可以请解释为什么这个错误造成的,什么是最好的方法来消除它?

  WARN / InputManagerService(61):窗口已经集中,忽略了聚焦增益:com.android.internal.view.IInputMethodClient$Stub$Proxy@405b1d68
 

解决方案

检查您的事件处理程序方法的菜单。我发现,我用

 公共布尔onOptionsItemSelected(菜单项项)
 

我切换到下面,并解决了问题。

 公共布尔onMenuItemSelected(INT FEATUREID,菜单项项)
 

我得到了同样的警告消息,我的事件不触发下一个活动。看看你的方法,看看它是否表示要覆盖它。我不是。有一次,我改变了我重写方法和工作。

I have seen many solutions to this but none works for me! I faced this problem in two previous occasions and I just had to revert to my backup code for it to work. I never found out why this happens. Some people say its just a warning, so you can ignore it. But I am not able to switch from one intent to another. This is the exact case - I have made a menu from where I add something. So when I click on menu, and then click add item, It doesn't do anything! Just gives this warning and stays on the same screen. So, i am stuck! Can anyone please explain why this error is caused and what is the best way to eliminate it?

WARN/InputManagerService(61): Window already focused, ignoring focus gain of: com.android.internal.view.IInputMethodClient$Stub$Proxy@405b1d68

解决方案

Check your event handler method for the menu. I found that I was using

public boolean onOptionsItemSelected(MenuItem item)

I switched to the following and fixed the problem.

public boolean onMenuItemSelected(int featureId, MenuItem item)

I was getting the same warning message and my event was not firing the next activity. Look at your method and see if it indicates that you are overriding it. I was not. Once I changed the method I was overriding and worked.

这篇关于窗口已经聚焦 - 无视com.android.internal.view的聚焦增益的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆