- Timestamp:
- Jul 6, 2008, 8:20:14 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
cprs/branches/foia-cprs/CPRS-Chart/Options/fOptionsTeams.pas
r459 r460 37 37 procedure cboSubscribeKeyDown(Sender: TObject; var Key: Word; 38 38 Shift: TShiftState); 39 procedure cboSubscribeMouseClick(Sender: TObject); 39 40 private 40 41 FKeyBoarding: boolean; … … 224 225 procedure TfrmOptionsTeams.cboSubscribeClick(Sender: TObject); 225 226 begin 227 FKeyBoarding := False 228 end; 229 230 procedure TfrmOptionsTeams.btnRemoveClick(Sender: TObject); 231 begin 232 with lstTeams do 233 if InfoBox('Do you want to remove yourself from ' 234 + Piece(Items[ItemIndex], '^', 2) + '?', 235 'Confirmation', MB_YESNO or MB_ICONQUESTION) = IDYES then 236 begin 237 rpcRemoveList(ItemIEN); 238 Items.Delete(ItemIndex); 239 lstTeamsClick(self); 240 FillATeams; 241 end; 242 end; 243 244 procedure TfrmOptionsTeams.mnuPatientIDClick(Sender: TObject); 245 begin 246 DisplayPtInfo(lstPatients.ItemID); 247 end; 248 249 procedure TfrmOptionsTeams.lstPatientsMouseDown(Sender: TObject; 250 Button: TMouseButton; Shift: TShiftState; X, Y: Integer); 251 begin 252 mnuPopPatient.AutoPopup := (lstPatients.Items.Count > 0) 253 and (lstPatients.ItemIndex > -1) 254 and (Button = mbRight); 255 end; 256 257 procedure TfrmOptionsTeams.cboSubscribeKeyDown(Sender: TObject; 258 var Key: Word; Shift: TShiftState); 259 begin 260 case Key of VK_RETURN: 261 if (cboSubscribe.ItemIndex > -1) then 262 begin 263 FKeyBoarding := False; 264 cboSubscribeMouseClick(self); // Provide onmouseclick behavior. 265 end; 266 else 267 FKeyBoarding := True; // Suppress onmouseclick behavior. 268 end; 269 end; 270 271 procedure TfrmOptionsTeams.cboSubscribeMouseClick(Sender: TObject); 272 begin 226 273 if FKeyBoarding then 227 274 FKeyBoarding := False … … 229 276 begin 230 277 with cboSubscribe do 231 if InfoBox('Do you want to join ' 278 if ItemIndex < 0 then 279 exit 280 else if InfoBox('Do you want to join ' 232 281 + Piece(Items[ItemIndex], '^', 2) + '?', 233 282 'Confirmation', MB_YESNO or MB_ICONQUESTION) = IDYES then … … 249 298 end; 250 299 251 procedure TfrmOptionsTeams.btnRemoveClick(Sender: TObject);252 begin253 with lstTeams do254 if InfoBox('Do you want to remove yourself from '255 + Piece(Items[ItemIndex], '^', 2) + '?',256 'Confirmation', MB_YESNO or MB_ICONQUESTION) = IDYES then257 begin258 rpcRemoveList(ItemIEN);259 Items.Delete(ItemIndex);260 lstTeamsClick(self);261 FillATeams;262 end;263 end;264 265 procedure TfrmOptionsTeams.mnuPatientIDClick(Sender: TObject);266 begin267 DisplayPtInfo(lstPatients.ItemID);268 end;269 270 procedure TfrmOptionsTeams.lstPatientsMouseDown(Sender: TObject;271 Button: TMouseButton; Shift: TShiftState; X, Y: Integer);272 begin273 mnuPopPatient.AutoPopup := (lstPatients.Items.Count > 0)274 and (lstPatients.ItemIndex > -1)275 and (Button = mbRight);276 end;277 278 procedure TfrmOptionsTeams.cboSubscribeKeyDown(Sender: TObject;279 var Key: Word; Shift: TShiftState);280 begin281 case Key of VK_RETURN:282 if (lstTeams.ItemIndex > 0) then283 cboSubscribeClick(self); // Provide onclick behavior.284 else285 FKeyBoarding := True; // Suppress onclick behavior.286 end;287 end;288 289 300 end.
Note:
See TracChangeset
for help on using the changeset viewer.