--- a/editors/ConfTreeNodeEditor.py Wed Jul 31 10:45:07 2013 +0900
+++ b/editors/ConfTreeNodeEditor.py Mon Nov 18 12:12:31 2013 +0900
@@ -3,7 +3,6 @@
import types
import wx
-import wx.lib.buttons
from EditorPanel import EditorPanel
@@ -35,22 +34,6 @@
def Bpath(*args):
return os.path.join(CWD,*args)
-# Patch wx.lib.imageutils so that gray is supported on alpha images
-import wx.lib.imageutils
-from wx.lib.imageutils import grayOut as old_grayOut
-def grayOut(anImage):
- if anImage.HasAlpha():
- AlphaData = anImage.GetAlphaData()
- else :
- AlphaData = None
-
- old_grayOut(anImage)
-
- if AlphaData is not None:
- anImage.SetAlphaData(AlphaData)
-
-wx.lib.imageutils.grayOut = grayOut
-
class GenBitmapTextButton(wx.lib.buttons.GenBitmapTextButton):
def _GetLabelSize(self):
""" used internally """
@@ -333,7 +316,11 @@
else:
element_path = element_infos["name"]
if element_infos["type"] == "element":
- label = element_infos["name"]
+ name = element_infos["name"]
+ value = element_infos["value"]
+ label = _(name)
+ if value is not None:
+ label += " - %s" % _(value)
staticbox = wx.StaticBox(self.ParamsEditor,
label=_(label), size=wx.Size(10, 0))
staticboxsizer = wx.StaticBoxSizer(staticbox, wx.VERTICAL)
@@ -509,6 +496,8 @@
def GetChoiceCallBackFunction(self, choicectrl, path):
def OnChoiceChanged(event):
res = self.SetConfNodeParamsAttribute(path, choicectrl.GetStringSelection())
+ if res is None:
+ res = ""
choicectrl.SetStringSelection(res)
event.Skip()
return OnChoiceChanged