Merge branch 'develop' of https://github.com/cnjinhao/nana into develop
Conflicts: include/nana/gui/detail/widget_notifier_interface.hpp
This commit is contained in:
commit
0e024d3227
@ -1,22 +1,39 @@
|
|||||||
#pragma once
|
/*
|
||||||
|
* Widget Notifier Interface
|
||||||
|
* Nana C++ Library(http://www.nanapro.org)
|
||||||
|
* Copyright(C) 2003-2015 Jinhao(cnjinhao@hotmail.com)
|
||||||
|
*
|
||||||
|
* Distributed under the Boost Software License, Version 1.0.
|
||||||
|
* (See accompanying file LICENSE_1_0.txt or copy at
|
||||||
|
* http://www.boost.org/LICENSE_1_0.txt)
|
||||||
|
*
|
||||||
|
* @file: nana/gui/detail/widget_notifier_interface.hpp
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef NANA_GUI_DETAIL_WIDGET_NOTIFIER_INTERFACE_HEADER
|
||||||
|
#define NANA_GUI_DETAIL_WIDGET_NOTIFIER_INTERFACE_HEADER
|
||||||
#include <memory>
|
#include <memory>
|
||||||
#include <nana/gui/widgets/widget.hpp>
|
#include <string>
|
||||||
|
|
||||||
namespace nana {
|
namespace nana
|
||||||
namespace detail {
|
{
|
||||||
|
class widget; //forward declaration
|
||||||
|
|
||||||
|
namespace detail
|
||||||
|
{
|
||||||
|
class widget_notifier_interface
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
virtual ~widget_notifier_interface() = default;
|
||||||
|
|
||||||
|
static std::unique_ptr<widget_notifier_interface> get_notifier(widget*); //defined in nana/gui/widgets/widget.cpp
|
||||||
|
|
||||||
class widget_notifier_interface {
|
|
||||||
public:
|
|
||||||
virtual widget* widget_ptr() const = 0;
|
virtual widget* widget_ptr() const = 0;
|
||||||
virtual void destroy() = 0;
|
virtual void destroy() = 0;
|
||||||
virtual std::wstring caption() = 0;
|
virtual std::wstring caption() = 0;
|
||||||
virtual void caption(std::wstring text) = 0;
|
virtual void caption(std::wstring) = 0;
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
static std::unique_ptr<widget_notifier_interface> get_notifier(widget* wdg);
|
#endif
|
||||||
private:
|
|
||||||
widget::notifier* p;
|
|
||||||
};
|
|
||||||
|
|
||||||
} // namespace detail
|
|
||||||
} // namespace nana
|
|
||||||
Loading…
x
Reference in New Issue
Block a user