Commit Graph
19 Commits
Author SHA1 Message Date
Marek Habersack d8838a6414 This commit introduces a few 4.0 rendering changes which break some tests. The broken tests
fail to work on .NET 4.0 as well, for the most part. I will fix them next week.

    2010-07-02  Marek Habersack  <[email protected]>

    	* TemplateControlParser.cs: added support for ClientIDMode
    	property

    	* Control.cs: implemented 4.0 features - ClientIDMode and
    	RenderingCompatibility.

    	* ClientIDMode.cs, IDataKeysControl.cs: added

    2010-07-02  Marek Habersack  <[email protected]>

    	* Menu.cs: 4.0 API updates.

    	* GridView.cs: implemented 4.0 properties -
    	SortedAscendingCellStyle, SortedAscendingHeaderStyle,
    	SortedDescendingCellStyle, SortedDescendingHeaderStyle,
    	ClientIDRowSuffix, ClientIDRowSuffixDataKeys, ShowHeaderWhenEmpty
    	along with associated rendering changes.

    	* DetailsView.cs, FormView.cs, GridView.cs: 4.0 API changes -
    	renamed ShowPage to SetPageIndex and made it public.
    	Added 4.0 interfaces to inheritance list and implemented them.

    	* DataKeyArray.cs: added internal constructor which accepts IList
    	instead of ArrayList. Changed the 'keys' field type to IList.

    	* ContainedTable.cs: the 'id' attribute must be rendered last.

    	* CheckBox.cs, CheckBoxList.cs, SiteMapPath.cs, Table.cs,
    	TableStyle.cs, TextBox.cs, WebControl.cs: 4.0 rendering changes.

    	* Calendar.cs, CompositeControl.cs, DropDownList.cs, HyperLink.cs,
    	Image.cs, ImageButton.cs, Label.cs, LinkButton.cs, LoginName.cs,
    	Panel.cs, Table.cs, TableCell.cs, TableRow.cs:
    	added new 4.0 property, SupportsDisabledAttribute.

    2010-07-02  Marek Habersack  <[email protected]>

    	* VersionConverter.cs: added support for checking whether the
    	passed version is equal or more than a specified minimal version.

    	* PagesSection.cs: added two 4.0 properties - ClientIDMode and
    	ControlRenderingCompatibilityVersion

    2010-07-02  Marek Habersack  <[email protected]>

    	* TemplateControlCompiler.cs: added support for ClientIDMode 4.0
    	property

    	* PageCompiler.cs, UserControlCompiler.cs: AddStatementsToInitTop
    	must call the base implementation.

svn path=/trunk/mcs/; revision=159826
2010-07-02 19:12:31 +00:00
Marek Habersack 0b08553dbc 2010-06-01 Marek Habersack <[email protected]>
* HtmlHead.cs: added code to render description and keywords metas
	if the corresponding HtmlMeta controls aren't found and the user
	set either Description or Keywords properties.

2010-06-01  Marek Habersack  <[email protected]>

	* TemplateControlCompiler.cs: added new virtual method,
	AddStatementsToInitMethodBottom and renamed
	AddStatementsToInitMethod to AddStatementsToInitMethodTop.

	* PageCompiler.cs: code to set Meta{Description,Keywords}
	properties, if present.

2010-06-01  Marek Habersack  <[email protected]>

	* PageParser.cs: added support for MetaDescription and
	MetaKeywords main directive attributes

	* Page.cs: implemented MetaDescription and MetaKeywords
	4.0 properties.

