本文整理匯總了Python中xbmcplugin.SORT_METHOD_DATEADDED屬性的典型用法代碼示例。如果您正苦於以下問題:Python xbmcplugin.SORT_METHOD_DATEADDED屬性的具體用法?Python xbmcplugin.SORT_METHOD_DATEADDED怎麽用?Python xbmcplugin.SORT_METHOD_DATEADDED使用的例子?那麽, 這裏精選的屬性代碼示例或許可以為您提供幫助。您也可以進一步了解該屬性所在類xbmcplugin
的用法示例。
在下文中一共展示了xbmcplugin.SORT_METHOD_DATEADDED屬性的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。
示例1: __init__
# 需要導入模塊: import xbmcplugin [as 別名]
# 或者: from xbmcplugin import SORT_METHOD_DATEADDED [as 別名]
def __init__(self, plugin, sortmethods=None):
Film.__init__(self)
self.plugin = plugin
self.handle = plugin.addon_handle
self.settings = Settings()
# define sortmethod for films
# all av. sort method and put the default sortmethod on first place to be used by UI
allSortMethods = [
xbmcplugin.SORT_METHOD_TITLE,
xbmcplugin.SORT_METHOD_DATE,
xbmcplugin.SORT_METHOD_DATEADDED,
xbmcplugin.SORT_METHOD_SIZE,
xbmcplugin.SORT_METHOD_DURATION
]
if sortmethods is not None:
self.sortmethods = sortmethods
else:
method = allSortMethods[0]
allSortMethods[0] = allSortMethods[self.settings.filmSortMethod]
allSortMethods[self.settings.filmSortMethod]=method
self.sortmethods = allSortMethods
self.showshows = False
self.showchannels = False