private void CreatePasswordDataControls() { if (!controlsInstantiated) { for (int i = 0; i < PasswordData.DataCount; i++) { PasswordEntryControl c = new PasswordEntryControl(); c.Index = i; Controls.Add(c); } controlsInstantiated = true; selection = (PasswordEntryControl)Controls[0]; } }
private void SetSelection(PasswordEntryControl value) { PasswordEntryControl oldSelection = selection; selection = value; if (oldSelection != null) { oldSelection.Invalidate(); } if (value != null) { value.Invalidate(); } }
internal void NotifyActionOccurred(EditroidAction a) { PasswordDataAction action = a as PasswordDataAction; OverwritePasswordData ow = a as OverwritePasswordData; ////SetItemTilePosition t = a as SetItemTilePosition; ////SetItemRowPosition rowAction = a as SetItemRowPosition; if (action != null) { foreach (WindowlessControl c in Controls) { PasswordEntryControl pc = c as PasswordEntryControl; if (pc != null) { if (pc.Index == action.DataIndex) { pc.UpdateBounds(); } } } } else if (ow != null) { SuspendPaint(); foreach (WindowlessControl c in Controls) { PasswordEntryControl pc = c as PasswordEntryControl; if (pc != null) { pc.UpdateBounds(); } } ResumePaint(); ////} else if (t != null && t.UpdatesPassword) { //// ((PasswordEntryControl)Controls[t.PasswordDataIndex]).UpdateBounds(); ////} else if (rowAction != null) { //// rowAction.ForEachPasswordEntry(delegate(int index) { //// PasswordEntryControl c = Controls[index] as PasswordEntryControl; //// if (c != null) c.UpdateBounds(); //// }); } }