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
- MetadataItemSerializer.cs
- BitStack.cs
- HasCopySemanticsAttribute.cs
- XamlPointCollectionSerializer.cs
- AssemblyBuilderData.cs
- InternalConfigSettingsFactory.cs
- DictionaryTraceRecord.cs
- XpsFixedDocumentReaderWriter.cs
- Underline.cs
- ProxyWebPartConnectionCollection.cs
- IdnElement.cs
- ActiveDocumentEvent.cs
- XmlValidatingReaderImpl.cs
- ListItemConverter.cs
- DataGridViewButtonColumn.cs
- AdPostCacheSubstitution.cs
- XmlUtf8RawTextWriter.cs
- XmlILModule.cs
- CustomAttributeFormatException.cs
- glyphs.cs
- PageTheme.cs
- CoreSwitches.cs
- TextParagraphView.cs
- DataSourceHelper.cs
- IdentifierCollection.cs
- LocalizabilityAttribute.cs
- TransformerConfigurationWizardBase.cs
- _ContextAwareResult.cs
- X500Name.cs
- CommonRemoteMemoryBlock.cs
- Merger.cs
- HTMLTextWriter.cs
- XmlRawWriter.cs
- NavigateUrlConverter.cs
- LineProperties.cs
- EntityClassGenerator.cs
- DataAccessException.cs
- _LoggingObject.cs
- OrderedDictionary.cs
- HtmlValidatorAdapter.cs
- DateTimeSerializationSection.cs
- DataRowChangeEvent.cs
- ContentPosition.cs
- WebPartDisplayModeCollection.cs
- ClipboardProcessor.cs
- CodeNamespaceCollection.cs
- StyleTypedPropertyAttribute.cs
- VirtualPathProvider.cs
- ConnectionPointCookie.cs
- Visual3DCollection.cs
- NameValuePair.cs
- Parser.cs
- HostVisual.cs
- BaseParagraph.cs
- KeyTimeConverter.cs
- ContainerControl.cs
- WFItemsToSpacerVisibility.cs
- XmlSchemaSimpleContent.cs
- MessageBox.cs
- FamilyCollection.cs
- ListBoxItemWrapperAutomationPeer.cs
- XmlAtomicValue.cs
- sqlinternaltransaction.cs
- ConnectionManagementElementCollection.cs
- DuplicateWaitObjectException.cs
- DataGridViewBindingCompleteEventArgs.cs
- GridErrorDlg.cs
- HtmlString.cs
- SelectionRange.cs
- SessionStateUtil.cs
- WebPartsPersonalization.cs
- ExceptionUtil.cs
- FamilyMapCollection.cs
- FilterElement.cs
- CriticalHandle.cs
- AppDomainFactory.cs
- SystemWebSectionGroup.cs
- recordstatefactory.cs
- XmlSchemaGroup.cs
- PerformanceCounterManager.cs
- ListParagraph.cs
- OutputCacheProfile.cs
- WorkflowInlining.cs
- StreamReader.cs
- DependencyPropertyConverter.cs
- XmlElementAttributes.cs
- InternalCache.cs
- MetabaseServerConfig.cs
- KoreanLunisolarCalendar.cs
- UnionCodeGroup.cs
- SecurityUtils.cs
- wmiprovider.cs
- BufferedOutputStream.cs
- Currency.cs
- DataGridHyperlinkColumn.cs
- DataContractJsonSerializerOperationFormatter.cs
- PointHitTestResult.cs
- XmlExtensionFunction.cs
- GPStream.cs
- ZipIOCentralDirectoryFileHeader.cs