SidebarLibrary.WinControls.OutlookBar.RenameHeader C# (CSharp) Method

RenameHeader() private method

private RenameHeader ( ) : void
return void
		void RenameHeader()
		{
			// Display a edit control that will do the editing of the header
			// Get the item index first
			int index;
			HitTest(lastClickedPoint, out index, false);
			using ( Graphics g = Graphics.FromHwnd(Handle) )
			{
				Rectangle headerRect = GetHeaderRect(index);
				// Empty the text box first
				textBox.Text = "";
				textBox.Bounds = headerRect;
				// initialize the text box to the item text
				textBox.Text = bands[index].Text;
				// Flag that we are editing an header and not a item
				// --We'll use this on the textbox event handlers
				editingAnItem = false;
				textBox.Visible = true;
				textBox.Focus();
			}
		}