Пример #1
0
        static void HandleEndBuild(object sender, BuildEventArgs e)
        {
            if (!Enabled) return;

            var project = (IdeApp.ProjectOperations.CurrentSelectedSolution?.StartupItem
                ?? IdeApp.ProjectOperations.CurrentSelectedBuildTarget)
                as DotNetProject;

            //
            // Only Swizzle Xamarin.iOS Simulator builds
            //
            if (project?.TargetFramework?.Name != "Xamarin.iOS") return;

            var configSelector = IdeApp.Workspace.ActiveConfiguration;
            var config = configSelector.GetConfiguration (project);

            if (config.Platform != "iPhoneSimulator") return;

            var refAsms = project.GetReferencedAssemblies(configSelector).Result;
            var refsContinuous =
                refAsms.Any (x => x.FilePath.FileNameWithoutExtension == "Continuous.Server.iOS");

            if (!refsContinuous) return;

            //
            // Copy REPL assemblies to app directory
            //
            try
            {
                Swizzle (project, configSelector);
            }
            catch
            {
                // Eat the error because I don't know how to bubble it up to the user
            }
        }
Пример #2
0
		void OnEndBuild (IProgressMonitor monitor, bool success, BuildResult result = null, SolutionItem item = null)
		{
			if (EndBuild == null)
				return;
					
			var args = new BuildEventArgs (monitor, success) {
				SolutionItem = item
			};
			if (result != null) {
				args.WarningCount = result.WarningCount;
				args.ErrorCount = result.ErrorCount;
				args.BuildCount = result.BuildCount;
				args.FailedBuildCount = result.FailedBuildCount;
			}
			EndBuild (this, args);
		}
		void OnProjectBuilt (object s, BuildEventArgs args)
		{
			if (RefreshRequired)
				UpdateTests ();
		}
Пример #4
0
		static void OnProjectCompiled (object s, BuildEventArgs args)
		{
			if (args.Success) {
				// Unload stetic projects which are not currently
				// being used by the IDE. This will avoid unnecessary updates.
				if (IdeApp.Workspace.IsOpen) {
					foreach (Project prj in IdeApp.Workspace.GetAllProjects ()) {
						GtkDesignInfo info = GtkDesignInfo.FromProject (prj);
						if (!HasOpenDesigners (prj, false)) {
							info.ReloadGuiBuilderProject ();
						}
					}
				}
				
				SteticApp.UpdateWidgetLibraries (false);
			}
			else {
				// Some gtk# packages don't include the .pc file unless you install gtk-sharp-devel
				if (Runtime.SystemAssemblyService.DefaultAssemblyContext.GetPackage ("gtk-sharp-2.0") == null) {
					string msg = GettextCatalog.GetString ("ERROR: MonoDevelop could not find the Gtk# 2.0 development package. Compilation of projects depending on Gtk# libraries will fail. You may need to install development packages for gtk-sharp-2.0.");
					args.ProgressMonitor.Log.WriteLine ();
					args.ProgressMonitor.Log.WriteLine (msg);
				}
			}
		}
Пример #5
0
		static void OnProjectCompiled (object s, BuildEventArgs args)
		{
			if (args.Success) {
				// Unload stetic projects which are not currently
				// being used by the IDE. This will avoid unnecessary updates.
				if (IdeApp.Workspace.IsOpen) {
					foreach (Project prj in IdeApp.Workspace.GetAllProjects ()) {
						if (!HasOpenDesigners (prj, false)) {
							GtkDesignInfo info = GtkDesignInfo.FromProject (prj);
							info.ReloadGuiBuilderProject ();
						}
					}
				}
				
				SteticApp.UpdateWidgetLibraries (false);
			}
		}
		void OnProjectBuilt (object s, BuildEventArgs args)
		{
			if (RefreshRequired) {
				UpdateTests ();
			} else {
				Gtk.Application.Invoke (delegate {
					OnProjectBuiltWithoutTestChange (EventArgs.Empty);
				});
			}
		}
		static void HandleEndBuild (object sender, BuildEventArgs args)
		{
			var project = args.SolutionItem as DotNetProject;
			if (project == null)
				return;
			CheckProjectOutput (project, true);
		}
		static void OnEndBuild (object s, BuildEventArgs args)
		{
			if (args.Success && IdeApp.Workspace.IsOpen) {
				Dictionary<string, AddinRegistry> regs = new Dictionary<string, AddinRegistry> ();
				foreach (DotNetProject p in IdeApp.Workspace.GetAllSolutionItems<DotNetProject> ()) {
					AddinData data = AddinData.GetAddinData (p);
					if (data != null) {
						if (!regs.ContainsKey (data.AddinRegistry.RegistryPath))
							regs [data.AddinRegistry.RegistryPath] = data.AddinRegistry;
					}
				}
				if (regs.Count > 0) {
					args.ProgressMonitor.BeginTask (AddinManager.CurrentLocalizer.GetString ("Updating add-in registry"), regs.Count);
					foreach (AddinRegistry reg in regs.Values) {
						reg.Update (new ProgressStatusMonitor (args.ProgressMonitor, 2));
						args.ProgressMonitor.Step (1);
					}
					args.ProgressMonitor.EndTask ();
				}
			}
		}
Пример #9
0
		public void OnEndBuild (object s, BuildEventArgs args)
		{
			compiledDesc = null;
			Fill ();
		}