source: cprs/trunk/CPRS-Chart/Options/fOptions.pas@ 1495

Last change on this file since 1495 was 829, checked in by Kevin Toppenberg, 14 years ago

Upgrade to version 27

File size: 22.8 KB
Line 
1unit fOptions;
2
3interface
4
5uses Windows, SysUtils, Classes, Graphics, Forms, Controls, StdCtrls,
6 Buttons, ComCtrls, ExtCtrls, ORCtrls, OrFn, Dialogs, ORDtTmRng, fBAOptionsDiagnoses,
7 uBAGlobals, fBase508Form, VA508AccessibilityManager;
8
9type
10 TfrmOptions = class(TfrmBase508Form)
11 pnlMain: TPanel;
12 pnlBottom: TPanel;
13 pagOptions: TPageControl;
14 tsCoverSheet: TTabSheet;
15 tsNotifications: TTabSheet;
16 btnOK: TButton;
17 btnCancel: TButton;
18 btnApply: TButton;
19 tsOrderChecks: TTabSheet;
20 tsListsTeams: TTabSheet;
21 lblCoverReminderDesc: TMemo;
22 lblCoverReminders: TStaticText;
23 lblCoverDaysDesc: TMemo;
24 lblCoverDays: TStaticText;
25 btnCoverDays: TButton;
26 bvlCoverDays: TBevel;
27 btnCoverReminders: TButton;
28 bvlCoverReminders: TBevel;
29 imgCoverDays: TImage;
30 imgCoverReminders: TImage;
31 lblPatientSelectionDesc: TMemo;
32 lblPatientSelection: TStaticText;
33 btnPatientSelection: TButton;
34 bvlPatientSelection: TBevel;
35 btnPersonalLists: TButton;
36 imgPatientSelection: TImage;
37 lblNotificationsOptions: TStaticText;
38 lblNotifications: TStaticText;
39 bvlNotifications: TBevel;
40 imgNotifications: TImage;
41 lblOrderChecksDesc: TLabel;
42 lblOrderChecks: TStaticText;
43 bvlOrderChecks: TBevel;
44 imgOrderChecks: TImage;
45 lblTeamsDesc: TMemo;
46 lblTeams: TStaticText;
47 btnTeams: TButton;
48 bvlTeams: TBevel;
49 lvwNotifications: TCaptionListView;
50 lblNotificationView: TLabel;
51 btnNotificationsRemove: TButton;
52 chkNotificationsFlagged: TCheckBox;
53 lvwOrderChecks: TCaptionListView;
54 lblOrderChecksView: TLabel;
55 btnSurrogate: TButton;
56 lblNotificationsSurrogate: TStaticText;
57 lblNotificationsSurrogateText: TStaticText;
58 btnCombinations: TButton;
59 bvlOtherParameters: TBevel;
60 lblOtherParameters: TStaticText;
61 imgOtherParameters: TImage;
62 lblOtherParametersDesc: TMemo;
63 btnOtherParameters: TButton;
64 tsNotes: TTabSheet;
65 lblNotesNotesDesc: TMemo;
66 lblNotesNotes: TStaticText;
67 bvlNotesNotes: TBevel;
68 btnNotesNotes: TButton;
69 lblNotesTitles: TStaticText;
70 bvlNotesTitles: TBevel;
71 lblNotesTitlesDesc: TMemo;
72 btnNotesTitles: TButton;
73 imgNotesNotes: TImage;
74 imgNotes: TImage;
75 imgTeams: TImage;
76 tsCprsReports: TTabSheet;
77 lblReports: TStaticText;
78 bvlReports: TBevel;
79 memReports: TMemo;
80 imgReports: TImage;
81 btnReports: TButton;
82 lblReport1: TStaticText;
83 memReport1: TMemo;
84 btnReport1: TButton;
85 bvlReport1: TBevel;
86 btnDiagnoses: TButton;
87 tsGraphs: TTabSheet;
88 lblGraphSettings: TStaticText;
89 bvlGraphSettings: TBevel;
90 imgGraphSettings: TImage;
91 btnGraphSettings: TButton;
92 bvlGraphViews: TBevel;
93 lblGraphViews: TStaticText;
94 imgGraphViews: TImage;
95 btnGraphViews: TButton;
96 memGraphSettings: TMemo;
97 memGraphViews: TMemo;
98 bvlReport2: TBevel;
99 lblReport2: TStaticText;
100 memReport2: TMemo;
101 imgReport1: TImage;
102 imgReport2: TImage;
103 procedure FormCreate(Sender: TObject);
104 procedure FormDestroy(Sender: TObject);
105 procedure btnCoverDaysClick(Sender: TObject);
106 procedure btnCoverRemindersClick(Sender: TObject);
107 procedure btnOtherParametersClick(Sender: TObject);
108 procedure btnPatientSelectionClick(Sender: TObject);
109 procedure btnPersonalListsClick(Sender: TObject);
110 procedure btnTeamsClick(Sender: TObject);
111 procedure btnNotificationsRemoveClick(Sender: TObject);
112 procedure btnApplyClick(Sender: TObject);
113 procedure chkNotificationsFlaggedClick(Sender: TObject);
114 procedure lvwNotificationsChange(Sender: TObject; Item: TListItem;
115 Change: TItemChange);
116 procedure lvwNotificationsColumnClick(Sender: TObject;
117 Column: TListColumn);
118 procedure lvwNotificationsCompare(Sender: TObject; Item1,
119 Item2: TListItem; Data: Integer; var Compare: Integer);
120 procedure lvwNotificationsDblClick(Sender: TObject);
121 procedure btnSurrogateClick(Sender: TObject);
122 procedure btnCombinationsClick(Sender: TObject);
123 procedure btnNotesNotesClick(Sender: TObject);
124 procedure btnNotesTitlesClick(Sender: TObject);
125 procedure btnReportsClick(Sender: TObject);
126 procedure btnReport1Click(Sender: TObject);
127 procedure lvwNotificationsEnter(Sender: TObject);
128 procedure lvwNotificationsMouseDown(Sender: TObject;
129 Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
130 procedure btnDiagnosesClick(Sender: TObject);
131 procedure btnGraphSettingsClick(Sender: TObject);
132 procedure btnGraphViewsClick(Sender: TObject);
133 procedure pagOptionsEnter(Sender: TObject);
134 private
135 { Private declarations }
136 FdirtyNotifications: boolean; // used to determine edit changes to Notifications
137 FdirtyOrderChecks: boolean; // used to determine edit changes to Order Checks
138 FdirtyOtherStuff: boolean; // used to determine edit changes to misc settings
139 FuseCheckBoxes: boolean;
140 FsortCol: integer;
141 FsortAscending: boolean;
142 FLastClickedItem: TListItem;
143 FGiveMultiTabMessage: boolean;
144 procedure Offset(var topnum: integer; topoffset: integer; var leftnum: integer; leftoffset: integer);
145 procedure LoadNotifications;
146 procedure LoadOrderChecks;
147 procedure ApplyNotifications;
148 procedure ApplyOrderChecks;
149 procedure ApplyOtherStuff;
150 procedure CheckApply;
151 procedure LoadListView(aListView: TListView; aList: TStrings);
152 procedure ChangeOnOff(aListView: TListView; aListItem: TListItem);
153 public
154 { Public declarations }
155 end;
156
157var
158 frmOptions: TfrmOptions;
159
160procedure DialogOptions(var actiontype: Integer);
161
162implementation
163
164uses fOptionsDays, fOptionsReminders, fOptionsSurrogate,
165 fOptionsPatientSelection, fOptionsLists, fOptionsTeams, fOptionsCombinations,
166 fOptionsOther, fOptionsNotes, fOptionsTitles, fOptionsReportsCustom, fOptionsReportsDefault,
167 fGraphs, fGraphSettings, fGraphProfiles, rGraphs, uGraphs,
168 rOptions, rCore, uCore, uOptions, UBACore, fFrame,
169 VA508AccessibilityRouter;
170 //fTestDialog;
171
172{$R *.DFM}
173
174type
175 TRule = class
176 public
177 IEN: string;
178 OriginalValue: string;
179 ItemText: string;
180end;
181
182procedure DialogOptions(var actiontype: Integer);
183// create the form and make in modal, return an action
184const
185 PixelGapBetweenButtons = 5;
186var
187 frmOptions: TfrmOptions;
188begin
189 frmOptions := TfrmOptions.Create(Application);
190 try
191 with frmOptions do
192 begin
193 with pagOptions do
194 begin
195 tsCoverSheet.TabVisible := false;
196 tsNotifications.TabVisible := false;
197 tsOrderChecks.TabVisible := false;
198 tsListsTeams.TabVisible := false;
199 case actiontype of
200 1: begin
201 tsCoverSheet.TabVisible := true;
202 end;
203 2: begin
204 tsNotifications.TabVisible := true;
205 end;
206 3: begin
207 tsOrderChecks.TabVisible := true;
208 end;
209 4: begin
210 tsListsTeams.TabVisible := true;
211 end;
212 else
213 begin
214 tsCoverSheet.TabVisible := true;
215 tsNotifications.TabVisible := true;
216 tsOrderChecks.TabVisible := true;
217 tsListsTeams.TabVisible := true;
218 ActivePage := tsCoverSheet;
219 memReports.Text := 'Change the default date range and occurrence limits for all reports on ' +
220 'the CPRS Reports tab (excluding health summary reports) .';
221 memReport1.Text := 'Change the individual date range and occurrence limits for each report on ' +
222 'the CPRS Reports tab (excluding health summary reports) .';
223 btnReports.caption := 'Set All Reports...';
224 btnReport1.caption := 'Set Individual Reports...';
225 if User.IsReportsOnly then // For "Reports Only" users.
226 begin
227 tsCoverSheet.TabVisible := false;
228 tsNotifications.TabVisible := false;
229 tsOrderChecks.TabVisible := false;
230 tsListsTeams.TabVisible := false;
231 tsNotes.TabVisible := false;
232 if (not User.ToolsRptEdit) then
233 begin
234 btnOK.visible := false;
235 btnApply.visible := false;
236 btnCancel.caption := 'Close';
237 end;
238 end;
239 if (not User.ToolsRptEdit) then // For users with Reports settings edit parameter not set.
240 begin
241 memReports.Text := 'View the default date range and occurrence limits for all reports on ' +
242 'the CPRS Reports tab (excluding health summary reports) .';
243 memReport1.Text := 'View the individual date range and occurrence limits for each report on ' +
244 'the CPRS Reports tab (excluding health summary reports) .';
245 btnReports.caption := 'View All Report Settings...';
246 btnReport1.caption := 'View Individual Report Settings...';
247 end;
248 end;
249 end;
250 end;
251 actiontype := 0;
252 ResizeAnchoredFormToFont(frmOptions);
253 btnApply.Left := pagOptions.Left + pagOptions.Width - btnApply.Width;
254 btnCancel.Left := btnApply.Left - btnCancel.Width - PixelGapBetweenButtons;
255 btnOK.Left := btnCancel.Left - btnOK.Width - PixelGapBetweenButtons;
256 ShowModal;
257 actiontype := btnOK.Tag;
258 end;
259 finally
260 frmOptions.Release;
261 end;
262end;
263
264procedure TfrmOptions.FormCreate(Sender: TObject);
265// initialize form
266begin
267 LoadNotifications;
268 LoadOrderChecks;
269 FdirtyNotifications := false;
270 FdirtyOrderChecks := false;
271 FdirtyOtherStuff := false;
272 CheckApply;
273
274 if (Encounter.Provider = 0) and not IsCIDCProvider(User.DUZ) then
275 btnDiagnoses.Enabled := False;
276 FGiveMultiTabMessage := ScreenReaderSystemActive;
277end;
278
279procedure TfrmOptions.FormDestroy(Sender: TObject);
280// cleanup creation of objects
281var
282 i: integer;
283begin
284 for i := 0 to lvwOrderChecks.Items.Count - 1 do
285 lvwOrderChecks.Items.Item[i].SubItems.Objects[2].free;
286 for i := 0 to lvwNotifications.Items.Count - 1 do
287 lvwNotifications.Items.Item[i].SubItems.Objects[2].free;
288end;
289
290procedure TfrmOptions.btnCoverDaysClick(Sender: TObject);
291// display Date Range Defaults on Cover Sheet
292var
293 topsize, leftsize, value: integer;
294begin
295 value := 0;
296 Offset(topsize, -60, leftsize, -60);
297 DialogOptionsDays(topsize, leftsize, Font.Size, value);
298end;
299
300procedure TfrmOptions.btnCoverRemindersClick(Sender: TObject);
301// display Clinical Reminder Options
302var
303 topsize, leftsize, value: integer;
304begin
305 value := 0;
306 Offset(topsize, -60, leftsize, -60);
307 DialogOptionsReminders(topsize, leftsize, Font.Size, value);
308end;
309
310procedure TfrmOptions.btnOtherParametersClick(Sender: TObject);
311// display Other Parameters Options
312var
313 topsize, leftsize, value: integer;
314begin
315 value := 0;
316 Offset(topsize, 40, leftsize, 40);
317 DialogOptionsOther(topsize, leftsize, Font.Size, value);
318end;
319
320procedure TfrmOptions.btnPatientSelectionClick(Sender: TObject);
321// display Patient Selection Options
322var
323 topsize, leftsize, value: integer;
324begin
325 value := 0;
326 Offset(topsize, -60, leftsize, -60);
327 DialogOptionsPatientSelection(topsize, leftsize, Font.Size, value);
328end;
329
330procedure TfrmOptions.btnPersonalListsClick(Sender: TObject);
331// display Personal Lists Options
332var
333 topsize, leftsize, value: integer;
334begin
335 value := 0;
336 Offset(topsize, -60, leftsize, -60);
337 DialogOptionsLists(topsize, leftsize, Font.Size, value);
338end;
339
340procedure TfrmOptions.btnTeamsClick(Sender: TObject);
341// display Team Options
342var
343 topsize, leftsize, value: integer;
344begin
345 value := 0;
346 Offset(topsize, -60, leftsize, -60);
347 DialogOptionsTeams(topsize, leftsize, Font.Size, value);
348end;
349
350procedure TfrmOptions.btnNotificationsRemoveClick(Sender: TObject);
351// confirm before clearing notifications
352begin
353 if InfoBox('CAUTION: This will clear all the current notifications you have pending.'
354 + #13 + 'If you say YES, these changes will take place immediately.'
355 + #13 + 'Are you sure you want to erase all of your notifications?',
356 'Warning', MB_YESNO or MB_ICONWARNING) = IDYES then
357 begin
358 rpcClearNotifications;
359 end;
360end;
361
362procedure TfrmOptions.Offset(var topnum: integer; topoffset: integer; var leftnum: integer; leftoffset: integer);
363// get positions to display dialog
364begin
365 // use these top and left values to display dialog
366 topnum := Top;
367 leftnum := Left;
368 topnum := topnum + topoffset;
369 if topnum < 0 then topnum := 0;
370 leftnum := leftnum + leftoffset;
371 if leftnum < 0 then leftnum := 0;
372end;
373
374procedure TfrmOptions.pagOptionsEnter(Sender: TObject);
375begin
376 if FGiveMultiTabMessage then // CQ#15483
377 begin
378 FGiveMultiTabMessage := FALSE;
379 GetScreenReader.Speak('Multi Tab Form');
380 end;
381end;
382
383procedure TfrmOptions.btnApplyClick(Sender: TObject);
384// save actions without exiting
385begin
386 if FdirtyNotifications then
387 ApplyNotifications;
388 if FdirtyOrderChecks then
389 ApplyOrderChecks;
390 if FdirtyOtherStuff then
391 ApplyOtherStuff;
392 CheckApply;
393 if Sender = btnOK then
394 Close;
395end;
396
397procedure TfrmOptions.LoadNotifications;
398// load Notification tab
399var
400 notifydefaults, surrogateinfo, flag, enableerase: string;
401begin
402 LoadListView(lvwNotifications, rpcGetNotifications);
403 lvwNotificationsColumnClick(lvwNotifications, lvwNotifications.Column[0]); // make sure sorted
404 notifydefaults := rpcGetNotificationDefaults;
405 flag := Piece(notifydefaults, '^', 2);
406 enableerase := Piece(notifydefaults, '^', 3);
407 chkNotificationsFlagged.Checked := flag = '1';
408 btnNotificationsRemove.Enabled := enableerase = '1';
409 surrogateinfo := rpcGetSurrogateInfo;
410 btnSurrogate.Hint := surrogateinfo;
411 LabelSurrogate(surrogateinfo, lblNotificationsSurrogateText);
412end;
413
414procedure TfrmOptions.LoadOrderChecks;
415// load Order Check tab
416begin
417 LoadListView(lvwOrderChecks, rpcGetOrderChecks);
418 lvwOrderChecks.Checkboxes := true;
419end;
420
421procedure TfrmOptions.ApplyNotifications;
422// save Notification changes
423var
424 i: integer;
425 newonoff: string;
426 aRule: TRule;
427 aList: TStringList;
428begin
429 aList := TStringList.Create;
430 for i := 0 to lvwNotifications.Items.Count - 1 do
431 begin
432 aRule := TRule(lvwNotifications.Items.Item[i].SubItems.Objects[2]);
433 if lvwNotifications.Items.Item[i].SubItems[1] <> 'Mandatory' then
434 begin
435 newonoff := Uppercase(lvwNotifications.Items.Item[i].SubItems[0]);
436 if aRule.OriginalValue <> newonoff then
437 begin
438 //***Show508Message(aRule.IEN + ' ' + aRule.OriginalValue + ' ' + newonoff);
439 aList.Add(aRule.IEN + '^' + newonoff);
440 aRule.OriginalValue := lvwNotifications.Items.Item[i].SubItems[0];
441 end;
442 end;
443 end;
444 rpcSetNotifications(aList);
445 aList.free;
446 FdirtyNotifications := false;
447end;
448
449procedure TfrmOptions.ApplyOrderChecks;
450// save Order Check changes
451var
452 i: integer;
453 newonoff: string;
454 aRule: TRule;
455 aList: TStringList;
456begin
457 aList := TStringList.Create;
458 for i := 0 to lvwOrderChecks.Items.Count - 1 do
459 begin
460 aRule := TRule(lvwOrderChecks.Items.Item[i].SubItems.Objects[2]);
461 newonoff := Uppercase(lvwOrderChecks.Items.Item[i].SubItems[0]);
462 if aRule.OriginalValue <> newonoff then
463 begin
464 aList.Add(aRule.IEN + '^' + newonoff);
465 aRule.OriginalValue := lvwOrderChecks.Items.Item[i].SubItems[0];
466 end;
467 end;
468 rpcSetOrderChecks(aList);
469 aList.free;
470 FdirtyOrderChecks := false;
471end;
472
473procedure TfrmOptions.ApplyOtherStuff;
474// save other changes
475var
476 aString: string;
477begin
478 aString := '';
479 if chkNotificationsFlagged.Checked then
480 aString := aString + '^1'
481 else
482 aString := aString + '^0';
483 rpcSetOtherStuff(aString);
484 FdirtyOtherStuff := false;
485end;
486
487procedure TfrmOptions.CheckApply;
488// determine if Apply button is enabled
489begin
490 btnApply.Enabled := FdirtyOrderChecks or FdirtyNotifications or FdirtyOtherStuff;
491end;
492
493procedure TfrmOptions.chkNotificationsFlaggedClick(Sender: TObject);
494// set notification flagged status
495begin
496 FdirtyOtherStuff := true;
497 CheckApply;
498end;
499
500procedure TfrmOptions.LoadListView(aListView: TListView; aList: TStrings);
501// load a list view with: name, on/off, comment
502var
503 i: integer;
504 aListItem: TListItem;
505 aRule: TRule;
506 rulenum, ruletext, ruleonoff, rulecomment: string;
507begin
508 FuseCheckBoxes := false;
509 aListView.Items.Clear;
510 aListView.SortType := stNone; // if Sorting during load then potential error
511 with aList do
512 begin
513 for i := 0 to aList.Count - 1 do
514 begin
515 rulenum := Piece(aList[i], '^', 1);
516 ruletext := Piece(aList[i], '^', 2);
517 ruleonoff := Piece(aList[i], '^', 3);
518 rulecomment := Piece(aList[i], '^', 4);
519 aListItem := aListView.Items.Add;
520 with aListItem do
521 begin
522 Caption := ruletext;
523 SubItems.Add(ruleonoff);
524 if ruleonoff = 'On' then Checked := true;
525 SubItems.Add(rulecomment);
526 end;
527 aRule := TRule.Create;
528 with aRule do
529 begin
530 IEN := rulenum;
531 OriginalValue := ruleonoff;
532 ItemText := ruletext;
533 end;
534 aListItem.SubItems.AddObject('rule object', aRule);
535 end;
536 end;
537 aListView.SortType := stBoth;
538 FuseCheckBoxes := true;
539end;
540
541procedure TfrmOptions.lvwNotificationsChange(Sender: TObject;
542 Item: TListItem; Change: TItemChange);
543// change on/off on checkmark
544begin
545 if (Sender as TListView).ItemIndex = -1 then exit;
546 if not FuseCheckBoxes then exit;
547 if (Sender as TListView).Checkboxes = false then exit;
548 if (Item.SubItems[1] = 'Mandatory') and not Item.Checked then begin
549 Item.Checked := True;
550 exit;
551 end;
552 if Item.Checked then
553 begin
554 if Item.SubItems[0] <> 'On' then
555 ChangeOnOff(Sender as TListView, Item);
556 Item.SubItems[0] := 'On';
557 end
558 else
559 begin
560 if Item.SubItems[0] <> 'Off' then
561 ChangeOnOff(Sender as TListView, Item);
562 Item.SubItems[0] := 'Off';
563 end;
564end;
565
566procedure TfrmOptions.lvwNotificationsColumnClick(Sender: TObject;
567 Column: TListColumn);
568// toggle sort
569begin
570 if FsortCol = Column.Index then
571 FsortAscending := not FsortAscending
572 else
573 FsortAscending := true;
574 FsortCol := Column.Index;
575 (Sender as TListView).AlphaSort;
576end;
577
578procedure TfrmOptions.lvwNotificationsCompare(Sender: TObject; Item1,
579 Item2: TListItem; Data: Integer; var Compare: Integer);
580// sort columns
581begin
582 if not(Sender is TListView) then exit;
583 if FsortAscending then
584 begin
585 if FsortCol = 0 then
586 Compare := CompareStr(Item1.Caption, Item2.Caption)
587 else
588 Compare := CompareStr(Item1.SubItems[FsortCol - 1],
589 Item2.SubItems[FsortCol - 1]);
590 end
591 else
592 begin
593 if FsortCol = 0 then
594 Compare := CompareStr(Item2.Caption, Item1.Caption)
595 else
596 Compare := CompareStr(Item2.SubItems[FsortCol - 1],
597 Item1.SubItems[FsortCol - 1]);
598 end;
599end;
600
601procedure TfrmOptions.lvwNotificationsDblClick(Sender: TObject);
602// toggle check marks with double click
603var
604 aListItem: TListItem;
605begin
606 with (Sender as TListView) do
607 begin
608 if Checkboxes = false then exit;
609 if Selected = nil then exit;
610 if Selected.SubItems[1] = 'Mandatory' then exit;
611 if Selected <> FLastClickedItem then exit;
612 aListItem := Selected;
613 aListItem.Checked := not aListItem.Checked;
614 ChangeOnOff(Sender as TListView, aListItem);
615
616 if aListItem.Checked then
617 aListItem.SubItems[0] := 'On'
618 else
619 aListItem.SubItems[0] := 'Off';
620 end;
621end;
622
623procedure TfrmOptions.ChangeOnOff(aListView: TListView; aListItem: TListItem);
624// check if list items were edited
625begin
626 if aListView = lvwNotifications then FdirtyNotifications := true;
627 if aListView = lvwOrderChecks then FdirtyOrderChecks := true;
628 CheckApply;
629end;
630
631procedure TfrmOptions.btnSurrogateClick(Sender: TObject);
632// display Surrogate Options
633var
634 topsize, leftsize: integer;
635 surrogateinfo: string;
636begin
637 surrogateinfo := btnSurrogate.Hint;
638 Offset(topsize, -30, leftsize, -30);
639 DialogOptionsSurrogate(topsize, leftsize, Font.Size, surrogateinfo);
640 LabelSurrogate(surrogateinfo, lblNotificationsSurrogateText);
641 btnSurrogate.Hint := surrogateinfo;
642end;
643
644procedure TfrmOptions.btnCombinationsClick(Sender: TObject);
645// display Combination List Options
646var
647 topsize, leftsize, value: integer;
648begin
649 value := 0;
650 Offset(topsize, -60, leftsize, -60);
651 DialogOptionsCombinations(topsize, leftsize, Font.Size, value);
652end;
653
654procedure TfrmOptions.btnNotesNotesClick(Sender: TObject);
655// display Notes Options
656var
657 topsize, leftsize, value: integer;
658begin
659 value := 0;
660 Offset(topsize, -60, leftsize, -60);
661 DialogOptionsNotes(topsize, leftsize, Font.Size, value);
662end;
663
664procedure TfrmOptions.btnNotesTitlesClick(Sender: TObject);
665// display Titles Options
666var
667 topsize, leftsize, value: integer;
668begin
669 value := 0;
670 Offset(topsize, -60, leftsize, -60);
671 DialogOptionsTitles(topsize, leftsize, Font.Size, value);
672end;
673
674procedure TfrmOptions.btnReportsClick(Sender: TObject);
675var
676 topsize, leftsize, value: integer;
677begin
678 value := 0;
679 Offset(topsize, 90, leftsize, 23);
680 DialogOptionsHSDefault(topsize, leftsize, Font.Size, value);
681end;
682
683procedure TfrmOptions.btnReport1Click(Sender: TObject);
684var
685 topsize, leftsize, value: integer;
686begin
687 value := 0;
688 Offset(topsize, -18, leftsize, -15);
689 DialogOptionsHSCustom(topsize, leftsize, Font.Size, value);
690end;
691
692procedure TfrmOptions.lvwNotificationsEnter(Sender: TObject);
693begin
694 with Sender as TListView do begin
695 if (Selected = nil) and (Items.Count > 0) then
696 Selected := Items[0];
697 end;
698end;
699
700procedure TfrmOptions.lvwNotificationsMouseDown(Sender: TObject;
701 Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
702begin
703 FLastClickedItem := (Sender as TListView).GetItemAt(X,Y);
704end;
705
706procedure TfrmOptions.btnDiagnosesClick(Sender: TObject);
707// display Personal Diagnoses List
708var
709 topsize, leftsize, value: integer;
710begin
711 if IsCIDCProvider(User.DUZ) then //(hds7564)
712 begin
713 value := 0;
714 Offset(topsize, -60, leftsize, -60);
715 DialogOptionsDiagnoses(topsize, leftsize, Font.Size, value);
716 end;
717end;
718
719procedure TfrmOptions.btnGraphSettingsClick(Sender: TObject);
720// display GraphSettings
721var
722 actiontype: boolean;
723 topsize, leftsize: integer;
724begin
725 actiontype := false;
726 Offset(topsize, -60, leftsize, -60);
727 DialogOptionsGraphSettings(topsize, leftsize, Font.Size, actiontype);
728end;
729
730procedure TfrmOptions.btnGraphViewsClick(Sender: TObject);
731// display Graph Views
732var
733 actiontype: boolean;
734begin
735 actiontype := false;
736 DialogOptionsGraphProfiles(actiontype);
737 // if changes were made then view listing should be updated ***********
738end;
739
740end.
741
Note: See TracBrowser for help on using the repository browser.