Index: src/DeltaShell/DeltaShell.Gui/Forms/PropertyGrid/PropertyGrid.cs =================================================================== diff -u -r4bf6fe9e8e7f044806697a836aef9c4dba1d6b70 -rc3c85cbf6ee8796f8c7aec00505945f8e611923d --- src/DeltaShell/DeltaShell.Gui/Forms/PropertyGrid/PropertyGrid.cs (.../PropertyGrid.cs) (revision 4bf6fe9e8e7f044806697a836aef9c4dba1d6b70) +++ src/DeltaShell/DeltaShell.Gui/Forms/PropertyGrid/PropertyGrid.cs (.../PropertyGrid.cs) (revision c3c85cbf6ee8796f8c7aec00505945f8e611923d) @@ -63,12 +63,8 @@ gui.SelectionChanged += GuiSelectionChanged; - // removing "property tabs" button and separator before it - var strip = propertyGrid1.Controls.OfType().ToList()[0] as ToolStrip; - strip.Items[3].Visible = false; - strip.Items[4].Visible = false; + HideTabsButton(); - // TODO: make timer start only when property was changed and then stop refreshTimer = new Timer(); refreshTimer.Tick += delegate { @@ -84,6 +80,14 @@ refreshTimer.Start(); } + private void HideTabsButton() + { + // removing "property tabs" button and separator before it + var strip = propertyGrid1.Controls.OfType().ToList()[0] as ToolStrip; + strip.Items[3].Visible = false; + strip.Items[4].Visible = false; + } + //from: http://stackoverflow.com/questions/7553423/c-sharp-propertygrid-check-if-a-value-is-currently-beeing-edited private static bool IsInEditMode(System.Windows.Forms.PropertyGrid grid) {