[Monodevelop-patches-list] r2127 - in trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding: . Gui Parser Project
commit-watcher at mono-cvs.ximian.com
commit-watcher at mono-cvs.ximian.com
Thu Jan 13 19:27:29 EST 2005
Author: lluis
Date: 2005-01-13 19:27:29 -0500 (Thu, 13 Jan 2005)
New Revision: 2127
Removed:
trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/CSharpBindingExecutionManager.cs.in
trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Gui/OutputOptionsPanel.cs
trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Project/CSharpProject.cs
Modified:
trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/CSharp.glade
trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/CSharpBinding.addin.xml
trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/CSharpBindingCompilerManager.cs
trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/CSharpLanguageBinding.cs
trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/ChangeLog
trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Gui/ChooseRuntimePanel.cs
trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Gui/CodeGenerationPanel.cs
trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Makefile.am
trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Parser/Parser.cs
trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Parser/Resolver.cs
trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Project/CSharpCompilerParameters.cs
Log:
2005-01-11 Lluis Sanchez Gual <lluis at novell.com>
* CSharpLanguageBinding.cs:
* Gui/ChooseRuntimePanel.cs:
* Gui/CodeGenerationPanel.cs:
* CSharpBindingCompilerManager.cs:
* CSharpBinding.addin.xml:
* Parser/Parser.cs:
* Parser/Resolver.cs: Follow architecture changes.
* Project/CSharpCompilerParameters.cs: Moved some parameters and enum
definitions to DotNetProjectConfiguration.
* CSharp.glade:
* Gui/OutputOptionsPanel.cs: Removed dialog now implemented in Monodevelop.Base.
* Project/CSharpProject.cs:
* CSharpBindingExecutionManager.cs.in: Removed. Not needed any more.
* Makefile.am: Updated.
Modified: trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/CSharp.glade
===================================================================
--- trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/CSharp.glade 2005-01-14 00:26:36 UTC (rev 2126)
+++ trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/CSharp.glade 2005-01-14 00:27:29 UTC (rev 2127)
@@ -469,568 +469,4 @@
</child>
</widget>
-<widget class="GtkWindow" id="OutputOptionsPanel">
- <property name="visible">True</property>
- <property name="title" translatable="yes">OutputOptionsPanel</property>
- <property name="type">GTK_WINDOW_TOPLEVEL</property>
- <property name="window_position">GTK_WIN_POS_NONE</property>
- <property name="modal">False</property>
- <property name="resizable">True</property>
- <property name="destroy_with_parent">False</property>
-
- <child>
- <widget class="GtkVBox" id="vbox66">
- <property name="visible">True</property>
- <property name="homogeneous">False</property>
- <property name="spacing">12</property>
-
- <child>
- <widget class="GtkVBox" id="vbox67">
- <property name="visible">True</property>
- <property name="homogeneous">False</property>
- <property name="spacing">6</property>
-
- <child>
- <widget class="GtkLabel" id="label93">
- <property name="visible">True</property>
- <property name="label" translatable="yes"><b>Output</b></property>
- <property name="use_underline">False</property>
- <property name="use_markup">True</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkHBox" id="hbox57">
- <property name="visible">True</property>
- <property name="homogeneous">False</property>
- <property name="spacing">6</property>
-
- <child>
- <widget class="GtkLabel" id="label91">
- <property name="visible">True</property>
- <property name="label" translatable="yes"> </property>
- <property name="use_underline">False</property>
- <property name="use_markup">False</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0.5</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkVBox" id="vbox69">
- <property name="visible">True</property>
- <property name="homogeneous">False</property>
- <property name="spacing">6</property>
-
- <child>
- <widget class="GtkTable" id="table10">
- <property name="visible">True</property>
- <property name="n_rows">3</property>
- <property name="n_columns">3</property>
- <property name="homogeneous">False</property>
- <property name="row_spacing">6</property>
- <property name="column_spacing">6</property>
-
- <child>
- <widget class="GtkLabel" id="label98">
- <property name="visible">True</property>
- <property name="label" translatable="yes">Assembly _name</property>
- <property name="use_underline">True</property>
- <property name="use_markup">False</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- <property name="mnemonic_widget">assemblyNameEntry</property>
- </widget>
- <packing>
- <property name="left_attach">0</property>
- <property name="right_attach">1</property>
- <property name="top_attach">0</property>
- <property name="bottom_attach">1</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkLabel" id="label99">
- <property name="visible">True</property>
- <property name="label" translatable="yes">Output _path</property>
- <property name="use_underline">True</property>
- <property name="use_markup">False</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- <property name="mnemonic_widget">outputDirectoryEntry</property>
- </widget>
- <packing>
- <property name="left_attach">0</property>
- <property name="right_attach">1</property>
- <property name="top_attach">1</property>
- <property name="bottom_attach">2</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkLabel" id="label100">
- <property name="visible">True</property>
- <property name="label" translatable="yes">Paramet_ers</property>
- <property name="use_underline">True</property>
- <property name="use_markup">False</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- <property name="mnemonic_widget">parametersEntry</property>
- </widget>
- <packing>
- <property name="left_attach">0</property>
- <property name="right_attach">1</property>
- <property name="top_attach">2</property>
- <property name="bottom_attach">3</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkEntry" id="outputDirectoryEntry">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="editable">True</property>
- <property name="visibility">True</property>
- <property name="max_length">0</property>
- <property name="text" translatable="yes"></property>
- <property name="has_frame">True</property>
- <property name="invisible_char" translatable="yes">*</property>
- <property name="activates_default">False</property>
- </widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="top_attach">1</property>
- <property name="bottom_attach">2</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkButton" id="browseButton">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="label" translatable="yes">...</property>
- <property name="use_underline">True</property>
- <property name="relief">GTK_RELIEF_NORMAL</property>
- </widget>
- <packing>
- <property name="left_attach">2</property>
- <property name="right_attach">3</property>
- <property name="top_attach">1</property>
- <property name="bottom_attach">2</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkEntry" id="assemblyNameEntry">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="editable">True</property>
- <property name="visibility">True</property>
- <property name="max_length">0</property>
- <property name="text" translatable="yes"></property>
- <property name="has_frame">True</property>
- <property name="invisible_char" translatable="yes">*</property>
- <property name="activates_default">False</property>
- </widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">3</property>
- <property name="top_attach">0</property>
- <property name="bottom_attach">1</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkEntry" id="parametersEntry">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="editable">True</property>
- <property name="visibility">True</property>
- <property name="max_length">0</property>
- <property name="text" translatable="yes"></property>
- <property name="has_frame">True</property>
- <property name="invisible_char" translatable="yes">*</property>
- <property name="activates_default">False</property>
- </widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">3</property>
- <property name="top_attach">2</property>
- <property name="bottom_attach">3</property>
- <property name="y_options"></property>
- </packing>
- </child>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkCheckButton" id="pauseConsoleOutputCheckButton">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="label" translatable="yes">Pause _console output</property>
- <property name="use_underline">True</property>
- <property name="relief">GTK_RELIEF_NORMAL</property>
- <property name="active">False</property>
- <property name="inconsistent">False</property>
- <property name="draw_indicator">True</property>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
- </child>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
- </child>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
- </child>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkVBox" id="vbox68">
- <property name="visible">True</property>
- <property name="homogeneous">False</property>
- <property name="spacing">6</property>
-
- <child>
- <widget class="GtkLabel" id="label94">
- <property name="visible">True</property>
- <property name="label" translatable="yes"><b>Execute scripts </b></property>
- <property name="use_underline">False</property>
- <property name="use_markup">True</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkHBox" id="hbox58">
- <property name="visible">True</property>
- <property name="homogeneous">False</property>
- <property name="spacing">6</property>
-
- <child>
- <widget class="GtkLabel" id="label92">
- <property name="visible">True</property>
- <property name="label" translatable="yes"> </property>
- <property name="use_underline">False</property>
- <property name="use_markup">False</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0.5</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkTable" id="table9">
- <property name="visible">True</property>
- <property name="n_rows">3</property>
- <property name="n_columns">3</property>
- <property name="homogeneous">False</property>
- <property name="row_spacing">6</property>
- <property name="column_spacing">6</property>
-
- <child>
- <widget class="GtkLabel" id="label95">
- <property name="visible">True</property>
- <property name="label" translatable="yes">Execute Command</property>
- <property name="use_underline">False</property>
- <property name="use_markup">False</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- </widget>
- <packing>
- <property name="left_attach">0</property>
- <property name="right_attach">1</property>
- <property name="top_attach">0</property>
- <property name="bottom_attach">1</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkLabel" id="label96">
- <property name="visible">True</property>
- <property name="label" translatable="yes">_After Build</property>
- <property name="use_underline">True</property>
- <property name="use_markup">False</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- <property name="mnemonic_widget">executeAfterEntry</property>
- </widget>
- <packing>
- <property name="left_attach">0</property>
- <property name="right_attach">1</property>
- <property name="top_attach">1</property>
- <property name="bottom_attach">2</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkLabel" id="label97">
- <property name="visible">True</property>
- <property name="label" translatable="yes">_Before build</property>
- <property name="use_underline">True</property>
- <property name="use_markup">False</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">0</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- <property name="mnemonic_widget">executeBeforeEntry</property>
- </widget>
- <packing>
- <property name="left_attach">0</property>
- <property name="right_attach">1</property>
- <property name="top_attach">2</property>
- <property name="bottom_attach">3</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkEntry" id="executeScriptEntry">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="editable">True</property>
- <property name="visibility">True</property>
- <property name="max_length">0</property>
- <property name="text" translatable="yes"></property>
- <property name="has_frame">True</property>
- <property name="invisible_char" translatable="yes">*</property>
- <property name="activates_default">False</property>
- </widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="top_attach">0</property>
- <property name="bottom_attach">1</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkEntry" id="executeAfterEntry">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="editable">True</property>
- <property name="visibility">True</property>
- <property name="max_length">0</property>
- <property name="text" translatable="yes"></property>
- <property name="has_frame">True</property>
- <property name="invisible_char" translatable="yes">*</property>
- <property name="activates_default">False</property>
- </widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="top_attach">1</property>
- <property name="bottom_attach">2</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkEntry" id="executeBeforeEntry">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="editable">True</property>
- <property name="visibility">True</property>
- <property name="max_length">0</property>
- <property name="text" translatable="yes"></property>
- <property name="has_frame">True</property>
- <property name="invisible_char" translatable="yes">*</property>
- <property name="activates_default">False</property>
- </widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="top_attach">2</property>
- <property name="bottom_attach">3</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkButton" id="browseButton2">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="label" translatable="yes">...</property>
- <property name="use_underline">True</property>
- <property name="relief">GTK_RELIEF_NORMAL</property>
- </widget>
- <packing>
- <property name="left_attach">2</property>
- <property name="right_attach">3</property>
- <property name="top_attach">0</property>
- <property name="bottom_attach">1</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkButton" id="browseButton3">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="label" translatable="yes">...</property>
- <property name="use_underline">True</property>
- <property name="relief">GTK_RELIEF_NORMAL</property>
- </widget>
- <packing>
- <property name="left_attach">2</property>
- <property name="right_attach">3</property>
- <property name="top_attach">1</property>
- <property name="bottom_attach">2</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkButton" id="browseButton4">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="label" translatable="yes">...</property>
- <property name="use_underline">True</property>
- <property name="relief">GTK_RELIEF_NORMAL</property>
- </widget>
- <packing>
- <property name="left_attach">2</property>
- <property name="right_attach">3</property>
- <property name="top_attach">2</property>
- <property name="bottom_attach">3</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
- </child>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
- </child>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
- </child>
- </widget>
- </child>
-</widget>
-
</glade-interface>
Modified: trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/CSharpBinding.addin.xml
===================================================================
--- trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/CSharpBinding.addin.xml 2005-01-14 00:26:36 UTC (rev 2126)
+++ trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/CSharpBinding.addin.xml 2005-01-14 00:27:29 UTC (rev 2127)
@@ -85,13 +85,13 @@
</Extension>
<Extension path = "/SharpDevelop/Workbench/ProjectOptions/ConfigurationProperties">
- <Conditional activeproject="C#">
+ <Conditional activelanguage="C#">
<DialogPanel id = "CSharpCodeGenerationPanel"
_label = "Code Generation"
class = "CSharpBinding.CodeGenerationPanel"/>
<DialogPanel id = "CSharpOutputOptionsPanel"
_label = "Output"
- class = "CSharpBinding.OutputOptionsPanel"/>
+ class = "MonoDevelop.Gui.Dialogs.OptionPanels.OutputOptionsPanel"/>
</Conditional>
</Extension>
Modified: trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/CSharpBindingCompilerManager.cs
===================================================================
--- trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/CSharpBindingCompilerManager.cs 2005-01-14 00:26:36 UTC (rev 2126)
+++ trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/CSharpBindingCompilerManager.cs 2005-01-14 00:27:29 UTC (rev 2127)
@@ -29,145 +29,46 @@
{
FileUtilityService fileUtilityService = (FileUtilityService)ServiceManager.GetService(typeof(FileUtilityService));
- public string GetCompiledOutputName(string fileName)
- {
- return Path.ChangeExtension(fileName, ".exe");
- }
-
- public string GetCompiledOutputName(IProject project)
- {
- CSharpProject p = (CSharpProject)project;
- CSharpCompilerParameters compilerparameters = (CSharpCompilerParameters)p.ActiveConfiguration;
- string exe = fileUtilityService.GetDirectoryNameWithSeparator(compilerparameters.OutputDirectory) + compilerparameters.OutputAssembly + (compilerparameters.CompileTarget == CompileTarget.Library ? ".dll" : ".exe");
- return exe;
- }
-
public bool CanCompile(string fileName)
{
return Path.GetExtension(fileName).ToUpper() == ".CS";
}
-
- public ICompilerResult CompileFile(string filename, CSharpCompilerParameters compilerparameters)
- {
- string output = "";
- string error = "";
- string exe = Path.ChangeExtension(filename, ".exe");
- if (compilerparameters.OutputAssembly != null && compilerparameters.OutputAssembly.Length > 0) {
- exe = compilerparameters.OutputAssembly;
- }
- string responseFileName = Path.GetTempFileName();
-
- StreamWriter writer = new StreamWriter(responseFileName);
- writer.WriteLine("\"/out:" + exe + '"');
-
- writer.WriteLine("/nologo");
- writer.WriteLine("/utf8output");
- writer.WriteLine("/w:" + compilerparameters.WarningLevel);
-
- if (compilerparameters.Debugmode) {
- writer.WriteLine("/debug:+");
- writer.WriteLine("/debug:full");
- writer.WriteLine("/d:DEBUG");
- }
-
- if (!compilerparameters.RunWithWarnings) {
- writer.WriteLine("/warnaserror+");
- }
-
- if (compilerparameters.Optimize) {
- writer.WriteLine("/o");
- }
-
- if (compilerparameters.UnsafeCode) {
- writer.WriteLine("/unsafe");
- }
-
- if (compilerparameters.DefineSymbols.Length > 0) {
- writer.WriteLine("/define:" + '"' + compilerparameters.DefineSymbols + '"');
- }
-
- switch (compilerparameters.CompileTarget) {
- case CompileTarget.Exe:
- writer.WriteLine("/target:exe");
- break;
- case CompileTarget.WinExe:
- writer.WriteLine("/target:winexe");
- break;
- case CompileTarget.Library:
- writer.WriteLine("/target:library");
- break;
- case CompileTarget.Module:
- writer.WriteLine("/target:module");
- break;
- }
-
- writer.WriteLine('"' + filename + '"');
-
- TempFileCollection tf = new TempFileCollection ();
-
- if (compilerparameters.GenerateXmlDocumentation) {
- writer.WriteLine("\"/doc:" + Path.ChangeExtension(exe, ".xml") + '"');
- }
-
- writer.Close();
-
- // add " to the responseFileName when they aren't there
- if (!responseFileName.StartsWith("\"") && !responseFileName.EndsWith("\"")) {
- responseFileName = String.Concat("\"", responseFileName, "\"");
- }
-
- string compilerName = compilerparameters.CsharpCompiler == CsharpCompiler.Csc ? GetCompilerName() : "mcs";
- string outstr = compilerName + " @" +responseFileName;
- Executor.ExecWaitWithCapture(outstr, tf, ref output, ref error);
-
- ICompilerResult result = ParseOutput(tf, output, error);
-
- File.Delete(responseFileName);
- File.Delete(output);
- File.Delete(error);
- return result;
- }
-
- public ICompilerResult CompileProject(IProject project)
+ public ICompilerResult Compile (ProjectFileCollection projectFiles, ProjectReferenceCollection references, DotNetProjectConfiguration configuration)
{
- CSharpProject p = (CSharpProject)project;
- CSharpCompilerParameters compilerparameters = (CSharpCompilerParameters)p.ActiveConfiguration;
+ CSharpCompilerParameters compilerparameters = (CSharpCompilerParameters) configuration.CompilationParameters;
+ if (compilerparameters == null) compilerparameters = new CSharpCompilerParameters ();
- string exe = fileUtilityService.GetDirectoryNameWithSeparator(compilerparameters.OutputDirectory) + compilerparameters.OutputAssembly + (compilerparameters.CompileTarget == CompileTarget.Library ? ".dll" : ".exe");
+ string exe = configuration.CompiledOutputName;
string responseFileName = Path.GetTempFileName();
StreamWriter writer = new StreamWriter(responseFileName);
- string optionString = compilerparameters.CsharpCompiler == CsharpCompiler.Csc ? "/" : "-";
-
if (compilerparameters.CsharpCompiler == CsharpCompiler.Csc) {
writer.WriteLine("\"/out:" + exe + '"');
IProjectService projectService = (IProjectService)MonoDevelop.Core.Services.ServiceManager.GetService(typeof(IProjectService));
- ArrayList allProjects = Combine.GetAllProjects(projectService.CurrentOpenCombine);
- SystemAssemblyService sas = (SystemAssemblyService)ServiceManager.GetService (typeof (SystemAssemblyService));
ArrayList pkg_references = new ArrayList ();
- foreach (ProjectReference lib in project.ProjectReferences) {
- switch (lib.ReferenceType) {
- case ReferenceType.Gac:
- string pkg = sas.GetPackageFromFullName (lib.Reference);
- if (pkg.Trim () == String.Empty)
- continue;
- if (pkg == "MONO-SYSTEM") {
- writer.WriteLine ("\"/r:" + Path.GetFileName (lib.GetReferencedFileName (project)) + "\"");
- } else if (!pkg_references.Contains (pkg)) {
- pkg_references.Add (pkg);
- writer.WriteLine ("\"-pkg:" + pkg + "\"");
+
+ if (references != null) {
+ foreach (ProjectReference lib in references) {
+ string fileName = lib.GetReferencedFileName ();
+ switch (lib.ReferenceType) {
+ case ReferenceType.Gac:
+ string pkg = Runtime.SystemAssemblyService.GetPackageFromFullName (lib.Reference);
+ if (pkg.Trim () == String.Empty)
+ continue;
+ if (pkg == "MONO-SYSTEM") {
+ writer.WriteLine ("\"/r:" + Path.GetFileName (fileName) + "\"");
+ } else if (!pkg_references.Contains (pkg)) {
+ pkg_references.Add (pkg);
+ writer.WriteLine ("\"-pkg:" + pkg + "\"");
+ }
+ break;
+ case ReferenceType.Assembly:
+ case ReferenceType.Project:
+ writer.WriteLine ("\"/r:" + fileName + "\"");
+ break;
}
- break;
- case ReferenceType.Assembly:
- string assembly_fileName = lib.GetReferencedFileName (project);
- writer.WriteLine ("\"/r:" + assembly_fileName + "\"");
- break;
- case ReferenceType.Project:
- string project_fileName = lib.GetReferencedFileName (project);
- writer.WriteLine ("\"/r:" + project_fileName + "\"");
- break;
}
}
@@ -176,7 +77,7 @@
// writer.WriteLine("/utf8output");
// writer.WriteLine("/w:" + compilerparameters.WarningLevel);;
- if (compilerparameters.Debugmode) {
+ if (configuration.DebugMode) {
writer.WriteLine("/debug:+");
writer.WriteLine("/debug:full");
writer.WriteLine("/d:DEBUG");
@@ -186,7 +87,7 @@
// writer.WriteLine("/o");
// }
- if (compilerparameters.Win32Icon != null && compilerparameters.Win32Icon.Length > 0 && File.Exists(compilerparameters.Win32Icon)) {
+ if (compilerparameters.Win32Icon != null && compilerparameters.Win32Icon.Length > 0 && File.Exists (compilerparameters.Win32Icon)) {
writer.WriteLine("\"/win32icon:" + compilerparameters.Win32Icon + "\"");
}
@@ -202,7 +103,7 @@
writer.WriteLine("/main:" + compilerparameters.MainClass);
}
- switch (compilerparameters.CompileTarget) {
+ switch (configuration.CompileTarget) {
case CompileTarget.Exe:
writer.WriteLine("/t:exe");
break;
@@ -214,7 +115,7 @@
break;
}
- foreach (ProjectFile finfo in p.ProjectFiles) {
+ foreach (ProjectFile finfo in projectFiles) {
if (finfo.Subtype != Subtype.Directory) {
switch (finfo.BuildAction) {
case BuildAction.Compile:
@@ -227,11 +128,6 @@
break;
}
}
-
- // Treat app.config in the project root directory as the application config
- if(Path.GetFileName(finfo.Name).ToUpper()=="app.config".ToUpper() &&
- Path.GetDirectoryName(finfo.Name)==p.BaseDirectory)
- File.Copy(finfo.Name,exe+".config",true);
}
if (compilerparameters.GenerateXmlDocumentation) {
writer.WriteLine("\"/doc:" + Path.ChangeExtension(exe, ".xml") + '"');
@@ -246,14 +142,15 @@
writer.WriteLine("--wlevel " + compilerparameters.WarningLevel);
IProjectService projectService = (IProjectService)MonoDevelop.Core.Services.ServiceManager.GetService(typeof(IProjectService));
- ArrayList allProjects = Combine.GetAllProjects(projectService.CurrentOpenCombine);
-
- foreach (ProjectReference lib in p.ProjectReferences) {
- string fileName = lib.GetReferencedFileName(p);
- writer.WriteLine("-r:" + fileName );
+
+ if (references != null) {
+ foreach (ProjectReference lib in references) {
+ string fileName = lib.GetReferencedFileName ();
+ writer.WriteLine("-r:" + fileName );
+ }
}
- switch (compilerparameters.CompileTarget) {
+ switch (configuration.CompileTarget) {
case CompileTarget.Exe:
writer.WriteLine("--target exe");
break;
@@ -264,7 +161,7 @@
writer.WriteLine("--target library");
break;
}
- foreach (ProjectFile finfo in p.ProjectFiles) {
+ foreach (ProjectFile finfo in projectFiles) {
if (finfo.Subtype != Subtype.Directory) {
switch (finfo.BuildAction) {
case BuildAction.Compile:
@@ -294,26 +191,25 @@
DoCompilation(outstr, tf, ref output, ref error);
ICompilerResult result = ParseOutput(tf, output, error);
- project.CopyReferencesToOutputPath(false);
File.Delete(responseFileName);
File.Delete(output);
File.Delete(error);
return result;
}
-
- public void GenerateMakefile (IProject project, Combine parentCombine)
+
+ public void GenerateMakefile (Project project, Combine parentCombine)
{
StreamWriter stream = new StreamWriter (Path.Combine (project.BaseDirectory, "Makefile." + project.Name.Replace (" ", "")));
- CSharpProject p = (CSharpProject)project;
- CSharpCompilerParameters compilerparameters = (CSharpCompilerParameters)p.ActiveConfiguration;
+ DotNetProjectConfiguration conf = (DotNetProjectConfiguration) project.ActiveConfiguration;
+ CSharpCompilerParameters compilerparameters = (CSharpCompilerParameters) conf.CompilationParameters;
- string outputName = compilerparameters.OutputAssembly + (compilerparameters.CompileTarget == CompileTarget.Library ? ".dll" : ".exe");
+ string outputName = conf.CompiledOutputName;
string target = "";
string relativeOutputDir = fileUtilityService.AbsoluteToRelativePath (project.BaseDirectory, parentCombine.OutputDirectory);
- switch (compilerparameters.CompileTarget) {
+ switch (conf.CompileTarget) {
case CompileTarget.Exe:
target = "exe";
break;
@@ -349,34 +245,33 @@
}
}
- SystemAssemblyService sas = (SystemAssemblyService)ServiceManager.GetService (typeof (SystemAssemblyService));
foreach (ProjectReference lib in project.ProjectReferences) {
switch (lib.ReferenceType) {
case ReferenceType.Gac:
- string pkg = sas.GetPackageFromFullName (lib.Reference);
+ string pkg = Runtime.SystemAssemblyService.GetPackageFromFullName (lib.Reference);
if (pkg.Trim () == String.Empty)
continue;
if (pkg == "MONO-SYSTEM") {
- system_references.Add (Path.GetFileName (lib.GetReferencedFileName (project)));
+ system_references.Add (Path.GetFileName (lib.GetReferencedFileName ()));
} else if (!pkg_references.Contains (pkg)) {
pkg_references.Add (pkg);
}
break;
case ReferenceType.Assembly:
- string assembly_fileName = lib.GetReferencedFileName (project);
+ string assembly_fileName = lib.GetReferencedFileName ();
string rel_path_to = fileUtilityService.AbsoluteToRelativePath (project.BaseDirectory, Path.GetDirectoryName (assembly_fileName));
assembly_references.Add (Path.Combine (rel_path_to, Path.GetFileName (assembly_fileName)));
break;
case ReferenceType.Project:
- string project_fileName = lib.GetReferencedFileName (project);
+ string project_fileName = lib.GetReferencedFileName ();
IProjectService prjService = (IProjectService)ServiceManager.GetService (typeof (IProjectService));
- ArrayList allProjects = Combine.GetAllProjects(prjService.CurrentOpenCombine);
+ CombineEntryCollection allProjects = prjService.CurrentOpenCombine.GetAllProjects();
- foreach (ProjectCombineEntry projectEntry in allProjects) {
- if (projectEntry.Project.Name == lib.Reference) {
- string project_base_dir = fileUtilityService.AbsoluteToRelativePath (project.BaseDirectory, projectEntry.Project.BaseDirectory);
+ foreach (Project projectEntry in allProjects) {
+ if (projectEntry.Name == lib.Reference) {
+ string project_base_dir = fileUtilityService.AbsoluteToRelativePath (project.BaseDirectory, projectEntry.BaseDirectory);
- string project_output_fileName = prjService.GetOutputAssemblyName (projectEntry.Project);
+ string project_output_fileName = projectEntry.GetOutputFileName ();
project_references.Add (Path.Combine (project_base_dir, Path.GetFileName (project_output_fileName)));
}
}
@@ -576,7 +471,6 @@
ret = ret + "bin/mcs";
}
return ret;
-
}
ICompilerResult ParseOutput(TempFileCollection tf, string stdout, string stderr)
@@ -647,13 +541,13 @@
bool done ()
{
- ((SdStatusBar)Runtime.Gui.StatusBar.Control).Done ();
+ Runtime.Gui.StatusBar.ProgressMonitor.Done ();
return false;
}
bool pulse ()
{
- ((SdStatusBar)Runtime.Gui.StatusBar.Control).Pulse ();
+ Runtime.Gui.StatusBar.ProgressMonitor.Pulse ();
while (Gtk.Application.EventsPending ())
Gtk.Application.RunIteration ();
return false;
Deleted: trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/CSharpBindingExecutionManager.cs.in
===================================================================
--- trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/CSharpBindingExecutionManager.cs.in 2005-01-14 00:26:36 UTC (rev 2126)
+++ trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/CSharpBindingExecutionManager.cs.in 2005-01-14 00:27:29 UTC (rev 2127)
@@ -1,109 +0,0 @@
-// <file>
-// <copyright see="prj:///doc/copyright.txt"/>
-// <license see="prj:///doc/license.txt"/>
-// <owner name="Mike Krüger" email="mike at icsharpcode.net"/>
-// <version value="$version"/>
-// </file>
-
-using System;
-using System.IO;
-using System.Diagnostics;
-using System.Collections;
-using System.Reflection;
-using System.Resources;
-using System.Xml;
-using System.CodeDom.Compiler;
-using System.Threading;
-
-using MonoDevelop.Internal.Project;
-using MonoDevelop.Gui;
-using MonoDevelop.Core.Services;
-using MonoDevelop.Services;
-
-namespace CSharpBinding
-{
- /// <summary>
- /// This class describes the main functionalaty of a language codon
- /// </summary>
- public class CSharpBindingExecutionManager
- {
- public void Debug (IProject project)
- {
- FileUtilityService fileUtilityService = (FileUtilityService) ServiceManager.GetService (typeof (FileUtilityService));
- string directory = fileUtilityService.GetDirectoryNameWithSeparator(((CSharpCompilerParameters)project.ActiveConfiguration).OutputDirectory);
- string exe = ((CSharpCompilerParameters)project.ActiveConfiguration).OutputAssembly + ".exe";
-
- IDebuggingService dbgr = (IDebuggingService) ServiceManager.GetService (typeof (IDebuggingService));
- if (dbgr != null)
- dbgr.Run (new string[] { Path.Combine (directory, exe) } );
- }
-
- public void Execute(string filename)
- {
- string exe = Path.ChangeExtension(filename, ".exe");
-
- ProcessStartInfo psi = new ProcessStartInfo("@RUNTIME@ " + exe);
- psi.WorkingDirectory = Path.GetDirectoryName(exe);
- psi.UseShellExecute = false;
- try {
- Process p = new Process();
- p.StartInfo = psi;
- p.Start();
- } catch (Exception) {
- throw new ApplicationException("Can not execute " + "\"" + exe + "\"\n(Try restarting MonoDevelop or start your app manually)");
- }
- }
-
- public void Execute(IProject project)
- {
- CSharpCompilerParameters parameters = (CSharpCompilerParameters)project.ActiveConfiguration;
- FileUtilityService fileUtilityService = (FileUtilityService)ServiceManager.GetService(typeof(FileUtilityService));
-
- string directory = fileUtilityService.GetDirectoryNameWithSeparator(((CSharpCompilerParameters)project.ActiveConfiguration).OutputDirectory);
- string exe = ((CSharpCompilerParameters)project.ActiveConfiguration).OutputAssembly + ".exe";
- string args = ((CSharpCompilerParameters)project.ActiveConfiguration).CommandLineParameters;
-
- ProcessStartInfo psi;
- if (parameters.ExecuteScript != null && parameters.ExecuteScript.Length > 0) {
- string additionalCommands = "";
- if (parameters.PauseConsoleOutput)
- additionalCommands = @"echo; read -p 'press any key to continue...' -n1;";
- psi = new ProcessStartInfo("xterm",
- String.Format (@"-e ""cd {3} ; '{0}' {1} ; {2}""", parameters.ExecuteScript, args, additionalCommands, project.BaseDirectory));
- psi.UseShellExecute = false;
- } else {
- string runtimeStarter = "mono --debug ";
-
- switch (parameters.NetRuntime) {
- case NetRuntime.Mono:
- runtimeStarter = "mono --debug ";
- break;
- case NetRuntime.MonoInterpreter:
- runtimeStarter = "mint ";
- break;
- }
-
- string additionalCommands = "";
- if (parameters.PauseConsoleOutput)
- additionalCommands = @"echo; read -p 'press any key to continue...' -n1;";
-
- psi = new ProcessStartInfo("xterm",
- string.Format (
- @"-e ""{0} '{1}{2}' {3} ; {4}""",
- runtimeStarter, directory, exe, args, additionalCommands));
- psi.UseShellExecute = false;
- }
-
- try {
- psi.WorkingDirectory = Path.GetDirectoryName(directory);
- psi.UseShellExecute = false;
-
- Process p = new Process();
- p.StartInfo = psi;
- p.Start();
- } catch (Exception) {
- throw new ApplicationException("Can not execute " + "\"" + directory + exe + "\"\n(Try restarting MonoDevelop or start your app manually)");
- }
- }
- }
-}
Modified: trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/CSharpLanguageBinding.cs
===================================================================
--- trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/CSharpLanguageBinding.cs 2005-01-14 00:26:36 UTC (rev 2126)
+++ trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/CSharpLanguageBinding.cs 2005-01-14 00:27:29 UTC (rev 2127)
@@ -18,6 +18,7 @@
using MonoDevelop.Internal.Project;
using MonoDevelop.Internal.Templates;
using MonoDevelop.Gui;
+using MonoDevelop.Services;
namespace CSharpBinding
{
@@ -26,78 +27,40 @@
public const string LanguageName = "C#";
CSharpBindingCompilerManager compilerManager = new CSharpBindingCompilerManager();
- CSharpBindingExecutionManager executionManager = new CSharpBindingExecutionManager();
+ public CSharpLanguageBinding ()
+ {
+ Runtime.ProjectService.DataContext.IncludeType (typeof(CSharpCompilerParameters));
+ }
+
public string Language {
get {
return LanguageName;
}
}
- public void Execute(string filename)
- {
- Debug.Assert(executionManager != null);
- executionManager.Execute(filename);
- }
-
- public void Execute(IProject project)
- {
- Debug.Assert(executionManager != null);
- executionManager.Execute(project);
- }
-
- public void DebugProject (IProject project)
- {
- executionManager.Debug (project);
- }
-
- public string GetCompiledOutputName(string fileName)
- {
- Debug.Assert(compilerManager != null);
- return compilerManager.GetCompiledOutputName(fileName);
- }
-
- public string GetCompiledOutputName(IProject project)
- {
- Debug.Assert(compilerManager != null);
- return compilerManager.GetCompiledOutputName(project);
- }
-
public bool CanCompile(string fileName)
{
Debug.Assert(compilerManager != null);
return compilerManager.CanCompile(fileName);
}
- public ICompilerResult CompileFile(string fileName)
+ public ICompilerResult Compile (ProjectFileCollection projectFiles, ProjectReferenceCollection references, DotNetProjectConfiguration configuration)
{
Debug.Assert(compilerManager != null);
- CSharpCompilerParameters param = new CSharpCompilerParameters();
- param.OutputAssembly = Path.ChangeExtension(fileName, ".exe");
- return compilerManager.CompileFile(fileName, param);
+ return compilerManager.Compile (projectFiles, references, configuration);
}
- public ICompilerResult CompileProject(IProject project)
+ public void GenerateMakefile (Project project, Combine parentCombine)
{
- Debug.Assert(compilerManager != null);
- return compilerManager.CompileProject(project);
+ compilerManager.GenerateMakefile (project, parentCombine);
}
- public ICompilerResult RecompileProject(IProject project)
+ public object CreateCompilationParameters (XmlElement projectOptions)
{
- return CompileProject(project);
+ return new CSharpCompilerParameters();
}
- public IProject CreateProject(ProjectCreateInformation info, XmlElement projectOptions)
- {
- return new CSharpProject(info, projectOptions);
- }
-
- public void GenerateMakefile (IProject project, Combine parentCombine)
- {
- compilerManager.GenerateMakefile (project, parentCombine);
- }
-
public string CommentTag
{
get { return "//"; }
Modified: trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/ChangeLog
===================================================================
--- trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/ChangeLog 2005-01-14 00:26:36 UTC (rev 2126)
+++ trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/ChangeLog 2005-01-14 00:27:29 UTC (rev 2127)
@@ -1,3 +1,24 @@
+2005-01-11 Lluis Sanchez Gual <lluis at novell.com>
+
+ * CSharpLanguageBinding.cs:
+ * Gui/ChooseRuntimePanel.cs:
+ * Gui/CodeGenerationPanel.cs:
+ * CSharpBindingCompilerManager.cs:
+ * CSharpBinding.addin.xml:
+ * Parser/Parser.cs:
+ * Parser/Resolver.cs: Follow architecture changes.
+
+ * Project/CSharpCompilerParameters.cs: Moved some parameters and enum
+ definitions to DotNetProjectConfiguration.
+
+ * CSharp.glade:
+ * Gui/OutputOptionsPanel.cs: Removed dialog now implemented in Monodevelop.Base.
+
+ * Project/CSharpProject.cs:
+ * CSharpBindingExecutionManager.cs.in: Removed. Not needed any more.
+
+ * Makefile.am: Updated.
+
2004-12-13 Lluis Sanchez Gual <lluis at novell.com>
* CSharpBindingCompilerManager.cs: StatusBarService.ProgressMonitor is
Modified: trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Gui/ChooseRuntimePanel.cs
===================================================================
--- trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Gui/ChooseRuntimePanel.cs 2005-01-14 00:26:36 UTC (rev 2126)
+++ trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Gui/ChooseRuntimePanel.cs 2005-01-14 00:27:29 UTC (rev 2127)
@@ -21,7 +21,9 @@
{
public class ChooseRuntimePanel : AbstractOptionPanel
{
- CSharpCompilerParameters config = null;
+ CSharpCompilerParameters parameters;
+ DotNetProjectConfiguration config;
+
// FIXME: set the right rb groups
RadioButton msnetRadioButton = new RadioButton ("Msnet");
RadioButton monoRadioButton = new RadioButton ("Mono");
@@ -31,14 +33,15 @@
public override void LoadPanelContents()
{
- this.config = (CSharpCompilerParameters)((IProperties)CustomizationObject).GetProperty("Config");
+ config = (DotNetProjectConfiguration)((IProperties)CustomizationObject).GetProperty("Config");
+ parameters = (CSharpCompilerParameters) config.CompilationParameters;
msnetRadioButton.Active = config.NetRuntime == NetRuntime.MsNet;
monoRadioButton.Active = config.NetRuntime == NetRuntime.Mono;
mintRadioButton.Active = config.NetRuntime == NetRuntime.MonoInterpreter;
- cscRadioButton.Active = config.CsharpCompiler == CsharpCompiler.Csc;
- mcsRadioButton.Active = config.CsharpCompiler == CsharpCompiler.Mcs;
+ cscRadioButton.Active = parameters.CsharpCompiler == CsharpCompiler.Csc;
+ mcsRadioButton.Active = parameters.CsharpCompiler == CsharpCompiler.Mcs;
}
public override bool StorePanelContents()
@@ -50,7 +53,7 @@
} else {
config.NetRuntime = NetRuntime.MonoInterpreter;
}
- config.CsharpCompiler = cscRadioButton.Active ? CsharpCompiler.Csc : CsharpCompiler.Mcs;
+ parameters.CsharpCompiler = cscRadioButton.Active ? CsharpCompiler.Csc : CsharpCompiler.Mcs;
return true;
}
Modified: trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Gui/CodeGenerationPanel.cs
===================================================================
--- trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Gui/CodeGenerationPanel.cs 2005-01-14 00:26:36 UTC (rev 2126)
+++ trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Gui/CodeGenerationPanel.cs 2005-01-14 00:27:29 UTC (rev 2127)
@@ -50,12 +50,15 @@
StringParserService StringParserService = (StringParserService)ServiceManager.GetService (
typeof (StringParserService));
+ DotNetProjectConfiguration configuration;
CSharpCompilerParameters compilerParameters = null;
public CodeGenerationPanelWidget(IProperties CustomizationObject) : base ("CSharp.glade", "CodeGenerationPanel")
{
- this.compilerParameters = (CSharpCompilerParameters)((IProperties)CustomizationObject).GetProperty("Config");
-
+ configuration = (DotNetProjectConfiguration)((IProperties)CustomizationObject).GetProperty("Config");
+
+ compilerParameters = (CSharpCompilerParameters) configuration.CompilationParameters;
+
// FIXME: Enable when mcs has this feature
generateXmlOutputCheckButton.Sensitive = false;
@@ -69,18 +72,18 @@
// "${res:Dialog.Options.PrjOptions.Configuration.CompileTarget.Module}")));
CompileTargetOptionMenu.Menu = CompileTargetMenu;
- CompileTargetOptionMenu.SetHistory ( (uint) compilerParameters.CompileTarget);
+ CompileTargetOptionMenu.SetHistory ( (uint) configuration.CompileTarget);
symbolsEntry.Text = compilerParameters.DefineSymbols;
mainClassEntry.Text = compilerParameters.MainClass;
- generateDebugInformationCheckButton.Active = compilerParameters.Debugmode;
+ generateDebugInformationCheckButton.Active = configuration.DebugMode;
generateXmlOutputCheckButton.Active = compilerParameters.GenerateXmlDocumentation;
enableOptimizationCheckButton.Active = compilerParameters.Optimize;
allowUnsafeCodeCheckButton.Active = compilerParameters.UnsafeCode;
generateOverflowChecksCheckButton.Active = compilerParameters.GenerateOverflowChecks;
- warningsAsErrorsCheckButton.Active = ! compilerParameters.RunWithWarnings;
+ warningsAsErrorsCheckButton.Active = ! configuration.RunWithWarnings;
warningLevelSpinButton.Value = compilerParameters.WarningLevel;
}
@@ -89,16 +92,16 @@
if (compilerParameters == null) {
return true;
}
- compilerParameters.CompileTarget = (CompileTarget) CompileTargetOptionMenu.History;
+ configuration.CompileTarget = (CompileTarget) CompileTargetOptionMenu.History;
compilerParameters.DefineSymbols = symbolsEntry.Text;
compilerParameters.MainClass = mainClassEntry.Text;
- compilerParameters.Debugmode = generateDebugInformationCheckButton.Active;
+ configuration.DebugMode = generateDebugInformationCheckButton.Active;
compilerParameters.GenerateXmlDocumentation = generateXmlOutputCheckButton.Active;
compilerParameters.Optimize = enableOptimizationCheckButton.Active;
compilerParameters.UnsafeCode = allowUnsafeCodeCheckButton.Active;
compilerParameters.GenerateOverflowChecks = generateOverflowChecksCheckButton.Active;
- compilerParameters.RunWithWarnings = ! warningsAsErrorsCheckButton.Active;
+ configuration.RunWithWarnings = ! warningsAsErrorsCheckButton.Active;
compilerParameters.WarningLevel = warningLevelSpinButton.ValueAsInt;
Deleted: trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Gui/OutputOptionsPanel.cs
===================================================================
--- trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Gui/OutputOptionsPanel.cs 2005-01-14 00:26:36 UTC (rev 2126)
+++ trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Gui/OutputOptionsPanel.cs 2005-01-14 00:27:29 UTC (rev 2127)
@@ -1,163 +0,0 @@
-// <file>
-// <copyright see="prj:///doc/copyright.txt"/>
-// <license see="prj:///doc/license.txt"/>
-// <owner name="Mike Krger" email="mike at icsharpcode.net"/>
-// <version value="$version"/>
-// </file>
-
-using System;
-using System.IO;
-using System.Drawing;
-
-using MonoDevelop.Internal.Project;
-using MonoDevelop.Internal.ExternalTool;
-using MonoDevelop.Gui.Dialogs;
-using MonoDevelop.Gui.Widgets;
-using MonoDevelop.Core.Services;
-using MonoDevelop.Core.Properties;
-using MonoDevelop.Core.AddIns.Codons;
-using MonoDevelop.Services;
-
-using Gtk;
-
-namespace CSharpBinding
-{
- public class OutputOptionsPanel : AbstractOptionPanel
- {
- static MessageService messageService = (MessageService) ServiceManager.GetService (typeof (MessageService));
-
- class OutputOptionsPanelWidget : GladeWidgetExtract
- {
- //
- // Gtk Controls
- //
- [Glade.Widget] Entry assemblyNameEntry;
- [Glade.Widget] Entry outputDirectoryEntry;
- [Glade.Widget] Entry parametersEntry;
- [Glade.Widget] Entry executeBeforeEntry;
- [Glade.Widget] Entry executeScriptEntry;
- [Glade.Widget] Entry executeAfterEntry;
- [Glade.Widget] CheckButton pauseConsoleOutputCheckButton;
- [Glade.Widget] Button browseButton;
- [Glade.Widget] Button browseButton2;
- [Glade.Widget] Button browseButton3;
- [Glade.Widget] Button browseButton4;
-
- CSharpCompilerParameters compilerParameters;
-
- public OutputOptionsPanelWidget(IProperties CustomizationObject) : base ("CSharp.glade", "OutputOptionsPanel")
- {
- this.compilerParameters = (CSharpCompilerParameters)((IProperties)CustomizationObject).GetProperty("Config");
- browseButton.Clicked += new EventHandler (SelectFolder);
- browseButton2.Clicked += new EventHandler (SelectFile4);
- browseButton3.Clicked += new EventHandler (SelectFile3);
- browseButton4.Clicked += new EventHandler (SelectFile2);
-
- assemblyNameEntry.Text = compilerParameters.OutputAssembly;
- outputDirectoryEntry.Text = compilerParameters.OutputDirectory;
- parametersEntry.Text = compilerParameters.CommandLineParameters;
- executeScriptEntry.Text = compilerParameters.ExecuteScript;
- executeBeforeEntry.Text = compilerParameters.ExecuteBeforeBuild;
- executeAfterEntry.Text = compilerParameters.ExecuteAfterBuild;
-
- pauseConsoleOutputCheckButton.Active = compilerParameters.PauseConsoleOutput;
- }
-
- public bool Store ()
- {
- if (compilerParameters == null) {
- return true;
- }
-
- FileUtilityService fileUtilityService = (FileUtilityService) ServiceManager.GetService (typeof (FileUtilityService));
-
- if (!fileUtilityService.IsValidFileName(assemblyNameEntry.Text)) {
- messageService.ShowError (GettextCatalog.GetString ("Invalid assembly name specified"));
- return false;
- }
-
- if (!fileUtilityService.IsValidFileName (outputDirectoryEntry.Text)) {
- messageService.ShowError (GettextCatalog.GetString ("Invalid output directory specified"));
- return false;
- }
-
- compilerParameters.OutputAssembly = assemblyNameEntry.Text;
- compilerParameters.OutputDirectory = outputDirectoryEntry.Text;
- compilerParameters.CommandLineParameters = parametersEntry.Text;
- compilerParameters.ExecuteBeforeBuild = executeBeforeEntry.Text;
- compilerParameters.ExecuteAfterBuild = executeAfterEntry.Text;
- compilerParameters.ExecuteScript = executeScriptEntry.Text;
-
- compilerParameters.PauseConsoleOutput = pauseConsoleOutputCheckButton.Active;
- return true;
- }
-
- void SelectFolder(object sender, EventArgs e)
- {
- using (FileSelector fdiag = new FileSelector (GettextCatalog.GetString ("Select the directory in which the assembly will be created"))) {
- if (fdiag.Run () == (int) ResponseType.Ok) {
- outputDirectoryEntry.Text = fdiag.Filename;
- }
-
- fdiag.Hide ();
- }
- }
-
- void SelectFile2(object sender, EventArgs e)
- {
- using (FileSelector fdiag = new FileSelector ("")) {
- //fdiag.Filter = StringParserService.Parse("${res:SharpDevelop.FileFilter.AllFiles}|*.*");
- fdiag.SelectMultiple = false;
-
- if(fdiag.Run () == (int) ResponseType.Ok) {
- executeBeforeEntry.Text = fdiag.Filename;
- }
-
- fdiag.Hide ();
- }
- }
-
- void SelectFile3(object sender, EventArgs e)
- {
- using (FileSelector fdiag = new FileSelector ("")) {
- //fdiag.Filter = StringParserService.Parse("${res:SharpDevelop.FileFilter.AllFiles}|*.*");
- fdiag.SelectMultiple = false;
-
- if(fdiag.Run () == (int) ResponseType.Ok) {
- executeAfterEntry.Text = fdiag.Filename;
- }
-
- fdiag.Hide ();
- }
- }
-
- void SelectFile4(object sender, EventArgs e)
- {
- using (FileSelector fdiag = new FileSelector ("")) {
- //fdiag.Filter = StringParserService.Parse("${res:SharpDevelop.FileFilter.AllFiles}|*.*");
- fdiag.SelectMultiple = false;
-
- if(fdiag.Run () == (int) ResponseType.Ok) {
- executeScriptEntry.Text = fdiag.Filename;
- }
-
- fdiag.Hide ();
- }
- }
- }
-
- OutputOptionsPanelWidget widget;
-
- public override void LoadPanelContents()
- {
- Add (widget = new OutputOptionsPanelWidget ((IProperties) CustomizationObject));
- }
-
- public override bool StorePanelContents()
- {
- bool result = true;
- result = widget.Store ();
- return result;
- }
- }
-}
Modified: trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Makefile.am
===================================================================
--- trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Makefile.am 2005-01-14 00:26:36 UTC (rev 2126)
+++ trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Makefile.am 2005-01-14 00:27:29 UTC (rev 2127)
@@ -11,7 +11,6 @@
FILES = \
Gui/ChooseRuntimePanel.cs \
-Gui/OutputOptionsPanel.cs \
Gui/CodeGenerationPanel.cs \
Parser/SharpDevelopTree/Event.cs \
Parser/SharpDevelopTree/Indexer.cs \
@@ -30,7 +29,6 @@
Parser/Parser.cs \
Parser/ExpressionFinder.cs \
CSharpAmbience.cs \
-Project/CSharpProject.cs \
Project/CSharpCompilerParameters.cs \
CSharpLanguageBinding.cs \
FormattingStrategy/CSharpFormattingStrategy.cs \
@@ -55,7 +53,7 @@
templates/GtkSharpWindow.xft.xml \
templates/Library.xpt.xml
-build_sources = $(addprefix $(srcdir)/, $(FILES)) CSharpBindingExecutionManager.cs
+build_sources = $(addprefix $(srcdir)/, $(FILES))
ADDIN = CSharpBinding.addin.xml
@@ -94,7 +92,5 @@
CLEANFILES = $(ASSEMBLY) $(ASSEMBLY).mdb
-DISTCLEANFILES = CSharpBindingExecutionManager.cs
+EXTRA_DIST = $(FILES) CSharp.glade $(ADDIN) $(TEMPLATES)
-EXTRA_DIST = $(FILES) CSharpBindingExecutionManager.cs.in CSharp.glade $(ADDIN) $(TEMPLATES)
-
Modified: trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Parser/Parser.cs
===================================================================
--- trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Parser/Parser.cs 2005-01-14 00:26:36 UTC (rev 2126)
+++ trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Parser/Parser.cs 2005-01-14 00:27:29 UTC (rev 2127)
@@ -94,22 +94,22 @@
return visitor.Cu;
}
- public ArrayList CtrlSpace(IParserService parserService, IProject project, int caretLine, int caretColumn, string fileName)
+ public ArrayList CtrlSpace(IParserService parserService, Project project, int caretLine, int caretColumn, string fileName)
{
return new Resolver(project).CtrlSpace(parserService, caretLine, caretColumn, fileName);
}
- public ArrayList IsAsResolve (IParserService parserService, IProject project, string expression, int caretLineNumber, int caretColumn, string fileName, string fileContent)
+ public ArrayList IsAsResolve (IParserService parserService, Project project, string expression, int caretLineNumber, int caretColumn, string fileName, string fileContent)
{
return new Resolver (project).IsAsResolve (parserService, expression, caretLineNumber, caretColumn, fileName, fileContent);
}
- public ResolveResult Resolve(IParserService parserService, IProject project, string expression, int caretLineNumber, int caretColumn, string fileName, string fileContent)
+ public ResolveResult Resolve(IParserService parserService, Project project, string expression, int caretLineNumber, int caretColumn, string fileName, string fileContent)
{
return new Resolver(project).Resolve(parserService, expression, caretLineNumber, caretColumn, fileName, fileContent);
}
- public string MonodocResolver (IParserService parserService, IProject project, string expression, int caretLineNumber, int caretColumn, string fileName, string fileContent)
+ public string MonodocResolver (IParserService parserService, Project project, string expression, int caretLineNumber, int caretColumn, string fileName, string fileContent)
{
return new Resolver (project).MonodocResolver (parserService, expression, caretLineNumber, caretColumn, fileName, fileContent);
}
Modified: trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Parser/Resolver.cs
===================================================================
--- trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Parser/Resolver.cs 2005-01-14 00:26:36 UTC (rev 2126)
+++ trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Parser/Resolver.cs 2005-01-14 00:27:29 UTC (rev 2127)
@@ -24,9 +24,9 @@
ICompilationUnit cu;
IClass callingClass;
LookupTableVisitor lookupTableVisitor;
- IProject project;
+ Project project;
- public Resolver (IProject project)
+ public Resolver (Project project)
{
this.project = project;
}
Modified: trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Project/CSharpCompilerParameters.cs
===================================================================
--- trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Project/CSharpCompilerParameters.cs 2005-01-14 00:26:36 UTC (rev 2126)
+++ trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Project/CSharpCompilerParameters.cs 2005-01-14 00:27:29 UTC (rev 2127)
@@ -11,116 +11,69 @@
using System.ComponentModel;
using MonoDevelop.Gui.Components;
using MonoDevelop.Internal.Project;
+using MonoDevelop.Internal.Serialization;
namespace CSharpBinding
{
- public enum CompileTarget {
- Exe,
- Library,
- WinExe,
- Module
- };
-
public enum CsharpCompiler {
Csc,
Mcs
};
- public enum NetRuntime {
- Mono,
- MonoInterpreter,
- MsNet
- };
-
/// <summary>
/// This class handles project specific compiler parameters
/// </summary>
- public class CSharpCompilerParameters : AbstractProjectConfiguration
+ public class CSharpCompilerParameters
{
- [XmlNodeName("CodeGeneration")]
- public class CodeGeneration
- {
- [XmlAttribute("runtime")]
- public NetRuntime netRuntime = NetRuntime.MsNet;
-
- [XmlAttribute("compiler")]
- public CsharpCompiler csharpCompiler = CsharpCompiler.Csc;
-
- [XmlAttribute("warninglevel")]
- public int warninglevel = 4;
-
- [XmlAttribute("nowarn")]
- public string noWarnings = String.Empty;
-
- [XmlAttribute("includedebuginformation")]
- public bool debugmode = true;
-
- [XmlAttribute("optimize")]
- public bool optimize = true;
-
- [XmlAttribute("unsafecodeallowed")]
- public bool unsafecode = false;
-
- [XmlAttribute("generateoverflowchecks")]
- public bool generateOverflowChecks = true;
-
- [XmlAttribute("mainclass")]
- public string mainclass = null;
-
- [XmlAttribute("target")]
- public CompileTarget compiletarget = CompileTarget.Exe;
-
- [XmlAttribute("definesymbols")]
- public string definesymbols = String.Empty;
-
- [XmlAttribute("generatexmldocumentation")]
- public bool generateXmlDocumentation = false;
-
- [ConvertToRelativePathAttribute()]
- [XmlAttribute("win32Icon")]
- public string win32Icon = String.Empty;
- }
+ // Configuration parameters
- [XmlNodeName("Execution")]
- public class Execution
- {
- [XmlAttribute("commandlineparameters")]
- public string commandLineParameters = String.Empty;
-
- [XmlAttribute("consolepause")]
- public bool pauseconsoleoutput = true;
- }
+ [ItemProperty ("compiler")]
+ CsharpCompiler csharpCompiler = CsharpCompiler.Csc;
- protected CodeGeneration codeGeneration = new CodeGeneration();
- protected Execution execution = new Execution();
+ [ItemProperty ("warninglevel")]
+ int warninglevel = 4;
+ [ItemProperty ("nowarn", DefaultValue = "")]
+ string noWarnings = String.Empty;
+
+ [ItemProperty ("optimize")]
+ bool optimize = true;
+
+ [ItemProperty ("unsafecodeallowed")]
+ bool unsafecode = false;
+
+ [ItemProperty ("generateoverflowchecks")]
+ bool generateOverflowChecks = true;
+
+ [ItemProperty ("mainclass")]
+ string mainclass = null;
+
+ [ItemProperty ("definesymbols", DefaultValue = "")]
+ string definesymbols = String.Empty;
+
+ [ItemProperty ("generatexmldocumentation")]
+ bool generateXmlDocumentation = false;
+
+ [ProjectPathItemProperty ("win32Icon", DefaultValue = "")]
+ string win32Icon = String.Empty;
+
[Browsable(false)]
public CsharpCompiler CsharpCompiler {
get {
- return codeGeneration.csharpCompiler;
+ return csharpCompiler;
}
set {
- codeGeneration.csharpCompiler = value;
+ csharpCompiler = value;
}
}
[Browsable(false)]
- public NetRuntime NetRuntime {
- get {
- return codeGeneration.netRuntime;
- }
- set {
- codeGeneration.netRuntime = value;
- }
- }
-
- [Browsable(false)]
public string Win32Icon {
get {
- return codeGeneration.win32Icon;
+ return win32Icon;
}
set {
- codeGeneration.win32Icon = value;
+ win32Icon = value;
}
}
#region Code Generation
@@ -130,10 +83,10 @@
Description = "${res:BackendBindings.CompilerOptions.CodeGeneration.MainClass.Description}")]
public string MainClass {
get {
- return codeGeneration.mainclass;
+ return mainclass;
}
set {
- codeGeneration.mainclass = value;
+ mainclass = value;
}
}
@@ -143,36 +96,23 @@
Description = "${res:BackendBindings.CompilerOptions.CodeGeneration.DefineSymbols.Description}")]
public string DefineSymbols {
get {
- return codeGeneration.definesymbols;
+ return definesymbols;
}
set {
- codeGeneration.definesymbols = value;
+ definesymbols = value;
}
}
[DefaultValue(true)]
- [LocalizedProperty("${res:BackendBindings.CompilerOptions.CodeGeneration.DebugMode}",
- Category = "${res:BackendBindings.CompilerOptions.CodeGeneration}",
- Description = "${res:BackendBindings.CompilerOptions.CodeGeneration.DebugMode.Description}")]
- public bool Debugmode {
- get {
- return codeGeneration.debugmode;
- }
- set {
- codeGeneration.debugmode = value;
- }
- }
-
- [DefaultValue(true)]
[LocalizedProperty("${res:BackendBindings.CompilerOptions.CodeGeneration.Optimize}",
Category = "${res:BackendBindings.CompilerOptions.CodeGeneration}",
Description = "${res:BackendBindings.CompilerOptions.CodeGeneration.Optimize.Description}")]
public bool Optimize {
get {
- return codeGeneration.optimize;
+ return optimize;
}
set {
- codeGeneration.optimize = value;
+ optimize = value;
}
}
@@ -182,10 +122,10 @@
Description = "${res:BackendBindings.CompilerOptions.CodeGeneration.UnsafeCode.Description}")]
public bool UnsafeCode {
get {
- return codeGeneration.unsafecode;
+ return unsafecode;
}
set {
- codeGeneration.unsafecode = value;
+ unsafecode = value;
}
}
@@ -195,10 +135,10 @@
Description = "${res:BackendBindings.CompilerOptions.CodeGeneration.GenerateOverflowChecks.Description}")]
public bool GenerateOverflowChecks {
get {
- return codeGeneration.generateOverflowChecks;
+ return generateOverflowChecks;
}
set {
- codeGeneration.generateOverflowChecks = value;
+ generateOverflowChecks = value;
}
}
@@ -208,10 +148,10 @@
Description = "${res:BackendBindings.CompilerOptions.CodeGeneration.GenerateXmlDocumentation.Description}")]
public bool GenerateXmlDocumentation {
get {
- return codeGeneration.generateXmlDocumentation;
+ return generateXmlDocumentation;
}
set {
- codeGeneration.generateXmlDocumentation = value;
+ generateXmlDocumentation = value;
}
}
@@ -224,10 +164,10 @@
Description = "${res:BackendBindings.CompilerOptions.WarningAndErrorCategory.WarningLevel.Description}")]
public int WarningLevel {
get {
- return codeGeneration.warninglevel;
+ return warninglevel;
}
set {
- codeGeneration.warninglevel = value;
+ warninglevel = value;
}
}
@@ -237,50 +177,12 @@
Description = "${res:BackendBindings.CompilerOptions.WarningAndErrorCategory.NoWarnings.Description}")]
public string NoWarnings {
get {
- return codeGeneration.noWarnings;
+ return noWarnings;
}
set {
- codeGeneration.noWarnings = value;
+ noWarnings = value;
}
}
#endregion
- [Browsable(false)]
- public string CommandLineParameters {
- get {
- return execution.commandLineParameters;
- }
- set {
- execution.commandLineParameters = value;
- }
- }
-
- [Browsable(false)]
- public bool PauseConsoleOutput {
- get {
- return execution.pauseconsoleoutput;
- }
- set {
- execution.pauseconsoleoutput = value;
- }
- }
-
-
- [Browsable(false)]
- public CompileTarget CompileTarget {
- get {
- return codeGeneration.compiletarget;
- }
- set {
- codeGeneration.compiletarget = value;
- }
- }
-
- public CSharpCompilerParameters()
- {
- }
- public CSharpCompilerParameters(string name)
- {
- this.name = name;
- }
}
}
Deleted: trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Project/CSharpProject.cs
===================================================================
--- trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Project/CSharpProject.cs 2005-01-14 00:26:36 UTC (rev 2126)
+++ trunk/MonoDevelop/Core/src/AddIns/BackendBindings/CSharpBinding/Project/CSharpProject.cs 2005-01-14 00:27:29 UTC (rev 2127)
@@ -1,66 +0,0 @@
-// <file>
-// <copyright see="prj:///doc/copyright.txt"/>
-// <license see="prj:///doc/license.txt"/>
-// <owner name="Mike Krüger" email="mike at icsharpcode.net"/>
-// <version value="$version"/>
-// </file>
-
-using System;
-using System.IO;
-using System.Collections;
-using System.Diagnostics;
-using System.ComponentModel;
-using System.Xml;
-
-using MonoDevelop.Internal.Project;
-using MonoDevelop.Internal.Templates;
-
-namespace CSharpBinding
-{
- /// <summary>
- /// This class describes a C Sharp project and it compilation options.
- /// </summary>
- public class CSharpProject : AbstractProject
- {
- public override string ProjectType {
- get {
- return CSharpLanguageBinding.LanguageName;
- }
- }
-
- public CSharpProject()
- {
- }
-
- public override IConfiguration CreateConfiguration()
- {
- return new CSharpCompilerParameters();
- }
-
- public CSharpProject(ProjectCreateInformation info, XmlElement projectOptions)
- {
- if (info != null) {
- Name = info.ProjectName;
- Configurations.Add(CreateConfiguration("Debug"));
- Configurations.Add(CreateConfiguration("Release"));
-
- foreach (CSharpCompilerParameters parameter in Configurations) {
- parameter.OutputDirectory = info.BinPath + Path.DirectorySeparatorChar + parameter.Name;
- parameter.OutputAssembly = Name;
- //}
- //XmlElement el = info.ProjectTemplate.ProjectOptions; -- moved above foreach loop
- //para variable renamed parameter
- //CSharpCompilerParameters para = ActiveConfiguration;?? - removed as nolonger needed
- if (projectOptions != null) {
- if (projectOptions.Attributes["Target"] != null) {
- parameter.CompileTarget = (CompileTarget)Enum.Parse(typeof(CompileTarget), projectOptions.Attributes["Target"].InnerText);
- }
- if (projectOptions.Attributes["PauseConsoleOutput"] != null) {
- parameter.PauseConsoleOutput = Boolean.Parse(projectOptions.Attributes["PauseConsoleOutput"].InnerText);
- }
- }
- }
- }
- }
- }
-}
More information about the Monodevelop-patches-list
mailing list