我正在使用来自StandOut的https://github.com/pingpongboss/StandOut API,当我使用在窗口中组合的下列标志时:
FLAG_DECORATION_SYSTEM | FLAG_WINDOW_HIDE_ENABLE我的方法getPersistentNotificationIntent和getHiddenNotificationIntent实现如下:
@Override
public Intent getPersistentNotificationIntent(int id) {
return StandOutWindow.getCloseAllIntent(this, MyFloatingWindow.class);
}
@Override
public Intent getHiddenNotificationIntent(int id) {
return StandOutWindow.getShowIntent(this, MyFloatingWindow.class, id);
}而且几乎一切都很好。如果使用装饰关闭按钮关闭窗口,则通知将关闭。如果按下通知“单击关闭所有窗口”,则通知和窗口将关闭。如果我隐藏窗口并按下“隐藏通知”,则该窗口将恢复,并且可以使用第一种方法关闭。但是,如果我按下隐藏按钮,然后按下第一个通知“单击关闭所有窗口”,窗口和“隐藏”通知关闭,但我以一个通知结束,该通知永远不会自动关闭。
我怎么才能解决这个问题?
发布于 2014-02-18 09:29:37
https://stackoverflow.com/questions/21848268
复制相似问题