Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gui: insert --no-check #2161

Merged
merged 1 commit into from
Feb 20, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 10 additions & 5 deletions lib/cylc/gui/app_gcylc.py
Original file line number Diff line number Diff line change
Expand Up @@ -2142,15 +2142,19 @@ def insert_task_popup(self, *b, **kwargs):
hbox.pack_start(entry_stop_point, True)
vbox.pack_start(hbox)

no_check_cb = gtk.CheckButton(
"Do not check if cycle point is valid or not")
no_check_cb.set_active(False)
vbox.pack_start(no_check_cb, True)

help_button = gtk.Button("_Help")
help_button.connect("clicked", self.command_help, "control", "insert")

hbox = gtk.HBox()
insert_button = gtk.Button("_Insert")
insert_button.connect(
"clicked", self.insert_task, window, entry_task_ids,
entry_stop_point,
)
entry_stop_point, no_check_cb)
cancel_button = gtk.Button("_Cancel")
cancel_button.connect("clicked", lambda x: window.destroy())
hbox.pack_start(insert_button, False)
Expand All @@ -2161,7 +2165,8 @@ def insert_task_popup(self, *b, **kwargs):
window.add(vbox)
window.show_all()

def insert_task(self, w, window, entry_task_ids, entry_stop_point):
def insert_task(
self, w, window, entry_task_ids, entry_stop_point, no_check_cb):
"""Insert a task, callback for "insert_task_popup"."""
task_ids = shlex.split(entry_task_ids.get_text())
if not task_ids:
Expand All @@ -2179,8 +2184,8 @@ def insert_task(self, w, window, entry_task_ids, entry_stop_point):
stop_point_str = None
self.put_comms_command(
'insert_tasks', items=task_ids,
stop_point_string=stop_point_str
)
stop_point_string=stop_point_str,
no_check=no_check_cb.get_active())

def poll_all(self, w):
"""Poll all active tasks."""
Expand Down