예제 #1
0
    def build_widget(self):
        self.titlebar = itemlistwidgets.ConvertingTitlebar()
        self.widget.pack_start(self.titlebar)
        self.titlebar.connect('stop-all', self.on_cancel_all)
        self.titlebar.connect('reveal', self.on_reveal_conversions_folder)
        self.titlebar.connect('clear-finished', self.on_clear_finished)

        self.model = widgetset.TableModel('object')
        self.table = ConvertingTableView(self.model)
        self.table.connect_weak('hotspot-clicked', self.on_hotspot_clicked)
        scroller = widgetset.Scroller(False, True)
        scroller.add(self.table)

        self.widget.pack_start(scroller, expand=True)

        conversion_manager.fetch_tasks_list()
예제 #2
0
    def build_widget(self):
        self.titlebar = itemlistwidgets.ConvertingTitlebar()
        self.widget.pack_start(self.titlebar)
        self.titlebar.connect('stop-all', self.on_cancel_all)
        self.titlebar.connect('reveal', self.on_reveal_conversions_folder)
        self.titlebar.connect('clear-finished', self.on_clear_finished)

        self.model = widgetset.TableModel('object')
        self.table = ConvertingTableView(self.model)
        self.table.connect_weak('hotspot-clicked', self.on_hotspot_clicked)
        scroller = widgetset.Scroller(False, True)
        scroller.add(self.table)

        self.widget.pack_start(scroller, expand=True)

        conversion_manager.fetch_tasks_list()
예제 #3
0
    def build_widget(self):
        image_path = resources.path("images/icon-conversions_large.png")
        icon = imagepool.get(image_path)
        titlebar = ConversionsTitleBar(_("Conversions"), icon)
        self.widget.pack_start(titlebar)

        sep = separator.HSeparator((0.85, 0.85, 0.85), (0.95, 0.95, 0.95))
        self.widget.pack_start(sep)

        self.stop_all_button = widgetset.Button(_('Stop All Conversions'), style='smooth')
        self.stop_all_button.set_size(widgetconst.SIZE_SMALL)
        self.stop_all_button.set_color(widgetset.TOOLBAR_GRAY)
        self.stop_all_button.disable()
        self.stop_all_button.connect('clicked', self.on_cancel_all)

        reveal_button = widgetset.Button(_('Show Conversion Folder'), style='smooth')
        reveal_button.set_size(widgetconst.SIZE_SMALL)
        reveal_button.set_color(widgetset.TOOLBAR_GRAY)
        reveal_button.connect('clicked', self.on_reveal_conversions_folder)

        self.clear_finished_button = widgetset.Button(
                _('Clear Finished Conversions'), style='smooth')
        self.clear_finished_button.set_size(widgetconst.SIZE_SMALL)
        self.clear_finished_button.set_color(widgetset.TOOLBAR_GRAY)
        self.clear_finished_button.connect('clicked', self.on_clear_finished)

        toolbar = itemlistwidgets.DisplayToolbar()
        hbox = widgetset.HBox()
        hbox.pack_start(widgetutil.pad(self.stop_all_button, top=8, bottom=8, left=8))
        hbox.pack_end(widgetutil.pad(reveal_button, top=8, bottom=8, right=8))
        hbox.pack_end(widgetutil.pad(self.clear_finished_button, top=8, bottom=8, right=8))
        toolbar.add(hbox)
        self.widget.pack_start(toolbar)
        
        self.iter_map = dict()
        self.model = widgetset.TableModel('object')
        self.table = ConversionTableView(self.model)
        self.table.connect_weak('hotspot-clicked', self.on_hotspot_clicked)
        scroller = widgetset.Scroller(False, True)
        scroller.add(self.table)

        self.widget.pack_start(scroller, expand=True)

        conversion_manager.fetch_tasks_list()