本文整理汇总了C#中Solution.GetAddinData方法的典型用法代码示例。如果您正苦于以下问题:C# Solution.GetAddinData方法的具体用法?C# Solution.GetAddinData怎么用?C# Solution.GetAddinData使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Solution
的用法示例。
在下文中一共展示了Solution.GetAddinData方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Build
protected override BuildResult Build (IProgressMonitor monitor, Solution solution, ConfigurationSelector configuration)
{
try {
buildingSolution = true;
BuildResult res = base.Build (monitor, solution, configuration);
if (res.ErrorCount == 0) {
SolutionAddinData data = solution.GetAddinData ();
if (data != null && data.Registry != null) {
data.Registry.Update (new ProgressStatusMonitor (monitor));
DispatchService.GuiDispatch (delegate {
data.NotifyChanged ();
});
}
}
return res;
} finally {
buildingSolution = false;
}
}
示例2: Load
public void Load (Solution solution, DotNetProject project, bool forOptionsPanel)
{
AddinData data = AddinData.GetAddinData (project);
if (data != null && !forOptionsPanel) {
boxLibraryType.Visible = false;
AddinDescription desc = data.CachedAddinManifest;
if (project.CompileTarget != CompileTarget.Library || desc.IsRoot || solution.HasAddinRoot ()) {
boxRepo.Visible = false;
hseparator.Visible = false;
isRoot = true;
}
else {
if (solution.HasAddinRoot ())
boxRepo.Visible = false;
else if (solution.GetAddinData() != null) {
string app = solution.GetAddinData().ApplicationName;
if (app != null) {
regSelector.ApplicationName = app;
regSelector.Sensitive = false;
}
}
isRoot = false;
}
entryName.Text = project.Name;
entryId.Text = project.Name;
} else {
if (project.CompileTarget != CompileTarget.Library) {
// Editing options of an exe
labelExtensibleApp.Visible = data == null;
boxRepo.Visible = false;
boxLibraryType.Visible = false;
hseparator.Visible = false;
isRoot = true;
}
else {
// Editing options of an add-in or extensible library
labelExtensibleApp.Visible = false;
if (data != null && data.CachedAddinManifest != null && data.CachedAddinManifest.IsRoot)
radiobuttonLibrary.Active = true;
else
radiobuttonAddin.Active = true;
isRoot = radiobuttonLibrary.Active;
// There is a root in the solution. The target registry can't be selected.
if (solution.HasAddinRoot ())
boxRepo.Visible = false;
}
if (data != null) {
regSelector.ApplicationName = data.ApplicationName;
((Gtk.Container)tableNames.Parent).Remove (tableNames);
((Gtk.Container)labelAddinInfo.Parent).Remove (labelAddinInfo);
} else {
entryName.Text = project.Name;
entryId.Text = project.Name;
}
}
if (project.CompileTarget == CompileTarget.Library) {
if (radiobuttonLibrary.Active)
labelAddinInfo.Text = AddinManager.CurrentLocalizer.GetString ("Library information:");
else
labelAddinInfo.Text = AddinManager.CurrentLocalizer.GetString ("Add-in information:");
} else {
labelAddinInfo.Text = AddinManager.CurrentLocalizer.GetString ("Application information:");
}
UpdateControls ();
}
示例3: AddSolution
void AddSolution (Solution sol)
{
SolutionAddinData data = sol.GetAddinData ();
if (data != null) {
RegistryInfo reg = new RegistryInfo ();
reg.ApplicationName = data.ApplicationName;
reg.CachedRegistry = data.Registry;
tree.AddChild (reg);
registries [reg.CachedRegistry] = reg;
solutions [sol] = reg;
}
}