Skip to content

Commit 5f89e8f

Browse files
committed
Fix ProgramFinishedException color.
1 parent 7df8d30 commit 5f89e8f

File tree

3 files changed

+3
-1
lines changed

3 files changed

+3
-1
lines changed

SerialPrograms/Source/CommonFramework/Exceptions/ProgramFinishedException.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ class ProgramFinishedException : public ScreenshotException{
5151
std::shared_ptr<const ImageRGB32> screenshot
5252
);
5353

54+
virtual Color color() const override{ return COLOR_GREEN; }
5455

5556
public:
5657
virtual void log(Logger& logger) const override;

SerialPrograms/Source/CommonFramework/Exceptions/ScreenshotException.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ void ScreenshotException::send_notification(ProgramEnvironment& env, EventNotifi
100100

101101
send_program_notification(
102102
env, notification,
103-
COLOR_RED,
103+
color(),
104104
name(),
105105
std::move(embeds), "",
106106
screenshot()

SerialPrograms/Source/CommonFramework/Exceptions/ScreenshotException.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,7 @@ class ScreenshotException : public Exception{
6969
virtual std::string message() const override{ return m_message; }
7070
ImageViewRGB32 screenshot() const;
7171

72+
virtual Color color() const{ return COLOR_RED; }
7273
virtual void send_notification(ProgramEnvironment& env, EventNotificationOption& notification) const;
7374

7475
public:

0 commit comments

Comments
 (0)