svn path=/trunk/mcs/; revision=158303
2010-06-01 22:01:28 +00:00
Marek Habersack 5411dd0e2a 2010-05-19 Marek Habersack <[email protected]>
* PageParser.cs: handle several main directive attributes
    	specially, as they can have expressions as their values. Fixes bug
    	#603532

    	* MainDirectiveAttribute.cs: added - helper class to handle
    	directive attributes which can take either a value or an
    	expression.

    	* BaseParser.cs: IsDirective, IsExpression and IsDataBound methods
    	moved to here from TemplateControlCompiler.

    2010-05-19  Marek Habersack  <[email protected]>

    	* TemplateControlCompiler.cs: IsDirective, IsExpression and
    	IsDataBound methods moved to System.Web.UI.BaseParser.
    	Made CompileExpression and GetFieldOrProperty methods internal.

    	* PageCompiler.cs: check several of the Page directive attributes
    	for expressions. Fixes bug #603532

    	* AspGenerator.cs, TagAttributes.cs: use IDictionary instead of
    	Hashtable

svn path=/trunk/mcs/; revision=157519
2010-05-19 01:28:09 +00:00
Marek Habersack b40844116b More 1.1 code and NET_2_0 ifdefs removed
svn path=/trunk/mcs/; revision=145319
2009-11-03 20:19:37 +00:00
Marek Habersack ef9c9e51ce Do not abuse the 'private' keyword
svn path=/trunk/mcs/; revision=116539
2008-10-20 17:37:54 +00:00
Marek Habersack 5c99286487 2008-01-02 Marek Habersack <[email protected]>
* TemplateParser.cs: added a wrapper class for server-side script
	snippets, to keep track of locations.
	Store main directive location for later use in DirectiveLocation
	internal property.
2008-01-02  Marek Habersack  <[email protected]>

	* TemplateControlCompiler.cs: add line pragma wherever necessary.

	* PageCompiler.cs: reorder the statements to match MS.NET output.
	Output line pragma information for directive attributes.

	* BaseCompiler.cs: add a set of AddLinePragma methods for various
	CodeDOM elements. 
	Output line pragmas when adding server-side scripts to the CodeDOM
	tree.

	* AspGenerator.cs: use ServerSideScript to store script location
	in the original file.

	* UserControlCompiler.cs: output line pragmas for the init
	method.

svn path=/trunk/mcs/; revision=92125
2008-01-02 20:52:10 +00:00
Marek Habersack fc25d3889c 2007-05-22 Marek Habersack <[email protected]>
* UserControlCompiler.cs: the Profile property should be present
	also in user controls.

