Added basic flag function to editor