sprockets/src/main/java/net/sf/sprockets/view/Windows.java
public static Rect getFrame(Activity a) {
        Rect frame = new Rect();
        a.getWindow().getDecorView().getWindowVisibleDisplayFrame(frame);
        return frame;
    }
public static Rect getFrame(Activity a) {
        Rect frame = new Rect();
        a.getWindow().getDecorView().getWindowVisibleDisplayFrame(frame);
        return frame;
    }
Get the {@link View#getWindowVisibleDisplayFrame(Rect) visible area} of the Activity's
Window. The height of screen decorations above the Window can be found in {@link Rect#top}.