Changeset 7380 for branches/ClientUserManagement/HeuristicLab.Clients.Access/3.3/Views/RefreshableLightweightUserView.cs
- Timestamp:
- 01/20/12 13:24:10 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/ClientUserManagement/HeuristicLab.Clients.Access/3.3/Views/RefreshableLightweightUserView.cs
r7375 r7380 34 34 public RefreshableLightweightUserView() { 35 35 InitializeComponent(); 36 37 36 } 38 37 39 //set an action like a webservice call to retrieve the users which should be marked as checked 40 //TODO: disable refresh button if not set 38 //set an action like a webservice call to retrieve the users which should be marked as checked 41 39 public Func<List<Guid>> FetchSelectedUsers { get; set; } 42 40 private List<Guid> selectedUsers; … … 64 62 checkedUsers.SetItemCheckedState(idx, selectedUsers.Contains(u.Id)); 65 63 }); 66 lightweightUserView.Content = checkedUsers; 64 lightweightUserView.Content = checkedUsers.AsReadOnly(); 65 } 66 67 protected override void SetEnabledStateOfControls() { 68 base.SetEnabledStateOfControls(); 69 refreshButton.Enabled = FetchSelectedUsers != null; 67 70 } 68 71 69 72 public ICheckedItemList<LightweightUser> GetCheckedUsers() { 70 if (lightweightUserView.Content == null) 71 return null; 72 else 73 return lightweightUserView.Content; 73 return (lightweightUserView.Content == null) ? null : lightweightUserView.Content; 74 74 } 75 75
Note: See TracChangeset
for help on using the changeset viewer.