def search_prompt(self):
# XXX: remove if when thread search is supported
if self.mode != "index":
return
popup = OptionsMenu(
urwid.ListBox(
urwid.SimpleFocusListWalker([
urwid.Text(("button", "Enter a query:")),
urwid.AttrMap(StringPrompt(self.search_callback), "opt_prompt"),
urwid.Text("Use a blank query to reset the {}.".format(self.mode))
])),
**frame_theme())
self.loop.widget = urwid.Overlay(
popup, self.loop.widget,
align=("relative", 50),
valign=("relative", 25 if self.window_split else 50),
width=("relative", 40), height=6)
评论列表
文章目录