]> git.saurik.com Git - wxWidgets.git/commitdiff
Added $Id keyword, a bit of cleanup and also some backwards
authorRobin Dunn <robin@alldunn.com>
Wed, 2 Jun 2004 20:49:09 +0000 (20:49 +0000)
committerRobin Dunn <robin@alldunn.com>
Wed, 2 Jun 2004 20:49:09 +0000 (20:49 +0000)
compatibility aliases.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@27591 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

wxPython/wx/lib/ogl/basic.py
wxPython/wx/lib/ogl/bmpshape.py
wxPython/wx/lib/ogl/canvas.py
wxPython/wx/lib/ogl/composit.py
wxPython/wx/lib/ogl/diagram.py
wxPython/wx/lib/ogl/divided.py
wxPython/wx/lib/ogl/lines.py
wxPython/wx/lib/ogl/oglmisc.py

index 3aacb596d099694d7c72f71b618af5eabbcf35a4..43bdb7424835967ecead7ef26502193578690e61 100644 (file)
@@ -5,8 +5,8 @@
 #
 # Author:       Pierre Hjälm (from C++ original by Julian Smart)
 #
-# Created:      20040508
-# RCS-ID:       
+# Created:      2004-05-08
+# RCS-ID:       $Id$
 # Copyright:    (c) 2004 Pierre Hjälm - 1998 Julian Smart
 # Licence:      wxWindows license
 #----------------------------------------------------------------------------
index 76e06de1114b2535fcb50986057a4cbc3a6e01ee..9346bc775ffb2205c048d356802a2bc9597eb8c5 100644 (file)
@@ -5,8 +5,8 @@
 #
 # Author:       Pierre Hjälm (from C++ original by Julian Smart)
 #
-# Created:      20040508
-# RCS-ID:       
+# Created:      2004-05-08
+# RCS-ID:       $Id$
 # Copyright:    (c) 2004 Pierre Hjälm - 1998 Julian Smart
 # Licence:      wxWindows license
 #----------------------------------------------------------------------------
index aaafd4d1e8c29d2b06eac27721a5fc3d2d82c6dd..d9ad610b0f4894dc11ecf51bcafbdde01ca7cfa7 100644 (file)
@@ -5,8 +5,8 @@
 #
 # Author:       Pierre Hjälm (from C++ original by Julian Smart)
 #
-# Created:      20040508
-# RCS-ID:       
+# Created:      2004-05-08
+# RCS-ID:       $Id$
 # Copyright:    (c) 2004 Pierre Hjälm - 1998 Julian Smart
 # Licence:      wxWindows license
 #----------------------------------------------------------------------------
index 8d53b9db95cb747a9b81afc1b9b0dae829a7fa3c..6f502aba09f2ab587dfab463495aa837fe821861 100644 (file)
@@ -5,8 +5,8 @@
 #
 # Author:       Pierre Hjälm (from C++ original by Julian Smart)
 #
-# Created:      20040508
-# RCS-ID:       
+# Created:      2004-05-08
+# RCS-ID:       $Id$
 # Copyright:    (c) 2004 Pierre Hjälm - 1998 Julian Smart
 # Licence:      wxWindows license
 #----------------------------------------------------------------------------
@@ -21,8 +21,8 @@ from oglmisc import *
 
 KEY_SHIFT, KEY_CTRL = 1, 2
 
-objectStartX = 0.0
-objectStartY = 0.0
+_objectStartX = 0.0
+_objectStartY = 0.0
 
 CONSTRAINT_CENTRED_VERTICALLY   = 1
 CONSTRAINT_CENTRED_HORIZONTALLY = 2
@@ -44,6 +44,24 @@ CONSTRAINT_MIDALIGNED_LEFT      = 14
 CONSTRAINT_MIDALIGNED_RIGHT     = 15
 
 
+# Backwards compatibility names.  These should be removed eventually.
+gyCONSTRAINT_CENTRED_VERTICALLY   = CONSTRAINT_CENTRED_VERTICALLY   
+gyCONSTRAINT_CENTRED_HORIZONTALLY = CONSTRAINT_CENTRED_HORIZONTALLY 
+gyCONSTRAINT_CENTRED_BOTH         = CONSTRAINT_CENTRED_BOTH         
+gyCONSTRAINT_LEFT_OF              = CONSTRAINT_LEFT_OF              
+gyCONSTRAINT_RIGHT_OF             = CONSTRAINT_RIGHT_OF             
+gyCONSTRAINT_ABOVE                = CONSTRAINT_ABOVE                
+gyCONSTRAINT_BELOW                = CONSTRAINT_BELOW                
+gyCONSTRAINT_ALIGNED_TOP          = CONSTRAINT_ALIGNED_TOP          
+gyCONSTRAINT_ALIGNED_BOTTOM       = CONSTRAINT_ALIGNED_BOTTOM       
+gyCONSTRAINT_ALIGNED_LEFT         = CONSTRAINT_ALIGNED_LEFT         
+gyCONSTRAINT_ALIGNED_RIGHT        = CONSTRAINT_ALIGNED_RIGHT        
+gyCONSTRAINT_MIDALIGNED_TOP       = CONSTRAINT_MIDALIGNED_TOP       
+gyCONSTRAINT_MIDALIGNED_BOTTOM    = CONSTRAINT_MIDALIGNED_BOTTOM    
+gyCONSTRAINT_MIDALIGNED_LEFT      = CONSTRAINT_MIDALIGNED_LEFT      
+gyCONSTRAINT_MIDALIGNED_RIGHT     = CONSTRAINT_MIDALIGNED_RIGHT     
+
+
 
 class ConstraintType(object):
     def __init__(self, theType, theName, thePhrase):
