dotgnu-pnet-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Dotgnu-pnet-commits] pnetlib/System.Drawing.Xsharp DrawingPopupWindow.c


From: Rhys Weatherley <address@hidden>
Subject: [Dotgnu-pnet-commits] pnetlib/System.Drawing.Xsharp DrawingPopupWindow.cs, 1.5, 1.6 DrawingToolkit.cs, 1.21, 1.22 DrawingTopLevelWindow.cs, 1.14, 1.15 DrawingWindow.cs, 1.17, 1.18
Date: Mon, 01 Dec 2003 00:23:30 +0000

Update of /cvsroot/dotgnu-pnet/pnetlib/System.Drawing.Xsharp
In directory subversions:/tmp/cvs-serv6883/System.Drawing.Xsharp

Modified Files:
        DrawingPopupWindow.cs DrawingToolkit.cs 
        DrawingTopLevelWindow.cs DrawingWindow.cs 
Log Message:


Add the "IToolkitTopLevelWindow" interface to encapsulate top-level
window operations; implement some more top-level window operations in "Form".


Index: DrawingWindow.cs
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnetlib/System.Drawing.Xsharp/DrawingWindow.cs,v
retrieving revision 1.17
retrieving revision 1.18
diff -C2 -d -r1.17 -r1.18
*** DrawingWindow.cs    2 Nov 2003 22:22:07 -0000       1.17
--- DrawingWindow.cs    1 Dec 2003 00:23:28 -0000       1.18
***************
*** 144,153 ****
                        }
  
-       // Iconify the window.
-       void IToolkitWindow.Iconify()
-                       {
-                               // Not used for ordinary windows.
-                       }
- 
        // Reparent this window to underneath a new parent.
        void IToolkitWindow.Reparent(IToolkitWindow parent, int x, int y)
--- 144,147 ----
***************
*** 170,179 ****
                        }
  
-       // Set the window title (top-level windows only).
-       void IToolkitWindow.SetTitle(String title)
-                       {
-                               // Not used for ordinary windows.
-                       }
- 
        // Set the foreground of the window to a solid color.
        void IToolkitWindow.SetForeground(System.Drawing.Color color)
--- 164,167 ----
***************
*** 186,195 ****
                        {
                                Background = 
DrawingToolkit.DrawingToXColor(color);
-                       }
- 
-       // Change the set of supported window decorations and functions.
-       void IToolkitWindow.SetWindowFlags(ToolkitWindowFlags flags)
-                       {
-                               // Not used for ordinary windows.
                        }
  
--- 174,177 ----

Index: DrawingToolkit.cs
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnetlib/System.Drawing.Xsharp/DrawingToolkit.cs,v
retrieving revision 1.21
retrieving revision 1.22
diff -C2 -d -r1.21 -r1.22
*** DrawingToolkit.cs   30 Nov 2003 05:50:40 -0000      1.21
--- DrawingToolkit.cs   1 Dec 2003 00:23:28 -0000       1.22
***************
*** 361,365 ****
  
        // Create a top-level application window.
