diff options
Diffstat (limited to 'NxWidgets/libnxwidgets/include')
-rw-r--r-- | NxWidgets/libnxwidgets/include/ibitmap.hxx | 9 | ||||
-rw-r--r-- | NxWidgets/libnxwidgets/include/ilistbox.hxx | 8 | ||||
-rw-r--r-- | NxWidgets/libnxwidgets/include/ilistdataeventhandler.hxx | 9 | ||||
-rw-r--r-- | NxWidgets/libnxwidgets/include/inxwindow.hxx | 8 | ||||
-rw-r--r-- | NxWidgets/libnxwidgets/include/iscrollable.hxx | 9 | ||||
-rw-r--r-- | NxWidgets/libnxwidgets/include/islider.hxx | 8 | ||||
-rw-r--r-- | NxWidgets/libnxwidgets/include/itextbox.hxx | 8 |
7 files changed, 59 insertions, 0 deletions
diff --git a/NxWidgets/libnxwidgets/include/ibitmap.hxx b/NxWidgets/libnxwidgets/include/ibitmap.hxx index 5eaa5b3c9..923df407a 100644 --- a/NxWidgets/libnxwidgets/include/ibitmap.hxx +++ b/NxWidgets/libnxwidgets/include/ibitmap.hxx @@ -103,6 +103,15 @@ namespace NXWidgets { public: /** + * A virtual destructor is required in order to override the IBitmap + * destructor. We do this because if we delete IBitmap, we want the + * destructor of the class that inherits from IBitmap to run, not this + * one. + */ + + virtual ~IBitmap(void) { } + + /** * Get the bitmap's color format. * * @return The bitmap's width. diff --git a/NxWidgets/libnxwidgets/include/ilistbox.hxx b/NxWidgets/libnxwidgets/include/ilistbox.hxx index 9184f23c8..0eb33bc3b 100644 --- a/NxWidgets/libnxwidgets/include/ilistbox.hxx +++ b/NxWidgets/libnxwidgets/include/ilistbox.hxx @@ -102,6 +102,14 @@ namespace NXWidgets class IListBox { public: + /** + * A virtual destructor is required in order to override the IListBox + * destructor. We do this because if we delete IListBox, we want the + * destructor of the class that inherits from IListBox to run, not this + * one. + */ + + virtual ~IListBox(void) { } /** * Add a new option to the widget using default colors. diff --git a/NxWidgets/libnxwidgets/include/ilistdataeventhandler.hxx b/NxWidgets/libnxwidgets/include/ilistdataeventhandler.hxx index b6119a2ae..26bf1411b 100644 --- a/NxWidgets/libnxwidgets/include/ilistdataeventhandler.hxx +++ b/NxWidgets/libnxwidgets/include/ilistdataeventhandler.hxx @@ -104,6 +104,15 @@ namespace NXWidgets { public: /** + * A virtual destructor is required in order to override the IListDataEventHandler + * destructor. We do this because if we delete IListDataEventHandler, we want the + * destructor of the class that inherits from IListDataEventHandler to run, not this + * one. + */ + + virtual ~IListDataEventHandler(void) { } + + /** * Handle data changes. * * @param e Event arguments. diff --git a/NxWidgets/libnxwidgets/include/inxwindow.hxx b/NxWidgets/libnxwidgets/include/inxwindow.hxx index c38052de0..750994a71 100644 --- a/NxWidgets/libnxwidgets/include/inxwindow.hxx +++ b/NxWidgets/libnxwidgets/include/inxwindow.hxx @@ -79,6 +79,14 @@ namespace NXWidgets class INxWindow { public: + /** + * A virtual destructor is required in order to override the INxWindow + * destructor. We do this because if we delete INxWindow, we want the + * destructor of the class that inherits from INxWindow to run, not this + * one. + */ + + virtual ~INxWindow(void) { } /** * Creates a new window. Window creation is separate from diff --git a/NxWidgets/libnxwidgets/include/iscrollable.hxx b/NxWidgets/libnxwidgets/include/iscrollable.hxx index 21a69e487..b0e65a9db 100644 --- a/NxWidgets/libnxwidgets/include/iscrollable.hxx +++ b/NxWidgets/libnxwidgets/include/iscrollable.hxx @@ -103,6 +103,15 @@ namespace NXWidgets { public: /** + * A virtual destructor is required in order to override the IScrollable + * destructor. We do this because if we delete IScrollable, we want the + * destructor of the class that inherits from IScrollable to run, not this + * one. + */ + + virtual ~IScrollable(void) { } + + /** * Gets the x coordinate of the virtual canvas. * * @return The x coordinate of the virtual canvas. diff --git a/NxWidgets/libnxwidgets/include/islider.hxx b/NxWidgets/libnxwidgets/include/islider.hxx index 5ea821e42..5a9340923 100644 --- a/NxWidgets/libnxwidgets/include/islider.hxx +++ b/NxWidgets/libnxwidgets/include/islider.hxx @@ -99,6 +99,14 @@ namespace NXWidgets class ISlider { public: + /** + * A virtual destructor is required in order to override the ISlider + * destructor. We do this because if we delete ISlider, we want the + * destructor of the class that inherits from ISlider to run, not this + * one. + */ + + virtual ~ISlider(void) { } /** * Get the smallest value that the slider can represent. diff --git a/NxWidgets/libnxwidgets/include/itextbox.hxx b/NxWidgets/libnxwidgets/include/itextbox.hxx index 78de7e502..0e2e7b824 100644 --- a/NxWidgets/libnxwidgets/include/itextbox.hxx +++ b/NxWidgets/libnxwidgets/include/itextbox.hxx @@ -115,6 +115,14 @@ namespace NXWidgets class ITextBox { public: + /** + * A virtual destructor is required in order to override the ITextBox + * destructor. We do this because if we delete ITextBox, we want the + * destructor of the class that inherits from ITextBox to run, not this + * one. + */ + + virtual ~ITextBox(void) { } /** * Sets the cursor display mode. |