1 /**
2 * Whiteboard connection establishment dialog
3 *
4 * Authors:
5 * David Yip <yipdw@rose-hulman.edu>
6 * Jason Segal, Jonas Collaros, Stephen Montgomery, Brandi Soggs, Matthew Weinstock (original C/Gtk version)
7 *
8 * Copyright (c) 2004-2005 Authors
9 *
10 * Released under GNU GPL, read the file 'COPYING' for more information
11 */
13 #ifndef __WHITEBOARD_CONNECT_DIALOG_H__
14 #define __WHITEBOARD_CONNECT_DIALOG_H__
16 #include "verbs.h"
17 #include "dialog.h"
19 struct SPDesktop;
21 namespace Inkscape {
23 namespace Whiteboard {
25 class SessionManager;
27 }
29 namespace UI {
31 namespace Dialog {
33 class WhiteboardConnectDialog : public Dialog {
34 public:
35 WhiteboardConnectDialog() : Dialog("dialogs.whiteboard_connect", SP_VERB_DIALOG_WHITEBOARD_CONNECT)
36 {
38 }
40 static WhiteboardConnectDialog* create();
42 virtual ~WhiteboardConnectDialog()
43 {
45 }
46 };
48 class WhiteboardConnectDialogImpl : public WhiteboardConnectDialog {
49 public:
50 WhiteboardConnectDialogImpl();
51 ~WhiteboardConnectDialogImpl();
52 void present();
53 void setSessionManager();
55 private:
56 // GTK+ widgets
57 Gtk::Table _layout;
58 Gtk::HBox _buttons;
60 Gtk::Entry _server;
61 Gtk::Entry _username;
62 Gtk::Entry _password;
63 Gtk::Entry _port;
65 Gtk::Label _labels[4];
67 Gtk::CheckButton _usessl;
69 Gtk::Button _ok, _cancel;
71 // Construction and callbacks
72 void _construct();
73 void _respCallback(int resp);
74 void _useSSLClickedCallback();
76 // SessionManager and SPDesktop pointers
77 ::SPDesktop* _desktop;
78 Whiteboard::SessionManager* _sm;
79 };
82 }
84 }
86 }
88 #endif