#include <boost/utility.hpp>
+#include <boost/scoped_ptr.hpp>
class ViewBase;
-class ButtonControllerBase;
+class ButtonController;
/** Abstract base class for Controllers with a ButtonController.
*/
///
ControlButtons();
///
- virtual ~ControlButtons() {}
+ virtual ~ControlButtons();
/** These functions are called by the view when the appropriate buttons
* are pressed.
bool IconifyWithMain() const;
///
- ButtonControllerBase & bc();
+ ButtonController & bc();
///
void setView(ViewBase &);
- ///
- void setButtonController(ButtonControllerBase &);
/** When Applying it's useful to know whether the dialog is about
to close or not (no point refreshing the display for example). */
bool isClosing() const { return is_closing_; }
private:
///
bool is_closing_;
- /// We own neither of these pointers.
- ButtonControllerBase * bc_ptr_;
///
+ boost::scoped_ptr<ButtonController> bc_ptr_;
+ /// We do not own this pointer.
ViewBase * view_ptr_;
};