]> O.S.I.I.S - jp/crow.git/commitdiff
divers
authorJean-Philippe Bruyère <jp_bruyere@hotmail.com>
Tue, 4 Dec 2018 23:37:10 +0000 (00:37 +0100)
committerJean-Philippe Bruyère <jp_bruyere@hotmail.com>
Tue, 4 Dec 2018 23:37:10 +0000 (00:37 +0100)
.gitignore
Crow.csproj
Crow.sln
Properties/AssemblyInfo.cs
Templates/DockWindow.template
src/Gradient.cs
src/GraphicObjects/PrivateContainer.cs
src/Interface.cs
src/backends/xlib/XLibBackend.cs

index 477bac00d42662293e5d08f2eee80dc176b4657d..2f5de09419096635b261822890ace4d99b88b8fa 100644 (file)
@@ -4,6 +4,7 @@ Crow.userprefs
 Debug
 packages
 *.nupkg
+*.user
 /GOLib.suo
 /tmp
 /bin/*
index 0afb1db900e6b5fa566f8d405fa2333f94f3eee7..f181f154f47edb312f667da028c15f1e00a6560a 100644 (file)
@@ -32,7 +32,7 @@
     <CheckForOverflowUnderflow>true</CheckForOverflowUnderflow>
     <Optimize>false</Optimize>
     <OutputPath>$(SolutionDir)build\Debug</OutputPath>
-    <DefineConstants>DEBUG_DRAGNDROP0;DEBUG_LOG0;XLIB_BACKEND0;DESIGN_MODE;DEBUG_UPDATE0;DEBUG_FOCUS0;DEBUG_DISPOSE0;TRACE0;DEBUG;MEASURE_TIME;DEBUG_LOAD0;DEBUG_BINDING0;DEBUG_CLIP_RECTANGLE0</DefineConstants>
+    <DefineConstants>DEBUG_DRAGNDROP0;DEBUG_LOG;XLIB_BACKEND0;DESIGN_MODE;DEBUG_UPDATE0;DEBUG_FOCUS0;DEBUG_DISPOSE0;TRACE0;DEBUG;MEASURE_TIME;DEBUG_LOAD0;DEBUG_BINDING0;DEBUG_CLIP_RECTANGLE0</DefineConstants>
     <EnvironmentVariables>
       <EnvironmentVariables>
         <Variable name="MONO_CAIRO_DEBUG_DISPOSE" value="1" />
     <Compile Include="src\backends\xlib\X11Keyboard.cs" />
     <Compile Include="src\backends\xlib\XLibBackend.cs" />
     <Compile Include="src\debug\DbgLogViewer.cs" />
+    <Compile Include="src\debug\DbgEventTypeColors.cs" />
   </ItemGroup>
   <ItemGroup>
     <Reference Include="System" />
index 64088c26bd22d2c419b8688d7a611c046a0aee49..dc694b6b8f838a325aa791327d9bc651fe8a5e48 100644 (file)
--- a/Crow.sln
+++ b/Crow.sln
@@ -18,6 +18,7 @@ Global
                {74289092-9F70-4941-AFCB-DFD7BE2140B6}.Release|Any CPU.ActiveCfg = Release|Any CPU
                {74289092-9F70-4941-AFCB-DFD7BE2140B6}.Release|Any CPU.Build.0 = Release|Any CPU
                {B6D911CD-1D09-42FC-B300-9187190F2AE1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+               {B6D911CD-1D09-42FC-B300-9187190F2AE1}.Debug|Any CPU.Build.0 = Debug|Any CPU
                {B6D911CD-1D09-42FC-B300-9187190F2AE1}.Release|Any CPU.ActiveCfg = Release|Any CPU
                {B6D911CD-1D09-42FC-B300-9187190F2AE1}.Release|Any CPU.Build.0 = Release|Any CPU
                {C2980F9B-4798-4C05-99E2-E174810F7C7B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
index 3e2b7331631a39184284bd0c327e690581dbd708..a799c754857b1154d65d11f3ec21ee21a2d57194 100755 (executable)
@@ -49,5 +49,5 @@ using System.Runtime.CompilerServices;
 // if desired. See the Mono documentation for more information about signing.
 
 //[assembly: AssemblyDelaySign(false)]
-[assembly: AssemblyKeyFile("crow.key")]
+//[assembly: AssemblyKeyFile("crow.key")]
 
index f407502ae1db0328d9279e1477a491faedc1cf8a..b293e536184f113292c600201dbc31de0375968a 100755 (executable)
@@ -5,11 +5,14 @@
                                MouseEnter="./onBorderMouseEnter"
                                MouseLeave="./onBorderMouseLeave">
        <VerticalStack Spacing="0">
-               <HorizontalStack Visible="{./IsDocked}" Height="Fit" Margin="1" Background="Grey">
+               <HorizontalStack Visible="{./IsDocked}" Height="Fit" Margin="0" Background="Black">
                        <Label  Text="{./Caption}" TextAlignment="Left" Width="Stretched"
-                                        Foreground="Black" />
-                       <Image Width="10" Height="10" Focusable="true" Margin="0" Path="#Crow.Images.Icons.exit2.svg"
+                                        Foreground="White" />
+                       <Border CornerRadius="6" BorderWidth="1" Foreground="Transparent"  Height="10" Width="10"
+                               MouseEnter="{Foreground=White}" MouseLeave="{Foreground=Transparent}">
+                               <Image Focusable="true" Name="Image" Margin="0" Path="#Crow.Images.Icons.exit2.svg"
                                         MouseClick="./butQuitPress"/>
+                       </Border>
                </HorizontalStack>
                <HorizontalStack Background="vgradient|0:0.5,0.6,0.5,0.5|1:0.2,0.3,0.3,0.7"
                                Name="hs" Margin="0" Spacing="0" Height="Fit" Visible="{./IsFloating}">
@@ -23,6 +26,6 @@
                        </Border>
                        <GraphicObject Width="5"/>
                </HorizontalStack>
-               <Container Name="Content" MinimumSize="50,50"/>
+               <Container Name="Content" MinimumSize="50,50" Background="0.1,0.1,0.1,0.4"/>
        </VerticalStack>
 </Border>
index 0806e885b8aab9f24395cca6dbce0cffa709e7a3..2630c42a59dc00990c1b44068c27f6ed5d94d7c4 100644 (file)
@@ -96,8 +96,11 @@ namespace Crow
                                throw new NotImplementedException ();
                        }
 
-                       foreach (ColorStop cs in Stops)
+                       foreach (ColorStop cs in Stops) {
+                               if (cs == null)
+                                       continue;
                                grad.AddColorStop (cs.Offset, cs.Color);
+                       }
                        
                        ctx.SetSource (grad);
                        grad.Dispose ();
index 41918bc80b38e5adf2fd74e106d25149da40ca04..0f9b0c596eaa09ca92f27daba2bce2e1abf3bfcb 100644 (file)
@@ -51,7 +51,9 @@ namespace Crow
                        go = null;
                        if (base.FindByDesignID (designID, out go))
                                return true;
-                       return (bool)child?.FindByDesignID (designID, out go);                          
+                       if (child == null)
+                               return false;
+                       return child.FindByDesignID (designID, out go);                                 
                }
                #endif
                protected GraphicObject child;
index 3c586685af454eb69559e4856c58110ef7bc3f8c..f2d6a1ce9e3cd34a0c9167f31f336c2318f98bdd 100644 (file)
@@ -129,8 +129,8 @@ namespace Crow
                        Keyboard.KeyUp += Keyboard_KeyUp;
                        Keyboard.KeyPress += Keyboard_KeyPress;
 
-                       //initTooltip ();
-                       //initContextMenus ();
+                       initTooltip ();
+                       initContextMenus ();
 
                        running = true;
 
@@ -173,8 +173,7 @@ namespace Crow
                {                       
                        while (running) {
                                Update ();
-
-                               Thread.Sleep (1);
+                               Thread.Sleep (5);
                        }
                }
 
index 81500c03a3d85c485547858353257e3b777a061a..a123e2046f8877c878d26f32e375a0d3f5389d6b 100644 (file)
@@ -35,9 +35,9 @@ namespace Crow.XLib
                [DllImportAttribute("X11")]
                static extern int XInitThreads();
                [DllImportAttribute("X11")]
-               static extern IntPtr XOpenDisplay(IntPtr displayName);
+               internal static extern IntPtr XOpenDisplay(IntPtr displayName);
                [DllImportAttribute("X11")]
-               static extern IntPtr XCloseDisplay(IntPtr disp);
+               internal static extern IntPtr XCloseDisplay(IntPtr disp);
                [DllImportAttribute("X11")]
                static extern Int32 XDefaultScreen(IntPtr disp);
                [DllImportAttribute("X11")]