diff options
author | Mike Buland <eichlan@xagasoft.com> | 2011-05-17 04:18:13 +0000 |
---|---|---|
committer | Mike Buland <eichlan@xagasoft.com> | 2011-05-17 04:18:13 +0000 |
commit | 6aefa6632023c99c5b91bae0e099df94fa69d890 (patch) | |
tree | 6ac83b347cc70dca827c887f0046924dabec042d /src/gatscon/mainwnd.cpp | |
parent | efcbdb7a0347b4399cbabacf3cbea432eeafb17b (diff) | |
download | libgats-6aefa6632023c99c5b91bae0e099df94fa69d890.tar.gz libgats-6aefa6632023c99c5b91bae0e099df94fa69d890.tar.bz2 libgats-6aefa6632023c99c5b91bae0e099df94fa69d890.tar.xz libgats-6aefa6632023c99c5b91bae0e099df94fa69d890.zip |
GatsCon now supports proxying, and way better than qtbenc ever did. Not only
does it proxy, but you can inject your own messages going to the client or host.
Pretty slick, really. Next up, reading and creating files.
Diffstat (limited to 'src/gatscon/mainwnd.cpp')
-rw-r--r-- | src/gatscon/mainwnd.cpp | 25 |
1 files changed, 24 insertions, 1 deletions
diff --git a/src/gatscon/mainwnd.cpp b/src/gatscon/mainwnd.cpp index c86e1c2..f20a531 100644 --- a/src/gatscon/mainwnd.cpp +++ b/src/gatscon/mainwnd.cpp | |||
@@ -1,5 +1,10 @@ | |||
1 | #include "mainwnd.h" | 1 | #include "mainwnd.h" |
2 | |||
2 | #include "clientwidget.h" | 3 | #include "clientwidget.h" |
4 | #include "proxywidget.h" | ||
5 | |||
6 | #include "connectdlg.h" | ||
7 | #include "setupproxydlg.h" | ||
3 | 8 | ||
4 | MainWnd::MainWnd() | 9 | MainWnd::MainWnd() |
5 | { | 10 | { |
@@ -12,11 +17,29 @@ MainWnd::~MainWnd() | |||
12 | 17 | ||
13 | void MainWnd::connect() | 18 | void MainWnd::connect() |
14 | { | 19 | { |
15 | setCentralWidget( new ClientWidget( this ) ); | 20 | ConnectDlg dlg( this ); |
21 | if( dlg.exec() == QDialog::Accepted ) | ||
22 | { | ||
23 | setCentralWidget( | ||
24 | new ClientWidget( | ||
25 | this, dlg.getHostname(), dlg.getPort() | ||
26 | ) | ||
27 | ); | ||
28 | } | ||
16 | } | 29 | } |
17 | 30 | ||
18 | void MainWnd::proxy() | 31 | void MainWnd::proxy() |
19 | { | 32 | { |
33 | SetupProxyDlg dlg( this ); | ||
34 | |||
35 | if( dlg.exec() == QDialog::Accepted ) | ||
36 | { | ||
37 | setCentralWidget( | ||
38 | new ProxyWidget( | ||
39 | this, dlg.getPortIn(), dlg.getHostOut(), dlg.getPortOut() | ||
40 | ) | ||
41 | ); | ||
42 | } | ||
20 | } | 43 | } |
21 | 44 | ||
22 | void MainWnd::open() | 45 | void MainWnd::open() |