- Timestamp:
- Jul 6, 2008, 8:20:14 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
cprs/branches/foia-cprs/CPRS-Chart/VERGENCECONTEXTORLib_TLB.pas
r459 r460 12 12 // ************************************************************************ // 13 13 14 // PASTLWTR : $Revision: 1.130.1.0.1.0.1.6 $ 15 // File generated on 2/20/2003 12:37:40 PM from Type Library described below. 16 17 // ************************************************************************ // 18 // Type Lib: C:\Program Files\Sentillion\Sdk\WindowsComponents\VergenceContextor.dll (1) 19 // LIBID: {30AFBABD-5FD3-11D3-8727-0060B0B5E137} 20 // LCID: 0 14 // PASTLWTR : $Revision: 1.88.1.0.1.0 $ 15 // File generated on 2/9/2004 9:12:53 AM from Type Library described below. 16 17 // *************************************************************************// 18 // NOTE: 19 // Items guarded by $IFDEF_LIVE_SERVER_AT_DESIGN_TIME are used by properties 20 // which return objects that may need to be explicitly created via a function 21 // call prior to any access via the property. These items have been disabled 22 // in order to prevent accidental use from within the object inspector. You 23 // may enable them by defining LIVE_SERVER_AT_DESIGN_TIME or by selectively 24 // removing them from the $IFDEF blocks. However, such items must still be 25 // programmatically created via a method of the appropriate CoClass before 26 // they can be used. 27 // ************************************************************************ // 28 // Type Lib: D:\Development\BDK32_p40\Source\VergenceContextor.dll (1) 29 // IID\LCID: {30AFBABD-5FD3-11D3-8727-0060B0B5E137}\0 21 30 // Helpfile: 22 31 // DepndLst: … … 25 34 // Errors: 26 35 // Hint: Member 'Set' of 'IResponseDialogAccessor' changed to 'Set_' 36 // Error creating palette bitmap of (TContextor) : Invalid GUID format 37 // Error creating palette bitmap of (TContextItemCollection) : Invalid GUID format 38 // Error creating palette bitmap of (TContextItem) : Invalid GUID format 39 // Error creating palette bitmap of (TResponseDialog) : Invalid GUID format 40 // Error creating palette bitmap of (TContextorParticipant) : Invalid GUID format 27 41 // ************************************************************************ // 28 42 {$TYPEDADDRESS OFF} // Unit must be compiled without type-checked pointers. 29 {$WARN SYMBOL_PLATFORM OFF}30 {$WRITEABLECONST ON}31 {$VARPROPSETTER ON}32 43 interface 33 44 34 uses Windows, ActiveX, Classes, Graphics, OleCtrls, OleServer, StdVCL, Variants; 35 36 45 uses Windows, ActiveX, Classes, Graphics, OleServer, OleCtrls, StdVCL; 37 46 38 47 // *********************************************************************// … … 162 171 procedure Suspend; safecall; 163 172 procedure Resume; safecall; 164 function Get_State: ContextorState; safecall;165 function GetPrivilege(const subj: WideString): AccessPrivilege; safecall;166 function Get_CurrentContext: IContextItemCollection; safecall;173 function Get_State: ContextorState; safecall; 174 function GetPrivilege(const subj: WideString): AccessPrivilege; safecall; 175 function Get_CurrentContext: IContextItemCollection; safecall; 167 176 procedure StartContextChange; safecall; 168 function EndContextChange(commit: WordBool; const aContextItemCollection: IContextItemCollection): UserResponse; safecall; 177 function EndContextChange(commit: WordBool; 178 const aContextItemCollection: IContextItemCollection): UserResponse; safecall; 169 179 procedure SetSurveyResponse(const reason: WideString); safecall; 170 function Get_NotificationFilter: WideString; safecall;180 function Get_NotificationFilter: WideString; safecall; 171 181 procedure Set_NotificationFilter(const filter: WideString); safecall; 172 function Get_Name: WideString; safecall;182 function Get_Name: WideString; safecall; 173 183 property State: ContextorState read Get_State; 174 184 property CurrentContext: IContextItemCollection read Get_CurrentContext; … … 189 199 procedure Resume; dispid 3; 190 200 property State: ContextorState readonly dispid 4; 191 function GetPrivilege(const subj: WideString): AccessPrivilege; dispid 5;201 function GetPrivilege(const subj: WideString): AccessPrivilege; dispid 5; 192 202 property CurrentContext: IContextItemCollection readonly dispid 6; 193 203 procedure StartContextChange; dispid 7; 194 function EndContextChange(commit: WordBool; const aContextItemCollection: IContextItemCollection): UserResponse; dispid 8; 204 function EndContextChange(commit: WordBool; 205 const aContextItemCollection: IContextItemCollection): UserResponse; dispid 8; 195 206 procedure SetSurveyResponse(const reason: WideString); dispid 9; 196 207 property NotificationFilter: WideString dispid 10; … … 205 216 IContextParticipant = interface(IDispatch) 206 217 ['{3E3DD272-998E-11D0-808D-00A0240943E4}'] 207 function ContextChangesPending(contextCoupon: Integer; var reason: WideString): WideString; safecall;218 function ContextChangesPending(contextCoupon: Integer; var reason: WideString): WideString; safecall; 208 219 procedure ContextChangesAccepted(contextCoupon: Integer); safecall; 209 220 procedure ContextChangesCanceled(contextCoupon: Integer); safecall; … … 219 230 IContextParticipantDisp = dispinterface 220 231 ['{3E3DD272-998E-11D0-808D-00A0240943E4}'] 221 function ContextChangesPending(contextCoupon: Integer; var reason: WideString): WideString; dispid 1610743808;232 function ContextChangesPending(contextCoupon: Integer; var reason: WideString): WideString; dispid 1610743808; 222 233 procedure ContextChangesAccepted(contextCoupon: Integer); dispid 1610743809; 223 234 procedure ContextChangesCanceled(contextCoupon: Integer); dispid 1610743810; … … 233 244 IContextItemCollection = interface(IDispatch) 234 245 ['{AC4C0271-615A-11D3-84B5-0000861FDD4F}'] 235 function Count: Integer; safecall;246 function Count: Integer; safecall; 236 247 procedure Add(const aContextItem: IContextItem); safecall; 237 248 procedure Remove(const contextItemName: WideString); safecall; 238 249 procedure RemoveAll; safecall; 239 function Present(key: OleVariant): IContextItem; safecall;240 function Get__NewEnum: IUnknown; safecall;241 function Item(key: OleVariant): IContextItem; safecall;250 function Present(key: OleVariant): IContextItem; safecall; 251 function Get__NewEnum: IUnknown; safecall; 252 function Item(key: OleVariant): IContextItem; safecall; 242 253 property _NewEnum: IUnknown read Get__NewEnum; 243 254 end; … … 250 261 IContextItemCollectionDisp = dispinterface 251 262 ['{AC4C0271-615A-11D3-84B5-0000861FDD4F}'] 252 function Count: Integer; dispid 1;263 function Count: Integer; dispid 1; 253 264 procedure Add(const aContextItem: IContextItem); dispid 2; 254 265 procedure Remove(const contextItemName: WideString); dispid 3; 255 266 procedure RemoveAll; dispid 4; 256 function Present(key: OleVariant): IContextItem; dispid 5;267 function Present(key: OleVariant): IContextItem; dispid 5; 257 268 property _NewEnum: IUnknown readonly dispid -4; 258 function Item(key: OleVariant): IContextItem; dispid 0;269 function Item(key: OleVariant): IContextItem; dispid 0; 259 270 end; 260 271 … … 266 277 IContextItem = interface(IDispatch) 267 278 ['{AC4C0273-615A-11D3-84B5-0000861FDD4F}'] 268 function Get_Subject: WideString; safecall;279 function Get_Subject: WideString; safecall; 269 280 procedure Set_Subject(const pVal: WideString); safecall; 270 function Get_Role: WideString; safecall;281 function Get_Role: WideString; safecall; 271 282 procedure Set_Role(const pVal: WideString); safecall; 272 function Get_Prefix: WideString; safecall;283 function Get_Prefix: WideString; safecall; 273 284 procedure Set_Prefix(const pVal: WideString); safecall; 274 function Get_Suffix: WideString; safecall;285 function Get_Suffix: WideString; safecall; 275 286 procedure Set_Suffix(const pVal: WideString); safecall; 276 function Get_Name: WideString; safecall;287 function Get_Name: WideString; safecall; 277 288 procedure Set_Name(const pVal: WideString); safecall; 278 function Get_Value: WideString; safecall;289 function Get_Value: WideString; safecall; 279 290 procedure Set_Value(const pVal: WideString); safecall; 280 function Clone: IContextItem; safecall;291 function Clone: IContextItem; safecall; 281 292 property Subject: WideString read Get_Subject write Set_Subject; 282 293 property Role: WideString read Get_Role write Set_Role; … … 300 311 property Name: WideString dispid 5; 301 312 property Value: WideString dispid 6; 302 function Clone: IContextItem; dispid 7;313 function Clone: IContextItem; dispid 7; 303 314 end; 304 315 … … 311 322 ['{CBC6D968-9F6D-416A-8AA7-99172E588DF0}'] 312 323 procedure StartResponseContextChange; safecall; 313 function EndResponseContextChange(commit: WordBool;314 const aContextItemCollection: IContextItemCollection;315 var noContinue: WordBool): OleVariant; safecall;324 function EndResponseContextChange(commit: WordBool; 325 const aContextItemCollection: IContextItemCollection; 326 var noContinue: WordBool): OleVariant; safecall; 316 327 procedure CommitContextChange; safecall; 317 328 procedure CancelContextChange; safecall; … … 326 337 ['{CBC6D968-9F6D-416A-8AA7-99172E588DF0}'] 327 338 procedure StartResponseContextChange; dispid 1; 328 function EndResponseContextChange(commit: WordBool;329 const aContextItemCollection: IContextItemCollection;330 var noContinue: WordBool): OleVariant; dispid 2;339 function EndResponseContextChange(commit: WordBool; 340 const aContextItemCollection: IContextItemCollection; 341 var noContinue: WordBool): OleVariant; dispid 2; 331 342 procedure CommitContextChange; dispid 3; 332 343 procedure CancelContextChange; dispid 4; … … 386 397 IResponseDialog = interface(IDispatch) 387 398 ['{9D33ECF1-8277-11D3-8525-0000861FDD4F}'] 388 function ProcessSurveyResults(responses: OleVariant; noContinue: WordBool): UserResponse; safecall;399 function ProcessSurveyResults(responses: OleVariant; noContinue: WordBool): UserResponse; safecall; 389 400 end; 390 401 … … 396 407 IResponseDialogDisp = dispinterface 397 408 ['{9D33ECF1-8277-11D3-8525-0000861FDD4F}'] 398 function ProcessSurveyResults(responses: OleVariant; noContinue: WordBool): UserResponse; dispid 1;409 function ProcessSurveyResults(responses: OleVariant; noContinue: WordBool): UserResponse; dispid 1; 399 410 end; 400 411 … … 430 441 class function CreateRemote(const MachineName: string): IContextor; 431 442 end; 443 444 TContextorPending = procedure(Sender: TObject; var aContextItemCollection: OleVariant) of object; 445 446 447 // *********************************************************************// 448 // OLE Server Proxy class declaration 449 // Server Object : TContextor 450 // Help String : Vergence Contextor 451 // Default Interface: IContextor 452 // Def. Intf. DISP? : No 453 // Event Interface: _IContextChangesSink 454 // TypeFlags : (2) CanCreate 455 // *********************************************************************// 456 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 457 TContextorProperties= class; 458 {$ENDIF} 459 TContextor = class(TOleServer) 460 private 461 FOnPending: TContextorPending; 462 FOnCommitted: TNotifyEvent; 463 FOnCanceled: TNotifyEvent; 464 FIntf: IContextor; 465 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 466 FProps: TContextorProperties; 467 function GetServerProperties: TContextorProperties; 468 {$ENDIF} 469 function GetDefaultInterface: IContextor; 470 protected 471 procedure InitServerData; override; 472 procedure InvokeEvent(DispID: TDispID; var Params: TVariantArray); override; 473 function Get_State: ContextorState; 474 function Get_CurrentContext: IContextItemCollection; 475 function Get_NotificationFilter: WideString; 476 procedure Set_NotificationFilter(const filter: WideString); 477 function Get_Name: WideString; 478 public 479 constructor Create(AOwner: TComponent); override; 480 destructor Destroy; override; 481 procedure Connect; override; 482 procedure ConnectTo(svrIntf: IContextor); 483 procedure Disconnect; override; 484 procedure Run(const applicationLabel: WideString; const passcode: WideString; survey: WordBool; 485 const initialNotificationFilter: WideString); 486 procedure Suspend; 487 procedure Resume; 488 function GetPrivilege(const subj: WideString): AccessPrivilege; 489 procedure StartContextChange; 490 function EndContextChange(commit: WordBool; 491 const aContextItemCollection: IContextItemCollection): UserResponse; 492 procedure SetSurveyResponse(const reason: WideString); 493 property DefaultInterface: IContextor read GetDefaultInterface; 494 property State: ContextorState read Get_State; 495 property CurrentContext: IContextItemCollection read Get_CurrentContext; 496 property Name: WideString read Get_Name; 497 property NotificationFilter: WideString read Get_NotificationFilter write Set_NotificationFilter; 498 published 499 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 500 property Server: TContextorProperties read GetServerProperties; 501 {$ENDIF} 502 property OnPending: TContextorPending read FOnPending write FOnPending; 503 property OnCommitted: TNotifyEvent read FOnCommitted write FOnCommitted; 504 property OnCanceled: TNotifyEvent read FOnCanceled write FOnCanceled; 505 end; 506 507 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 508 // *********************************************************************// 509 // OLE Server Properties Proxy Class 510 // Server Object : TContextor 511 // (This object is used by the IDE's Property Inspector to allow editing 512 // of the properties of this server) 513 // *********************************************************************// 514 TContextorProperties = class(TPersistent) 515 private 516 FServer: TContextor; 517 function GetDefaultInterface: IContextor; 518 constructor Create(AServer: TContextor); 519 protected 520 function Get_State: ContextorState; 521 function Get_CurrentContext: IContextItemCollection; 522 function Get_NotificationFilter: WideString; 523 procedure Set_NotificationFilter(const filter: WideString); 524 function Get_Name: WideString; 525 public 526 property DefaultInterface: IContextor read GetDefaultInterface; 527 published 528 property NotificationFilter: WideString read Get_NotificationFilter write Set_NotificationFilter; 529 end; 530 {$ENDIF} 531 432 532 433 533 … … 453 553 procedure CreateControl; 454 554 procedure InitControlData; override; 455 function Get_CurrentContext: IContextItemCollection;555 function Get_CurrentContext: IContextItemCollection; 456 556 public 457 557 procedure Run(const applicationLabel: WideString; const passcode: WideString; survey: WordBool; … … 459 559 procedure Suspend; 460 560 procedure Resume; 461 function GetPrivilege(const subj: WideString): AccessPrivilege;561 function GetPrivilege(const subj: WideString): AccessPrivilege; 462 562 procedure StartContextChange; 463 function EndContextChange(commit: WordBool; const aContextItemCollection: IContextItemCollection): UserResponse; 563 function EndContextChange(commit: WordBool; 564 const aContextItemCollection: IContextItemCollection): UserResponse; 464 565 procedure SetSurveyResponse(const reason: WideString); 465 566 property ControlInterface: IContextor read GetControlInterface; … … 487 588 end; 488 589 590 591 // *********************************************************************// 592 // OLE Server Proxy class declaration 593 // Server Object : TContextItemCollection 594 // Help String : Vergence ContextItemCollection 595 // Default Interface: IContextItemCollection 596 // Def. Intf. DISP? : No 597 // Event Interface: 598 // TypeFlags : (2) CanCreate 599 // *********************************************************************// 600 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 601 TContextItemCollectionProperties= class; 602 {$ENDIF} 603 TContextItemCollection = class(TOleServer) 604 private 605 FIntf: IContextItemCollection; 606 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 607 FProps: TContextItemCollectionProperties; 608 function GetServerProperties: TContextItemCollectionProperties; 609 {$ENDIF} 610 function GetDefaultInterface: IContextItemCollection; 611 protected 612 procedure InitServerData; override; 613 function Get__NewEnum: IUnknown; 614 public 615 constructor Create(AOwner: TComponent); override; 616 destructor Destroy; override; 617 procedure Connect; override; 618 procedure ConnectTo(svrIntf: IContextItemCollection); 619 procedure Disconnect; override; 620 function Count: Integer; 621 procedure Add(const aContextItem: IContextItem); 622 procedure Remove(const contextItemName: WideString); 623 procedure RemoveAll; 624 function Present(key: OleVariant): IContextItem; 625 function Item(key: OleVariant): IContextItem; 626 property DefaultInterface: IContextItemCollection read GetDefaultInterface; 627 property _NewEnum: IUnknown read Get__NewEnum; 628 published 629 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 630 property Server: TContextItemCollectionProperties read GetServerProperties; 631 {$ENDIF} 632 end; 633 634 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 635 // *********************************************************************// 636 // OLE Server Properties Proxy Class 637 // Server Object : TContextItemCollection 638 // (This object is used by the IDE's Property Inspector to allow editing 639 // of the properties of this server) 640 // *********************************************************************// 641 TContextItemCollectionProperties = class(TPersistent) 642 private 643 FServer: TContextItemCollection; 644 function GetDefaultInterface: IContextItemCollection; 645 constructor Create(AServer: TContextItemCollection); 646 protected 647 function Get__NewEnum: IUnknown; 648 public 649 property DefaultInterface: IContextItemCollection read GetDefaultInterface; 650 published 651 end; 652 {$ENDIF} 653 654 489 655 // *********************************************************************// 490 656 // The Class CoContextItem provides a Create and CreateRemote method to … … 499 665 end; 500 666 667 668 // *********************************************************************// 669 // OLE Server Proxy class declaration 670 // Server Object : TContextItem 671 // Help String : Vergence ContextItem 672 // Default Interface: IContextItem 673 // Def. Intf. DISP? : No 674 // Event Interface: 675 // TypeFlags : (2) CanCreate 676 // *********************************************************************// 677 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 678 TContextItemProperties= class; 679 {$ENDIF} 680 TContextItem = class(TOleServer) 681 private 682 FIntf: IContextItem; 683 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 684 FProps: TContextItemProperties; 685 function GetServerProperties: TContextItemProperties; 686 {$ENDIF} 687 function GetDefaultInterface: IContextItem; 688 protected 689 procedure InitServerData; override; 690 function Get_Subject: WideString; 691 procedure Set_Subject(const pVal: WideString); 692 function Get_Role: WideString; 693 procedure Set_Role(const pVal: WideString); 694 function Get_Prefix: WideString; 695 procedure Set_Prefix(const pVal: WideString); 696 function Get_Suffix: WideString; 697 procedure Set_Suffix(const pVal: WideString); 698 function Get_Name: WideString; 699 procedure Set_Name(const pVal: WideString); 700 function Get_Value: WideString; 701 procedure Set_Value(const pVal: WideString); 702 public 703 constructor Create(AOwner: TComponent); override; 704 destructor Destroy; override; 705 procedure Connect; override; 706 procedure ConnectTo(svrIntf: IContextItem); 707 procedure Disconnect; override; 708 function Clone: IContextItem; 709 property DefaultInterface: IContextItem read GetDefaultInterface; 710 property Subject: WideString read Get_Subject write Set_Subject; 711 property Role: WideString read Get_Role write Set_Role; 712 property Prefix: WideString read Get_Prefix write Set_Prefix; 713 property Suffix: WideString read Get_Suffix write Set_Suffix; 714 property Name: WideString read Get_Name write Set_Name; 715 property Value: WideString read Get_Value write Set_Value; 716 published 717 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 718 property Server: TContextItemProperties read GetServerProperties; 719 {$ENDIF} 720 end; 721 722 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 723 // *********************************************************************// 724 // OLE Server Properties Proxy Class 725 // Server Object : TContextItem 726 // (This object is used by the IDE's Property Inspector to allow editing 727 // of the properties of this server) 728 // *********************************************************************// 729 TContextItemProperties = class(TPersistent) 730 private 731 FServer: TContextItem; 732 function GetDefaultInterface: IContextItem; 733 constructor Create(AServer: TContextItem); 734 protected 735 function Get_Subject: WideString; 736 procedure Set_Subject(const pVal: WideString); 737 function Get_Role: WideString; 738 procedure Set_Role(const pVal: WideString); 739 function Get_Prefix: WideString; 740 procedure Set_Prefix(const pVal: WideString); 741 function Get_Suffix: WideString; 742 procedure Set_Suffix(const pVal: WideString); 743 function Get_Name: WideString; 744 procedure Set_Name(const pVal: WideString); 745 function Get_Value: WideString; 746 procedure Set_Value(const pVal: WideString); 747 public 748 property DefaultInterface: IContextItem read GetDefaultInterface; 749 published 750 property Subject: WideString read Get_Subject write Set_Subject; 751 property Role: WideString read Get_Role write Set_Role; 752 property Prefix: WideString read Get_Prefix write Set_Prefix; 753 property Suffix: WideString read Get_Suffix write Set_Suffix; 754 property Name: WideString read Get_Name write Set_Name; 755 property Value: WideString read Get_Value write Set_Value; 756 end; 757 {$ENDIF} 758 759 501 760 // *********************************************************************// 502 761 // The Class CoResponseDialog provides a Create and CreateRemote method to … … 511 770 end; 512 771 772 773 // *********************************************************************// 774 // OLE Server Proxy class declaration 775 // Server Object : TResponseDialog 776 // Help String : Vergence ResponseDialog 777 // Default Interface: IResponseDialog 778 // Def. Intf. DISP? : No 779 // Event Interface: 780 // TypeFlags : (2) CanCreate 781 // *********************************************************************// 782 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 783 TResponseDialogProperties= class; 784 {$ENDIF} 785 TResponseDialog = class(TOleServer) 786 private 787 FIntf: IResponseDialog; 788 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 789 FProps: TResponseDialogProperties; 790 function GetServerProperties: TResponseDialogProperties; 791 {$ENDIF} 792 function GetDefaultInterface: IResponseDialog; 793 protected 794 procedure InitServerData; override; 795 public 796 constructor Create(AOwner: TComponent); override; 797 destructor Destroy; override; 798 procedure Connect; override; 799 procedure ConnectTo(svrIntf: IResponseDialog); 800 procedure Disconnect; override; 801 function ProcessSurveyResults(responses: OleVariant; noContinue: WordBool): UserResponse; 802 property DefaultInterface: IResponseDialog read GetDefaultInterface; 803 published 804 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 805 property Server: TResponseDialogProperties read GetServerProperties; 806 {$ENDIF} 807 end; 808 809 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 810 // *********************************************************************// 811 // OLE Server Properties Proxy Class 812 // Server Object : TResponseDialog 813 // (This object is used by the IDE's Property Inspector to allow editing 814 // of the properties of this server) 815 // *********************************************************************// 816 TResponseDialogProperties = class(TPersistent) 817 private 818 FServer: TResponseDialog; 819 function GetDefaultInterface: IResponseDialog; 820 constructor Create(AServer: TResponseDialog); 821 protected 822 public 823 property DefaultInterface: IResponseDialog read GetDefaultInterface; 824 published 825 end; 826 {$ENDIF} 827 828 513 829 // *********************************************************************// 514 830 // The Class CoContextorParticipant provides a Create and CreateRemote method to … … 523 839 end; 524 840 841 842 // *********************************************************************// 843 // OLE Server Proxy class declaration 844 // Server Object : TContextorParticipant 845 // Help String : ContextorParticipant Class 846 // Default Interface: IContextParticipant 847 // Def. Intf. DISP? : No 848 // Event Interface: 849 // TypeFlags : (2) CanCreate 850 // *********************************************************************// 851 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 852 TContextorParticipantProperties= class; 853 {$ENDIF} 854 TContextorParticipant = class(TOleServer) 855 private 856 FIntf: IContextParticipant; 857 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 858 FProps: TContextorParticipantProperties; 859 function GetServerProperties: TContextorParticipantProperties; 860 {$ENDIF} 861 function GetDefaultInterface: IContextParticipant; 862 protected 863 procedure InitServerData; override; 864 public 865 constructor Create(AOwner: TComponent); override; 866 destructor Destroy; override; 867 procedure Connect; override; 868 procedure ConnectTo(svrIntf: IContextParticipant); 869 procedure Disconnect; override; 870 function ContextChangesPending(contextCoupon: Integer; var reason: WideString): WideString; 871 procedure ContextChangesAccepted(contextCoupon: Integer); 872 procedure ContextChangesCanceled(contextCoupon: Integer); 873 procedure CommonContextTerminated; 874 procedure Ping; 875 property DefaultInterface: IContextParticipant read GetDefaultInterface; 876 published 877 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 878 property Server: TContextorParticipantProperties read GetServerProperties; 879 {$ENDIF} 880 end; 881 882 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 883 // *********************************************************************// 884 // OLE Server Properties Proxy Class 885 // Server Object : TContextorParticipant 886 // (This object is used by the IDE's Property Inspector to allow editing 887 // of the properties of this server) 888 // *********************************************************************// 889 TContextorParticipantProperties = class(TPersistent) 890 private 891 FServer: TContextorParticipant; 892 function GetDefaultInterface: IContextParticipant; 893 constructor Create(AServer: TContextorParticipant); 894 protected 895 public 896 property DefaultInterface: IContextParticipant read GetDefaultInterface; 897 published 898 end; 899 {$ENDIF} 900 901 { 525 902 procedure Register; 526 527 resourcestring 528 dtlServerPage = 'ActiveX'; 529 903 } 530 904 implementation 531 905 … … 541 915 Result := CreateRemoteComObject(MachineName, CLASS_Contextor) as IContextor; 542 916 end; 917 918 procedure TContextor.InitServerData; 919 const 920 CServerData: TServerData = ( 921 ClassID: '{D5C9CC98-5FDB-11D3-8727-0060B0B5E137}'; 922 IntfIID: '{8D879F5D-5FE6-11D3-8727-0060B0B5E137}'; 923 EventIID: '{6BED8971-B3DD-11D3-8736-0060B0B5E137}'; 924 LicenseKey: nil; 925 Version: 500); 926 begin 927 ServerData := @CServerData; 928 end; 929 930 procedure TContextor.Connect; 931 var 932 punk: IUnknown; 933 begin 934 if FIntf = nil then 935 begin 936 punk := GetServer; 937 ConnectEvents(punk); 938 Fintf:= punk as IContextor; 939 end; 940 end; 941 942 procedure TContextor.ConnectTo(svrIntf: IContextor); 943 begin 944 Disconnect; 945 FIntf := svrIntf; 946 ConnectEvents(FIntf); 947 end; 948 949 procedure TContextor.DisConnect; 950 begin 951 if Fintf <> nil then 952 begin 953 DisconnectEvents(FIntf); 954 FIntf := nil; 955 end; 956 end; 957 958 function TContextor.GetDefaultInterface: IContextor; 959 begin 960 if FIntf = nil then 961 Connect; 962 Assert(FIntf <> nil, 'DefaultInterface is NULL. Component is not connected to Server. You must call ''Connect'' or ''ConnectTo'' before this operation'); 963 Result := FIntf; 964 end; 965 966 constructor TContextor.Create(AOwner: TComponent); 967 begin 968 inherited Create(AOwner); 969 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 970 FProps := TContextorProperties.Create(Self); 971 {$ENDIF} 972 end; 973 974 destructor TContextor.Destroy; 975 begin 976 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 977 FProps.Free; 978 {$ENDIF} 979 inherited Destroy; 980 end; 981 982 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 983 function TContextor.GetServerProperties: TContextorProperties; 984 begin 985 Result := FProps; 986 end; 987 {$ENDIF} 988 989 procedure TContextor.InvokeEvent(DispID: TDispID; var Params: TVariantArray); 990 begin 991 case DispID of 992 -1: Exit; // DISPID_UNKNOWN 993 1: if Assigned(FOnPending) then 994 FOnPending(Self, Params[0] {const IDispatch}); 995 2: if Assigned(FOnCommitted) then 996 FOnCommitted(Self); 997 3: if Assigned(FOnCanceled) then 998 FOnCanceled(Self); 999 end; {case DispID} 1000 end; 1001 1002 function TContextor.Get_State: ContextorState; 1003 begin 1004 Result := DefaultInterface.Get_State; 1005 end; 1006 1007 function TContextor.Get_CurrentContext: IContextItemCollection; 1008 begin 1009 Result := DefaultInterface.Get_CurrentContext; 1010 end; 1011 1012 function TContextor.Get_NotificationFilter: WideString; 1013 begin 1014 Result := DefaultInterface.Get_NotificationFilter; 1015 end; 1016 1017 procedure TContextor.Set_NotificationFilter(const filter: WideString); 1018 begin 1019 DefaultInterface.Set_NotificationFilter(filter); 1020 end; 1021 1022 function TContextor.Get_Name: WideString; 1023 begin 1024 Result := DefaultInterface.Get_Name; 1025 end; 1026 1027 procedure TContextor.Run(const applicationLabel: WideString; const passcode: WideString; 1028 survey: WordBool; const initialNotificationFilter: WideString); 1029 begin 1030 DefaultInterface.Run(applicationLabel, passcode, survey, initialNotificationFilter); 1031 end; 1032 1033 procedure TContextor.Suspend; 1034 begin 1035 DefaultInterface.Suspend; 1036 end; 1037 1038 procedure TContextor.Resume; 1039 begin 1040 DefaultInterface.Resume; 1041 end; 1042 1043 function TContextor.GetPrivilege(const subj: WideString): AccessPrivilege; 1044 begin 1045 Result := DefaultInterface.GetPrivilege(subj); 1046 end; 1047 1048 procedure TContextor.StartContextChange; 1049 begin 1050 DefaultInterface.StartContextChange; 1051 end; 1052 1053 function TContextor.EndContextChange(commit: WordBool; 1054 const aContextItemCollection: IContextItemCollection): UserResponse; 1055 begin 1056 Result := DefaultInterface.EndContextChange(commit, aContextItemCollection); 1057 end; 1058 1059 procedure TContextor.SetSurveyResponse(const reason: WideString); 1060 begin 1061 DefaultInterface.SetSurveyResponse(reason); 1062 end; 1063 1064 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 1065 constructor TContextorProperties.Create(AServer: TContextor); 1066 begin 1067 inherited Create; 1068 FServer := AServer; 1069 end; 1070 1071 function TContextorProperties.GetDefaultInterface: IContextor; 1072 begin 1073 Result := FServer.DefaultInterface; 1074 end; 1075 1076 function TContextorProperties.Get_State: ContextorState; 1077 begin 1078 Result := DefaultInterface.Get_State; 1079 end; 1080 1081 function TContextorProperties.Get_CurrentContext: IContextItemCollection; 1082 begin 1083 Result := DefaultInterface.Get_CurrentContext; 1084 end; 1085 1086 function TContextorProperties.Get_NotificationFilter: WideString; 1087 begin 1088 Result := DefaultInterface.Get_NotificationFilter; 1089 end; 1090 1091 procedure TContextorProperties.Set_NotificationFilter(const filter: WideString); 1092 begin 1093 DefaultInterface.Set_NotificationFilter(filter); 1094 end; 1095 1096 function TContextorProperties.Get_Name: WideString; 1097 begin 1098 Result := DefaultInterface.Get_Name; 1099 end; 1100 1101 {$ENDIF} 543 1102 544 1103 procedure TContextorControl.InitControlData; … … 576 1135 end; 577 1136 578 function TContextorControl.Get_CurrentContext: IContextItemCollection;579 begin 580 Result := DefaultInterface.CurrentContext;1137 function TContextorControl.Get_CurrentContext: IContextItemCollection; 1138 begin 1139 Result := DefaultInterface.Get_CurrentContext; 581 1140 end; 582 1141 … … 597 1156 end; 598 1157 599 function TContextorControl.GetPrivilege(const subj: WideString): AccessPrivilege;1158 function TContextorControl.GetPrivilege(const subj: WideString): AccessPrivilege; 600 1159 begin 601 1160 Result := DefaultInterface.GetPrivilege(subj); … … 607 1166 end; 608 1167 609 function TContextorControl.EndContextChange(commit: WordBool;610 const aContextItemCollection: IContextItemCollection): UserResponse;1168 function TContextorControl.EndContextChange(commit: WordBool; 1169 const aContextItemCollection: IContextItemCollection): UserResponse; 611 1170 begin 612 1171 Result := DefaultInterface.EndContextChange(commit, aContextItemCollection); … … 628 1187 end; 629 1188 1189 procedure TContextItemCollection.InitServerData; 1190 const 1191 CServerData: TServerData = ( 1192 ClassID: '{AC4C0272-615A-11D3-84B5-0000861FDD4F}'; 1193 IntfIID: '{AC4C0271-615A-11D3-84B5-0000861FDD4F}'; 1194 EventIID: ''; 1195 LicenseKey: nil; 1196 Version: 500); 1197 begin 1198 ServerData := @CServerData; 1199 end; 1200 1201 procedure TContextItemCollection.Connect; 1202 var 1203 punk: IUnknown; 1204 begin 1205 if FIntf = nil then 1206 begin 1207 punk := GetServer; 1208 Fintf:= punk as IContextItemCollection; 1209 end; 1210 end; 1211 1212 procedure TContextItemCollection.ConnectTo(svrIntf: IContextItemCollection); 1213 begin 1214 Disconnect; 1215 FIntf := svrIntf; 1216 end; 1217 1218 procedure TContextItemCollection.DisConnect; 1219 begin 1220 if Fintf <> nil then 1221 begin 1222 FIntf := nil; 1223 end; 1224 end; 1225 1226 function TContextItemCollection.GetDefaultInterface: IContextItemCollection; 1227 begin 1228 if FIntf = nil then 1229 Connect; 1230 Assert(FIntf <> nil, 'DefaultInterface is NULL. Component is not connected to Server. You must call ''Connect'' or ''ConnectTo'' before this operation'); 1231 Result := FIntf; 1232 end; 1233 1234 constructor TContextItemCollection.Create(AOwner: TComponent); 1235 begin 1236 inherited Create(AOwner); 1237 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 1238 FProps := TContextItemCollectionProperties.Create(Self); 1239 {$ENDIF} 1240 end; 1241 1242 destructor TContextItemCollection.Destroy; 1243 begin 1244 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 1245 FProps.Free; 1246 {$ENDIF} 1247 inherited Destroy; 1248 end; 1249 1250 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 1251 function TContextItemCollection.GetServerProperties: TContextItemCollectionProperties; 1252 begin 1253 Result := FProps; 1254 end; 1255 {$ENDIF} 1256 1257 function TContextItemCollection.Get__NewEnum: IUnknown; 1258 begin 1259 Result := DefaultInterface.Get__NewEnum; 1260 end; 1261 1262 function TContextItemCollection.Count: Integer; 1263 begin 1264 Result := DefaultInterface.Count; 1265 end; 1266 1267 procedure TContextItemCollection.Add(const aContextItem: IContextItem); 1268 begin 1269 DefaultInterface.Add(aContextItem); 1270 end; 1271 1272 procedure TContextItemCollection.Remove(const contextItemName: WideString); 1273 begin 1274 DefaultInterface.Remove(contextItemName); 1275 end; 1276 1277 procedure TContextItemCollection.RemoveAll; 1278 begin 1279 DefaultInterface.RemoveAll; 1280 end; 1281 1282 function TContextItemCollection.Present(key: OleVariant): IContextItem; 1283 begin 1284 Result := DefaultInterface.Present(key); 1285 end; 1286 1287 function TContextItemCollection.Item(key: OleVariant): IContextItem; 1288 begin 1289 Result := DefaultInterface.Item(key); 1290 end; 1291 1292 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 1293 constructor TContextItemCollectionProperties.Create(AServer: TContextItemCollection); 1294 begin 1295 inherited Create; 1296 FServer := AServer; 1297 end; 1298 1299 function TContextItemCollectionProperties.GetDefaultInterface: IContextItemCollection; 1300 begin 1301 Result := FServer.DefaultInterface; 1302 end; 1303 1304 function TContextItemCollectionProperties.Get__NewEnum: IUnknown; 1305 begin 1306 Result := DefaultInterface.Get__NewEnum; 1307 end; 1308 1309 {$ENDIF} 1310 630 1311 class function CoContextItem.Create: IContextItem; 631 1312 begin … … 638 1319 end; 639 1320 1321 procedure TContextItem.InitServerData; 1322 const 1323 CServerData: TServerData = ( 1324 ClassID: '{AC4C0274-615A-11D3-84B5-0000861FDD4F}'; 1325 IntfIID: '{AC4C0273-615A-11D3-84B5-0000861FDD4F}'; 1326 EventIID: ''; 1327 LicenseKey: nil; 1328 Version: 500); 1329 begin 1330 ServerData := @CServerData; 1331 end; 1332 1333 procedure TContextItem.Connect; 1334 var 1335 punk: IUnknown; 1336 begin 1337 if FIntf = nil then 1338 begin 1339 punk := GetServer; 1340 Fintf:= punk as IContextItem; 1341 end; 1342 end; 1343 1344 procedure TContextItem.ConnectTo(svrIntf: IContextItem); 1345 begin 1346 Disconnect; 1347 FIntf := svrIntf; 1348 end; 1349 1350 procedure TContextItem.DisConnect; 1351 begin 1352 if Fintf <> nil then 1353 begin 1354 FIntf := nil; 1355 end; 1356 end; 1357 1358 function TContextItem.GetDefaultInterface: IContextItem; 1359 begin 1360 if FIntf = nil then 1361 Connect; 1362 Assert(FIntf <> nil, 'DefaultInterface is NULL. Component is not connected to Server. You must call ''Connect'' or ''ConnectTo'' before this operation'); 1363 Result := FIntf; 1364 end; 1365 1366 constructor TContextItem.Create(AOwner: TComponent); 1367 begin 1368 inherited Create(AOwner); 1369 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 1370 FProps := TContextItemProperties.Create(Self); 1371 {$ENDIF} 1372 end; 1373 1374 destructor TContextItem.Destroy; 1375 begin 1376 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 1377 FProps.Free; 1378 {$ENDIF} 1379 inherited Destroy; 1380 end; 1381 1382 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 1383 function TContextItem.GetServerProperties: TContextItemProperties; 1384 begin 1385 Result := FProps; 1386 end; 1387 {$ENDIF} 1388 1389 function TContextItem.Get_Subject: WideString; 1390 begin 1391 Result := DefaultInterface.Get_Subject; 1392 end; 1393 1394 procedure TContextItem.Set_Subject(const pVal: WideString); 1395 begin 1396 DefaultInterface.Set_Subject(pVal); 1397 end; 1398 1399 function TContextItem.Get_Role: WideString; 1400 begin 1401 Result := DefaultInterface.Get_Role; 1402 end; 1403 1404 procedure TContextItem.Set_Role(const pVal: WideString); 1405 begin 1406 DefaultInterface.Set_Role(pVal); 1407 end; 1408 1409 function TContextItem.Get_Prefix: WideString; 1410 begin 1411 Result := DefaultInterface.Get_Prefix; 1412 end; 1413 1414 procedure TContextItem.Set_Prefix(const pVal: WideString); 1415 begin 1416 DefaultInterface.Set_Prefix(pVal); 1417 end; 1418 1419 function TContextItem.Get_Suffix: WideString; 1420 begin 1421 Result := DefaultInterface.Get_Suffix; 1422 end; 1423 1424 procedure TContextItem.Set_Suffix(const pVal: WideString); 1425 begin 1426 DefaultInterface.Set_Suffix(pVal); 1427 end; 1428 1429 function TContextItem.Get_Name: WideString; 1430 begin 1431 Result := DefaultInterface.Get_Name; 1432 end; 1433 1434 procedure TContextItem.Set_Name(const pVal: WideString); 1435 begin 1436 DefaultInterface.Set_Name(pVal); 1437 end; 1438 1439 function TContextItem.Get_Value: WideString; 1440 begin 1441 Result := DefaultInterface.Get_Value; 1442 end; 1443 1444 procedure TContextItem.Set_Value(const pVal: WideString); 1445 begin 1446 DefaultInterface.Set_Value(pVal); 1447 end; 1448 1449 function TContextItem.Clone: IContextItem; 1450 begin 1451 Result := DefaultInterface.Clone; 1452 end; 1453 1454 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 1455 constructor TContextItemProperties.Create(AServer: TContextItem); 1456 begin 1457 inherited Create; 1458 FServer := AServer; 1459 end; 1460 1461 function TContextItemProperties.GetDefaultInterface: IContextItem; 1462 begin 1463 Result := FServer.DefaultInterface; 1464 end; 1465 1466 function TContextItemProperties.Get_Subject: WideString; 1467 begin 1468 Result := DefaultInterface.Get_Subject; 1469 end; 1470 1471 procedure TContextItemProperties.Set_Subject(const pVal: WideString); 1472 begin 1473 DefaultInterface.Set_Subject(pVal); 1474 end; 1475 1476 function TContextItemProperties.Get_Role: WideString; 1477 begin 1478 Result := DefaultInterface.Get_Role; 1479 end; 1480 1481 procedure TContextItemProperties.Set_Role(const pVal: WideString); 1482 begin 1483 DefaultInterface.Set_Role(pVal); 1484 end; 1485 1486 function TContextItemProperties.Get_Prefix: WideString; 1487 begin 1488 Result := DefaultInterface.Get_Prefix; 1489 end; 1490 1491 procedure TContextItemProperties.Set_Prefix(const pVal: WideString); 1492 begin 1493 DefaultInterface.Set_Prefix(pVal); 1494 end; 1495 1496 function TContextItemProperties.Get_Suffix: WideString; 1497 begin 1498 Result := DefaultInterface.Get_Suffix; 1499 end; 1500 1501 procedure TContextItemProperties.Set_Suffix(const pVal: WideString); 1502 begin 1503 DefaultInterface.Set_Suffix(pVal); 1504 end; 1505 1506 function TContextItemProperties.Get_Name: WideString; 1507 begin 1508 Result := DefaultInterface.Get_Name; 1509 end; 1510 1511 procedure TContextItemProperties.Set_Name(const pVal: WideString); 1512 begin 1513 DefaultInterface.Set_Name(pVal); 1514 end; 1515 1516 function TContextItemProperties.Get_Value: WideString; 1517 begin 1518 Result := DefaultInterface.Get_Value; 1519 end; 1520 1521 procedure TContextItemProperties.Set_Value(const pVal: WideString); 1522 begin 1523 DefaultInterface.Set_Value(pVal); 1524 end; 1525 1526 {$ENDIF} 1527 640 1528 class function CoResponseDialog.Create: IResponseDialog; 641 1529 begin … … 648 1536 end; 649 1537 1538 procedure TResponseDialog.InitServerData; 1539 const 1540 CServerData: TServerData = ( 1541 ClassID: '{9D33ECF2-8277-11D3-8525-0000861FDD4F}'; 1542 IntfIID: '{9D33ECF1-8277-11D3-8525-0000861FDD4F}'; 1543 EventIID: ''; 1544 LicenseKey: nil; 1545 Version: 500); 1546 begin 1547 ServerData := @CServerData; 1548 end; 1549 1550 procedure TResponseDialog.Connect; 1551 var 1552 punk: IUnknown; 1553 begin 1554 if FIntf = nil then 1555 begin 1556 punk := GetServer; 1557 Fintf:= punk as IResponseDialog; 1558 end; 1559 end; 1560 1561 procedure TResponseDialog.ConnectTo(svrIntf: IResponseDialog); 1562 begin 1563 Disconnect; 1564 FIntf := svrIntf; 1565 end; 1566 1567 procedure TResponseDialog.DisConnect; 1568 begin 1569 if Fintf <> nil then 1570 begin 1571 FIntf := nil; 1572 end; 1573 end; 1574 1575 function TResponseDialog.GetDefaultInterface: IResponseDialog; 1576 begin 1577 if FIntf = nil then 1578 Connect; 1579 Assert(FIntf <> nil, 'DefaultInterface is NULL. Component is not connected to Server. You must call ''Connect'' or ''ConnectTo'' before this operation'); 1580 Result := FIntf; 1581 end; 1582 1583 constructor TResponseDialog.Create(AOwner: TComponent); 1584 begin 1585 inherited Create(AOwner); 1586 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 1587 FProps := TResponseDialogProperties.Create(Self); 1588 {$ENDIF} 1589 end; 1590 1591 destructor TResponseDialog.Destroy; 1592 begin 1593 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 1594 FProps.Free; 1595 {$ENDIF} 1596 inherited Destroy; 1597 end; 1598 1599 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 1600 function TResponseDialog.GetServerProperties: TResponseDialogProperties; 1601 begin 1602 Result := FProps; 1603 end; 1604 {$ENDIF} 1605 1606 function TResponseDialog.ProcessSurveyResults(responses: OleVariant; noContinue: WordBool): UserResponse; 1607 begin 1608 Result := DefaultInterface.ProcessSurveyResults(responses, noContinue); 1609 end; 1610 1611 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 1612 constructor TResponseDialogProperties.Create(AServer: TResponseDialog); 1613 begin 1614 inherited Create; 1615 FServer := AServer; 1616 end; 1617 1618 function TResponseDialogProperties.GetDefaultInterface: IResponseDialog; 1619 begin 1620 Result := FServer.DefaultInterface; 1621 end; 1622 1623 {$ENDIF} 1624 650 1625 class function CoContextorParticipant.Create: IContextParticipant; 651 1626 begin … … 658 1633 end; 659 1634 1635 procedure TContextorParticipant.InitServerData; 1636 const 1637 CServerData: TServerData = ( 1638 ClassID: '{4BA034A2-D0FA-11D3-818B-0050049598B2}'; 1639 IntfIID: '{3E3DD272-998E-11D0-808D-00A0240943E4}'; 1640 EventIID: ''; 1641 LicenseKey: nil; 1642 Version: 500); 1643 begin 1644 ServerData := @CServerData; 1645 end; 1646 1647 procedure TContextorParticipant.Connect; 1648 var 1649 punk: IUnknown; 1650 begin 1651 if FIntf = nil then 1652 begin 1653 punk := GetServer; 1654 Fintf:= punk as IContextParticipant; 1655 end; 1656 end; 1657 1658 procedure TContextorParticipant.ConnectTo(svrIntf: IContextParticipant); 1659 begin 1660 Disconnect; 1661 FIntf := svrIntf; 1662 end; 1663 1664 procedure TContextorParticipant.DisConnect; 1665 begin 1666 if Fintf <> nil then 1667 begin 1668 FIntf := nil; 1669 end; 1670 end; 1671 1672 function TContextorParticipant.GetDefaultInterface: IContextParticipant; 1673 begin 1674 if FIntf = nil then 1675 Connect; 1676 Assert(FIntf <> nil, 'DefaultInterface is NULL. Component is not connected to Server. You must call ''Connect'' or ''ConnectTo'' before this operation'); 1677 Result := FIntf; 1678 end; 1679 1680 constructor TContextorParticipant.Create(AOwner: TComponent); 1681 begin 1682 inherited Create(AOwner); 1683 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 1684 FProps := TContextorParticipantProperties.Create(Self); 1685 {$ENDIF} 1686 end; 1687 1688 destructor TContextorParticipant.Destroy; 1689 begin 1690 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 1691 FProps.Free; 1692 {$ENDIF} 1693 inherited Destroy; 1694 end; 1695 1696 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 1697 function TContextorParticipant.GetServerProperties: TContextorParticipantProperties; 1698 begin 1699 Result := FProps; 1700 end; 1701 {$ENDIF} 1702 1703 function TContextorParticipant.ContextChangesPending(contextCoupon: Integer; var reason: WideString): WideString; 1704 begin 1705 Result := DefaultInterface.ContextChangesPending(contextCoupon, reason); 1706 end; 1707 1708 procedure TContextorParticipant.ContextChangesAccepted(contextCoupon: Integer); 1709 begin 1710 DefaultInterface.ContextChangesAccepted(contextCoupon); 1711 end; 1712 1713 procedure TContextorParticipant.ContextChangesCanceled(contextCoupon: Integer); 1714 begin 1715 DefaultInterface.ContextChangesCanceled(contextCoupon); 1716 end; 1717 1718 procedure TContextorParticipant.CommonContextTerminated; 1719 begin 1720 DefaultInterface.CommonContextTerminated; 1721 end; 1722 1723 procedure TContextorParticipant.Ping; 1724 begin 1725 DefaultInterface.Ping; 1726 end; 1727 1728 {$IFDEF LIVE_SERVER_AT_DESIGN_TIME} 1729 constructor TContextorParticipantProperties.Create(AServer: TContextorParticipant); 1730 begin 1731 inherited Create; 1732 FServer := AServer; 1733 end; 1734 1735 function TContextorParticipantProperties.GetDefaultInterface: IContextParticipant; 1736 begin 1737 Result := FServer.DefaultInterface; 1738 end; 1739 1740 {$ENDIF} 1741 { 660 1742 procedure Register; 661 1743 begin 662 RegisterComponents('ActiveX',[TContextorControl]); 663 end; 664 1744 RegisterComponents('Kernel',[TContextorControl]); 1745 RegisterComponents('Kernel',[TContextor, TContextItemCollection, TContextItem, TResponseDialog, 1746 TContextorParticipant]); 1747 end; 1748 } 665 1749 end.
Note:
See TracChangeset
for help on using the changeset viewer.