-
Notifications
You must be signed in to change notification settings - Fork 189
refactor: Add override keyword to virtual function overrides in Generals code (2) #2604
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
603ae01
9c8f831
2e2b647
4897e4f
7980648
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -455,7 +455,7 @@ friend class Drawable; // for selection/deselection transactions | |
| virtual void disregardDrawable( Drawable *draw ); ///< Drawable is being destroyed, clean up any UI elements associated with it | ||
|
|
||
| virtual void preDraw(); ///< Logic which needs to occur before the UI renders | ||
| virtual void draw() = 0; ///< Render the in-game user interface | ||
| virtual void draw() override = 0; ///< Render the in-game user interface | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. What happens if this is omitted?
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Nothing. It's just to acknowledge that the base class also has this exact function, but it's not pure virtual. If that were removed that would lead to a compilation error here, which seems desirable. |
||
| virtual void postDraw(); ///< Logic which needs to occur after the UI renders | ||
| virtual void postWindowDraw(); ///< Logic which needs to occur after the WindowManager has repainted the menus | ||
|
|
||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is this hack added?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see this is a merge from Zero Hour.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I copied this from Zero Hour, to make it possible to add
overridehere in the Code code:GeneralsGameCode/Core/GameEngineDevice/Include/W3DDevice/GameClient/Module/W3DTreeDraw.h
Line 67 in efabb08