diff options
author | Joris | 2020-05-10 20:24:24 +0200 |
---|---|---|
committer | Joris | 2020-05-10 20:24:24 +0200 |
commit | 8a6e10d401eea8db0947f8c4b309b8a6256f9748 (patch) | |
tree | 6e2dc6956ce7825f0f1b6c3ed6f0b4171fe9c274 /src/gui/tasks | |
parent | 3e1415c738facb8b0274adb50ae65f218fd59c9b (diff) |
Add tags panel
Diffstat (limited to 'src/gui/tasks')
-rw-r--r-- | src/gui/tasks/form/state.py | 3 | ||||
-rw-r--r-- | src/gui/tasks/form/widget.py | 1 | ||||
-rw-r--r-- | src/gui/tasks/table/menu.py | 2 | ||||
-rw-r--r-- | src/gui/tasks/table/model.py | 1 | ||||
-rw-r--r-- | src/gui/tasks/widget.py | 3 |
5 files changed, 3 insertions, 7 deletions
diff --git a/src/gui/tasks/form/state.py b/src/gui/tasks/form/state.py index 727bedd..9bd3ae3 100644 --- a/src/gui/tasks/form/state.py +++ b/src/gui/tasks/form/state.py @@ -1,6 +1,5 @@ -import re from PyQt5 import QtCore -from typing import NamedTuple, Optional +from typing import Optional from model.task import ValidTaskForm from model.difficulty import Difficulty diff --git a/src/gui/tasks/form/widget.py b/src/gui/tasks/form/widget.py index adaf757..9feaad0 100644 --- a/src/gui/tasks/form/widget.py +++ b/src/gui/tasks/form/widget.py @@ -1,7 +1,6 @@ from PyQt5 import QtWidgets, QtCore from typing import Optional, Tuple, List, Any -import db.tasks from model.task import Task, ValidTaskForm from model import difficulty, priority import gui.icon diff --git a/src/gui/tasks/table/menu.py b/src/gui/tasks/table/menu.py index edc9833..435ff25 100644 --- a/src/gui/tasks/table/menu.py +++ b/src/gui/tasks/table/menu.py @@ -14,7 +14,7 @@ def open(database, table, update_task_signal, position): else: modify_action = QtWidgets.QAction(menu) - delete_action = menu.addAction(gui.icon.trash(menu.style()), 'Delete') + delete_action = menu.addAction(gui.icon.trash(menu.style()), 'delete') action = menu.exec_(table.mapToGlobal(position)) if action == modify_action and len(rows) == 1: diff --git a/src/gui/tasks/table/model.py b/src/gui/tasks/table/model.py index bf9e386..ab969ec 100644 --- a/src/gui/tasks/table/model.py +++ b/src/gui/tasks/table/model.py @@ -35,7 +35,6 @@ class TableModel(QtCore.QAbstractTableModel): task = self._tasks[index.row()] if role == Qt.DisplayRole: - task = self._tasks[index.row()] if index.column() == 0: return age_since(task.created_at) elif index.column() == 1: diff --git a/src/gui/tasks/widget.py b/src/gui/tasks/widget.py index 61ad605..ea4acb9 100644 --- a/src/gui/tasks/widget.py +++ b/src/gui/tasks/widget.py @@ -1,9 +1,8 @@ -from PyQt5 import QtWidgets, QtCore +from PyQt5 import QtWidgets import gui.tasks.signal import gui.tasks.table.widget import gui.icon -from model.task import ValidTaskForm def widget(database, parent): widget = QtWidgets.QWidget(parent) |