@@ -47,7 +47,8 @@ namespace IntelleSoft
47
47
ShowUI = BTA_SHOWUI,
48
48
SaveReport = BTA_SAVEREPORT,
49
49
MailReport = BTA_MAILREPORT,
50
- SendReport = BTA_SENDREPORT
50
+ SendReport = BTA_SENDREPORT,
51
+ Custom = BTA_CUSTOM
51
52
};
52
53
53
54
[Flags]
@@ -373,6 +374,8 @@ namespace IntelleSoft
373
374
374
375
public delegate void UnhandledExceptionDelegate (Object^ sender, UnhandledExceptionEventArgs^ args);
375
376
377
+ public delegate void CustomActivityDelegate (Object^ sender, String^ reportFilePath);
378
+
376
379
public ref class ExceptionHandler
377
380
{
378
381
private:
@@ -391,6 +394,7 @@ namespace IntelleSoft
391
394
392
395
static void ValidateIoResult (BOOL bResult);
393
396
397
+ static event CustomActivityDelegate^ customActivityEvent;
394
398
internal:
395
399
static property System::Exception^ Exception
396
400
{
@@ -418,7 +422,7 @@ namespace IntelleSoft
418
422
419
423
static void FireBeforeUnhandledExceptionEvent (void );
420
424
static void FireAfterUnhandledExceptionEvent (void );
421
-
425
+ static void FireCustomActivityEvent (String^ reportFilePath);
422
426
public:
423
427
static const int HttpPort = BUGTRAP_HTTP_PORT;
424
428
@@ -434,6 +438,12 @@ namespace IntelleSoft
434
438
void remove (UnhandledExceptionDelegate^ value);
435
439
}
436
440
441
+ static event CustomActivityDelegate^ CustomActivity
442
+ {
443
+ void add (CustomActivityDelegate^ value);
444
+ void remove (CustomActivityDelegate^ value);
445
+ }
446
+
437
447
static property String^ AppName
438
448
{
439
449
String^ get (void );
@@ -596,6 +606,11 @@ namespace IntelleSoft
596
606
afterUnhandledExceptionEvent (Sender, Arguments);
597
607
}
598
608
609
+ inline void ExceptionHandler::FireCustomActivityEvent (String^ reportFilePath)
610
+ {
611
+ customActivityEvent (Sender, reportFilePath);
612
+ }
613
+
599
614
inline void ExceptionHandler::BeforeUnhandledException::add (UnhandledExceptionDelegate^ value)
600
615
{
601
616
beforeUnhandledExceptionEvent += value;
@@ -616,6 +631,16 @@ namespace IntelleSoft
616
631
afterUnhandledExceptionEvent -= value;
617
632
}
618
633
634
+ inline void ExceptionHandler::CustomActivity::add (CustomActivityDelegate^ value)
635
+ {
636
+ customActivityEvent += value;
637
+ }
638
+
639
+ inline void ExceptionHandler::CustomActivity::remove (CustomActivityDelegate^ value)
640
+ {
641
+ customActivityEvent -= value;
642
+ }
643
+
619
644
inline String^ ExceptionHandler::AppName::get(void )
620
645
{
621
646
return gcnew String (BT_GetAppName ());
0 commit comments