// generated by Fast Light User Interface Designer (fluid) version 1.0308

#include "NSM_Proxy_UI.H"

Fl_Menu_Item NSM_Proxy_UI::menu_save_signal_choice[] = {
 {"None", 0,  0, 0, 0, (uchar)FL_NORMAL_LABEL, 0, 14, 0},
 {"SIGUSR1", 0,  0, 0, 0, (uchar)FL_NORMAL_LABEL, 0, 14, 0},
 {"SIGUSR2", 0,  0, 0, 0, (uchar)FL_NORMAL_LABEL, 0, 14, 0},
 {"SIGINT", 0,  0, 0, 0, (uchar)FL_NORMAL_LABEL, 0, 14, 0},
 {0,0,0,0,0,0,0,0,0}
};

Fl_Menu_Item NSM_Proxy_UI::menu_stop_signal_choice[] = {
 {"SIGTERM", 0,  0, 0, 0, (uchar)FL_NORMAL_LABEL, 0, 14, 0},
 {"SIGINT", 0,  0, 0, 0, (uchar)FL_NORMAL_LABEL, 0, 14, 0},
 {"SIGHUP", 0,  0, 0, 0, (uchar)FL_NORMAL_LABEL, 0, 14, 0},
 {0,0,0,0,0,0,0,0,0}
};

Fl_Double_Window* NSM_Proxy_UI::make_window() {
  Fl_Double_Window* w;
  { Fl_Double_Window* o = new Fl_Double_Window(675, 505, "NSM Proxy");
    w = o; if (w) {/* empty */}
    o->color(FL_DARK1);
    o->labelcolor((Fl_Color)55);
    o->user_data((void*)(this));
    { start_button = new Fl_Return_Button(285, 460, 88, 25, "Start");
    } // Fl_Return_Button* start_button
    { kill_button = new Fl_Button(150, 460, 80, 25, "Kill");
      kill_button->color(FL_DARK_RED);
      kill_button->hide();
    } // Fl_Button* kill_button
    { Fl_Tabs* o = new Fl_Tabs(0, 0, 678, 445);
      { Fl_Group* o = new Fl_Group(25, 46, 635, 359, "Run");
        { Fl_Box* o = new Fl_Box(28, 87, 612, 150, "NSM-Proxy handles clients without direct NSM support.\n            It should \
not be used to start real NSM clients.\n\nCommand-line options MUST go in the \
\"Arguments\" field.\n\n The program will be started with its current working \
directory being a uniquely named directory under the current session directory\
. It is recommended that you only refer to files as arguments in this director\
y to guarantee a transportable and archivable session.\n");
          o->box(FL_BORDER_BOX);
          o->color((Fl_Color)41);
          o->labelfont(8);
          o->labelsize(12);
          o->labelcolor((Fl_Color)55);
          o->align(Fl_Align(FL_ALIGN_WRAP));
        } // Fl_Box* o
        { arguments_input = new Fl_Input(170, 285, 345, 25, "Arguments:");
          arguments_input->tooltip("Command line parameter like --verbose");
        } // Fl_Input* arguments_input
        { label_input = new Fl_Input(170, 324, 345, 26, "NSM GUI Label:");
          label_input->tooltip("Will show in your NSM GUI, useful if you have multiple NSM-Proxy clients in o\
ne session");
        } // Fl_Input* label_input
        { executable_input = new Fl_Input(170, 249, 345, 26, "Executable Name:");
          executable_input->tooltip("The pure name of the executable. Just xterm not /usr/bin/xterm");
        } // Fl_Input* executable_input
        o->end();
      } // Fl_Group* o
      { Fl_Group* o = new Fl_Group(12, 31, 663, 414, "Advanced");
        o->hide();
        { save_signal_choice = new Fl_Choice(246, 400, 170, 25, "Save Signal:");
          save_signal_choice->down_box(FL_BORDER_BOX);
          save_signal_choice->menu(menu_save_signal_choice);
        } // Fl_Choice* save_signal_choice
        { Fl_Box* o = new Fl_Box(26, 46, 610, 84, "The environment variables $NSM_CLIENT_ID and $NSM_SESSION_NAME will contain t\
he unique client ID (suitable for use as e.g. a JACK client name) and the disp\
lay name for the session, respectively. The variable $CONFIG_FILE will contain\
 the name of the nsm-proxy config file.");
          o->box(FL_BORDER_BOX);
          o->color((Fl_Color)41);
          o->labelfont(8);
          o->labelsize(12);
          o->labelcolor((Fl_Color)55);
          o->align(Fl_Align(FL_ALIGN_WRAP));
        } // Fl_Box* o
        { Fl_Box* o = new Fl_Box(26, 306, 610, 79, "Very few programs may respond to a specific Unix signal by somehow saving the\
ir state. If \'Save Signal\' is set to something other than \'None\', then NSM\
 Proxy will deliver the specified signal to the proxied process upon an NSM \'\
Save\' event. Most programs will treat these signals just like SIGTERM and die\
. NSM-Proxy cannot force a program to save in our session directory.  ");
          o->box(FL_BORDER_BOX);
          o->color((Fl_Color)41);
          o->labelfont(8);
          o->labelsize(12);
          o->labelcolor((Fl_Color)55);
          o->align(Fl_Align(FL_ALIGN_WRAP));
        } // Fl_Box* o
        { stop_signal_choice = new Fl_Choice(246, 255, 170, 25, "Stop Signal:");
          stop_signal_choice->down_box(FL_BORDER_BOX);
          stop_signal_choice->menu(menu_stop_signal_choice);
        } // Fl_Choice* stop_signal_choice
        { Fl_Box* o = new Fl_Box(26, 166, 610, 79, "Most programs will shutdown gracefully when sent a SIGTERM or SIGINT signal. \
It\'s impossible to know which signal a specific program will respond to. A un\
handled signal will simply kill the process, and may cause problems with the a\
udio subsystem (e.g. JACK). Check the program\'s documentation or source code \
to determine which signal to use to stop it gracefully.");
          o->box(FL_BORDER_BOX);
          o->color((Fl_Color)41);
          o->labelfont(8);
          o->labelsize(12);
          o->labelcolor((Fl_Color)55);
          o->align(Fl_Align(FL_ALIGN_WRAP));
        } // Fl_Box* o
        { config_file_input = new Fl_File_Input(158, 409, 406, 31, "(Hidden!) Config File:");
          config_file_input->hide();
        } // Fl_File_Input* config_file_input
        { config_file_browse_button = new Fl_Button(573, 410, 85, 25, "Browse");
          config_file_browse_button->hide();
        } // Fl_Button* config_file_browse_button
        o->end();
      } // Fl_Group* o
      o->end();
    } // Fl_Tabs* o
    o->xclass("NSM-Proxy");
    o->end();
  } // Fl_Double_Window* o
  return w;
}
