private void textBox1_Leave(object sender, System.EventArgs e) { try { WhiteboardMessage msg=new WhiteboardMessage(); msg.ConferenceID = NetworkManager.thisInstance.profile.ConferenceID ; msg.start=this.textBox1.Location;//mouseDownPos; msg.end=this.textBox1.Location; msg.tool=(ushort)WhiteboardToolCode.Text;//tool; msg.c=this.color; msg.font=this.localCopyOfFont; msg.thickness=this.lineThickness; msg.text=this.textBox1.Text; this.eventStore.Add(msg); msg.txtSize = localCopyOfFont.Size; msg.txtItalics = localCopyOfFont.Italic; msg.txtBold = localCopyOfFont.Bold; msg.txtUnderline = localCopyOfFont.Underline; msg.FontFamily = localCopyOfFont.Name; NetworkManager network = NetworkManager.getInstance(); msg.SenderID = NetworkManager.getInstance().profile.ClientId;; msg.nSessionId = nSessionId; if(IsAppSharingWindow) msg.MessageType = (ushort) ((int)MessageObjectType.MsgAppSharingAnnotation); sendingArrayList.Add(msg); network.SendLoadPacket(msg); this.textBox1.Text=""; this.tool=WhiteboardToolCode.None; } catch(Exception ex) { ClientUI.getInstance().ShowExceptionMessage("Module ::: whiteboard private void textBox1_Leave(object sender, System.EventArgs e)",ex,"",false); //Trace.WriteLine("private void textBox1_Leave(object sender, System.EventArgs e)"+" exception string :::: "+ex.ToString()+" stack trace ::: " +ex.StackTrace+" Message ::: " +ex.Message); } }
public WhiteboardControl() { // This call is required by the Windows.Forms Form Designer. try { SelfFont=new FontStyle(); SelfFont=SelfFont|FontStyle.Bold; localCopyOfFont = new Font(this.Font.FontFamily,this.Font.Size,SelfFont); constFont=new FontStyle(); constFont=constFont|FontStyle.Bold; constmyFont = new Font(this.Font.FontFamily,this.Font.Size,constFont); InitializeComponent(); this.BackColor=Color.White; tool=WhiteboardToolCode.None;//.Brush;//.Ellipse;//Rectangle;//.Line; color=Color.Black; mouseDownPos=new Point(0,0); mouseCurrentPos=new Point(0,0); brushThickness=10; eventStore=new ArrayList(); pencilLastPoint=new Point(-1,-1); eraser=new Rectangle(0,0,10,10); msg=new WhiteboardMessage(); m_bDummyRect=new Rectangle(0,0,0,0); zoomLevel=1; ZoomView=false; undoArray=new ArrayList(); redoArray=new ArrayList(); filename=""; lineThickness=4; pA.nWidth = 10; pA.fTheta = 0.3f; pA.bFill = true; m_bIsActive = true; sendingThread = new Thread(new ThreadStart(SendingThreadFunction)); sendingThread.Name = "Whiteboard Control Constructor Thread: SendingThreadFunction()"; sendingThread.Start(); CursorImage = WebMeeting.Client.ClientUI.getInstance().LoadImageFromResource("WebMeeting.Client.cur.gif"); } catch(Exception ex) { WebMeeting.Client.ClientUI.getInstance().ShowExceptionMessage("Module ::: WhiteBoard public WhiteboardControl() ",ex,"",false); //Trace.WriteLine("public WhiteboardControl()"+" exception string :::: "+ex.ToString()+" stack trace ::: " +ex.StackTrace+" Message ::: " +ex.Message); } }
public void ZoomOut() { try { zoomLevel=(float)Math.Max((float)(zoomLevel/1.5) , .19753); ZoomView=true; this.tool=WhiteboardToolCode.None; this.AutoScrollMinSize = new Size ((int)(this.mainImage.Width * this.zoomLevel), (int)(this.mainImage.Height * this.zoomLevel)); Invalidate(); } catch(Exception ex) { ClientUI.getInstance().ShowExceptionMessage("Module ::: whiteboard public void ZoomOut() ",ex,"",false); //Trace.WriteLine("public void ZoomOut()"+" exception string :::: "+ex.ToString()+" stack trace ::: " +ex.StackTrace+" Message ::: " +ex.Message); } }
private void textBox1_KeyUp(object sender, System.Windows.Forms.KeyEventArgs e) { try { if(e.KeyCode == System.Windows.Forms.Keys.Enter) { textBox1_Leave(this,new System.EventArgs()); this.tool=WhiteboardToolCode.Text; //this.Refresh(); textBox1.Visible = false; } if(e.KeyCode==System.Windows.Forms.Keys.Escape) { textBox1.Text=""; this.tool=WhiteboardToolCode.None; textBox1.Visible = false; } } catch(Exception ex) { WebMeeting.Client.ClientUI.getInstance().ShowExceptionMessage("Module ::: WebSharing private void textBox1_KeyUp(object sender, System.Windows.Forms.KeyEventArgs e)",ex,"",false); } }
public IEHwd() { try { msgGlobalPencilMessage = new WhiteboardMessage(); /*if(NetworkManager.getInstance().profile.clientType== ClientType.ClientAttendee) // for restricting attendees { Trace.WriteLine("attendee"); tool=WhiteboardToolCode.None; } else */ { //Trace.WriteLine("presenter"); tool=WhiteboardToolCode.Line;//.Brush;//.Ellipse;//Rectangle;//.Line; } CursorImage = WebMeeting.Client.ClientUI.getInstance().LoadImageFromResource("WebMeeting.Client.cur.gif"); //tool=WhiteboardToolCode.Line;//.Brush;//.Ellipse;//Rectangle;//.Line; color=Color.Red; mouseDownPos=new Point(0,0); mouseCurrentPos=new Point(0,0); brushThickness=10; eventStore=new ArrayList(); pencilLastPoint=new Point(-1,-1); eraser=new Rectangle(0,0,10,10); msg=new WhiteboardMessage(); m_bDummyRect=new Rectangle(0,0,0,0); undoArray=new ArrayList(); redoArray=new ArrayList(); //filename=""; lineThickness=4; pA.nWidth = 10; pA.fTheta = 0.3f; pA.bFill = true; recieveThread = new Thread(new ThreadStart(ConsumeThread)); sendingThread = new Thread(new ThreadStart(sendFunction)); sendingThread.Name="IE ControlHook Constructor: sendFunction()"; sendingThread.Start(); m_bIsActive =true; recieveThread.Name="IE ControlHook Constructor: ConsumeThread()"; recieveThread.Start(); textBox1 = new TextBox(); textBox1.Visible = false; //this.textBox1.Leave += new System.EventHandler(this.textBox1_Leave); this.textBox1.KeyUp += new System.Windows.Forms.KeyEventHandler(this.textBox1_KeyUp); this.textBox1.TextChanged += new EventHandler(textBox1_TextChanged); } catch(Exception ex) { WebMeeting.Client.ClientUI.getInstance().ShowExceptionMessage("Module ::: WebSharing public IEHwd()",ex,"",false); } }
public void selectToolNone() { try { this.tool=WhiteboardToolCode.None; } catch(Exception ex) { WebMeeting.Client.ClientUI.getInstance().ShowExceptionMessage("Module ::: WebSharing public void selectToolNone()",ex,"",false); } }