Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / cdf / src / WF / Common / AuthoringOM / Design / Glyphs / ReadOnlyActivityGlyph.cs / 1305376 / ReadOnlyActivityGlyph.cs
namespace System.Workflow.ComponentModel.Design { using System; using System.Drawing; using System.Drawing.Drawing2D; using System.Windows.Forms; #region Glyphs #region Class ReadOnlyActivityGlyph //Class is internal but not sealed as we dont expect the ActivityDesigner writers to supply their own //Glyph instead based on comment property comment glyph is shown //Exception: StripItemCommentGlyph public class ReadOnlyActivityGlyph : DesignerGlyph { public override Rectangle GetBounds(ActivityDesigner designer, bool activated) { if (designer == null) throw new ArgumentNullException("designer"); Rectangle bounds = designer.Bounds; bounds.Inflate(WorkflowTheme.CurrentTheme.AmbientTheme.Margin); return bounds; } public override int Priority { get { return DesignerGlyph.ReadOnlyGlyphPriority; } } protected override void OnPaint(Graphics graphics, bool activated, AmbientTheme ambientTheme, ActivityDesigner designer) { Rectangle bounds = GetBounds(designer, activated); bounds.Inflate(WorkflowTheme.CurrentTheme.AmbientTheme.Margin); ActivityDesignerPaint.DrawImage(graphics, AmbientTheme.ReadOnlyImage, bounds, DesignerContentAlignment.TopLeft); } } #endregion #endregion } // 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
- RequestResizeEvent.cs
- webclient.cs
- MimeParameters.cs
- DecoderExceptionFallback.cs
- CapabilitiesRule.cs
- SymmetricKeyWrap.cs
- ThousandthOfEmRealPoints.cs
- Configuration.cs
- HttpResponse.cs
- SqlConnection.cs
- SqlRemoveConstantOrderBy.cs
- NetStream.cs
- CommandDevice.cs
- DelegatingTypeDescriptionProvider.cs
- SafeRegistryHandle.cs
- AuthenticationException.cs
- ReferenceConverter.cs
- DesignerAutoFormatStyle.cs
- TemplatedWizardStep.cs
- CodeCatchClauseCollection.cs
- XmlnsCache.cs
- ScriptReference.cs
- WindowsFormsHost.cs
- TextBox.cs
- ServicesUtilities.cs
- ColorContextHelper.cs
- PropertySet.cs
- UIElementParaClient.cs
- EncoderBestFitFallback.cs
- SplitContainer.cs
- XmlNodeChangedEventArgs.cs
- Metadata.cs
- XmlDesigner.cs
- DataControlFieldHeaderCell.cs
- unsafenativemethodsother.cs
- TextTreeInsertUndoUnit.cs
- XmlLoader.cs
- QueuedDeliveryRequirementsMode.cs
- SQLString.cs
- cookiecontainer.cs
- BindingExpressionUncommonField.cs
- Tablet.cs
- DefaultAssemblyResolver.cs
- GAC.cs
- DoubleStorage.cs
- CriticalHandle.cs
- TaiwanLunisolarCalendar.cs
- HttpDebugHandler.cs
- SqlCacheDependencyDatabaseCollection.cs
- DataPagerFieldItem.cs
- Type.cs
- SectionRecord.cs
- DesignerLinkAdapter.cs
- ICspAsymmetricAlgorithm.cs
- TypeResolvingOptions.cs
- FigureParagraph.cs
- VectorCollectionValueSerializer.cs
- SurrogateEncoder.cs
- ResXFileRef.cs
- HttpModulesSection.cs
- EqualityComparer.cs
- FormatSettings.cs
- PolyLineSegmentFigureLogic.cs
- WebScriptMetadataMessage.cs
- QilFunction.cs
- WorkflowFileItem.cs
- SqlDataSourceSelectingEventArgs.cs
- Geometry.cs
- Wizard.cs
- NativeMethods.cs
- XPathDescendantIterator.cs
- TextTreeFixupNode.cs
- SecurityKeyIdentifierClause.cs
- FormsAuthenticationModule.cs
- TcpAppDomainProtocolHandler.cs
- Decimal.cs
- PipelineModuleStepContainer.cs
- MouseActionConverter.cs
- SelectionListDesigner.cs
- KeyValueInternalCollection.cs
- TextEncodedRawTextWriter.cs
- Pkcs7Signer.cs
- Slider.cs
- BitmapMetadataEnumerator.cs
- StoreItemCollection.cs
- UIElementHelper.cs
- SafeNativeMethods.cs
- PenContext.cs
- OleDbDataAdapter.cs
- ColorAnimationBase.cs
- _FtpDataStream.cs
- Compiler.cs
- CharacterMetrics.cs
- AuthenticateEventArgs.cs
- FeatureAttribute.cs
- NestedContainer.cs
- ColumnMapCopier.cs
- StandardCommands.cs
- ControlPersister.cs
- AnnotationResourceChangedEventArgs.cs