!       public IToolkitWindow CreateTopLevelWindow(int width, int height, 
IToolkitEventSink sink)
                        {
                                ValidateWindowSize(ref width, ref height);
--- 361,366 ----
  
        // Create a top-level application window.
!       public IToolkitTopLevelWindow CreateTopLevelWindow
!                               (int width, int height, IToolkitEventSink sink)
                        {
                                ValidateWindowSize(ref width, ref height);

Index: DrawingTopLevelWindow.cs
===================================================================
RCS file: 
/cvsroot/dotgnu-pnet/pnetlib/System.Drawing.Xsharp/DrawingTopLevelWindow.cs,v
retrieving revision 1.14
retrieving revision 1.15
diff -C2 -d -r1.14 -r1.15
*** DrawingTopLevelWindow.cs    25 Aug 2003 16:09:12 -0000      1.14
--- DrawingTopLevelWindow.cs    1 Dec 2003 00:23:28 -0000       1.15
***************
*** 28,32 ****
  using Xsharp;
  
! internal sealed class DrawingTopLevelWindow : TopLevelWindow, IToolkitWindow
  {
        // Internal state.
--- 28,33 ----
  using Xsharp;
  
! internal sealed class DrawingTopLevelWindow
!       : TopLevelWindow, IToolkitTopLevelWindow
  {
        // Internal state.
***************
*** 143,152 ****
                        }
  
-       // Iconify the window.
-       void IToolkitWindow.Iconify()
-                       {
-                               Iconify();
-                       }
- 
        // Reparent this window to underneath a new parent.
        void IToolkitWindow.Reparent(IToolkitWindow parent, int x, int y)
--- 144,147 ----
***************
*** 169,182 ****
                        }
  
-       // Set the window title (top-level windows only).
-       void IToolkitWindow.SetTitle(String title)
-                       {
-                               if(title == null)
-                               {
-                                       title = String.Empty;
-                               }
-                               Name = title;
-                       }
- 
        // Set the foreground of the window to a solid color.
        void IToolkitWindow.SetForeground(System.Drawing.Color color)
--- 164,167 ----
***************
*** 191,196 ****
                        }
  
        // Change the set of supported window decorations and functions.
!       void IToolkitWindow.SetWindowFlags(ToolkitWindowFlags flags)
                        {
                                // Set the default Motif decoration flags.
--- 176,271 ----
                        }
  
+       // Move this window to above one of its siblings.
+       void IToolkitWindow.MoveToAbove(IToolkitWindow sibling)
+                       {
+                               // TODO
+                       }
+ 
+       // Move this window to below one of its siblings.
+       void IToolkitWindow.MoveToBelow(IToolkitWindow sibling)
+                       {
+                               // TODO
+                       }
+ 
+       // Get the HWND for this window.  IntPtr.Zero if not supported.
+       IntPtr IToolkitWindow.GetHwnd()
+                       {
+                               return IntPtr.Zero;
+                       }
+ 
+       // Invalidate this window.
+       void IToolkitWindow.Invalidate()
+                       {
+                               Repaint();
+                       }
+ 
+       // Invalidate a rectangle within this window.
+       void IToolkitWindow.Invalidate(int x, int y, int width, int height)
+                       {
+                               DrawingToolkit.ValidateWindowPosition(ref x, 
ref y);
+                               DrawingToolkit.ValidateWindowSize(ref width, 
ref height);
+                               Repaint(x, y, width, height);
+                       }
+ 
+       // Force an update of all invalidated regions.
+       void IToolkitWindow.Update()
+                       {
+                               Display.Flush();
+                       }
+ 
+       // Iconify the window.
+       void IToolkitTopLevelWindow.Iconify()
+                       {
+                               Iconify();
+                       }
+ 
+       // Maximize the window.
+       void IToolkitTopLevelWindow.Maximize()
+                       {
+                               // TODO
+                       }
+ 
+       // Restore the window from its iconified or maximized state.
+       void IToolkitTopLevelWindow.Restore()
+                       {
+                               // TODO
+                       }
+ 
+       // Set the owner for modal and modeless dialog support.
+       void IToolkitTopLevelWindow.SetDialogOwner(IToolkitTopLevelWindow owner)
+                       {
+                               // TODO
+                       }
+ 
+       // Set this window's icon.
+       void IToolkitTopLevelWindow.SetIcon(Icon icon)
+                       {
+                               // TODO
+                       }
+ 
+       // Set this window's maximum size.
+       void IToolkitTopLevelWindow.SetMaximumSize(Size size)
+                       {
+                               // TODO
+                       }
+ 
+       // Set this window's minimum size.
+       void IToolkitTopLevelWindow.SetMinimumSize(Size size)
+                       {
+                               // TODO
+                       }
+ 
+       // Set the window title (top-level windows only).
+       void IToolkitTopLevelWindow.SetTitle(String title)
+                       {
+                               if(title == null)
+                               {
+                                       title = String.Empty;
+                               }
+                               Name = title;
+                       }
+ 
        // Change the set of supported window decorations and functions.
!       void IToolkitTopLevelWindow.SetWindowFlags(ToolkitWindowFlags flags)
                        {
                                // Set the default Motif decoration flags.
***************
*** 245,286 ****
                                Functions = functions;
                                InputType = inputType;
-                       }
- 
-       // Move this window to above one of its siblings.
-       void IToolkitWindow.MoveToAbove(IToolkitWindow sibling)
-                       {
-                               // TODO
-                       }
- 
-       // Move this window to below one of its siblings.
-       void IToolkitWindow.MoveToBelow(IToolkitWindow sibling)
-                       {
-                               // TODO
-                       }
- 
-       // Get the HWND for this window.  IntPtr.Zero if not supported.
-       IntPtr IToolkitWindow.GetHwnd()
-                       {
-                               return IntPtr.Zero;
-                       }
- 
-       // Invalidate this window.
-       void IToolkitWindow.Invalidate()
-                       {
-                               Repaint();
-                       }
- 
-       // Invalidate a rectangle within this window.
-       void IToolkitWindow.Invalidate(int x, int y, int width, int height)
-                       {
-                               DrawingToolkit.ValidateWindowPosition(ref x, 
ref y);
-                               DrawingToolkit.ValidateWindowSize(ref width, 
ref height);
-                               Repaint(x, y, width, height);
-                       }
- 
-       // Force an update of all invalidated regions.
-       void IToolkitWindow.Update()
-                       {
-                               Display.Flush();
                        }
  
--- 320,323 ----

Index: DrawingPopupWindow.cs
===================================================================
RCS file: 
/cvsroot/dotgnu-pnet/pnetlib/System.Drawing.Xsharp/DrawingPopupWindow.cs,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** DrawingPopupWindow.cs       25 Aug 2003 16:09:12 -0000      1.5
--- DrawingPopupWindow.cs       1 Dec 2003 00:23:27 -0000       1.6
***************
*** 144,153 ****
                        }
  
-       // Iconify the window.
-       void IToolkitWindow.Iconify()
-                       {
-                               // Not used for ordinary windows.
-                       }
- 
        // Reparent this window to underneath a new parent.
        void IToolkitWindow.Reparent(IToolkitWindow parent, int x, int y)
--- 144,147 ----
***************
*** 170,179 ****
                        }
  
-       // Set the window title (top-level windows only).
-       void IToolkitWindow.SetTitle(String title)
-                       {
-                               // Not used for ordinary windows.
-                       }
- 
        // Set the foreground of the window to a solid color.
        void IToolkitWindow.SetForeground(System.Drawing.Color color)
--- 164,167 ----
***************
*** 186,195 ****
                        {
                                Background = 
DrawingToolkit.DrawingToXColor(color);
-                       }
- 
-       // Change the set of supported window decorations and functions.
-       void IToolkitWindow.SetWindowFlags(ToolkitWindowFlags flags)
-                       {
-                               // Not used for ordinary windows.
                        }
  
--- 174,177 ----





reply via email to

[Prev in Thread] Current Thread [Next in Thread]