summaryrefslogtreecommitdiff
path: root/cad/src/graphics/drawing/drawing_constants.py
blob: b9fefa4e6d12c7081685fa30e019277be270972a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
# Copyright 2004-2009 Nanorex, Inc.  See LICENSE file for details. 
"""
drawing_constants.py - constants and helpers for graphics.drawing package

@author: Russ, plus others if the code that belongs here is ever moved here
@version: $Id$
@copyright: 2004-2009 Nanorex, Inc.  See LICENSE file for details. 

History:

090304 bruce split out of drawing_globals to avoid import cycles

TODO:

some geometric variables (but not display lists!) stored into drawing_globals
by external code (mostly setup_draw) should instead be defined here.
"""

# Common constants and helpers for DrawingSet, TransformControl, et al.

# Russ 080915: Support for lazily updating drawing caches, namely a change
# timestamp.  Rather than recording a time per se, an event counter is used.
NO_EVENT_YET = 0
_event_counter = NO_EVENT_YET
def eventStamp():
    global _event_counter
    _event_counter += 1
    return _event_counter

def eventNow(): # not used
    return _event_counter

# end