Code:
/ DotNET / DotNET / 8.0 / untmp / whidbey / REDBITS / ndp / fx / src / Designer / WebForms / System / Web / UI / Design / WebParts / ToolZoneDesigner.cs / 1 / ToolZoneDesigner.cs
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//-----------------------------------------------------------------------------
namespace System.Web.UI.Design.WebControls.WebParts {
using System;
using System.ComponentModel;
using System.ComponentModel.Design;
using System.Design;
using System.Web.UI.WebControls.WebParts;
[System.Security.Permissions.SecurityPermission(System.Security.Permissions.SecurityAction.Demand, Flags=System.Security.Permissions.SecurityPermissionFlag.UnmanagedCode)]
public class ToolZoneDesigner : WebZoneDesigner {
public override DesignerActionListCollection ActionLists {
get {
DesignerActionListCollection actionLists = new DesignerActionListCollection();
actionLists.AddRange(base.ActionLists);
actionLists.Add(new ToolZoneDesignerActionList(this));
return actionLists;
}
}
protected bool ViewInBrowseMode {
get {
object o = DesignerState["ViewInBrowseMode"];
return (o != null) ? (bool)o : false;
}
private set {
if (value != ViewInBrowseMode) {
DesignerState["ViewInBrowseMode"] = value;
UpdateDesignTimeHtml();
}
}
}
public override void Initialize(IComponent component) {
VerifyInitializeArgument(component, typeof(ToolZone));
base.Initialize(component);
}
private class ToolZoneDesignerActionList : DesignerActionList {
private ToolZoneDesigner _parent;
public ToolZoneDesignerActionList(ToolZoneDesigner parent) : base (parent.Component){
_parent = parent;
}
public override bool AutoShow {
get {
return true;
}
set {
}
}
public bool ViewInBrowseMode {
get {
return _parent.ViewInBrowseMode;
}
set {
_parent.ViewInBrowseMode = value;
}
}
public override DesignerActionItemCollection GetSortedActionItems() {
DesignerActionItemCollection items = new DesignerActionItemCollection();
items.Add(new DesignerActionPropertyItem("ViewInBrowseMode",
SR.GetString(SR.ToolZoneDesigner_ViewInBrowseMode),
String.Empty,
SR.GetString(SR.ToolZoneDesigner_ViewInBrowseModeDesc)));
return items;
}
}
}
}
// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
// Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- XmlExtensionFunction.cs
- WmlObjectListAdapter.cs
- AdPostCacheSubstitution.cs
- OptionalColumn.cs
- SqlUDTStorage.cs
- GuidConverter.cs
- GridViewPageEventArgs.cs
- _emptywebproxy.cs
- TreeNodeEventArgs.cs
- TypeForwardedToAttribute.cs
- InfoCardListRequest.cs
- Input.cs
- SchemaHelper.cs
- OdbcConnectionString.cs
- UnmanagedMemoryStreamWrapper.cs
- Padding.cs
- AutomationElement.cs
- XslNumber.cs
- QilCloneVisitor.cs
- CategoryAttribute.cs
- BrushConverter.cs
- SizeAnimation.cs
- AnimatedTypeHelpers.cs
- XmlHierarchicalDataSourceView.cs
- PersistenceTypeAttribute.cs
- AutomationPropertyInfo.cs
- StyleCollectionEditor.cs
- QilLiteral.cs
- TableSectionStyle.cs
- DirectoryNotFoundException.cs
- DataSourceNameHandler.cs
- _ShellExpression.cs
- QuarticEase.cs
- SafeSecurityHandles.cs
- Classification.cs
- DataGridHeaderBorder.cs
- DataGridViewCellValueEventArgs.cs
- HtmlInputHidden.cs
- KnownTypeAttribute.cs
- RequiredFieldValidator.cs
- ScrollData.cs
- FormatConvertedBitmap.cs
- DataGridLinkButton.cs
- NativeConfigurationLoader.cs
- ComponentEvent.cs
- MetaModel.cs
- HebrewCalendar.cs
- httpstaticobjectscollection.cs
- OSEnvironmentHelper.cs
- XsdCachingReader.cs
- entityreference_tresulttype.cs
- RoleManagerEventArgs.cs
- TextProviderWrapper.cs
- StrongName.cs
- Exception.cs
- Query.cs
- WmlPhoneCallAdapter.cs
- OleDbException.cs
- Image.cs
- MediaElement.cs
- ParameterCollection.cs
- ObjectDataSourceView.cs
- EntitySqlQueryBuilder.cs
- Splitter.cs
- ExtendedPropertyCollection.cs
- TimeSpanSecondsConverter.cs
- WorkflowInstanceAbortedRecord.cs
- FixedElement.cs
- FixedBufferAttribute.cs
- ValuePatternIdentifiers.cs
- EdmComplexPropertyAttribute.cs
- TimerEventSubscription.cs
- FunctionImportMapping.ReturnTypeRenameMapping.cs
- XPathAxisIterator.cs
- AuthenticationService.cs
- BinaryObjectInfo.cs
- DataGridCaption.cs
- IisTraceListener.cs
- DataRowView.cs
- CancellationHandler.cs
- Configuration.cs
- Inline.cs
- WizardPanel.cs
- RootNamespaceAttribute.cs
- StartUpEventArgs.cs
- DesignerProperties.cs
- InputProviderSite.cs
- SimpleType.cs
- SettingsPropertyIsReadOnlyException.cs
- filewebrequest.cs
- NegatedConstant.cs
- DbFunctionCommandTree.cs
- StaticContext.cs
- DataGridViewControlCollection.cs
- HyperLinkStyle.cs
- FileClassifier.cs
- BufferedGraphicsContext.cs
- PowerStatus.cs
- ForeignConstraint.cs
- TextTreeText.cs