1 #ifndef _MUSSA_GUI_LOAD_WINDOW_H_
2 #define _MUSSA_GUI_LOAD_WINDOW_H_
4 // This file is part of the Mussa source distribution.
5 // http://mussa.caltech.edu/
6 // Contact author: Tristan De Buysscher, tristan@caltech.edu
8 // This program and all associated source code files are Copyright (C) 2005
9 // the California Institute of Technology, Pasadena, CA, 91125 USA. It is
10 // under the GNU Public License; please see the included LICENSE.txt
11 // file for more information, or contact Tristan directly.
13 #include <FL/Fl_Button.H>
14 #include <FL/Fl_Input.H>
15 #include <FL/Fl_Scroll.H>
16 #include <FL/Fl_Window.H>
18 #include "mussa_class.hh"
19 #include "mussa_gui_load_window.hh"
21 class SetupWindow : public Fl_Window
24 SetupWindow(int w, int h, const char* title, Mussa *an_analysis);
29 //did I put these in public for a reason?
33 Fl_Input *thres_input;
34 Fl_Input *seq_num_input;
35 Fl_Scroll *seq_scroll;
36 // need to keep track of these so a browsed file search can set the input
37 // fields to teh selected file
38 std::vector<Fl_Input*> seq_inputs, annot_inputs;
41 // callback receiver functions
43 void real_do_analysis();
45 void real_set_ana_name_cb(Fl_Input* o);
46 void real_set_win_size_cb(Fl_Input* o);
47 void real_set_threshold_cb(Fl_Input* o);
48 void real_set_seq_num_cb(Fl_Input* o);
50 void real_seq_file_in_cb(Fl_Input* o, int i);
51 void real_choose_seq_file_cb(int i);
52 void real_annot_file_in_cb(Fl_Input* o, int i);
53 void real_choose_annot_file_cb(int i);
55 void real_fa_index_in_cb(Fl_Input* o, int i);
56 void real_sub_start_in_cb(Fl_Input* o, int i);
57 void real_sub_end_in_cb(Fl_Input* o, int i);
62 int window, threshold, seq_num;
63 std::vector<std::string> seq_files, annot_files;
64 std::vector<int> fasta_indices, sub_seq_starts, sub_seq_ends;
65 bool win_append, thres_append;
68 static void print_cb(Fl_Button*, void*);
69 inline void print_cb_real(Fl_Button*, void*);
71 void add_seq_input(int index);
74 // crazy whacked shite Titus taught me to do to get an index value associated
75 // with each instance of an input associated with the callback...
77 struct seq_data_instance