isInEditMode() added

just added  isInEditMode() for convenience