private void InitializeComponent() { base.Size = new Size(472, 357); this.m_pToolbar = new ToolStrip(); this.m_pToolbar.GripStyle = ToolStripGripStyle.Hidden; this.m_pToolbar.BackColor = this.BackColor; this.m_pToolbar.Renderer = new ToolBarRendererEx(); this.m_pToolbar.ItemClicked += new ToolStripItemClickedEventHandler(this.m_pToolbar_ItemClicked); ToolStripButton toolStripButton = new ToolStripButton(); toolStripButton.Enabled = false; toolStripButton.Image = ResManager.GetIcon("delete.ico").ToBitmap(); toolStripButton.Tag = "delete"; toolStripButton.ToolTipText = "Delete"; this.m_pToolbar.Items.Add(toolStripButton); ToolStripButton toolStripButton2 = new ToolStripButton(); toolStripButton2.Image = ResManager.GetIcon("refresh.ico").ToBitmap(); toolStripButton2.Tag = "refresh"; toolStripButton2.ToolTipText = "Refresh"; this.m_pToolbar.Items.Add(toolStripButton2); this.m_pCalls = new WListView(); this.m_pCalls.Size = new Size(445, 265); this.m_pCalls.Location = new Point(9, 47); this.m_pCalls.Anchor = (AnchorStyles.Top | AnchorStyles.Bottom | AnchorStyles.Left | AnchorStyles.Right); this.m_pCalls.View = View.Details; this.m_pCalls.FullRowSelect = true; this.m_pCalls.HideSelection = false; this.m_pCalls.Columns.Add("Caller", 180, HorizontalAlignment.Left); this.m_pCalls.Columns.Add("Callee", 180, HorizontalAlignment.Left); this.m_pCalls.Columns.Add("Start Time", 80, HorizontalAlignment.Left); this.m_pCalls.SelectedIndexChanged += new EventHandler(this.m_pCalls_SelectedIndexChanged); base.Controls.Add(this.m_pCalls); }
void SetSelectionColor(WListView view) { if (view.SelectionColor != Color.Default) { Control.Selector = new ColorDrawable(view.SelectionColor.ToAndroid()); } }
void SetSelectionEnabled(WListView view) { if (!view.SelectionEnabled) { Control.Selector = new ColorDrawable(Android.Graphics.Color.Transparent); Control.CacheColorHint = Android.Graphics.Color.Transparent; Control.SoundEffectsEnabled = false; } }
private void InitializeComponent() { base.Size = new Size(472, 357); this.m_pToolbar = new ToolStrip(); this.m_pToolbar.GripStyle = ToolStripGripStyle.Hidden; this.m_pToolbar.BackColor = this.BackColor; this.m_pToolbar.Renderer = new ToolBarRendererEx(); this.m_pToolbar.ItemClicked += new ToolStripItemClickedEventHandler(this.m_pToolbar_ItemClicked); ToolStripButton toolStripButton = new ToolStripButton(); toolStripButton.Image = ResManager.GetIcon("add.ico").ToBitmap(); toolStripButton.Tag = "add"; toolStripButton.ToolTipText = "Add"; this.m_pToolbar.Items.Add(toolStripButton); ToolStripButton toolStripButton2 = new ToolStripButton(); toolStripButton2.Enabled = false; toolStripButton2.Image = ResManager.GetIcon("delete.ico").ToBitmap(); toolStripButton2.Tag = "delete"; toolStripButton2.ToolTipText = "Delete"; this.m_pToolbar.Items.Add(toolStripButton2); this.m_pToolbar.Items.Add(new ToolStripSeparator()); ToolStripButton toolStripButton3 = new ToolStripButton(); toolStripButton3.Image = ResManager.GetIcon("refresh.ico").ToBitmap(); toolStripButton3.Tag = "refresh"; toolStripButton3.ToolTipText = "Refresh"; this.m_pToolbar.Items.Add(toolStripButton3); ToolStripButton toolStripButton4 = new ToolStripButton(); toolStripButton4.Enabled = false; toolStripButton4.Image = ResManager.GetIcon("viewmessages.ico").ToBitmap(); toolStripButton4.Tag = "view"; toolStripButton4.ToolTipText = "View Contacts"; this.m_pToolbar.Items.Add(toolStripButton4); this.m_pRegistrations = new WListView(); this.m_pRegistrations.Size = new Size(445, 265); this.m_pRegistrations.Location = new Point(9, 47); this.m_pRegistrations.Anchor = (AnchorStyles.Top | AnchorStyles.Bottom | AnchorStyles.Left | AnchorStyles.Right); this.m_pRegistrations.View = View.Details; this.m_pRegistrations.FullRowSelect = true; this.m_pRegistrations.HideSelection = false; this.m_pRegistrations.Columns.Add("User", 120, HorizontalAlignment.Left); this.m_pRegistrations.Columns.Add("Address of Record", 360, HorizontalAlignment.Left); this.m_pRegistrations.SelectedIndexChanged += new EventHandler(this.m_pRegistrations_SelectedIndexChanged); this.m_pRegistrations.DoubleClick += new EventHandler(this.m_pRegistrations_DoubleClick); base.Controls.Add(this.m_pRegistrations); }
private void InitializeComponent() { base.ClientSize = new Size(692, 473); this.MinimumSize = new Size(700, 500); base.StartPosition = FormStartPosition.CenterScreen; this.Text = string.Concat(new string[] { "User '", this.m_pFolder.User.UserName, "' Folder '", this.m_pFolder.FolderFullPath, "' Messages" }); base.Icon = ResManager.GetIcon("message.ico"); this.m_pIcon = new PictureBox(); this.m_pIcon.Size = new Size(32, 32); this.m_pIcon.Location = new Point(10, 10); this.m_pIcon.Image = ResManager.GetIcon("message.ico").ToBitmap(); this.mt_Info = new Label(); this.mt_Info.Size = new Size(400, 32); this.mt_Info.Location = new Point(50, 10); this.mt_Info.TextAlign = ContentAlignment.MiddleLeft; this.mt_Info.Text = string.Concat(new string[] { "User '", this.m_pFolder.User.UserName, "' Folder '", this.m_pFolder.FolderFullPath, "' Messages" }); this.m_pSeparator1 = new GroupBox(); this.m_pSeparator1.Size = new Size(682, 3); this.m_pSeparator1.Location = new Point(7, 50); this.m_pSeparator1.Anchor = (AnchorStyles.Top | AnchorStyles.Left | AnchorStyles.Right); this.m_pToolbar = new ToolStrip(); this.m_pToolbar.AutoSize = false; this.m_pToolbar.Size = new Size(100, 25); this.m_pToolbar.Location = new Point(595, 55); this.m_pToolbar.Dock = DockStyle.None; this.m_pToolbar.Anchor = (AnchorStyles.Top | AnchorStyles.Right); this.m_pToolbar.GripStyle = ToolStripGripStyle.Hidden; this.m_pToolbar.BackColor = this.BackColor; this.m_pToolbar.Renderer = new ToolBarRendererEx(); this.m_pToolbar.ItemClicked += new ToolStripItemClickedEventHandler(this.m_pToolbar_ItemClicked); ToolStripButton toolStripButton = new ToolStripButton(); toolStripButton.Image = ResManager.GetIcon("refresh.ico").ToBitmap(); toolStripButton.Tag = "refresh"; toolStripButton.ToolTipText = "Refresh"; this.m_pToolbar.Items.Add(toolStripButton); ToolStripButton toolStripButton2 = new ToolStripButton(); toolStripButton2.Image = ResManager.GetIcon("write.ico").ToBitmap(); toolStripButton2.Tag = "write"; toolStripButton2.ToolTipText = "Write Message"; this.m_pToolbar.Items.Add(toolStripButton2); ToolStripButton toolStripButton3 = new ToolStripButton(); toolStripButton3.Image = ResManager.GetIcon("save.ico").ToBitmap(); toolStripButton3.Tag = "save"; toolStripButton3.Enabled = false; toolStripButton3.ToolTipText = "Save Message"; this.m_pToolbar.Items.Add(toolStripButton3); ToolStripButton toolStripButton4 = new ToolStripButton(); toolStripButton4.Image = ResManager.GetIcon("delete.ico").ToBitmap(); toolStripButton4.Tag = "delete"; toolStripButton4.Enabled = false; toolStripButton4.ToolTipText = "Delete Message"; this.m_pToolbar.Items.Add(toolStripButton4); ImageList imageList = new ImageList(); imageList.Images.Add(ResManager.GetIcon("message16.ico")); this.m_pMessages = new WListView(); this.m_pMessages.Size = new Size(682, 390); this.m_pMessages.Location = new Point(5, 80); this.m_pMessages.Anchor = (AnchorStyles.Top | AnchorStyles.Bottom | AnchorStyles.Left | AnchorStyles.Right); this.m_pMessages.View = View.Details; this.m_pMessages.FullRowSelect = true; this.m_pMessages.HideSelection = false; this.m_pMessages.SmallImageList = imageList; this.m_pMessages.Columns.Add("Subject", 250, HorizontalAlignment.Left); this.m_pMessages.Columns.Add("Sender", 170, HorizontalAlignment.Left); this.m_pMessages.Columns.Add("Date", 120, HorizontalAlignment.Left); this.m_pMessages.Columns.Add("Size KB", 60, HorizontalAlignment.Right); this.m_pMessages.SelectedIndexChanged += new EventHandler(this.m_pMessages_SelectedIndexChanged); base.Controls.Add(this.m_pIcon); base.Controls.Add(this.mt_Info); base.Controls.Add(this.m_pSeparator1); base.Controls.Add(this.m_pToolbar); base.Controls.Add(this.m_pMessages); }
private void InitializeComponent() { base.ClientSize = new Size(692, 473); this.MinimumSize = new Size(700, 500); base.StartPosition = FormStartPosition.CenterScreen; this.Text = "User '" + this.m_pUser.UserName + "' Recyclebin messages"; base.Icon = ResManager.GetIcon("recyclebin16.ico"); this.m_pIcon = new PictureBox(); this.m_pIcon.Size = new Size(32, 32); this.m_pIcon.Location = new Point(10, 10); this.m_pIcon.Image = ResManager.GetImage("icon-recycle.png"); this.mt_Info = new Label(); this.mt_Info.Size = new Size(400, 32); this.mt_Info.Location = new Point(50, 10); this.mt_Info.TextAlign = ContentAlignment.MiddleLeft; this.mt_Info.Text = "User '" + this.m_pUser.UserName + "' Recyclebin messages"; this.m_pSeparator1 = new GroupBox(); this.m_pSeparator1.Size = new Size(682, 3); this.m_pSeparator1.Location = new Point(7, 50); this.m_pSeparator1.Anchor = (AnchorStyles.Top | AnchorStyles.Left | AnchorStyles.Right); this.mt_Between = new Label(); this.mt_Between.Size = new Size(100, 20); this.mt_Between.Location = new Point(295, 57); this.mt_Between.Anchor = (AnchorStyles.Top | AnchorStyles.Right); this.mt_Between.TextAlign = ContentAlignment.MiddleRight; this.mt_Between.Text = "Between:"; this.m_pStartDate = new DateTimePicker(); this.m_pStartDate.Size = new Size(100, 20); this.m_pStartDate.Location = new Point(400, 57); this.m_pStartDate.Anchor = (AnchorStyles.Top | AnchorStyles.Right); this.m_pStartDate.Format = DateTimePickerFormat.Short; this.m_pStartDate.Value = DateTime.Today.AddDays(-1.0); this.m_pEndDate = new DateTimePicker(); this.m_pEndDate.Size = new Size(100, 20); this.m_pEndDate.Location = new Point(505, 57); this.m_pEndDate.Anchor = (AnchorStyles.Top | AnchorStyles.Right); this.m_pEndDate.Format = DateTimePickerFormat.Short; this.m_pToolbar = new ToolStrip(); this.m_pToolbar.AutoSize = false; this.m_pToolbar.Size = new Size(100, 25); this.m_pToolbar.Location = new Point(617, 55); this.m_pToolbar.Dock = DockStyle.None; this.m_pToolbar.Anchor = (AnchorStyles.Top | AnchorStyles.Right); this.m_pToolbar.GripStyle = ToolStripGripStyle.Hidden; this.m_pToolbar.BackColor = this.BackColor; this.m_pToolbar.Renderer = new ToolBarRendererEx(); this.m_pToolbar.ItemClicked += new ToolStripItemClickedEventHandler(this.m_pToolbar_ItemClicked); ToolStripButton toolStripButton = new ToolStripButton(); toolStripButton.Image = ResManager.GetIcon("refresh.ico").ToBitmap(); toolStripButton.Tag = "refresh"; toolStripButton.ToolTipText = "Refresh"; this.m_pToolbar.Items.Add(toolStripButton); ToolStripButton toolStripButton2 = new ToolStripButton(); toolStripButton2.Image = ResManager.GetIcon("restore.ico").ToBitmap(); toolStripButton2.Tag = "restore"; toolStripButton2.Enabled = false; toolStripButton2.ToolTipText = "Restore Message"; this.m_pToolbar.Items.Add(toolStripButton2); ToolStripButton toolStripButton3 = new ToolStripButton(); toolStripButton3.Image = ResManager.GetIcon("save.ico").ToBitmap(); toolStripButton3.Tag = "save"; toolStripButton3.Enabled = false; toolStripButton3.ToolTipText = "Save Message"; this.m_pToolbar.Items.Add(toolStripButton3); ImageList imageList = new ImageList(); imageList.Images.Add(ResManager.GetIcon("message16.ico")); this.m_pMessages = new WListView(); this.m_pMessages.Size = new Size(682, 390); this.m_pMessages.Location = new Point(5, 80); this.m_pMessages.Anchor = (AnchorStyles.Top | AnchorStyles.Bottom | AnchorStyles.Left | AnchorStyles.Right); this.m_pMessages.View = View.Details; this.m_pMessages.FullRowSelect = true; this.m_pMessages.HideSelection = false; this.m_pMessages.SmallImageList = imageList; this.m_pMessages.Columns.Add("Folder", 120, HorizontalAlignment.Left); this.m_pMessages.Columns.Add("Subject", 250, HorizontalAlignment.Left); this.m_pMessages.Columns.Add("Sender", 170, HorizontalAlignment.Left); this.m_pMessages.Columns.Add("Date", 120, HorizontalAlignment.Left); this.m_pMessages.Columns.Add("Date Deleted", 120, HorizontalAlignment.Left); this.m_pMessages.Columns.Add("Size KB", 60, HorizontalAlignment.Right); this.m_pMessages.SelectedIndexChanged += new EventHandler(this.m_pMessages_SelectedIndexChanged); base.Controls.Add(this.m_pIcon); base.Controls.Add(this.mt_Info); base.Controls.Add(this.m_pSeparator1); base.Controls.Add(this.mt_Between); base.Controls.Add(this.m_pStartDate); base.Controls.Add(this.m_pEndDate); base.Controls.Add(this.m_pToolbar); base.Controls.Add(this.m_pMessages); }
void SetScrollEnabled(WListView view) { Control.ScrollEnabled = view.ScrollEnabled; }
void SetSelectionEnabled(WListView view) { Control.AllowsSelection = view.SelectionEnabled; }