+++ /dev/null
-#!/usr/bin/env python
-# -*-coding: utf-8 -*-
-# vim: sw=4 ts=4 expandtab ai
-# pylint: disable-msg=C0301
-
-class File(object):
- def add(self, fpath, fsize):
- self.fl_path = fpath
- self.fl_size = fsize
-
- def show(self):
- self.cur_ui.show(self.fl_path, self.fl_size)
-
- def __init__(self, ui):
- if ui is 'console':
- from consprint import ConsPrint
- self.cur_ui = ConsPrint()
- self.fl_path = None
- self.fl_size = None
--- /dev/null
+#!/usr/bin/env python
+# -*-coding: utf-8 -*-
+# vim: sw=4 ts=4 expandtab ai
+# pylint: disable-msg=C0301
+
+class FileList(object):
+ def add(self, fpath, fsize):
+ self.flist.append((fpath, fsize))
+
+ def show(self):
+ for fpath, fsize in self.flist:
+ self.ui.show(fpath, fsize)
+
+ def __init__(self, out_ui):
+ self.ui = out_ui
+ self.flist = []