@@ -353,6 +371,8 @@ class Constraint(object):
         
         return False
     
+OGLConstraint = wx._core._deprecated(Constraint,
+                     "The OGLConstraint name is deprecated, use `ogl.Constraint` instead.")
 
 
 class CompositeShape(RectangleShape):
@@ -412,8 +432,8 @@ class CompositeShape(RectangleShape):
 
     def OnDragLeft(self, draw, x, y, keys = 0, attachment = 0):
         xx, yy = self._canvas.Snap(x, y)
-        offsetX = xx-objectStartX
-        offsetY = yy-objectStartY
+        offsetX = xx - _objectStartX
+        offsetY = yy - _objectStartY
 
         dc = wx.ClientDC(self.GetCanvas())
         self.GetCanvas().PrepareDC(dc)
@@ -426,10 +446,10 @@ class CompositeShape(RectangleShape):
         self.GetEventHandler().OnDrawOutline(dc, self.GetX() + offsetX, self.GetY() + offsetY, self.GetWidth(), self.GetHeight())
 
     def OnBeginDragLeft(self, x, y, keys = 0, attachment = 0):
-        global objectStartX, objectStartY
+        global _objectStartX, _objectStartY
 
-        objectStartX = x
-        objectStartY = y
+        _objectStartX = x
+        _objectStartY = y
 
         dc = wx.ClientDC(self.GetCanvas())
         self.GetCanvas().PrepareDC(dc)
@@ -443,8 +463,8 @@ class CompositeShape(RectangleShape):
         self._canvas.CaptureMouse()
 
         xx, yy = self._canvas.Snap(x, y)
-        offsetX = xx-objectStartX
-        offsetY = yy-objectStartY
+        offsetX = xx - _objectStartX
+        offsetY = yy - _objectStartY
 
         self.GetEventHandler().OnDrawOutline(dc, self.GetX() + offsetX, self.GetY() + offsetY, self.GetWidth(), self.GetHeight())
 
@@ -465,8 +485,8 @@ class CompositeShape(RectangleShape):
         dc.SetLogicalFunction(wx.COPY)
         
         xx, yy = self._canvas.Snap(x, y)
-        offsetX = xx-objectStartX
-        offsetY = yy-objectStartY
+        offsetX = xx - _objectStartX
+        offsetY = yy - _objectStartY
 
         self.Move(dc, self.GetX() + offsetX, self.GetY() + offsetY)
 
index 86c0dd9e02f2a860afdfd9314592ad88adda1e81..95ef272206fa00736e805a1999481bc351f9bc4a 100644 (file)
@@ -5,8 +5,8 @@
 #
 # Author:       Pierre Hjälm (from C++ original by Julian Smart)
 #
-# Created:      20040508
-# RCS-ID:       
+# Created:      2004-05-08
+# RCS-ID:       $Id$
 # Copyright:    (c) 2004 Pierre Hjälm - 1998 Julian Smart
 # Licence:      wxWindows license
 #----------------------------------------------------------------------------
index 73ea006c0653b115daf647cae820778481017a7f..2c7a5b8e676b0394c3112d5eb769695782beddee 100644 (file)
@@ -5,8 +5,8 @@
 #
 # Author:       Pierre Hjälm (from C++ original by Julian Smart)
 #
-# Created:      20040508
-# RCS-ID:       
+# Created:      2004-05-08
+# RCS-ID:       $Id$
 # Copyright:    (c) 2004 Pierre Hjälm - 1998 Julian Smart
 # Licence:      wxWindows license
 #----------------------------------------------------------------------------
index 1012d160ccb8de7d73a6f1927d460a1800ccc59c..f4a191be9a0b7a5dc4a982338f77f4bd89be3359 100644 (file)
@@ -5,8 +5,8 @@
 #
 # Author:       Pierre Hjälm (from C++ original by Julian Smart)
 #
-# Created:      20040508
-# RCS-ID:       
+# Created:      2004-05-08
+# RCS-ID:       $Id$
 # Copyright:    (c) 2004 Pierre Hjälm - 1998 Julian Smart
 # Licence:      wxWindows license
 #----------------------------------------------------------------------------
index a899c0e96b277d84f0e4406c9f7cbfc1dd049a78..478f2ee7746edf2db6e0c536a5e0d0add441a18e 100644 (file)
@@ -5,8 +5,8 @@
 #
 # Author:       Pierre Hjälm (from C++ original by Julian Smart)
 #
-# Created:      20040508
-# RCS-ID:       
+# Created:      2004-05-08
+# RCS-ID:       $Id$
 # Copyright:    (c) 2004 Pierre Hjälm - 1998 Julian Smart
 # Licence:      wxWindows license
 #----------------------------------------------------------------------------