163 references to GetValueOrDefault
System.Windows.Forms (163)
System\Windows\Forms\Control.cs (39)
461return Properties.GetValueOrDefault( 482return Properties.GetValueOrDefault( 582get => Properties.GetValueOrDefault<string>(s_accessibleDefaultActionProperty); 595get => Properties.GetValueOrDefault<string>(s_accessibleDescriptionProperty); 608get => Properties.GetValueOrDefault<string>(s_accessibleNameProperty); 620get => Properties.GetValueOrDefault(s_accessibleRoleProperty, AccessibleRole.Default); 758get => Properties.GetValueOrDefault(s_autoScrollOffsetProperty, Point.Empty); 883get => Properties.GetValueOrDefault( 1114get => Properties.GetValueOrDefault<Image>(s_backgroundImageProperty); 1144get => Properties.GetValueOrDefault(s_backgroundImageLayoutProperty, ImageLayout.Tile); 1204Properties.GetValueOrDefault<ControlBindingsCollection>(s_bindingsProperty)?.Clear(); 1385int cacheTextCounter = Properties.GetValueOrDefault<int>(s_cacheTextCountProperty); 1398int cacheTextCounter = Properties.GetValueOrDefault<int>(s_cacheTextCountProperty); 1415_text = Properties.GetValueOrDefault<string?>(s_cacheTextFieldProperty); 1505get => Properties.GetValueOrDefault<ContextMenuStrip>(s_contextMenuStripProperty); 1748Cursor? localCursor = Properties.GetValueOrDefault<Cursor>(s_cursorProperty); 2079Font? previous = Properties.GetValueOrDefault<Font>(s_fontProperty); 2207fontHandle = Properties.GetValueOrDefault<FontHandleWrapper?>(s_fontHandleWrapperProperty); 2862string? name = Properties.GetValueOrDefault<string>(s_namePropertyProperty); 2932internal Color RawBackColor => Properties.GetValueOrDefault<Color>(s_backColorProperty); 2982get => Properties.GetValueOrDefault<Region>(s_regionProperty); 3376get => Properties.GetValueOrDefault<object>(s_userDataProperty); 4593int updateCount = Properties.GetValueOrDefault(s_updateCountProperty, 0); 5030Properties?.GetValueOrDefault<ActiveXImpl>(s_activeXImplProperty)?.Dispose(); 5288int updateCount = Properties.GetValueOrDefault(s_updateCountProperty, 0); 5576=> Properties.GetValueOrDefault(s_updateCountProperty, 0) > 0; 7169int changeVersion = Properties.GetValueOrDefault(s_visualStylesModeChangeVersionProperty, 0) + 1; 7367Color backColor = Properties.GetValueOrDefault<Color>(s_backColorProperty); 7403if (Equals(Properties.GetValueOrDefault<object>(s_dataContextProperty), Parent?.DataContext)) 7451if (Properties.GetValueOrDefault<VisualStylesMode>(s_visualStylesModeProperty) 7530=> _state.Source.Properties.GetValueOrDefault(s_visualStylesModeChangeVersionProperty, 0) 7532&& Control.Properties.GetValueOrDefault(s_visualStylesModeChangeVersionProperty, 0) 7545control.Properties.GetValueOrDefault(s_visualStylesModeChangeVersionProperty, 0), 7722Color foreColor = Properties.GetValueOrDefault<Color>(s_foreColorProperty); 8771int changeVersion = Properties.GetValueOrDefault(s_visualStylesModeChangeVersionProperty, 0) + 1; 8804|| Properties.GetValueOrDefault<bool>(s_systemVisualSettingsRefreshPendingProperty)) 8823SystemVisualSettings? oldSettings = Properties.GetValueOrDefault<SystemVisualSettings>(s_systemVisualSettingsProperty); 11303Color backColor = Properties.GetValueOrDefault<Color>(s_backColorProperty); 11323internal virtual bool ShouldSerializeForeColor() => !Properties.GetValueOrDefault<Color>(s_foreColorProperty).IsEmpty;
System\Windows\Forms\Control.Ime.cs (3)
110int val = Properties.GetValueOrDefault<int>(s_disableImeModeChangedCountProperty); 231get => Properties.GetValueOrDefault<int>(s_imeWmCharsToIgnoreProperty); 250get => Properties.GetValueOrDefault(s_lastCanEnableImeProperty, true);
System\Windows\Forms\Control.SuspendMutation.cs (4)
60=> Properties.GetValueOrDefault(s_suspendPaintingCountProperty, 0); 67int suspendPaintingCount = Properties.GetValueOrDefault( 81int suspendPaintingCount = Properties.GetValueOrDefault( 119if (Properties.GetValueOrDefault(s_suspendPaintingCountProperty, 0) != 0
System\Windows\Forms\Controls\ComboBox\ComboBox.cs (6)
429get => Properties.GetValueOrDefault(s_propDrawMode, DrawMode.Normal); 458if (Properties.GetValueOrDefault<int>(s_propDropDownWidth) != value) 488if (Properties.GetValueOrDefault<int>(s_propDropDownHeight) != value) 647if (Properties.GetValueOrDefault<int>(s_propItemHeight) != value) 732return Properties.GetValueOrDefault<int>(s_propMaxLength); 1121get => Properties.GetValueOrDefault(s_propStyle, ComboBoxStyle.DropDown);
System\Windows\Forms\Controls\DataGridView\DataGridViewBand.cs (4)
58get => Properties.GetValueOrDefault<ContextMenuStrip>(s_propContextMenuStrip); 165get => Properties.GetValueOrDefault<int>(s_propDividerThickness); 254DataGridViewHeaderCell? priorValue = Properties.GetValueOrDefault<DataGridViewHeaderCell?>(s_propHeaderCell); 588get => Properties.GetValueOrDefault<object?>(s_propUserData);
System\Windows\Forms\Controls\DataGridView\DataGridViewButtonCell.cs (3)
40get => Properties.GetValueOrDefault(s_propButtonCellState, ButtonState.Normal); 60get => Properties.GetValueOrDefault(s_propButtonCellFlatStyle, FlatStyle.Standard); 91get => Properties.GetValueOrDefault<bool>(s_propButtonCellUseColumnTextForButtonValue);
System\Windows\Forms\Controls\DataGridView\DataGridViewCell.cs (5)
116get => Properties.GetValueOrDefault<ContextMenuStrip>(s_propCellContextMenuStrip); 650get => Properties.GetValueOrDefault<object?>(s_propCellTag); 1531string? objErrorText = Properties.GetValueOrDefault<string>(s_propCellErrorText); 2421return Properties.GetValueOrDefault<object>(s_propCellValue); 2432return Properties.GetValueOrDefault<object>(s_propCellValue);
System\Windows\Forms\Controls\DataGridView\DataGridViewCellStyle.cs (9)
69get => Properties.GetValueOrDefault(s_propAlignment, DataGridViewContentAlignment.NotSet); 109get => Properties.GetValueOrDefault<Color>(s_propBackColor); 145get => Properties.GetValueOrDefault<Font>(s_propFont); 193get => Properties.GetValueOrDefault<IFormatProvider>(s_propFormatProvider) ?? Globalization.CultureInfo.CurrentCulture; 263get => Properties.GetValueOrDefault<Padding>(s_propPadding); 309get => Properties.GetValueOrDefault<Color>(s_propSelectionBackColor); 323get => Properties.GetValueOrDefault<Color>(s_propSelectionForeColor); 338get => Properties.GetValueOrDefault<object?>(s_propTag); 346get => Properties.GetValueOrDefault(s_propWrapMode, DataGridViewTriState.NotSet);
System\Windows\Forms\Controls\DataGridView\DataGridViewCheckBoxCell.cs (5)
182get => Properties.GetValueOrDefault(s_propButtonCellState, ButtonState.Normal); 209get => Properties.GetValueOrDefault<object?>(s_propFalseValue); 235get => Properties.GetValueOrDefault(s_propFlatStyle, FlatStyle.Standard); 264get => Properties.GetValueOrDefault<object?>(s_propIndeterminateValue); 362get => Properties.GetValueOrDefault<object?>(s_propTrueValue);
System\Windows\Forms\Controls\DataGridView\DataGridViewColumn.cs (1)
791get => Properties.GetValueOrDefault<Type>(s_propDataGridViewColumnValueType);
System\Windows\Forms\Controls\DataGridView\DataGridViewComboBoxCell.cs (11)
132get => Properties.GetValueOrDefault<object>(s_propComboBoxCellDataSource); 226get => Properties.GetValueOrDefault<PropertyDescriptor?>(s_propComboBoxCellDisplayMemberProp); 233get => Properties.GetValueOrDefault(s_propComboBoxCellDisplayStyle, DataGridViewComboBoxDisplayStyle.DropDownButton); 269get => Properties.GetValueOrDefault<bool>(s_propComboBoxCellDisplayStyleForCurrentCellOnly); 318get => Properties.GetValueOrDefault(s_propComboBoxCellDropDownWidth, 1); 336get => Properties.GetValueOrDefault<DataGridViewComboBoxEditingControl?>(s_propComboBoxCellEditingComboBox); 346get => Properties.GetValueOrDefault(s_propComboBoxCellFlatStyle, FlatStyle.Standard); 378get => Properties.GetValueOrDefault(s_propComboBoxCellMaxDropDownItems, DefaultMaxDropDownItems); 447get => Properties.GetValueOrDefault<DataGridViewComboBoxColumn>(s_propComboBoxCellColumnTemplate); 482get => Properties.GetValueOrDefault<PropertyDescriptor?>(s_propComboBoxCellValueMemberProp); 792CurrencyManager? cm = Properties.GetValueOrDefault<CurrencyManager?>(s_propComboBoxCellDataManager);
System\Windows\Forms\Controls\DataGridView\DataGridViewHeaderCell.cs (4)
31get => Properties.GetValueOrDefault(s_propButtonState, ButtonState.Normal); 80get => Properties.GetValueOrDefault<Bitmap?>(s_propFlipXPThemesBitmap); 157get => Properties.GetValueOrDefault<Type?>(s_propValueType, s_defaultValueType); 425return Properties.GetValueOrDefault<object>(s_propCellValue);
System\Windows\Forms\Controls\DataGridView\DataGridViewImageCell.cs (1)
98get => Properties.GetValueOrDefault(s_propImageCellLayout, DataGridViewImageCellLayout.Normal);
System\Windows\Forms\Controls\DataGridView\DataGridViewLinkCell.cs (4)
117get => Properties.GetValueOrDefault(s_propLinkCellLinkBehavior, LinkBehavior.SystemDefault); 206get => Properties.GetValueOrDefault(s_propLinkCellLinkState, LinkState.Normal); 241get => Properties.GetValueOrDefault(s_propLinkCellTrackVisitedState, true); 272get => Properties.GetValueOrDefault<bool>(s_propLinkCellUseColumnTextForLinkValue);
System\Windows\Forms\Controls\DataGridView\DataGridViewRowHeaderCell.cs (1)
570return Properties.GetValueOrDefault<object?>(s_propCellValue);
System\Windows\Forms\Controls\DataGridView\DataGridViewTextBoxCell.cs (2)
51get => Properties.GetValueOrDefault<DataGridViewTextBoxEditingControl?>(s_propTextBoxCellEditingTextBox); 67get => Properties.GetValueOrDefault(s_propTextBoxCellMaxInputLength, MaxInputLengthDefault);
System\Windows\Forms\Controls\Labels\Label.cs (4)
370Image? image = Properties.GetValueOrDefault<Image>(s_propImage); 505get => Properties.GetValueOrDefault<ImageList>(s_propImageList); 550get => Properties.GetValueOrDefault(s_propImageAlign, ContentAlignment.MiddleCenter); 694get => Properties.GetValueOrDefault(s_propTextAlign, ContentAlignment.TopLeft);
System\Windows\Forms\Controls\ToolStrips\ToolStrip.cs (1)
1687ToolStripTextDirection textDirection = Properties.GetValueOrDefault(s_propTextDirection, ToolStripTextDirection.Horizontal);
System\Windows\Forms\Controls\ToolStrips\ToolStripDropDown.cs (2)
568get => Properties.GetValueOrDefault(s_propOpacity, 1.0d); 753get => Properties.GetValueOrDefault<Control>(s_propSourceControl);
System\Windows\Forms\Controls\ToolStrips\ToolStripItem.cs (22)
214get => Properties.GetValueOrDefault<string>(s_accessibleDefaultActionDescriptionProperty); 231get => Properties.GetValueOrDefault<string>(s_accessibleDescriptionProperty); 248get => Properties.GetValueOrDefault<string>(s_accessibleNameProperty); 264get => Properties.GetValueOrDefault(s_accessibleRoleProperty, AccessibleRole.Default); 390get => Properties.GetValueOrDefault<Image>(s_backgroundImageProperty); 494get => Properties.GetValueOrDefault(s_backgroundImageLayoutProperty, ImageLayout.Tile); 868Color foreColor = Properties.GetValueOrDefault<Color>(s_foreColorProperty); 1030Image? image = Properties.GetValueOrDefault<Image>(s_imageProperty); 1201Color color = Properties.GetValueOrDefault<Color>(s_foreColorProperty); 1289get => Properties.GetValueOrDefault(s_mergeActionProperty, MergeAction.Append); 1305get => Properties.GetValueOrDefault(s_mergeIndexProperty, -1); 1391get => WindowsFormsUtils.GetComponentName(this, Properties.GetValueOrDefault<string>(s_nameProperty)); 1561Image? image = Properties.GetValueOrDefault<Image>(s_imageProperty); 1614internal Color RawBackColor => Properties.GetValueOrDefault(s_backColorProperty, Color.Empty); 1730return Properties.GetValueOrDefault<Image>(s_mirroredImageProperty); 1850get => Properties.GetValueOrDefault<object>(s_tagProperty); 1909ToolStripTextDirection textDirection = Properties.GetValueOrDefault(s_textDirectionProperty, ToolStripTextDirection.Inherit); 2888Color backColor = Properties.GetValueOrDefault<Color>(s_backColorProperty); 2936Color foreColor = Properties.GetValueOrDefault<Color>(s_foreColorProperty); 2977ToolStripTextDirection textDirection = Properties.GetValueOrDefault(s_textDirectionProperty, ToolStripTextDirection.Inherit); 3287Color backColor = Properties.GetValueOrDefault<Color>(s_backColorProperty); 3301Color foreColor = Properties.GetValueOrDefault<Color>(s_foreColorProperty);
System\Windows\Forms\Controls\ToolStrips\ToolStripMenuItem.cs (3)
302get => Properties.GetValueOrDefault(s_propCheckState, CheckState.Unchecked); 359get => Properties.GetValueOrDefault(s_propShortcutKeys, Keys.None); 480internal Form? MdiForm => Properties.GetValueOrDefault<Form>(s_propMdiForm);
System\Windows\Forms\Controls\TreeView\TreeView.cs (1)
831get => Properties.GetValueOrDefault(s_nodeLeadingProperty, 0.0f);
System\Windows\Forms\Form.cs (23)
221get => Properties.GetValueOrDefault<IButtonControl?>(s_propAcceptButton); 336get => Properties.GetValueOrDefault<Form>(s_propActiveMdiChild); 344get => Properties.GetValueOrDefault<Form>(s_propFormerlyActiveMdiChild); 713get => Properties.GetValueOrDefault<IButtonControl>(s_propCancelButton); 803Form? formMdiParent = Properties.GetValueOrDefault<Form>(s_propFormMdiParent); 1076get => Properties.GetValueOrDefault<bool>(s_propMdiChildFocusable); 1158get => Properties.GetValueOrDefault<Rectangle>(s_propMaximizedBounds); 1260get => Properties.GetValueOrDefault<MenuStrip>(s_propMainMenuStrip); 1452get => Properties.GetValueOrDefault<Form>(s_propFormMdiParent); 1455Form? formMdiParent = Properties.GetValueOrDefault<Form>(s_propFormMdiParent); 1524get => Properties.GetValueOrDefault<MdiWindowListStrip>(s_propMdiWindowListStrip); 1530get => Properties.GetValueOrDefault<MdiControlStrip>(s_propMdiControlStrip); 1569get => Properties.GetValueOrDefault(s_propOpacity, 1.0d); 1656internal Form? OwnerInternal => Properties.GetValueOrDefault<Form?>(s_propOwner); 1761get => Properties.GetValueOrDefault(s_propFormScreenCaptureMode, ScreenCaptureMode.Allow); 2086get => Properties.GetValueOrDefault(s_propTransparencyKey, Color.Empty); 2268get => Properties.GetValueOrDefault(s_propFormCornerPreference, FormCornerPreference.Default); 2356get => Properties.GetValueOrDefault(s_propFormBorderColor, Color.Empty); 2416get => Properties.GetValueOrDefault(s_propFormCaptionBackColor, Color.Empty); 2477get => Properties.GetValueOrDefault(s_propFormCaptionTextColor, Color.Empty); 3348Form? form = Properties.GetValueOrDefault<Form>(s_propFormMdiParent); 3712IWin32Window? dialogOwner = Properties.GetValueOrDefault<IWin32Window>(s_propDialogOwner); 5355IButtonControl? existing = Properties.GetValueOrDefault<IButtonControl>(s_propDefaultButton);
System\Windows\Forms\Form.RevealMode.cs (1)
103get => Properties.GetValueOrDefault(s_propFormAppearanceCloaked, false);
System\Windows\Forms\Layout\CommonProperties.cs (1)
723element.Properties.GetValueOrDefault<BitVector32>(s_layoutStateProperty);
System\Windows\Forms\Layout\Containers\ContainerControl.cs (1)
571private void AxContainerFormCreated() => Properties.GetValueOrDefault<AxHost.AxContainer>(s_propAxContainer)?.FormCreated();
System\Windows\Forms\Layout\DefaultLayout.cs (1)
1093element.Properties.GetValueOrDefault<AnchorInfo>(s_layoutInfoProperty);
System\Windows\Forms\Layout\FlowLayout.cs (1)
293container.Properties.GetValueOrDefault<FlowDirection>(s_flowDirectionProperty);