[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[gnue] r8406 - trunk/gnue-common/src/logic
From: |
reinhard |
Subject: |
[gnue] r8406 - trunk/gnue-common/src/logic |
Date: |
Fri, 14 Apr 2006 12:52:16 -0500 (CDT) |
Author: reinhard
Date: 2006-04-14 12:52:16 -0500 (Fri, 14 Apr 2006)
New Revision: 8406
Modified:
trunk/gnue-common/src/logic/actions.py
Log:
Clean up according to pylint.
Modified: trunk/gnue-common/src/logic/actions.py
===================================================================
--- trunk/gnue-common/src/logic/actions.py 2006-04-14 11:06:30 UTC (rev
8405)
+++ trunk/gnue-common/src/logic/actions.py 2006-04-14 17:52:16 UTC (rev
8406)
@@ -27,7 +27,9 @@
from gnue.common.definitions import GObjects
from gnue.common.formatting import GTypecast
+__all__ = ['GAction', 'GMenu', 'GMenuItem', 'GToolbar', 'GToolButton']
+
# =============================================================================
# <action>
# =============================================================================
@@ -67,11 +69,11 @@
# Constructor
# -------------------------------------------------------------------------
- def __init__(self, parent = None, type = "GCAction"):
+ def __init__(self, parent = None, object_type = "GCAction"):
"""
Create a GAction instance.
"""
- GObjects.GObj.__init__(self, parent, type)
+ GObjects.GObj.__init__(self, parent, object_type)
# Trigger support
_triggerGlobal = True
@@ -128,11 +130,11 @@
# Constructor
# -------------------------------------------------------------------------
- def __init__(self, parent, type):
+ def __init__(self, parent, object_type):
"""
Create a GCommander instance.
"""
- GObjects.GObj.__init__(self, parent, type)
+ GObjects.GObj.__init__(self, parent, object_type)
# Trigger support
_triggerProperties = {
@@ -175,11 +177,11 @@
# Constructor
# -------------------------------------------------------------------------
- def __init__(self, parent = None, type = "GCMenu"):
+ def __init__(self, parent = None, object_type = "GCMenu"):
"""
Create a GMenu instance.
"""
- GObjects.GObj.__init__(self, parent, type)
+ GObjects.GObj.__init__(self, parent, object_type)
# =============================================================================
@@ -195,11 +197,11 @@
# Constructor
# -------------------------------------------------------------------------
- def __init__(self, parent = None, type = "GCMenuItem"):
+ def __init__(self, parent = None, object_type = "GCMenuItem"):
"""
Create a GMenuItem instance.
"""
- GObjects.GObj.__init__(self, parent, type)
+ GCommander.__init__(self, parent, object_type)
# =============================================================================
@@ -222,11 +224,11 @@
# Constructor
# -------------------------------------------------------------------------
- def __init__(self, parent = None, type = "GCToolbar"):
+ def __init__(self, parent = None, object_type = "GCToolbar"):
"""
Create a GToolbar instance.
"""
- GObjects.GObj.__init__(self, parent, type)
+ GObjects.GObj.__init__(self, parent, object_type)
# =============================================================================
@@ -242,20 +244,25 @@
# Constructor
# -------------------------------------------------------------------------
- def __init__(self, parent = None, type = "GCToolButton"):
+ def __init__(self, parent = None, object_type = "GCToolButton"):
"""
Create a GToolButton instance.
"""
- GObjects.GObj.__init__(self, parent, type)
+ GCommander.__init__(self, parent, object_type)
# =============================================================================
# XML Element dictionary
# =============================================================================
-def getXMLelements(updates = {}):
+def get_xml_elements(updates):
+ """
+ Returns the XML Element dictionary for the objects defined in this module.
+ """
- xmlElements = {
+ checktype(updates, dict)
+
+ xml_elements = {
'action': {
'Description' : u_(
"A piece of code that can be bound to a button, a menu "
@@ -411,6 +418,6 @@
'Default' : False}}}}
for alteration in updates.keys():
- xmlElements[alteration].update(updates[alteration])
+ xml_elements[alteration].update(updates[alteration])
- return xmlElements
+ return xml_elements
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [gnue] r8406 - trunk/gnue-common/src/logic,
reinhard <=