Reputation: 207
How to know currently app is opened in multi-window feature in Samsung devices?
In my case onMeasure view, it considers any other app opened in bottom as keyboard visible. Also is there any method to reliably check keyboard is visible.
Upvotes: 1
Views: 374
Reputation: 1372
Use Samsung's multiwindow SDK
Add this two jar's to your libs/ folder:
You can download the sdk from here:
http://img-developer.samsung.com/contents/cmm/sms/MultiwindowSDK_v1.2.3.zip
Then use this listener in your OnCreate method:
SMultiWindowActivity mMultiWindowActivity = new SMultiWindowActivity(this);
mMultiWindowActivity.setStateChangeListener(new SMultiWindowActivity.StateChangeListener() {
@Override
public void onModeChanged(boolean isMultiWindow) {
if (isMultiWindow){
//called when changing to Multiple Window
}else{
}
}
@Override
public void onZoneChanged(int i) {
}
@Override
public void onSizeChanged(Rect rect) {
}
});
More info:
http://developer.samsung.com/board/download.do?bdId=T000000144&attachId=0000000001
Upvotes: 2