Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Framework / System / Windows / Controls / Primitives / CustomPopupPlacement.cs / 1305600 / CustomPopupPlacement.cs
using System; namespace System.Windows.Controls.Primitives { ////// Describes where a popup should be placed on screen. /// public struct CustomPopupPlacement { ////// Constructor /// /// Assigns to Point /// Assigns to PrimaryAxis public CustomPopupPlacement(Point point, PopupPrimaryAxis primaryAxis) { _point = point; _primaryAxis = primaryAxis; } ////// The point, relative to the PlacementTarget, where the upper left corner of the Popup should be. /// public Point Point { get { return _point; } set { _point = value; } } ////// The primary axis of the popup that will be used for nudging on-screen. /// public PopupPrimaryAxis PrimaryAxis { get { return _primaryAxis; } set { _primaryAxis = value; } } ////// Compares the value of two CustomPopupPlacement structs for equality. /// /// The first value. /// The second value. ///public static bool operator==(CustomPopupPlacement placement1, CustomPopupPlacement placement2) { return placement1.Equals(placement2); } /// /// Compares the value of two CustomPopupPlacement structs for inequality. /// /// The first value. /// The second value. ///public static bool operator !=(CustomPopupPlacement placement1, CustomPopupPlacement placement2) { return !placement1.Equals(placement2); } /// /// Compares the value of this struct with another object. /// /// An object to compare to. ///True if equivalent. False otherwise. public override bool Equals(object o) { if (o is CustomPopupPlacement) { CustomPopupPlacement placement = (CustomPopupPlacement)o; return (placement._primaryAxis == _primaryAxis) && (placement._point == _point); } return false; } ////// Hash function for this type. /// ///A hash code for this struct. public override int GetHashCode() { return _primaryAxis.GetHashCode() ^ _point.GetHashCode(); } private Point _point; private PopupPrimaryAxis _primaryAxis; } } // 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
- TextSegment.cs
- DetailsViewUpdatedEventArgs.cs
- DataList.cs
- Attributes.cs
- IOThreadTimer.cs
- SoapFormatter.cs
- smtpconnection.cs
- ConnectionPointCookie.cs
- DataRowCollection.cs
- HttpCapabilitiesBase.cs
- KeyNotFoundException.cs
- SystemInfo.cs
- WsdlWriter.cs
- _NestedSingleAsyncResult.cs
- SafeFindHandle.cs
- MessageBox.cs
- XsdCachingReader.cs
- SQLBoolean.cs
- COM2ExtendedBrowsingHandler.cs
- DefaultTraceListener.cs
- OpCopier.cs
- MimeTypeAttribute.cs
- HandlerElementCollection.cs
- XmlSchemaCompilationSettings.cs
- ExtensionSimplifierMarkupObject.cs
- DocumentPageHost.cs
- ProfileParameter.cs
- BitmapPalette.cs
- TextRangeProviderWrapper.cs
- SubMenuStyleCollectionEditor.cs
- FixedTextView.cs
- ConfigurationManagerHelperFactory.cs
- ConsumerConnectionPointCollection.cs
- WebPartTransformerAttribute.cs
- Util.cs
- TextBox.cs
- TextEffect.cs
- DataControlButton.cs
- DPCustomTypeDescriptor.cs
- DoubleCollection.cs
- EditorAttributeInfo.cs
- SqlExpander.cs
- ByteStream.cs
- httpstaticobjectscollection.cs
- FontCacheUtil.cs
- DynamicAttribute.cs
- HiddenFieldPageStatePersister.cs
- SecurityTokenAuthenticator.cs
- MetadataArtifactLoaderCompositeResource.cs
- KeyPullup.cs
- BaseValidator.cs
- ComponentDispatcher.cs
- LogSwitch.cs
- DnsPermission.cs
- serverconfig.cs
- Vector3DValueSerializer.cs
- BinaryWriter.cs
- followingsibling.cs
- DateBoldEvent.cs
- MultiBinding.cs
- UnionExpr.cs
- UIntPtr.cs
- DynamicField.cs
- SourceItem.cs
- SchemaMapping.cs
- AppliedDeviceFiltersEditor.cs
- SQLSingle.cs
- Transform.cs
- HostProtectionPermission.cs
- ChannelManagerBase.cs
- Stroke.cs
- ConfigurationSettings.cs
- MenuCommand.cs
- RootDesignerSerializerAttribute.cs
- MimeObjectFactory.cs
- StringArrayConverter.cs
- ComponentEditorForm.cs
- GeneratedContractType.cs
- UpdateExpressionVisitor.cs
- MobileContainerDesigner.cs
- FormViewRow.cs
- Stopwatch.cs
- QueryOpeningEnumerator.cs
- DataGrid.cs
- EventLogPermissionAttribute.cs
- ListViewDeletedEventArgs.cs
- PartManifestEntry.cs
- DelayedRegex.cs
- ToolStripItemCollection.cs
- ColorIndependentAnimationStorage.cs
- ExpandCollapsePattern.cs
- DataKeyCollection.cs
- FormsAuthenticationCredentials.cs
- AxImporter.cs
- HostProtectionPermission.cs
- RequestCacheManager.cs
- RSAPKCS1SignatureDeformatter.cs
- SecurityTokenProvider.cs
- HeaderUtility.cs
- SymbolType.cs