void FileSaved(object sender, FileNameEventArgs e)
 {
     if (options.CompileOnSave && TypeScriptFileExtensions.IsTypeScriptFileName(e.FileName)) {
         var action = new CompileTypeScriptOnSaveFileAction();
         action.Compile(e.FileName);
     }
 }
		void FileSaved(object sender, FileNameEventArgs e)
		{
			if (!TypeScriptFileExtensions.IsTypeScriptFileName(e.FileName))
				return;
			
			TypeScriptProject project = TypeScriptService.GetProjectForFile(e.FileName);
			if (project == null)
				return;
			
			if (project.CompileOnSave) {
				var action = new CompileTypeScriptOnSaveFileAction();
				TypeScriptContext context = TypeScriptService.ContextProvider.GetContext(e.FileName);
				action.Compile(e.FileName, project, context);
			}
		}
        void FileSaved(object sender, FileNameEventArgs e)
        {
            if (!TypeScriptFileExtensions.IsTypeScriptFileName(e.FileName))
            {
                return;
            }

            TypeScriptProject project = TypeScriptService.GetProjectForFile(e.FileName);

            if (project == null)
            {
                return;
            }

            if (project.CompileOnSave)
            {
                var action = new CompileTypeScriptOnSaveFileAction();
                TypeScriptContext context = TypeScriptService.ContextProvider.GetContext(e.FileName);
                action.Compile(e.FileName, project, context);
            }
        }