Subversion Repositories general

Compare Revisions

Ignore whitespace Rev 1199 → Rev 1200

/TCPproxy/trunk/MainForm.cs
17,7 → 17,7
// - set locks and check exceptions during log writing (?)
namespace TCPproxy
{
public class MainForm : System.Windows.Forms.Form
public class MainForm : Form
{
#region constants and settings
 
50,17 → 50,17
 
#region web forms fields
private System.ComponentModel.IContainer components;
private System.Windows.Forms.SaveFileDialog saveLogDialog;
private System.Windows.Forms.StatusBarPanel connectionStatusBar;
private System.Windows.Forms.MenuItem selectAllmenuItem;
private System.Windows.Forms.MenuItem copyMenuItem;
private System.Windows.Forms.ContextMenu viewContextMenu;
private System.Windows.Forms.MenuItem closeConnectionMenuItem;
private System.Windows.Forms.ImageList saveButtonImageList;
private System.Windows.Forms.StatusBar statusBar;
private System.Windows.Forms.ContextMenu messagesContextMenu;
private System.Windows.Forms.ImageList treeImageList;
private System.Windows.Forms.MenuItem wordWrapMenuItem;
private SaveFileDialog saveLogDialog;
private StatusBarPanel connectionStatusBar;
private MenuItem selectAllmenuItem;
private MenuItem copyMenuItem;
private ContextMenu viewContextMenu;
private MenuItem closeConnectionMenuItem;
private ImageList saveButtonImageList;
private StatusBar statusBar;
private ContextMenu messagesContextMenu;
private ImageList treeImageList;
private MenuItem wordWrapMenuItem;
private MainMenu mainMenu;
private MenuItem fileMenu;
private MenuItem loadBinLogMenuItem;
111,57 → 111,57
private void InitializeComponent() {
this.components = new System.ComponentModel.Container();
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(MainForm));
this.wordWrapMenuItem = new System.Windows.Forms.MenuItem();
this.treeImageList = new System.Windows.Forms.ImageList(this.components);
this.messagesContextMenu = new System.Windows.Forms.ContextMenu();
this.selectAllmenuItem = new System.Windows.Forms.MenuItem();
this.copyMenuItem = new System.Windows.Forms.MenuItem();
this.statusBar = new System.Windows.Forms.StatusBar();
this.connectionStatusBar = new System.Windows.Forms.StatusBarPanel();
this.saveButtonImageList = new System.Windows.Forms.ImageList(this.components);
this.closeConnectionMenuItem = new System.Windows.Forms.MenuItem();
this.viewContextMenu = new System.Windows.Forms.ContextMenu();
this.saveLogDialog = new System.Windows.Forms.SaveFileDialog();
this.mainMenu = new System.Windows.Forms.MainMenu(this.components);
this.fileMenu = new System.Windows.Forms.MenuItem();
this.startMenuItem = new System.Windows.Forms.MenuItem();
this.stopMenuItem = new System.Windows.Forms.MenuItem();
this.recentListeningMenu = new System.Windows.Forms.MenuItem();
this.recentListeningNoItem = new System.Windows.Forms.MenuItem();
this.menuSeparator5 = new System.Windows.Forms.MenuItem();
this.loadBinLogMenuItem = new System.Windows.Forms.MenuItem();
this.saveBinLogMenuItem = new System.Windows.Forms.MenuItem();
this.menuSeparator1 = new System.Windows.Forms.MenuItem();
this.saveFullLogMenuItem = new System.Windows.Forms.MenuItem();
this.saveTcoLogMenuItem = new System.Windows.Forms.MenuItem();
this.saveHttpLogMenuItem = new System.Windows.Forms.MenuItem();
this.saveXmlLogMenuItem = new System.Windows.Forms.MenuItem();
this.menuSeparator2 = new System.Windows.Forms.MenuItem();
this.exitMenuItem = new System.Windows.Forms.MenuItem();
this.viewMenu = new System.Windows.Forms.MenuItem();
this.clearMainMenuItem = new System.Windows.Forms.MenuItem();
this.messagesMenu = new System.Windows.Forms.MenuItem();
this.allMessagesMenuItem = new System.Windows.Forms.MenuItem();
this.infoMessagesMenuItem = new System.Windows.Forms.MenuItem();
this.importantMessagesMenuItem = new System.Windows.Forms.MenuItem();
this.menuSeparator3 = new System.Windows.Forms.MenuItem();
this.tcpShowByDirectionMenuItem = new System.Windows.Forms.MenuItem();
this.tcpShowByTimeMenuItem = new System.Windows.Forms.MenuItem();
this.menuSeparator4 = new System.Windows.Forms.MenuItem();
this.autoExpandMenuItem = new System.Windows.Forms.MenuItem();
this.wordWrapMainMenuItem = new System.Windows.Forms.MenuItem();
this.helpMenu = new System.Windows.Forms.MenuItem();
this.aboutMenuItem = new System.Windows.Forms.MenuItem();
this.panel1 = new System.Windows.Forms.Panel();
this.panel3 = new System.Windows.Forms.Panel();
this.panel4 = new System.Windows.Forms.Panel();
this.wordWrapMenuItem = new MenuItem();
this.treeImageList = new ImageList(this.components);
this.messagesContextMenu = new ContextMenu();
this.selectAllmenuItem = new MenuItem();
this.copyMenuItem = new MenuItem();
this.statusBar = new StatusBar();
this.connectionStatusBar = new StatusBarPanel();
this.saveButtonImageList = new ImageList(this.components);
this.closeConnectionMenuItem = new MenuItem();
this.viewContextMenu = new ContextMenu();
this.saveLogDialog = new SaveFileDialog();
this.mainMenu = new MainMenu(this.components);
this.fileMenu = new MenuItem();
this.startMenuItem = new MenuItem();
this.stopMenuItem = new MenuItem();
this.recentListeningMenu = new MenuItem();
this.recentListeningNoItem = new MenuItem();
this.menuSeparator5 = new MenuItem();
this.loadBinLogMenuItem = new MenuItem();
this.saveBinLogMenuItem = new MenuItem();
this.menuSeparator1 = new MenuItem();
this.saveFullLogMenuItem = new MenuItem();
this.saveTcoLogMenuItem = new MenuItem();
this.saveHttpLogMenuItem = new MenuItem();
this.saveXmlLogMenuItem = new MenuItem();
this.menuSeparator2 = new MenuItem();
this.exitMenuItem = new MenuItem();
this.viewMenu = new MenuItem();
this.clearMainMenuItem = new MenuItem();
this.messagesMenu = new MenuItem();
this.allMessagesMenuItem = new MenuItem();
this.infoMessagesMenuItem = new MenuItem();
this.importantMessagesMenuItem = new MenuItem();
this.menuSeparator3 = new MenuItem();
this.tcpShowByDirectionMenuItem = new MenuItem();
this.tcpShowByTimeMenuItem = new MenuItem();
this.menuSeparator4 = new MenuItem();
this.autoExpandMenuItem = new MenuItem();
this.wordWrapMainMenuItem = new MenuItem();
this.helpMenu = new MenuItem();
this.aboutMenuItem = new MenuItem();
this.panel1 = new Panel();
this.panel3 = new Panel();
this.panel4 = new Panel();
this.messagesBox = new TCPproxy.ViewControl();
this.splitter2 = new System.Windows.Forms.Splitter();
this.logBox = new System.Windows.Forms.ListBox();
this.splitter1 = new System.Windows.Forms.Splitter();
this.messageView = new System.Windows.Forms.TreeView();
this.saveBinLogDialog = new System.Windows.Forms.SaveFileDialog();
this.loadBinLogDialog = new System.Windows.Forms.OpenFileDialog();
this.splitter2 = new Splitter();
this.logBox = new ListBox();
this.splitter1 = new Splitter();
this.messageView = new TreeView();
this.saveBinLogDialog = new SaveFileDialog();
this.loadBinLogDialog = new OpenFileDialog();
((System.ComponentModel.ISupportInitialize)(this.connectionStatusBar)).BeginInit();
this.panel1.SuspendLayout();
this.panel3.SuspendLayout();
176,7 → 176,7
//
// treeImageList
//
this.treeImageList.ImageStream = ((System.Windows.Forms.ImageListStreamer)(resources.GetObject("treeImageList.ImageStream")));
this.treeImageList.ImageStream = ((ImageListStreamer)(resources.GetObject("treeImageList.ImageStream")));
this.treeImageList.TransparentColor = System.Drawing.Color.Magenta;
this.treeImageList.Images.SetKeyName(0, "");
this.treeImageList.Images.SetKeyName(1, "");
184,7 → 184,7
//
// messagesContextMenu
//
this.messagesContextMenu.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] {
this.messagesContextMenu.MenuItems.AddRange(new MenuItem[] {
this.selectAllmenuItem,
this.copyMenuItem,
this.wordWrapMenuItem});
192,7 → 192,7
// selectAllmenuItem
//
this.selectAllmenuItem.Index = 0;
this.selectAllmenuItem.Shortcut = System.Windows.Forms.Shortcut.CtrlA;
this.selectAllmenuItem.Shortcut = Shortcut.CtrlA;
this.selectAllmenuItem.Text = "Select &All";
this.selectAllmenuItem.Click += new System.EventHandler(this.selectAllMenuItem_Click);
//
199,7 → 199,7
// copyMenuItem
//
this.copyMenuItem.Index = 1;
this.copyMenuItem.Shortcut = System.Windows.Forms.Shortcut.CtrlC;
this.copyMenuItem.Shortcut = Shortcut.CtrlC;
this.copyMenuItem.Text = "&Copy";
this.copyMenuItem.Click += new System.EventHandler(this.copyMenuItem_Click);
//
207,7 → 207,7
//
this.statusBar.Location = new System.Drawing.Point(0, 359);
this.statusBar.Name = "statusBar";
this.statusBar.Panels.AddRange(new System.Windows.Forms.StatusBarPanel[] {
this.statusBar.Panels.AddRange(new StatusBarPanel[] {
this.connectionStatusBar});
this.statusBar.ShowPanels = true;
this.statusBar.Size = new System.Drawing.Size(780, 22);
215,13 → 215,13
//
// connectionStatusBar
//
this.connectionStatusBar.AutoSize = System.Windows.Forms.StatusBarPanelAutoSize.Spring;
this.connectionStatusBar.AutoSize = StatusBarPanelAutoSize.Spring;
this.connectionStatusBar.Name = "connectionStatusBar";
this.connectionStatusBar.Width = 764;
//
// saveButtonImageList
//
this.saveButtonImageList.ImageStream = ((System.Windows.Forms.ImageListStreamer)(resources.GetObject("saveButtonImageList.ImageStream")));
this.saveButtonImageList.ImageStream = ((ImageListStreamer)(resources.GetObject("saveButtonImageList.ImageStream")));
this.saveButtonImageList.TransparentColor = System.Drawing.Color.Magenta;
this.saveButtonImageList.Images.SetKeyName(0, "");
//
233,7 → 233,7
//
// viewContextMenu
//
this.viewContextMenu.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] {
this.viewContextMenu.MenuItems.AddRange(new MenuItem[] {
this.closeConnectionMenuItem});
//
// saveLogDialog
244,7 → 244,7
//
// mainMenu
//
this.mainMenu.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] {
this.mainMenu.MenuItems.AddRange(new MenuItem[] {
this.fileMenu,
this.viewMenu,
this.helpMenu});
252,7 → 252,7
// fileMenu
//
this.fileMenu.Index = 0;
this.fileMenu.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] {
this.fileMenu.MenuItems.AddRange(new MenuItem[] {
this.startMenuItem,
this.stopMenuItem,
this.recentListeningMenu,
284,7 → 284,7
// recentListeningMenu
//
this.recentListeningMenu.Index = 2;
this.recentListeningMenu.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] {
this.recentListeningMenu.MenuItems.AddRange(new MenuItem[] {
this.recentListeningNoItem});
this.recentListeningMenu.Text = "&Recent Listenings";
//
353,7 → 353,7
// viewMenu
//
this.viewMenu.Index = 1;
this.viewMenu.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] {
this.viewMenu.MenuItems.AddRange(new MenuItem[] {
this.clearMainMenuItem,
this.messagesMenu,
this.menuSeparator3,
373,7 → 373,7
// messagesMenu
//
this.messagesMenu.Index = 1;
this.messagesMenu.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] {
this.messagesMenu.MenuItems.AddRange(new MenuItem[] {
this.allMessagesMenuItem,
this.infoMessagesMenuItem,
this.importantMessagesMenuItem});
436,7 → 436,7
// helpMenu
//
this.helpMenu.Index = 2;
this.helpMenu.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] {
this.helpMenu.MenuItems.AddRange(new MenuItem[] {
this.aboutMenuItem});
this.helpMenu.Text = "&Help";
//
449,7 → 449,7
// panel1
//
this.panel1.Controls.Add(this.panel3);
this.panel1.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel1.Dock = DockStyle.Fill;
this.panel1.Location = new System.Drawing.Point(0, 0);
this.panel1.Name = "panel1";
this.panel1.Size = new System.Drawing.Size(780, 359);
460,7 → 460,7
this.panel3.Controls.Add(this.panel4);
this.panel3.Controls.Add(this.splitter1);
this.panel3.Controls.Add(this.messageView);
this.panel3.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel3.Dock = DockStyle.Fill;
this.panel3.Location = new System.Drawing.Point(0, 0);
this.panel3.Name = "panel3";
this.panel3.Size = new System.Drawing.Size(780, 359);
471,7 → 471,7
this.panel4.Controls.Add(this.messagesBox);
this.panel4.Controls.Add(this.splitter2);
this.panel4.Controls.Add(this.logBox);
this.panel4.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel4.Dock = DockStyle.Fill;
this.panel4.Location = new System.Drawing.Point(163, 0);
this.panel4.Name = "panel4";
this.panel4.Size = new System.Drawing.Size(617, 359);
480,7 → 480,7
// messagesBox
//
this.messagesBox.ContextMenu = this.messagesContextMenu;
this.messagesBox.Dock = System.Windows.Forms.DockStyle.Fill;
this.messagesBox.Dock = DockStyle.Fill;
this.messagesBox.Font = new System.Drawing.Font("Courier New", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.messagesBox.Location = new System.Drawing.Point(0, 0);
this.messagesBox.Name = "messagesBox";
490,7 → 490,7
//
// splitter2
//
this.splitter2.Dock = System.Windows.Forms.DockStyle.Bottom;
this.splitter2.Dock = DockStyle.Bottom;
this.splitter2.Location = new System.Drawing.Point(0, 288);
this.splitter2.Name = "splitter2";
this.splitter2.Size = new System.Drawing.Size(617, 3);
499,7 → 499,7
//
// logBox
//
this.logBox.Dock = System.Windows.Forms.DockStyle.Bottom;
this.logBox.Dock = DockStyle.Bottom;
this.logBox.Font = new System.Drawing.Font("Courier New", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.logBox.HorizontalScrollbar = true;
this.logBox.ItemHeight = 16;
520,7 → 520,7
// messageView
//
this.messageView.ContextMenu = this.viewContextMenu;
this.messageView.Dock = System.Windows.Forms.DockStyle.Left;
this.messageView.Dock = DockStyle.Left;
this.messageView.HideSelection = false;
this.messageView.ImageIndex = 0;
this.messageView.ImageList = this.treeImageList;
529,8 → 529,8
this.messageView.SelectedImageIndex = 0;
this.messageView.Size = new System.Drawing.Size(160, 359);
this.messageView.TabIndex = 11;
this.messageView.AfterSelect += new System.Windows.Forms.TreeViewEventHandler(this.messageView_AfterSelect);
this.messageView.BeforeSelect += new System.Windows.Forms.TreeViewCancelEventHandler(this.messageView_BeforeSelect);
this.messageView.AfterSelect += new TreeViewEventHandler(this.messageView_AfterSelect);
this.messageView.BeforeSelect += new TreeViewCancelEventHandler(this.messageView_BeforeSelect);
//
// saveBinLogDialog
//
553,7 → 553,7
this.Menu = this.mainMenu;
this.MinimumSize = new System.Drawing.Size(400, 200);
this.Name = "MainForm";
this.StartPosition = System.Windows.Forms.FormStartPosition.Manual;
this.StartPosition = FormStartPosition.Manual;
this.Text = "TCPproxy";
((System.ComponentModel.ISupportInitialize)(this.connectionStatusBar)).EndInit();
this.panel1.ResumeLayout(false);
670,7 → 670,7
(new AboutForm()).ShowDialog(this);
}
 
private void messageView_BeforeSelect(object sender, System.Windows.Forms.TreeViewCancelEventArgs e)
private void messageView_BeforeSelect(object sender, TreeViewCancelEventArgs e)
{
if(messageView.SelectedNode == null) return;
 
682,7 → 682,7
}
}
 
private void messageView_AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e)
private void messageView_AfterSelect(object sender, TreeViewEventArgs e)
{
if(messageView.SelectedNode == null) return;
 
/TCPproxy/trunk/AboutForm.cs
10,14 → 10,14
public class AboutForm : Form
{
private System.ComponentModel.IContainer components = null;
private System.Windows.Forms.Label appLabel;
private System.Windows.Forms.Label copyrightLabel;
private System.Windows.Forms.Label license1Label;
private System.Windows.Forms.Button okButton;
private System.Windows.Forms.LinkLabel homePageLabel;
private System.Windows.Forms.Label versionLabel;
private System.Windows.Forms.Label license2Label;
private System.Windows.Forms.Label warrantyLabel;
private Label appLabel;
private Label copyrightLabel;
private Label license1Label;
private Button okButton;
private LinkLabel homePageLabel;
private Label versionLabel;
private Label license2Label;
private Label warrantyLabel;
 
#region Windows Form Designer generated code
 
27,14 → 27,14
/// </summary>
private void InitializeComponent()
{
this.appLabel = new System.Windows.Forms.Label();
this.copyrightLabel = new System.Windows.Forms.Label();
this.license1Label = new System.Windows.Forms.Label();
this.okButton = new System.Windows.Forms.Button();
this.homePageLabel = new System.Windows.Forms.LinkLabel();
this.versionLabel = new System.Windows.Forms.Label();
this.license2Label = new System.Windows.Forms.Label();
this.warrantyLabel = new System.Windows.Forms.Label();
this.appLabel = new Label();
this.copyrightLabel = new Label();
this.license1Label = new Label();
this.okButton = new Button();
this.homePageLabel = new LinkLabel();
this.versionLabel = new Label();
this.license2Label = new Label();
this.warrantyLabel = new Label();
this.SuspendLayout();
//
// appLabel
67,8 → 67,8
//
// okButton
//
this.okButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.okButton.DialogResult = System.Windows.Forms.DialogResult.OK;
this.okButton.Anchor = ((AnchorStyles)((AnchorStyles.Bottom | AnchorStyles.Right)));
this.okButton.DialogResult = DialogResult.OK;
this.okButton.Location = new System.Drawing.Point(205, 217);
this.okButton.Name = "okButton";
this.okButton.Size = new System.Drawing.Size(75, 23);
84,7 → 84,7
this.homePageLabel.TabIndex = 4;
this.homePageLabel.TabStop = true;
this.homePageLabel.Text = "http://www.26th.net/public/projects/tcpproxy/";
this.homePageLabel.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.homePageLabel_LinkClicked);
this.homePageLabel.LinkClicked += new LinkLabelLinkClickedEventHandler(this.homePageLabel_LinkClicked);
//
// versionLabel
//
126,12 → 126,12
this.Controls.Add(this.license1Label);
this.Controls.Add(this.copyrightLabel);
this.Controls.Add(this.appLabel);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog;
this.FormBorderStyle = FormBorderStyle.FixedDialog;
this.MaximizeBox = false;
this.MinimizeBox = false;
this.Name = "AboutForm";
this.ShowInTaskbar = false;
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
this.StartPosition = FormStartPosition.CenterParent;
this.Text = "About TCPproxy";
this.ResumeLayout(false);
this.PerformLayout();
/TCPproxy/trunk/ListenForm.cs
19,13 → 19,13
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
private System.Windows.Forms.Button startButton;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.TextBox resendPortBox;
private System.Windows.Forms.TextBox resendHostBox;
private System.Windows.Forms.TextBox listenPortBox;
private System.Windows.Forms.Button cancelButton;
private Button startButton;
private Label label2;
private Label label1;
private TextBox resendPortBox;
private TextBox resendHostBox;
private TextBox listenPortBox;
private Button cancelButton;
 
#region Windows Form Designer generated code
 
35,13 → 35,13
/// </summary>
private void InitializeComponent()
{
this.startButton = new System.Windows.Forms.Button();
this.label2 = new System.Windows.Forms.Label();
this.label1 = new System.Windows.Forms.Label();
this.resendPortBox = new System.Windows.Forms.TextBox();
this.resendHostBox = new System.Windows.Forms.TextBox();
this.listenPortBox = new System.Windows.Forms.TextBox();
this.cancelButton = new System.Windows.Forms.Button();
this.startButton = new Button();
this.label2 = new Label();
this.label1 = new Label();
this.resendPortBox = new TextBox();
this.resendHostBox = new TextBox();
this.listenPortBox = new TextBox();
this.cancelButton = new Button();
this.SuspendLayout();
//
// startButton
94,7 → 94,7
//
// cancelButton
//
this.cancelButton.DialogResult = System.Windows.Forms.DialogResult.Cancel;
this.cancelButton.DialogResult = DialogResult.Cancel;
this.cancelButton.Location = new System.Drawing.Point(217, 62);
this.cancelButton.Name = "cancelButton";
this.cancelButton.Size = new System.Drawing.Size(75, 23);
113,12 → 113,12
this.Controls.Add(this.resendPortBox);
this.Controls.Add(this.resendHostBox);
this.Controls.Add(this.listenPortBox);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog;
this.FormBorderStyle = FormBorderStyle.FixedDialog;
this.MaximizeBox = false;
this.MinimizeBox = false;
this.Name = "ListenForm";
this.ShowInTaskbar = false;
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
this.StartPosition = FormStartPosition.CenterParent;
this.Text = "TCPproxy - Start Listening";
this.ResumeLayout(false);
this.PerformLayout();