]> O.S.I.I.S - jp/crow.git/commitdiff
restore lock in Visible prop of GO
authorJean-Philippe Bruyère <jp_bruyere@hotmail.com>
Wed, 1 Mar 2017 06:00:56 +0000 (07:00 +0100)
committerJean-Philippe Bruyère <jp_bruyere@hotmail.com>
Wed, 1 Mar 2017 06:01:45 +0000 (07:01 +0100)
Tests/Interfaces/Divers/0.crow
src/GraphicObjects/GraphicObject.cs

index 480dde3b3676cbc713b86c6a3a0064aec68de484..15ab65f44aec531c950c56163ed8a7aff23cf4af 100755 (executable)
                </VerticalStack>
                <Splitter/>
                <VerticalStack Width="30%" Margin="5">
-                       <Border Margin="5" Height="Fit">
+<!--                   <Border Margin="5" Height="Fit">
                                <Label Width="Stretched" Margin="1" Text="{../../dv.SelectedItem}"/>
-                       </Border>
-                       <Border Margin="5" Height="30%">
+                       </Border>-->
+<!--                   <Border Margin="5" Height="30%">
                                <DirectoryView Name="dv" CurrentDirectory="/" Margin="1"/>
                        </Border>
-                       <Splitter/>
+                       <Splitter/>-->
                        <ListBox Name="colorList" Data="{TestList}" Margin="5"
                                         ItemTemplate="#Tests.Interfaces.colorItem.crow"
                                         Template="#Crow.Templates.ScrollingListBox.goml"
index 059fc568deffde69a6126a5f815fd032e61844a7..22bfdea29ae02fd3555260a524a0c693369afffa 100644 (file)
@@ -516,13 +516,15 @@ namespace Crow
                                if (isVisible)
                                        RegisterForLayouting (LayoutingType.Sizing);
                                else {
-                                       Slot.Width = 0;
-                                       LayoutChanged.Raise (this, new LayoutingEventArgs (LayoutingType.Width));
-                                       Slot.Height = 0;
-                                       LayoutChanged.Raise (this, new LayoutingEventArgs (LayoutingType.Height));
-                                       if (this.parent != null)
-                                               CurrentInterface.EnqueueForRepaint (this);
-                                       LastSlots.Width = LastSlots.Height = 0;
+                                       lock (CurrentInterface.UpdateMutex) {
+                                               Slot.Width = 0;
+                                               LayoutChanged.Raise (this, new LayoutingEventArgs (LayoutingType.Width));
+                                               Slot.Height = 0;
+                                               LayoutChanged.Raise (this, new LayoutingEventArgs (LayoutingType.Height));
+                                               if (this.parent != null)
+                                                       CurrentInterface.EnqueueForRepaint (this);
+                                               LastSlots.Width = LastSlots.Height = 0;
+                                       }
                                }
 
                                //trigger a mouse to handle possible hover changes