ARB
Classes | Functions
aw_question.hxx File Reference
#include "aw_base.hxx"
#include <arbtools.h>
#include <attributes.h>
#include <cstdlib>
Include dependency graph for aw_question.hxx:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  FINAL_TYPE< SEQTYPE >
 xml element More...
 

Functions

int aw_question (const char *unique_id, const char *msg, const char *buttons, bool sameSizeButtons=true, const char *helpfile=NULp)
 
bool aw_ask_sure (const char *unique_id, const char *msg)
 
void aw_popup_ok (const char *msg)
 
void aw_popup_exit (const char *msg) __ATTR__NORETURN
 
void AW_reactivate_all_questions (AW_window *)
 

Function Documentation

int aw_question ( const char unique_id,
const char msg,
const char buttons,
bool  sameSizeButtons = true,
const char helpfile = NULp 
)

Ask the user a question. Blocks all UI input until the answer is provided.

Parameters
unique_idUnique ID to identify the question. Must be valid hkey.
questionThe question.
buttonsComma separated list of button names. A button named starting with "^" will begin a new row of buttons. A button named "EXIT" will cause abnormal (EXIT_FAILURE) termination of program.
sameSizeButtonsMake all buttons have the same size.
helpfileAdds a "HELP" button. May be NULp. (currently ignored)
Returns
the index of the selected answer

Definition at line 26 of file AW_question.cxx.

References AW_root::add_timed_callback_never_disabled(), ARB_SIGSEGV, AW_advice(), AW_ADVICE_TOGGLE, aw_assert, aw_detect_text_size(), aw_message(), aw_message_cb_result, AW_MESSAGE_LISTEN_DELAY, aw_message_timer_listen_event(), AW_RESIZE_DEFAULT, AW_ROOT_DEFAULT, AW_root::awar_int(), AW_awar::awar_name, AWAR_QUESTION, AW_root::awar_string(), AW_root::disable_callbacks, error(), fflush(), GB_check_key(), GB_MIND_CASE, GBK_dump_backtrace(), GBS_create_hash(), GBS_global_string(), GBS_global_string_copy(), GBS_read_hash(), GBS_string_2_key(), GBS_write_hash(), AW_window::hide(), label, makeHelpCallback(), message_cb(), NULp, AW_root::process_events(), AW_root::program_name, AW_awar::read_int(), result, AW_window::show_modal(), AW_root::SINGLETON, AW_awar::write_int(), and AW_awar::write_string().

Referenced by alignToNextRelative(), ARB_main(), aw_ask_sure(), aw_popup_exit(), aw_popup_ok(), AW_select_nameserver(), aw_status_timer_event(), check_argument_for_mode(), create_new_mask_cb(), ArbImporter::import_data(), MERGE_create_main_window(), MERGE_sequences_simple(), MG_equal_alignments(), nt_disconnect_from_db(), NT_fix_dict_compress(), pd_export_pt_server(), primer_design_event_go(), probe_design_event(), ArbImporter::read_data(), save_probe_collection(), save_search_paras_to_file(), SEC_new_structure(), AWT_graphic_tree::toggle_group(), write_file(), and ED4_terminal::write_sequence().

bool aw_ask_sure ( const char unique_id,
const char msg 
)

pop up a modal yes/no question

Parameters
unique_idIf given, the dialog will get an "do not show again" checkbox
msgThe question.
Returns
True if the answer was "Yes"

Definition at line 250 of file AW_question.cxx.

References aw_question(), and NULp.

Referenced by ALI_translate_marked(), aw_status_kill(), aw_window_destroy_cb(), continue_with_namesDat_destruction(), delete_ali_cb(), delete_queried_species_cb(), experiment_delete_cb(), gene_delete_cb(), nt_delete_database(), NT_delete_mark_all_cb(), pars_start_cb(), pd_kill_pt_server(), SEC_delete_structure(), species_delete_cb(), and species_rename_handler().

void aw_popup_ok ( const char msg)

Pop up a modal message with an Ok button

Parameters
msgThe message.

Definition at line 260 of file AW_question.cxx.

References aw_question(), and NULp.

Referenced by ARB_main(), ED4_root::create_hierarchy(), nt_intro_start_existing(), and startup_gui().

void aw_popup_exit ( const char msg)

Pop up a modal message with an Exit button. Won't return but exit with "EXIT_FAILURE"

Definition at line 268 of file AW_question.cxx.

References aw_assert, aw_question(), EXIT_FAILURE, and NULp.

Referenced by ARB_main(), pars_generate_aliview(), pars_start_cb(), and PARS_tree_init().

void AW_reactivate_all_questions ( AW_window )