seriesmarker.gui.main_window module

class MainWindow(parent=None)[source]

Bases: PySide.QtGui.QMainWindow

Displays the main application window.

__init__(parent=None)[source]

Creates a new window instance.

Initializes the different views and loads series information from the database into the view’s models for displaying them.

Parameters:parent (PySide.QtGui.QWidget) – The parent widget of the window.
_enable_icon_mode()[source]

Changes the style of the list view to icon mode.

_enable_list_mode()[source]

Changes the style of the list view to list mode.

_handle_context_menu(pos)[source]
on_action_about_qt_triggered()[source]

Displays a dialog with information about Qt.

on_action_about_triggered()[source]

Displays an AboutDialog for additional information.

on_action_add_triggered()[source]

Displays a SearchDialog to add a new series to the database.

on_action_exit_triggered()[source]

Terminates the application normally.

on_action_home_triggered()[source]

Restores the initial perspective of the application.

on_action_mark_unwatched_triggered()[source]

Marks all episodes of the currently selected series as unwatched.

on_action_mark_watched_triggered()[source]

Marks all episodes of the currently selected series as watched.

on_action_remove_triggered()[source]

Removes a series from the database and the views.

on_action_update_triggered()[source]

Sequentially updates all series in the database.

Todo

Update should also recognize/announce updated episodes.

on_list_view_entered(index)[source]

Sets the tooltip of the list view.

A tooltip is set, when the mouse hovers above an episode in the list view.

Parameters:index (QModelIndex) – The index of the item whose view has been entered.
on_list_view_viewportEntered()[source]

Removes the tooltip from the list view.

A tooltip is removed, when the mouse leaves the area of an episode in the list view.

on_tree_view_clicked(index)[source]

Changes the style of the list view according to context.

The list view shows icons in portrait mode if a series or season is selected in the tree view. It changes to list mode if an episode has been selected.

Todo

Should change view only if next style differs from current one - needs to compare with previous selection.

staticMetaObject = <PySide.QtCore.QMetaObject object>