Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
T
topydo
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
topydo
Commits
0b07837f
Commit
0b07837f
authored
Jun 21, 2015
by
Bram Schoenmakers
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add functionality to copy a column with 'Y'.
parent
33685a5d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
1 deletion
+8
-1
topydo/ui/Main.py
topydo/ui/Main.py
+8
-1
No files found.
topydo/ui/Main.py
View file @
0b07837f
...
...
@@ -43,6 +43,7 @@ class UIView(View):
_NEW_COLUMN
=
1
_EDIT_COLUMN
=
2
_COPY_COLUMN
=
3
class
UIApplication
(
CLIApplicationBase
):
def
__init__
(
self
):
...
...
@@ -168,6 +169,11 @@ class UIApplication(CLIApplicationBase):
# no columns
pass
def
_copy_column
(
self
):
self
.
viewwidget
.
data
=
self
.
columns
.
focus
.
view
.
data
self
.
column_mode
=
_COPY_COLUMN
self
.
_viewwidget_visible
=
True
def
_handle_input
(
self
,
p_input
):
dispatch
=
{
':'
:
self
.
_focus_commandline
,
...
...
@@ -180,6 +186,7 @@ class UIApplication(CLIApplicationBase):
'N'
:
self
.
_new_column
,
'E'
:
self
.
_edit_column
,
'D'
:
self
.
_delete_column
,
'Y'
:
self
.
_copy_column
,
}
try
:
...
...
@@ -207,7 +214,7 @@ class UIApplication(CLIApplicationBase):
""" Creates a view from the data entered in the view widget. """
view
=
self
.
_viewdata_to_view
(
p_data
)
if
self
.
column_mode
==
_NEW_COLUMN
:
if
self
.
column_mode
==
_NEW_COLUMN
or
self
.
column_mode
==
_COPY_COLUMN
:
self
.
_add_column
(
view
)
elif
self
.
column_mode
==
_EDIT_COLUMN
:
current_column
=
self
.
columns
.
focus
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment