本文整理汇总了Python中CeciliaLib.setSoundfilePlayerPath方法的典型用法代码示例。如果您正苦于以下问题:Python CeciliaLib.setSoundfilePlayerPath方法的具体用法?Python CeciliaLib.setSoundfilePlayerPath怎么用?Python CeciliaLib.setSoundfilePlayerPath使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CeciliaLib
的用法示例。
在下文中一共展示了CeciliaLib.setSoundfilePlayerPath方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: changeSfPlayer
# 需要导入模块: import CeciliaLib [as 别名]
# 或者: from CeciliaLib import setSoundfilePlayerPath [as 别名]
def changeSfPlayer(self):
if CeciliaLib.getPlatform() == 'win32':
wildcard = "Executable files (*.exe)|*.exe|" \
"All files (*.*)|*.*"
elif CeciliaLib.getPlatform() == 'darwin':
wildcard = "Application files (*.app)|*.app|" \
"All files (*.*)|*.*"
else:
wildcard = "All files (*.*)|*.*"
path = ''
dlg = wx.FileDialog(self, message="Choose a soundfile player...",
defaultDir=os.path.expanduser('~'),
wildcard=wildcard,
style=wx.OPEN)
if dlg.ShowModal() == wx.ID_OK:
path = dlg.GetPath()
dlg.Destroy()
if path:
CeciliaLib.setSoundfilePlayerPath(path)
self.textSfPlayerPath.SetValue(path)
示例2: handleSfPlayerPath
# 需要导入模块: import CeciliaLib [as 别名]
# 或者: from CeciliaLib import setSoundfilePlayerPath [as 别名]
def handleSfPlayerPath(self, event):
path = self.textSfPlayerPath.GetValue()
CeciliaLib.setSoundfilePlayerPath(path)
self.textSfPlayerPath.Navigate()