svn path=/trunk/mcs/; revision=77786
2007-05-22 11:09:14 +00:00
Chris Toshok e210711eea 2006-02-07 Chris Toshok <[email protected]>
* UserControlCompiler.cs (AddStatementsToInitMethod): emit code to
	assign __ctrl.MasterPageFile to our master page, if we have one.

	* PageCompiler.cs (CreateContructor): remove the MasterPageFile
	assignment from here.
	(AddStatementsToInitMethod): and move it here.
	
	* TemplateControlCompiler.cs (InitMethod): in the case where
	builder is a RootBuilder (we're building the __BuildControlTree
	method), call a virtual method so that subclasses can add their
	own statements to the method (used by both Page and MasterPage);
	Also, in the RootBuilder case, the argument should be the
	parser.ClassName type (the class we're building); lastly, expand
	the ContentPlaceHolder logic to include all the
	ContentTemplates/InstantiateIn magic.
	(AddStatementsToInitMethod): empty virtual method.
	(AddContentTemplateInvocation): ContentControlBuilder ->
	ContentControlBuilderInternal.
	(CreateControlTree): same.
	(CallBaseFrameworkInitialize): new function, create call to
	base.FrameworkInitialize.
	(CreateFrameworkInitializeMethod): call CallBaseFrameworkIniitialize.


svn path=/trunk/mcs/; revision=56619
2006-02-07 16:48:02 +00:00
Duncan Mak d1c09fcc67 Add licensing info
svn path=/trunk/mcs/; revision=30345
2004-06-24 20:59:43 +00:00
Gonzalo Paniagua Javier be31b0ce2d 2004-06-16 Gonzalo Paniagua Javier <[email protected]>
* System.Web.Compilation/BaseCompiler.cs: try getting the Type from
	the cache before doing the real work. Remove temporary files right after
	successful compilation.

	* System.Web.Compilation/CachingCompiler.cs: added GetTypeFromCache.

	* System.Web.Compilation/UserControlCompiler.cs: nothing interesting.

	* System.Web.Compilation/WebServiceCompiler.cs: try getting the Type
	from the cache before doing anything else. Remove temp files on
	sucessful compilation.

	* System.Web.UI/SimpleWebHandlerParser.cs: implemented
	GetCompiledTypeFromCache. When we read the default directive, check the
	cache for the Type and if present, don't keep reading and store the
	type found.

	* System.Web.UI/WebHandlerParser.cs:
	* System.Web.UI/WebServiceParser.cs: try GetCompiledTypeFromCache
	before actually compiling.

svn path=/trunk/mcs/; revision=29652
2004-06-16 01:41:10 +00:00
Jackson Harper 478790c70c * TemplateControlCompiler.cs: If an item has the partial caching
attribute build a PartialCachingControl in the parents __Build method.
	* BaseCompiler.cs: Add a method for adding class attributes to the
	class.
	* UserControlCompiler.cs: If caching is enabled on a user control
	add the PartialCachingAttribute to it.

svn path=/trunk/mcs/; revision=22034
2004-01-13 21:22:37 +00:00
Gonzalo Paniagua Javier e80814a23c 2003-04-30 Gonzalo Paniagua Javier <[email protected]>
* AspComponentFoundry.cs: simplified it a lot by using Type and Assembly
	instead of their names.

	* AspElements.cs: removed. No longer needed.

	* AspGenerator.cs: this file is now in charge of interfacing between
	the parser and the compiler. It manages the creation of the
	ControlBuilder tree and the compilation of the CodeDOM tree.

	* AspParser.cs: tag handling is simpler now.  Instead of a whole bunch
	of different Types, tags are just and id and a set of attributes.
	Implement ILocation interface.

	* AspTokenizer.cs: added a few methods to help the parser implementing
	ILocation.

	* BaseCompiler.cs: handles the portions of the CodeDOM tree that are
	common to appliaction, page and user control, including the actual
	compilation and error handling.

	* CSCompiler.cs: compiles C# files using CodeDOM interfaces.

	* CachingCompiler.cs: simplified to use the new interfaces.

	* CompilationException.cs: it's now using CompilationResult to report
	errors.

	* CompilationResult.cs: Removed file.

	* Directive.cs: to check for the validity of a directive.

	* GlobalAsaxCompiler.cs: simplified a lot, as most of the work is done
	in BaseCompiler.

	* ILocation.cs: interface used to now the exact place where a parse
	error happens.

	* PageCompiler.cs: generates a couple of methods that are only used in
	pages.

	* ParseException.cs: use the ILocation interface.

	* TagAttributes.cs: handles the attributes of the tags parsed.

	* TagType.cs: an enum for the different kinds of tags.

	* TemplateControlCompiler.cs: this is the one that does most of the
	conversion from teh ControlBuilder tree into a CodeDOM tree.

	* UserControlCompiler.cs: simplified as most of the work is done in
	its base classes.

	* WebServiceCompiler.cs: dummy.

svn path=/trunk/mcs/; revision=14140
2003-04-30 04:56:01 +00:00
Gonzalo Paniagua Javier 3f3247b3ee 2003-03-10 Gonzalo Paniagua Javier <[email protected]>
* AspGenerator.cs:
	* BaseCompiler.cs:
	* CachingCompiler.cs:
	* CompilationResult.cs:
	* GlobalAsaxCompiler.cs:
	* PageCompiler.cs:
	* UserControlCompiler.cs: recompile the page if dependencies change.

svn path=/trunk/mcs/; revision=12401
2003-03-10 06:41:26 +00:00
Gonzalo Paniagua Javier 216bec00c9 2003-02-11 Gonzalo Paniagua Javier <[email protected]>
* list: added a couple of new files.
	* System.Web/HtmlizedException.cs: base class for exceptions that makes
	it easy to generate error pages.

	* System.Web/HttpException.cs: improved error displaying.

	* System.Web/HttpRuntime.cs: removed debugging output.

	* System.Web.Compilation/AspGenerator.cs: throw ParseException on parse
	error.

	* System.Web.Compilation/AspParser.cs: added Line and Column props.

	* System.Web.Compilation/CompilationException.cs: derives now from
	HtmlizedException.

	* System.Web.Compilation/CompilationResult.cs: added fileName field.
	Fixed set_ExitCode.

	* System.Web.Compilation/GlobalAsaxCompiler.cs:
	* System.Web.Compilation/PageCompiler.cs:
	* System.Web.Compilation/UserControlCompiler.cs: pass the file name in
	the CompilationResult.

	* System.Web.Compilation/ParseException.cs: new exception.

svn path=/trunk/mcs/; revision=11467
2003-02-11 05:04:30 +00:00
Gonzalo Paniagua Javier 3444afed80 2003-02-03 Gonzalo Paniagua Javier <[email protected]>
* System.Web.Compilation/AspParser.cs: the parser fires events when it
	parses an element.

	* System.Web.UI/SimpleWebHandlerParser.cs:
	* System.Web.Compilation/GlobalAsaxCompiler.cs:
	* System.Web.Compilation/PageCompiler.cs:
	* System.Web.Compilation/UserControlCompiler.cs:
	* System.Web.Compilation/AspElements.cs: modified to use the new parser
	interface.

	* System.Web.Compilation/AspGenerator.cs: modified to use the new
	parser. Merge multiple text strings into one single LiteralControl.

	* System.Web.Compilation/AspTokenizer.cs: added Line and Column properties.

svn path=/trunk/mcs/; revision=11146
2003-02-03 02:25:00 +00:00
Gonzalo Paniagua Javier 8e91ed0203 2002-12-18 Gonzalo Paniagua Javier <[email protected]>
* System.Web/HttpApplicationFactory.cs: add the context as parameter
	when building the application Type.

	* System.Web/HttpCookie.cs: new internal constructor.
	* System.Web/HttpCookieCollection.cs: new internal method to make a
	cookie expire.

	* System.Web/HttpRequest.cs: MapPath fixes.
	* System.Web/HttpResponse.cs: implemented ApplyAppPathModifier.
	* System.Web/HttpRuntime.cs: fixed typo in AppDomainAppVirtualPath.
	* System.Web.Compilation/AspGenerator.cs: now it uses the current
	HttpContext when creating user controls. TemplateSourceDirectory is no
	longer a dummy value.

	* System.Web.Compilation/GlobalAsaxCompiler.cs:
	* System.Web.Compilation/PageCompiler.cs:
	* System.Web.Compilation/UserControlCompiler.cs: set the context which
	will be used to locate the files.

	* System.Web.UI/BaseParser.cs: use MapPath and context to locate files.
	* System.Web.UI/Control.cs: implemented MapPathSecure.
	* System.Web.UI/TemplateControl.cs: use UrlUtils to generate the path.
	* System.Web.UI/TemplateControlParser.cs: use the context and MapPath.
	* System.Web.UI/UserControl.cs: implemented MapPath.
	* System.Web.UI/UserControlParser.cs: added context parameter to
	constructor.
	* System.Web.Util/PathUtil.cs: removed.
	* System.Web.Util/UrlUtils.cs: fixed Combine to handle '~'.

svn path=/trunk/mcs/; revision=9737
2002-12-18 02:17:17 +00:00
Gonzalo Paniagua Javier 31c202887f 2002-12-13 Gonzalo Paniagua Javier <[email protected]>
* System.Web.Compilation/AspGenerator.cs: added support for
	AutoEventWireup attribute in @Page and @Control.

	* System.Web.Compilation/CompilationResult.cs:
	* System.Web.Compilation/GlobalAsaxCompiler.cs:
	* System.Web.Compilation/PageCompiler.cs:
	* System.Web.Compilation/UserControlCompiler.cs: store the options.

	* System.Web.UI/Control.cs: added AutoEventWireup internal property.

	* System.Web.UI/Page.cs: removed page events wire up from here.

	* System.Web.UI/TemplateControl.cs: new method WireupAutomaticEvents to
	hook up page and user controls events.

	* System.Web.UI/TemplateControlParser.cs: process the options that are
	applicable once we have the instance of the control.

	* System.Web.UI/TemplateParser.cs: also stores the options.

	* System.Web.UI/UserControl.cs: hook up events before initializing the
	control.

svn path=/trunk/mcs/; revision=9623
2002-12-13 15:57:07 +00:00
Gonzalo Paniagua Javier 43d7f24f1c 2002-12-12 Gonzalo Paniagua Javier <[email protected]>
* list: Modified file.
	* System.Web/HttpRuntime.cs: avoid nulls and exception when getting
	resource format strings.

	* System.Web/StaticFileHandler.cs: added file name to error message.
	* System.Web.Compilation/AspElements.cs: new method Tag.GetElements
	used to parse the inner contents of a tag looking for data binding or
	code render tags.

	New property HtmlControlTag.ParseChildren allows
	differentiation of a couple of HtmlControls that has children as
	properties (namely HtmlTable and HtmlTableRow).

	* System.Web.Compilation/AspGenerator.cs: fixed container semantics to
	match BindingContainer one. Implemented Inherits attribute for page and
	control.

	Support HtmlControls that has ChildrenAsProperties.

	Generate code for data binding functions that matches the semantic of
	Container.

	Handle data bound and code render attribute values.

	Set proper value return for TemplateSourceDirectory. Should be relative
	to appPath.

	* System.Web.Compilation/BaseCompiler.cs: moved CompilerOptions and
	References handling here.

	* System.Web.Compilation/CachingCompiler.cs: copy result of compilation.

	* System.Web.Compilation/CompilationException.cs: simple ToString ()
	implementation.

	* System.Web.Compilation/CompilationResult.cs: implemented CopyFrom and
	ToString.

	* System.Web.Compilation/GlobalAsaxCompiler.cs:
	* System.Web.Compilation/PageCompiler.cs:
	* System.Web.Compilation/UserControlCompiler.cs: removed
	CompilerOptions as it's now handled in the base class. Get all the
	types in the generated assembly and look for one that derives from
	the correct Type.

	* System.Web.UI/Control.cs: implemented TemplateSourceDirectory.
	* System.Web.UI/TemplateControl.cs: implemented LoadControl and
	LoadTemplate.

	* System.Web.Util/PathUtil.cs: some path handling methods that are not
	available in Path.

svn path=/trunk/mcs/; revision=9583
2002-12-12 03:20:19 +00:00
Gonzalo Paniagua Javier be2bff830e 2002-11-26 Gonzalo Paniagua Javier <[email protected]>
* list: added/removed files.

	* System.Web.Compilation/AspGenerator.cs: reworked user control
	compilation. Provide the options as a Hashtable for use in compilation.
	Create the user controls in the private bin path of the domain.

	* System.Web.Compilation/BaseCompiler.cs: base class for the various
	compiler types.

	* System.Web.Compilation/CachingCompiler.cs: actually executes mcs and
	do some poor caching (it will use Cache when finished).

	* System.Web.Compilation/CompilationException.cs: this exception has
	enough information to generate a nice error page.
	* System.Web.Compilation/CompilationResult.cs: used in caching.

	* System.Web.Compilation/PageCompiler.cs: now derives from BaseCompiler

	* System.Web.Compilation/TemplateFactory.cs: no longer needed.

	* System.Web.Compilation/UserControlCompiler.cs: new class used when
	compiling user controls.
	* System.Web.Compilation/WebServiceCompiler.cs: derives from
	BaseCompiler.
	* System.Web.Mail/SmtpMail.cs: i don't wanna see that warning :-).
	* System.Web.UI/TemplateParser.cs: fixed BaseType.
	* System.Web.UI/UserControlParser.cs: helper class to compile user
	controls.

svn path=/trunk/mcs/; revision=9191
2002-11-26 02:52:25 +00:00