Improved open file plugin