本文整理汇总了Python中kivy.input.factory.MotionEventFactory.list方法的典型用法代码示例。如果您正苦于以下问题:Python MotionEventFactory.list方法的具体用法?Python MotionEventFactory.list怎么用?Python MotionEventFactory.list使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类kivy.input.factory.MotionEventFactory
的用法示例。
在下文中一共展示了MotionEventFactory.list方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: _get_provider_map
# 需要导入模块: from kivy.input.factory import MotionEventFactory [as 别名]
# 或者: from kivy.input.factory.MotionEventFactory import list [as 别名]
def _get_provider_map(self):
"""Iterates through all registered input provider names and finds the
respective MotionEvent subclass for each. Returns a dict of MotionEvent
subclasses mapped to their provider name.
"""
provider_map = {}
for input_provider in MotionEventFactory.list():
if not hasattr(providers, input_provider):
continue
p = getattr(providers, input_provider)
for m in p.__all__:
event = getattr(p, m)
if issubclass(event, MotionEvent):
provider_map[event] = input_provider
return provider_map
示例2: title
# 需要导入模块: from kivy.input.factory import MotionEventFactory [as 别名]
# 或者: from kivy.input.factory.MotionEventFactory import list [as 别名]
report_dict["Libraries"] = report
report = []
title("Configuration")
s = StringIO()
from kivy.config import Config
ConfigParser.write(Config, s)
report.extend(s.getvalue().split("\n"))
report_dict["Configuration"] = report
report = []
title("Input availability")
from kivy.input.factory import MotionEventFactory
for x in MotionEventFactory.list():
report.append(x)
report_dict["InputAvailablity"] = report
report = []
"""
title('Log')
for x in pymt_logger_history.history:
report.append(x.message)
"""
title("Environ")
for k, v in os.environ.items():
report.append("%s = %s" % (k, v))
report_dict["Environ"] = report
report = []