Commit Graph
60 Commits
Author SHA1 Message Date
Marek Habersack e5ec9150cb [asp.net] Fix for bug #633756. Children processed as properties must be instantiated before using.
When a server-side control processes its children (in the markup) as properties, it needs to instantiate
an object of the property type and assign it to the appropriate property of the control. Failing to do so
will cause markup which references properties to fail in certain cases (for instance when the control's
property type is a class and it is not instantiated by the control's constructor).
2010-08-24 01:02:47 +02: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 5e9719f57c Gotten rid of NET_2_0 ifdefs and 1.1 code from System.Web.UI
svn path=/trunk/mcs/; revision=149929
2010-01-20 21:21:01 +00:00
Marek Habersack 8b4e17d0d2 2009-11-10 Marek Habersack <[email protected]>
* TemplateParser.cs: AddImports is called from LoadConfigDefaults
	so that it reads configuration from the correct .config file (it
	needs to be called after this.VirtualPath has been
	initialized). Fixes an issue with MVC apps which put configuration
	in Views/web.config etc. Fixes bug #552457

	* ControlBuilder.cs, Page.cs: system.web/pages section is not
	confined to the top-level web.config

2009-11-10  Marek Habersack  <[email protected]>

	* WebConfigurationManager.cs: path passed to OpenWebConfiguration
	from GetSection does not come from FindWebConfig.

2009-11-10  Marek Habersack  <[email protected]>

	* BaseCompiler.cs: parser.Imports is a Dictionary <>/Hashtable
	now.

	* AspComponentFoundry.cs: system.web/pages section is not confined
	to the top-level web.config

svn path=/trunk/mcs/; revision=145831
2009-11-10 13:49:01 +00:00
Marek Habersack 5c59801fff Performance improvements:
- made sure invariant culture is used with String.ToLower, String.ToUpper and String.Compare
- replaced all calls to CultureInfo.InvariantCulture with a reference to a static field System.Web.Util.Helpers.InvariantCulture

svn path=/trunk/mcs/; revision=143587
2009-10-07 00:10:03 +00:00
Marek Habersack b68b65ad17 2009-08-18 Marek Habersack <[email protected]>
* Makefile (TEST_RESOURCE_FILES): added
	Test/mainsoft/NunitWebResources/DuplicateControlsInClientComment.aspx

2009-08-18  Marek Habersack  <[email protected]>

	* ControlBuilder.cs: Location property makes a copy of assigned
	ILocation now.

2009-08-18  Marek Habersack  <[email protected]>

	* AspParser.cs: added a constructor which creates an internal
	parser, nested within the outer one, and adjusts its ILocation
	members to report correct locations in the outer parser for better
	error reporting. Inner parser also returns the outer's FileText,
	if available.

	* AspGenerator.cs: restored part of r138474 reverted in r138657,
	r138658 and r138659 to fix bug #525104
	BuilderLocation creates a copy of Location for its own use (since
	the ILocation passed is actually AspParser, the line numbers
	change between creating a BuilderLocation and using its Location
	member).
	The end of tag, expression and client comment regular expressions
	now use lazy quantifiers. This fixes bugs #525104 and #517656
	Client side comment blocks aren't ignored anymore, they are parsed
	just as the other parts of the document. Fixes bug #524358

2009-08-18  Marek Habersack  <[email protected]>

	* JavaScriptSerializer.cs: read converters from the config only if
	explicitly requested.

2009-08-18  Marek Habersack  <[email protected]>

	* TemplateControlCompilerTest.cs: added test for bug #525104 and
	improved test for bug #517656

svn path=/trunk/mcs/; revision=140161
2009-08-18 13:31:49 +00:00
Marek Habersack bbd9577d71 2009-08-14 Marek Habersack <[email protected]>
* ControlBuilder.cs: when CreateSubBuilder is called on a builder
	which is supposed to treat its children as properties and the
	default property builder is defined, first check if the tag which
	has just been parsed isn't a template property. If it is, don't
	use the default property builder, instead create a template
	property builder directly. Fixes bug #527753

svn path=/trunk/mcs/; revision=139895
2009-08-14 02:01:12 +00:00
Marek Habersack 0460df3566 2009-07-23 Marek Habersack <[email protected]>
* AspGenerator.cs:
	Check for duplicate control IDs at the end of parse. Fixes bug
	#524358

2009-07-23  Marek Habersack  <[email protected]>

	* ControlBuilder.cs: added an internal helper property
	IsNamingContainer.

2009-07-23  Marek Habersack  <[email protected]>

	* HttpException.cs: if an exception is processed which refers to
	internal "files", don't show the internal name.

svn path=/trunk/mcs/; revision=138521
2009-07-23 10:16:54 +00:00
Marek Habersack 8aa3c10397 2009-05-04 Marek Habersack <[email protected]>
* ThemeDirectoryBuildProvider.cs: use new AspGenerator constructor
	which takes AspComponentFoundery as its
	parameter. AspGenerator.RootBuilder isn't initialized until after
	the parser is initialized.

	* TemplateControlCompiler.cs: make sure to call
	ProcessGeneratedCode on each instance of ControlBuilder after it's
	fully generated. Fixes bug #500075

	* TemplateBuildProvider.cs: moved the directive regex to
	AspGenerator

	* BaseCompiler.cs: added two internal properties, BaseType and
	DerivedType, which are used in calls to
	ControlBuilder.ProcessGeneratedCode. Fixes bug #500075

	* AspGenerator.cs: implemented a work around for our parser
	limitation which is unable to extract the page/control's base type
	before parsing the actual file contents. This is necessary to
	support ASP.NET MVC's "generic" Inherits attribute. The reason we
	need to find out what the base type is before parsing the file is
	that we need to look at the type's custom attributes to see if a
	root control builder type is specified (which is what ASP.NET MVC
	does) and, if yes, use it instead of the default type. Fixes bug
	#500075

2009-05-04  Marek Habersack  <[email protected]>

	* TemplateParser.cs: take RootBuilder from the associated
	generator.
	Allow the main page directive to be added twice if the parser
	needs it. Used by AspGenerator when extracting the inherited type
	name before actual parsing. Fixes bug #500075

	* FileLevelControlBuilderAttribute.cs,
	FileLevelPageControlBuilder.cs, FileLevelUserControlBuilder.cs:
	implemented

	* ControlBuilder.cs: added a new internal property,
	DataBindingMethod.
	Implemented ProcessGeneratedCode.

svn path=/trunk/mcs/; revision=133500
2009-05-04 13:29:32 +00:00
Marek Habersack bf41db70d0 2009-03-06 Marek Habersack <[email protected]>
* ControlBuilder.cs: BindingContainerType - if control type of the
	containing builder is null, return typeof (Control)

svn path=/trunk/mcs/; revision=128796
2009-03-06 20:54:40 +00:00
Gonzalo Paniagua Javier 871da8a251 2009-02-28 Gonzalo Paniagua Javier <[email protected]>
* BaseParser.cs:
	* PageParser.cs:
	* ControlBuilder.cs:
	* TemplateParser.cs:
	* Page.cs:
	* SimpleWebHandlerParser.cs: settings that have to be in
	machine.config or the root level web.config now call
	GetWebApplicationSection.



svn path=/trunk/mcs/; revision=128273
2009-02-28 20:04:36 +00:00
Marek Safar b1a2042b83 2009-02-12 Marek Safar <[email protected]>
* ControlBuilder.cs, PageParserFilter.cs, CodeConstructType.cs:
	Add few missing members.


svn path=/trunk/mcs/; revision=126769
2009-02-12 22:51:00 +00:00
Marek Habersack 3fcbf0735a 2009-01-13 Marek Habersack <[email protected]>
* CodeBuilder.cs, RootBuilder.cs, CollectionBuilder.cs: updates
	related to ControlBuilder cleanup.

	* ControlBuilder.cs: code cleanup - no field should be visible
	outside the class unless it's a constant or a read-only field.

2009-01-13  Marek Habersack  <[email protected]>

	* XmlBuilder.cs: updates related to ControlBuilder cleanup.

2009-01-13  Marek Habersack  <[email protected]>

	* TemplateControlCompiler.cs, AspGenerator.cs, BaseCompiler.cs,
	GlobalAsaxCompiler.cs, PageThemeCompiler.cs: updates related to
	ControlBuilder cleanup.


svn path=/trunk/mcs/; revision=123229
2009-01-13 18:38:18 +00:00
Marek Habersack 6e8c180f09 Reverted r123106
svn path=/trunk/mcs/; revision=123113
2009-01-12 19:42:35 +00:00
Marek Habersack dbd6e55cdc 2009-01-12 Marek Habersack <[email protected]>
* LiteralStringControlBuilder.cs: added. Fixes bug #461214

	* ControlBuilder.cs: added location tracking for literal string
	children. Fixes bug #461214

	* TemplateParser.cs: line pragmas are on by default. Fixes bug
	#460479

2009-01-12  Marek Habersack  <[email protected]>

	* TemplateControlCompiler.cs: the LiteralStringControlBuilder
	class is now used to track the location of the plain strings being
	output to the generated code. Fixes bug #461214

	* AspGenerator.cs: AppendLiteralString is called with the current
	parser location as one of its parameters in FlushText (). Fixes
	bug #461214

2009-01-12  Marek Habersack  <[email protected]>

	* System.Web.dll.sources: added
	System.Web.UI/LiteralStringControlBuilder.cs


svn path=/trunk/mcs/; revision=123106
2009-01-12 18:53:41 +00:00
Marek Habersack b62e106bbd 2008-12-18 Marek Habersack <[email protected]>
* ControlBuilder.cs: BindingContainerType returns typeof (Page)
	only when the current object is a RootBuilder and it's been
	created for a page parser. Otherwise it returns typeof
	(Control). Fixes bug #45630

svn path=/trunk/mcs/; revision=121752
2008-12-18 01:18:50 +00:00
Marek Habersack fa32fdf482 2008-11-25 Marek Habersack <[email protected]>
* System.Web.dll.sources: added
	System.Web.Compilation/AspComponent.cs

2008-11-25  Marek Habersack  <[email protected]>

	* RootBuilder.cs: use new API in AspComponentFoundry to retrieve
	registered control type.

	* TemplateControlParser.cs: AddControlImports () removed. Its
	functionality is now implemented in ControlBuilder.AddChild in a
	more elegant, fine grained and correct way.

	* TemplateParser.cs: replaced some "" with String.Empty

	* ControlBuilder.cs: AddChild now adds an import for child's
	namespace if the control being added has been registered in the
	web.config file. Possible fix for #447896 and #447898

	* PageParser.cs, MasterPageParser.cs: do not call
	AddControlImports, it no longer exists.

2008-11-25  Marek Habersack  <[email protected]>

	* AspComponentFoundry.cs: GetComponentType methods replaced with
	GetComponent returning an instance of AspComponent which fully
	describes the registered item. Components are cached, indexed by
	full tag name.

	* AspComponent.cs: added

svn path=/trunk/mcs/; revision=119893
2008-11-25 00:51:21 +00:00
Marek Habersack a2bad5bd17 2008-11-21 Marek Habersack <[email protected]>
* TemplateControlCompiler.cs: make the Bind regex stricter.
	When creating Eval expression from Bind, replace single quotes
	with double quotes. Fixes bug #447597
	When processing Bind expressions and the regex doesn't match,
	throw an exception.

2008-11-21  Marek Habersack  <[email protected]>

	* ControlBuilder.cs: in BindingContainerType if builder is a
	RootBuilder and no naming container is found, return typeof
	(Page). In the TemplateBuilder case return cb.ControlType, not
	this.ControlType.

svn path=/trunk/mcs/; revision=119661
2008-11-21 19:27:51 +00:00
Gonzalo Paniagua Javier cdac72488f 2008-11-18 Gonzalo Paniagua Javier <[email protected]>
* ControlBuilder.cs: make sure the binding container container is a
	naming container.


svn path=/trunk/mcs/; revision=119269
2008-11-19 04:06:46 +00:00
Marek Habersack 49df583968 2008-11-18 Marek Habersack <[email protected]>
* ControlBuilder.cs: make sure no control implementing the
	INonBindingContainer can be returned from BindingContainerType.

svn path=/trunk/mcs/; revision=119233
2008-11-18 22:18:41 +00:00
Gonzalo Paniagua Javier 9bf26ae78e 2008-11-18 Gonzalo Paniagua Javier <[email protected]>
* ControlBuilder.cs: find the correct naming container even inside
	user controls. A corner case of bug #445889.


svn path=/trunk/mcs/; revision=119130
2008-11-18 07:16:13 +00:00
Marek Habersack cd9089259b 2008-11-15 Marek Habersack <[email protected]>
* ContentPlaceHolder.cs, Content.cs, FormViewPagerRow.cs,
	ChangePassword.cs, DetailsViewPagerRow.cs: implements
	INonBindingContainer interface.

	* Wizard.cs: implement INonBindingContainer interface for several
	private/internal classes.

2008-11-15  Marek Habersack  <[email protected]>

	* INonBindingContainer.cs: added

	* Control.cs: BindingContainer now checks if a control implements
	INonBindingContainer interface in addition to the
	BINDING_CONTAINER mask check.

	* UserControl.cs: implements INonBindingContainer

	* ControlBuilder.cs: use the new INonBindingContainer interface to
	determine the binding container type in the BindingContainerType
	property. If TemplateBuilder's ContainerType implements that
	interface, the NamingContainer is queried for the binding
	container type. If ContainerType is null, we return our own
	ControlType (if we're TemplateBuilder)

2008-11-15  Marek Habersack  <[email protected]>

	* System.Web.dll.sources: added System.Web.UI/INonBindingContainer.cs

svn path=/trunk/mcs/; revision=118917
2008-11-15 03:40:24 +00:00
Marek Habersack a34534b9c3 2008-09-01 Marek Habersack <[email protected]>
* ControlBuilder.cs:
	CreateSubBuilder compares tagid to tagName case-insensitively now.

svn path=/trunk/mcs/; revision=112005
2008-09-01 02:30:35 +00:00
Marek Habersack 6c416d1a76 2008-09-01 Marek Habersack <[email protected]>
* ControlBuilder.cs: CreatePropertyBuilder now correctly processes
	property names with prefixes (e.g. 'prefix:PropertyName'). 
	Original, parsed, tag name is stored to properly handle closing
	tags.

2008-09-01  Marek Habersack  <[email protected]>

	* AspGenerator.cs:
	CloseControl uses ControlBuilder's OriginalTagName property,
	should the property/tag name be prefixed with 'prefix:'

svn path=/trunk/mcs/; revision=112003
2008-09-01 01:33:27 +00:00
Marek Habersack 90e612afe1 2008-08-31 Marek Habersack <[email protected]>
* TemplateControlCompiler.cs:
	Templates are processed before anything else, so that children
	which may depend on parent's templates can get access to them.

2008-08-31  Marek Habersack  <[email protected]>

	* Control.cs: improved FillControlCache

	* ControlBuilder.cs:
	Added a cache for children of TemplateBuilder, used later in
	TemplateControlCompiler.

svn path=/trunk/mcs/; revision=111990
2008-08-31 17:05:28 +00:00
Marek Habersack 27ece7a9b2 2008-08-31 Marek Habersack <[email protected]>
* TemplateParser.cs: added support for the LinePragmas directive
	attribute.

	* ControlBuilder.cs: if this instance is a TemplateBuilder do not
	call MyNamingContainer, so that our own ContainerType can be used
	as the binding container (if present).

2008-08-31  Marek Habersack  <[email protected]>

	* TemplateControlCompiler.cs: trust builder.BindingContainerType
	in the 2.0+ profile - do not use container properties to detect
	the type.
	Added a helper method, compiled only when DEBUG is defined, to
	generate Console.WriteLine CodeDOM calls.

	* BaseCompiler.cs: add line pragmas only if enabled for the
	current file.


svn path=/trunk/mcs/; revision=111983
2008-08-31 01:41:14 +00:00
Marek Habersack 4944213e17 2008-06-30 Marek Habersack <[email protected]>
* AspGenerator.cs: hush the warnings and fix invalid type
	comparison.

	* AssemblyBuilder.cs: hush the warnings and add some debugging
	CWLs.

	* AspParser.cs, AppResourcesCompiler.cs, TemplateBuildProvider.cs,
	CachingCompiler.cs, BaseCompiler.cs, TemplateControlCompiler.cs,
	SimpleBuildProvider.cs, BuildManager.cs: hush the warnings

2008-06-30  Marek Habersack  <[email protected]>

	* HtmlForm.cs: hush the warnings

2008-06-30  Marek Habersack  <[email protected]>

	* ObjectDataSourceView.cs, Menu.cs, DataList.cs,
	CustomValidator.cs: hush the warnings

2008-06-30  Marek Habersack  <[email protected]>

	* MachineKeyRegistryStorage.cs: hush the warnings

2008-06-30  Marek Habersack  <[email protected]>

	* SqliteMembershipProvider.cs, SqliteRoleProvider.cs: remove
	unused method

	* SqlRoleProvider.cs, AspNetDBSchemaChecker.cs: hush the warnings

2008-06-30  Marek Habersack  <[email protected]>

	* UserControlParser.cs: hush the warnings and remove unnecessary
	code.

	* ControlCachePolicy.cs, PageParser.cs, ControlBuilder.cs,
	TemplateParser.cs, SimpleWebHandlerParser.cs, TemplateControl.cs,
	ApplicationFileParser.cs: hush the warnings

	* Page.cs: Context is protected internal in .NET 3.5
	Initialize encryption IVs before returning the transform.

	* Control.cs: Hush the warnings.

2008-06-30  Marek Habersack  <[email protected]>

	* HttpRuntime.cs, HttpApplication.cs: hush the warnings

	* HttpContext.cs: Hush the warnings.

2008-06-30  Marek Habersack  <[email protected]>

	* SqliteProfileProvider.cs: remove unused method

2008-06-30  Marek Habersack  <[email protected]>

	* CompilationSection.cs: hush the warnings



svn path=/trunk/mcs/; revision=106886
2008-06-30 13:20:58 +00:00
Marek Habersack a2a7d08ceb 2008-02-26 Marek Habersack <[email protected]>
* TemplateParser.cs: a better error message.

	* ControlBuilder.cs: if one of the parent builders is a
	TemplateBuilder, use it as the naming container and use its
	ContainerType property as the value of the BindingContainerType
	property.
2008-02-26  Marek Habersack  <[email protected]>

	* BuildProviderCollection.cs: be case-insensitive when looking for
	the extension match.
2008-02-26  Marek Habersack  <[email protected]>

	* BuildManager.cs: known file types extensions are now matched
	case-insensitively.

svn path=/trunk/mcs/; revision=96644
2008-02-26 13:56:15 +00:00
Marek Habersack 1cbb00dda5 2008-02-25 Marek Habersack <[email protected]>
* ControlBuilder.cs: correctly chain up to the parent builder when
	looking for the naming container.
2008-02-25  Marek Habersack  <[email protected]>

	* TemplateControlCompiler.cs: GetContainerType now checks whether
	the binding container returned from the builder implements
	IDataItemContainer (for 2.0+ profiles) and looks for one more
	property, Rows, if no Items property is found.

svn path=/trunk/mcs/; revision=96536
2008-02-25 12:33:16 +00:00
Marek Habersack 66916dc696 2008-02-21 Marek Habersack <[email protected]>
* ControlBuilder.cs: introduced a new internal property -
	MyNamingContainer used by the public properties
	NamingContainerType and BindingContainerType. This simplifies the
	code in the latter property, as the binding container type must
	almost always be the same as the naming container type. The only
	exception is when we're inside a content builder, in which case we
	return the parent's BindingContainerType. Fixes bug #363665

svn path=/trunk/mcs/; revision=96395
2008-02-21 21:06:57 +00:00
Marek Habersack fcc675453f 2007-08-21 Marek Habersack <[email protected]>
* ApplicationHostTest.cs: adjust the test for the PrivateBinPath
        changes.

2007-08-21  Marek Habersack  <[email protected]>

        * ProvidersHelper.cs: use HttpApplication.LoadTypeFromPrivateBin
        to get the provider settings type.

2007-08-21  Marek Habersack  <[email protected]>

        * HttpApplicationFactory.cs: watch for changes in all the
        private binary directories for the current application domain.

        * HttpApplication.cs: turn the PrivateBinPath property into an
        internal enumerable, so that code throughout the assembly can
        iterate over the list of private bin directories configured for
        the application domain.
        Added a new internal method LoadTypeFromPrivateBin, for sharing
        with other parts of the assembly.

2007-08-21  Marek Habersack  <[email protected]>

        * SimpleWebHandlerParser.cs: use HttpApplication.PrivateBinPath
        enumerator when loading or adding assemblies from binary
        directories. Remove unused PrivateBinPath property.

        * ControlBuilder.cs: remove unused PrivateBinPath property.

        * TemplateParser.cs: use HttpApplication.PrivateBinPath when
        adding assemblis and loading types.

2007-08-21  Marek Habersack  <[email protected]>

        * ApplicationHost.cs: AppDomainSetup.PrivateBinPath should contain
        a list of paths relative to AppDomainSetup.ApplicationBase, not a
        full path.
        We no longer check if the bin directories exist, the user can
        create them while the application is running.

2007-08-21  Marek Habersack  <[email protected]>

        * ObjectDataSourceView.cs: get rid of PrivateBinPath property,
        it's unused.

2007-08-21  Marek Habersack  <[email protected]>

        * BuildProvider.cs: use HttpApplication.PrivateBinPath enumerator
        to look up assemblies in the binary path(s).

svn path=/trunk/mcs/; revision=84589
2007-08-21 21:13:54 +00:00
Marek Habersack 6a629d62d7 2007-07-18 Marek Habersack <[email protected]>
* ControlBuilder.cs: on the 2.0 profile BindingContainerType
	returns the associated control's base type when parent builder is
	absent instead of typeof (Control). It returns typeof (Control) if
	the parent builder type is determined to be a
	NamingContainer. This makes the generated code match the MS.NET
	output. Fixes bug #82119.

2007-07-18  Marek Habersack  <[email protected]>

	* TemplateControlCompiler.cs: on the 2.0 profile, GetContainerType
	does not look up the Item/Items properties to determine the
	container type, instead it just returns the type reported by the
	builder passed to this method. This change makes the generated
	code match MS.NET. Fixes bug #82119.


svn path=/trunk/mcs/; revision=82200
2007-07-18 12:48:55 +00:00
Marek Habersack c7d897bbf4 2007-05-15 Marek Habersack <[email protected]>
* TemplateParser.cs: refactoring - use HttpApplication.LoadType to
	actually look up types.
	
	* ControlBuilder.cs: as above

2007-05-15  Marek Habersack  <[email protected]>

	* BuildProviderCollection.cs: refactoring - use
	HttpApplication.LoadType to actually look up the type.

	* HttpHandlerAction.cs: as above

	* WebConfigurationHost.cs: refactoring - moved the LoadType to
	HttpApplication to share the code between 1.1 and 2.0 profiles.

2007-05-15  Marek Habersack  <[email protected]>

	* ObjectDataSourceView.cs: refactoring - use
	HttpApplication.LoadType to look up types.

2007-05-15  Marek Habersack  <[email protected]>

	* HttpApplication.cs: refactoring - moved LoadType from
	WebConfigurationHost here and made it internal static, in order to
	make the code avaliable from all the places where extended type
	loading is required.


svn path=/trunk/mcs/; revision=77396
2007-05-15 09:35:00 +00:00
Gert Driesen 266a7e0e91 * ControlBuilder.cs: Fixed exception message in MapType.
svn path=/trunk/mcs/; revision=77265
2007-05-11 21:59:50 +00:00
Marek Habersack 040076ea09 2007-05-09 Marek Habersack <[email protected]>
* CollectionBuilder.cs: formatting changes

	* ControlBuilder.cs: if a control enables children as properties,
	has a default property and parser encounters a child tag/container
	with the default property name, discard the default property
	builder in order to avoid invalid sub builder invocation. An
	example is: <asp:DropDownList><Items></Items></asp:DropDownList>
	Formatting changes.
	When checking for empty string, use Length not comparison with ""

svn path=/trunk/mcs/; revision=76995
2007-05-09 11:03:08 +00:00
Marek Habersack e97f1be4f8 2007-05-07 Marek Habersack <[email protected]>
* ControlBuilder.cs: when mapping types, catch casses of missing
	original and mapped types.
	If mapped type doesn't derive from the original type, throw an
	exception. Fixes bug #81553.

svn path=/trunk/mcs/; revision=76855
2007-05-07 18:07:06 +00:00
Marek Habersack 61bff8fe42 2007-04-06 Marek Habersack <[email protected]>
* ControlBuilder.cs: allow tag mappings from code found 
	in bin/* or App_Code/*. Fixes bug #80811.


svn path=/trunk/mcs/; revision=75467
2007-04-05 22:48:20 +00:00
Marek Habersack 5dd4bebf9e Implement tag mapping for asp.net 2.0
svn path=/trunk/mcs/; revision=69906
2006-12-21 22:00:50 +00:00
Chris Toshok 81693a8ae2 2006-05-08 Chris Toshok <[email protected]>
* ControlBuilder.cs (ResetState): set renderIndex to 0 here.  This
	fixes the last thing keeping the test in #78616 from working.


svn path=/trunk/mcs/; revision=60420
2006-05-08 19:19:54 +00:00
Gonzalo Paniagua Javier 915d986f09 2006-03-24 Gonzalo Paniagua Javier <[email protected]>
* System.Web.UI/ControlBuilder.cs: when creating a default property
	builder, handle strings specially.

	* System.Web.UI/StringPropertyBuilder.cs: new builder used in
	TextBox 2.0.
	* System.Web.dll.sources: add StringPropertyBuilder.
	* System.Web.Compilation/TemplateControlCompiler.cs: handle the new
	StringPropertyBuilder.

	Fixes bug #77762.


svn path=/trunk/mcs/; revision=58505
2006-03-24 23:11:09 +00:00
Chris Toshok d19727e2ed * TemplateControl.cs: corcompare work.
* ExpressionBindingCollection.cs: same.

	* HierarchicalDataSourceControl.cs: same.

	* PostBackOptions.cs: same.

	* ClientScriptManager.cs: same.

	* FilterableAttribute.cs: same.

	* ControlCollection.cs: same.

	* DataBindingCollection.cs: same.
	
	* PropertyEntry.cs: mark ctor internal.

	* SimpleWebHandlerParser.cs: mark the 2.0 ctor as internal.

	* Page.cs: stub out two Theme oriented 2.0 properties.

	* DataBinder.cs: remove the obsolete attribute on the ctor.

	* TwoWayBoundPropertyEntry.cs: remove this.
	
	* ControlBuilder.cs (BindingContainerType): virtual in 2.0.

	* ThemeProvider: new (stubbed) class.

	* SkinBuilder.cs: same.

	* PageTheme.cs: same.

	* ControlSkin.cs: same.
	
	* ControlSkinProc.cs: rename this to ControlSkinDelegate.cs.
	
	* SimplePropertyEntry.cs: mark ctor as internal.

	* IThemeResolutionService.cs: enable the 3 members of this
	interface.

2006-02-27  Chris Toshok  <[email protected]>


svn path=/trunk/mcs/; revision=57352
2006-02-27 21:13:03 +00:00
Chris Toshok 7ad5ba37f4 2006-02-07 Chris Toshok <[email protected]>
* ControlBuilder.cs: rename flushOutputStatements to
	methodStatements to at least reflect that they're in that method.


svn path=/trunk/mcs/; revision=56638
2006-02-07 20:34:47 +00:00
Chris Toshok b5cb597758 2006-02-07 Chris Toshok <[email protected]>
* MasterPage.cs (CreateMasterPage): don't nullref on null
	contentTemplateCollection.

	* ControlBuilder.cs: add a flushOutputStatements field.

	* PageParser.cs (ProcessMainAttributes): handle Title attribute.
	(Title): add getter.
	
	* Page.cs (Title): implement getter/setter.
	(InternalProcessRequest): after calling ApplyMasterPage, apply the
	page's Title directive if there is one.
	(AddContentTemplate): make the EditorBrowsable attribute apply to
	the method, not the field.


svn path=/trunk/mcs/; revision=56634
2006-02-07 20:04:15 +00:00
Gonzalo Paniagua Javier cc5d84d39d Patch by D. Moonfire that fixes several issues with 2.0 page attributes.
svn path=/trunk/mcs/; revision=54363
2005-12-14 15:49:16 +00:00
Sebastien Pouliot 7836b64c9d 2005-09-19 Sebastien Pouliot <[email protected]>
* ControlBuilder.cs: Added BuildObject override for 2.0 profile.
	* TagPrefixAttribute.cs: Added LinkDemand for AspNetHostingPermission
	with Minimal level. Fixed checks on ctor.
	* TemplateBuilder.cs: Added LinkDemand and InheritanceDemand for 
	AspNetHostingPermission with Minimal level.
	* TemplateContainerAttribute.cs: Added LinkDemand for 
	AspNetHostingPermission with Minimal level.
	* TemplateControl.cs: Added LinkDemand and InheritanceDemand for 
	AspNetHostingPermission with Minimal level. Fixed checks/exceptions. 
	Stubbed IFilterResolutionService for CAS testing.
	* TemplateControlParser.cs: Added LinkDemand and InheritanceDemand for
	AspNetHostingPermission with Minimal level.
	* TemplateParser.cs: Added LinkDemand and InheritanceDemand for 
	AspNetHostingPermission with Minimal level.
	* ThemeableAttribute.cs: Added LinkDemand for AspNetHostingPermission
	with Minimal level. Removed IDispose interface.
	* ToolboxDataAttribute.cs: Added LinkDemand for 
	AspNetHostingPermission with Minimal level. Fixed IsDefaultAttribute 
	to work on both 1.x and 2.0 profiles.
	* Triplet.cs: Added LinkDemand and (only for 1.x) InheritanceDemand 
	for AspNetHostingPermission with Minimal level.
	* UserControl.cs: Added LinkDemand and InheritanceDemand for 
	AspNetHostingPermission with Minimal level. Stubbed 
	IFilterResolutionService for CAS testing.
	* UserControlControlBuilder.cs: Added LinkDemand and InheritanceDemand
	for AspNetHostingPermission with Minimal level.
	* ValidationPropertyAttribute.cs: Added LinkDemand for 
	AspNetHostingPermission with Minimal level.
	* ValidatorCollection.cs: Added LinkDemand for AspNetHostingPermission 
	with Minimal level.
	* WebResourceAttribute.cs: Removed extra ctor and added setter to 
	PerformSubstitution.
	* WebServiceParser.cs: Added LinkDemand and InheritanceDemand for 
	AspNetHostingPermission with Minimal level.


svn path=/trunk/mcs/; revision=50230
2005-09-19 13:55:35 +00:00
Sebastien Pouliot c1cc7616df 2005-09-14 Sebastien Pouliot <[email protected]>
* AttributeCollection.cs: Added LinkDemand for AspNetHostingPermission
	with Minimal level.
	* BaseParser.cs: Added LinkDemand and InheritanceDemand for 
	AspNetHostingPermission with Minimal level.
	* BasePartialCachingControl.cs: Added LinkDemand and InheritanceDemand
	for AspNetHostingPermission with Minimal level.
	* CompiledTemplateBuilder.cs: Added LinkDemand for 
	AspNetHostingPermission with Minimal level.
	* ConstructorNeedsTagAttribute.cs: Added LinkDemand for 
	AspNetHostingPermission with Minimal level.
	* ControlBuilderAttribute.cs: Added LinkDemand for 
	AspNetHostingPermission with Minimal level. Simplified Equals and 
	IsDefaultAttribute.
	* ControlBuilder.cs: Added LinkDemand and InheritanceDemand for 
	AspNetHostingPermission with Minimal level.
	* ControlCachePolicy.cs: Hided ctor and removed SupportsCaching setter
	* ControlCollection.cs: Added LinkDemand and InheritanceDemand for 
	AspNetHostingPermission with Minimal level. Fixed possible stack 
	overflow in Add* methods. Fixed CopyTo as we're not allocating the 
	array based on the number of items.
	* Control.cs: Added LinkDemand and InheritanceDemand for 
	AspNetHostingPermission with Minimal level. Fixed 2.0 signatures.
	* CssStyleCollection.cs: Added LinkDemand for AspNetHostingPermission 
	with Minimal level.
	* IStyleSheet.cs: Fixed parameter orders (2.0).


svn path=/trunk/mcs/; revision=50041
2005-09-14 17:25:07 +00:00
Ben Maurer 0e8decdb37 remove svn:executable from .cs files
svn path=/trunk/mcs/; revision=46562
2005-06-27 15:51:40 +00:00
Lluis Sanchez 00d1ac7d6d 2005-04-15 Lluis Sanchez Gual <[email protected]>
* ControlBuilder.cs: The BindingContainerType property happens
	to exist in 2.0, so I made it public. Added ParentTemplateBuilder,
	which is used to get the binding container that is managing
	the current two-way binding context.
	* TemplateBuilder.cs: Added some methods and an internal class
	to support two-way bindings.
	* CompiledBindableTemplateBuilder.cs: Implemented.
	* IBindableTemplate.cs: This interface inherits from ITemplate.


svn path=/trunk/mcs/; revision=43073
2005-04-15 20:41:11 +00:00
Lluis Sanchez 3a6d4aec24 2005-04-14 Lluis Sanchez Gual <[email protected]>
* ControlBuilder.cs: Added BindingContainerType property,
	which works like NamingContainerType but takes into account
	template builders with a specific container type (specified
	using the TemplateContainerAttribute.
	* StateManagedCollection.cs: Reimplemented Save/Load view
	state methods. The existing implementation was not correct
	in all cases.


svn path=/trunk/mcs/; revision=42996
2005-04-14 12:22:26 +00:00
Lluis Sanchez bf4c99d6a6 2005-01-10 Lluis Sanchez Gual <[email protected]>
* TemplateBuilder.cs: Added a special constructor that takes an
	attribute provider as parameter. The container type for the template
	may be defined in a TemplateContainerAttribute.
	* ControlBuilder.cs: Create the TemplateBuilder using that special
	constructor.
	* TemplateContainerAttribute.cs: Added 2.0 property and ctor.


svn path=/trunk/mcs/; revision=38619
2005-01-10 15:21:19 +00:00