Module adhoc_commands :: Class CommandWindow
[hide private]
[frames] | no frames]

Class CommandWindow

source code

Class for a window for single ad-hoc commands session

Note, that there might be more than one for one account/jid pair in one moment.

TODO: Maybe put this window into MessageWindow? consider this when it will be possible to manage more than one window of one. TODO: Account/jid pair in MessageWindowMgr. TODO: GTK 2.10 has a special wizard-widget, consider using it...

Instance Methods [hide private]
 
__init__(self, account, jid, commandnode=None)
Create new window
source code
 
initiate(self) source code
 
stage_finish(self, *anything) source code
 
stage_back_button_clicked(self, *anything) source code
 
stage_forward_button_clicked(self, *anything) source code
 
stage_execute_button_clicked(self, *anything) source code
 
stage_close_button_clicked(self, *anything) source code
 
stage_restart_button_clicked(self, *anything) source code
 
stage_adhoc_commands_window_delete_event(self, *anything) source code
 
do_nothing(self, *anything) source code
 
on_back_button_clicked(self, *anything) source code
 
on_forward_button_clicked(self, *anything) source code
 
on_execute_button_clicked(self, *anything) source code
 
on_finish_button_clicked(self, *anything) source code
 
on_close_button_clicked(self, *anything) source code
 
on_restart_button_clicked(self, *anything) source code
 
on_adhoc_commands_window_destroy(self, *anything) source code
 
on_adhoc_commands_window_delete_event(self, *anything) source code
 
__del__(self) source code
 
stage1(self)
Prepare the first stage.
source code
 
stage1_finish(self) source code
 
stage1_close_button_clicked(self, widget) source code
 
stage1_restart_button_clicked(self, widget) source code
 
stage1_adhoc_commands_window_delete_event(self, widget) source code
 
stage2(self)
Populate the command list vbox with radiobuttons
source code
 
stage2_finish(self)
Remove widgets we created.
source code
 
stage2_close_button_clicked(self, widget) source code
 
stage2_restart_button_clicked(self, widget) source code
 
stage2_forward_button_clicked(self, widget) source code
 
on_command_radiobutton_toggled(self, widget, commandnode) source code
 
on_check_commands_1_button_clicked(self, widget) source code
 
stage3(self) source code
 
stage3_finish(self) source code
 
stage3_can_close(self, cb) source code
 
stage3_close_button_clicked(self, widget)
We are in the middle of executing command.
source code
 
stage3_restart_button_clicked(self, widget) source code
 
stage3_back_button_clicked(self, widget) source code
 
stage3_forward_button_clicked(self, widget) source code
 
stage3_execute_button_clicked(self, widget) source code
 
stage3_finish_button_clicked(self, widget) source code
 
stage3_submit_form(self, action='execute') source code
 
stage3_next_form(self, command) source code
 
restart(self) source code
 
stage4(self)
Display the message.
source code
 
stage4_close_button_clicked(self, widget) source code
 
stage4_restart_button_clicked(self, widget) source code
 
on_check_commands_2_button_clicked(self, widget) source code
 
stage5(self, error=None, errorid=None, senderror=False)
Display the error message.
source code
 
stage5_close_button_clicked(self, widget) source code
 
stage5_restart_button_clicked(self, widget) source code
 
setup_pulsing(self, progressbar)
Set the progressbar to pulse.
source code
 
remove_pulsing(self)
Stop pulsing, useful when especially when removing widget
source code
 
request_command_list(self)
Request the command list.
source code
 
send_command(self, action='execute')
Send the command with data form.
source code
 
send_cancel(self)
Send the command with action='cancel'
source code
Method Details [hide private]

__init__(self, account, jid, commandnode=None)
(Constructor)

source code 
Create new window

initiate(self)

source code 

stage_finish(self, *anything)

source code 

stage_back_button_clicked(self, *anything)

source code 

stage_forward_button_clicked(self, *anything)

source code 

stage_execute_button_clicked(self, *anything)

source code 

stage_close_button_clicked(self, *anything)

source code 

stage_restart_button_clicked(self, *anything)

source code 

stage_adhoc_commands_window_delete_event(self, *anything)

source code 

do_nothing(self, *anything)

source code 

on_back_button_clicked(self, *anything)

source code 

on_forward_button_clicked(self, *anything)

source code 

on_execute_button_clicked(self, *anything)

source code 

on_finish_button_clicked(self, *anything)

source code 

on_close_button_clicked(self, *anything)

source code 

on_restart_button_clicked(self, *anything)

source code 

on_adhoc_commands_window_destroy(self, *anything)

source code 

on_adhoc_commands_window_delete_event(self, *anything)

source code 

__del__(self)
(Destructor)

source code 

stage1(self)

source code 
Prepare the first stage. Request command list, set appropriate state of widgets

stage1_finish(self)

source code 

stage1_close_button_clicked(self, widget)

source code 

stage1_restart_button_clicked(self, widget)

source code 

stage1_adhoc_commands_window_delete_event(self, widget)

source code 

stage2(self)

source code 

Populate the command list vbox with radiobuttons

FIXME: If there is more commands, maybe some kind of list, set widgets state

stage2_finish(self)

source code 
Remove widgets we created. Not needed when the window is destroyed

stage2_close_button_clicked(self, widget)

source code 

stage2_restart_button_clicked(self, widget)

source code 

stage2_forward_button_clicked(self, widget)

source code 

on_command_radiobutton_toggled(self, widget, commandnode)

source code 

on_check_commands_1_button_clicked(self, widget)

source code 

stage3(self)

source code 

stage3_finish(self)

source code 

stage3_can_close(self, cb)

source code 

stage3_close_button_clicked(self, widget)

source code 
We are in the middle of executing command. Ask user if he really want to cancel the process, then cancel it

stage3_restart_button_clicked(self, widget)

source code 

stage3_back_button_clicked(self, widget)

source code 

stage3_forward_button_clicked(self, widget)

source code 

stage3_execute_button_clicked(self, widget)

source code 

stage3_finish_button_clicked(self, widget)

source code 

stage3_submit_form(self, action='execute')

source code 

stage3_next_form(self, command)

source code 

restart(self)

source code 

stage4(self)

source code 
Display the message. Wait for user to close the window

stage4_close_button_clicked(self, widget)

source code 

stage4_restart_button_clicked(self, widget)

source code 

on_check_commands_2_button_clicked(self, widget)

source code 

stage5(self, error=None, errorid=None, senderror=False)

source code 
Display the error message. Wait for user to close the window

stage5_close_button_clicked(self, widget)

source code 

stage5_restart_button_clicked(self, widget)

source code 

setup_pulsing(self, progressbar)

source code 
Set the progressbar to pulse. Makes a custom function to repeatedly call progressbar.pulse() method

remove_pulsing(self)

source code 
Stop pulsing, useful when especially when removing widget

request_command_list(self)

source code 
Request the command list. Change stage on delivery

send_command(self, action='execute')

source code 
Send the command with data form. Wait for reply

send_cancel(self)

source code 
Send the command with action='cancel'