Initial options dialog (read-only) loosly based on the Unix vncviewer.


git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@4416 3789f03b-4d11-0410-bbf8-ca57d06f2519
diff --git a/vncviewer/ServerDialog.cxx b/vncviewer/ServerDialog.cxx
index fab1448..e65cbad 100644
--- a/vncviewer/ServerDialog.cxx
+++ b/vncviewer/ServerDialog.cxx
@@ -23,6 +23,8 @@
 #include <FL/fl_draw.H>
 
 #include "ServerDialog.h"
+#include "OptionsDialog.h"
+#include "fltk_layout.h"
 #include "i18n.h"
 
 extern void about_vncviewer();
@@ -33,8 +35,7 @@
   int width;
   Fl_Button *button;
 
-  fl_font(FL_HELVETICA, FL_NORMAL_SIZE);
-  width = fl_width(_("VNC server:"));
+  width = gui_str_len(_("VNC server:"));
   serverName = new Fl_Input(20 + width, 20, w() - 20*2 - width, 25, _("VNC server:"));
 
   width = (w() - 20) / 4;
@@ -42,6 +43,9 @@
   button = new Fl_Button(20 + width*0, 20+25+20, width - 20, 27, _("About..."));
   button->callback(this->handleAbout, this);
 
+  button = new Fl_Button(20 + width*1, 20+25+20, width - 20, 27, _("Options..."));
+  button->callback(this->handleOptions, this);
+
   button = new Fl_Button(20 + width*2, 20+25+20, width - 20, 27, _("Cancel"));
   button->callback(this->handleCancel, this);
 
@@ -83,6 +87,12 @@
 }
 
 
+void ServerDialog::handleOptions(Fl_Widget *widget, void *data)
+{
+  OptionsDialog::showDialog();
+}
+
+
 void ServerDialog::handleCancel(Fl_Widget *widget, void *data)
 {
   ServerDialog *dialog = (ServerDialog*)data;