本文整理匯總了Python中pyanaconda.ui.tui.tuiobject.TUIObject.refresh方法的典型用法代碼示例。如果您正苦於以下問題:Python TUIObject.refresh方法的具體用法?Python TUIObject.refresh怎麽用?Python TUIObject.refresh使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類pyanaconda.ui.tui.tuiobject.TUIObject
的用法示例。
在下文中一共展示了TUIObject.refresh方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。
示例1: refresh
# 需要導入模塊: from pyanaconda.ui.tui.tuiobject import TUIObject [as 別名]
# 或者: from pyanaconda.ui.tui.tuiobject.TUIObject import refresh [as 別名]
def refresh(self, args=None):
"""This methods fills the self.window list by all the objects
we want shown on this screen. Title and Spokes mostly."""
TUIObject.refresh(self, args)
self._container = ListRowContainer(2, columns_width=39, spacing=2)
for w in self._spokes_map:
self._container.add(w, callback=self._item_called, data=w)
self.window.add_with_separator(self._container)
示例2: refresh
# 需要導入模塊: from pyanaconda.ui.tui.tuiobject import TUIObject [as 別名]
# 或者: from pyanaconda.ui.tui.tuiobject.TUIObject import refresh [as 別名]
def refresh(self, args=None):
"""This methods fills the self._window list by all the objects
we want shown on this screen. Title and Spokes mostly."""
TUIObject.refresh(self, args)
def _prep(i, w):
number = tui.TextWidget("%2d)" % i)
return tui.ColumnWidget([(3, [number]), (None, [w])], 1)
# split spokes to two columns
left = [_prep(i, w) for i, w in self._keys.items() if i % 2 == 1]
right = [_prep(i, w) for i, w in self._keys.items() if i % 2 == 0]
c = tui.ColumnWidget([(39, left), (39, right)], 2)
self._window.append(c)
return True
示例3: refresh
# 需要導入模塊: from pyanaconda.ui.tui.tuiobject import TUIObject [as 別名]
# 或者: from pyanaconda.ui.tui.tuiobject.TUIObject import refresh [as 別名]
def refresh(self, args=None):
TUIObject.refresh(self, args)
return True