git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@48076
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
- Show standard options in wxCmdLineParser usage message (Francesco Montorsi).
- Added wxRect::operator+ (union) and * (intersection) (bdonner).
- Added support for two auxiliary mouse buttons to wxMouseEvent (Chris Weiland).
- Show standard options in wxCmdLineParser usage message (Francesco Montorsi).
- Added wxRect::operator+ (union) and * (intersection) (bdonner).
- Added support for two auxiliary mouse buttons to wxMouseEvent (Chris Weiland).
+- Added wxTaskBarIcon::Destroy()
\latexignore{\rtfignore{\wxheading{Members}}}
\latexignore{\rtfignore{\wxheading{Members}}}
\membersection{wxTaskBarIcon::wxTaskBarIcon}\label{wxtaskbariconctor}
\func{}{wxTaskBarIcon}{\void}
Default constructor.
\membersection{wxTaskBarIcon::wxTaskBarIcon}\label{wxtaskbariconctor}
\func{}{wxTaskBarIcon}{\void}
Default constructor.
\membersection{wxTaskBarIcon::\destruct{wxTaskBarIcon}}\label{wxtaskbaricondtor}
\func{}{\destruct{wxTaskBarIcon}}{\void}
Destroys the wxTaskBarIcon object, removing the icon if not already removed.
\membersection{wxTaskBarIcon::\destruct{wxTaskBarIcon}}\label{wxtaskbaricondtor}
\func{}{\destruct{wxTaskBarIcon}}{\void}
Destroys the wxTaskBarIcon object, removing the icon if not already removed.
\membersection{wxTaskBarIcon::CreatePopupMenu}\label{wxtaskbariconcreatepopupmenu}
\func{virtual wxMenu*}{CreatePopupMenu}{\void}
\membersection{wxTaskBarIcon::CreatePopupMenu}\label{wxtaskbariconcreatepopupmenu}
\func{virtual wxMenu*}{CreatePopupMenu}{\void}
displayed and then deleted by the library as soon as the user dismisses it.
The events can be handled by a class derived from wxTaskBarIcon.
displayed and then deleted by the library as soon as the user dismisses it.
The events can be handled by a class derived from wxTaskBarIcon.
+
+\membersection{wxTaskBarIcon::Destroy}\label{wxtaskbaricondestroy}
+
+\func{void}{Destroy}{\void}
+
+This method is similar to \helpref{wxWindow::Destroy}{wxwindowdestroy} and can
+be used to schedule the task bar icon object for the delayed destruction: it
+will be deleted during the next event loop iteration, which allows the task bar
+icon to process any pending events for it before being destroyed.
+
+
\membersection{wxTaskBarIcon::IsIconInstalled}\label{wxtaskbariconisiconinstalled}
\func{bool}{IsIconInstalled}{\void}
Returns true if \helpref{SetIcon}{wxtaskbariconseticon} was called with no subsequent \helpref{RemoveIcon}{wxtaskbariconremoveicon}.
\membersection{wxTaskBarIcon::IsIconInstalled}\label{wxtaskbariconisiconinstalled}
\func{bool}{IsIconInstalled}{\void}
Returns true if \helpref{SetIcon}{wxtaskbariconseticon} was called with no subsequent \helpref{RemoveIcon}{wxtaskbariconremoveicon}.
\membersection{wxTaskBarIcon::IsOk}\label{wxtaskbariconisok}
\func{bool}{IsOk}{\void}
Returns true if the object initialized successfully.
\membersection{wxTaskBarIcon::IsOk}\label{wxtaskbariconisok}
\func{bool}{IsOk}{\void}
Returns true if the object initialized successfully.
\membersection{wxTaskBarIcon::PopupMenu}\label{wxtaskbariconpopupmenu}
\func{bool}{PopupMenu}{\param{wxMenu*}{ menu}}
\membersection{wxTaskBarIcon::PopupMenu}\label{wxtaskbariconpopupmenu}
\func{bool}{PopupMenu}{\param{wxMenu*}{ menu}}
callback instead of calling this method from event handler, because some
ports (e.g. wxCocoa) may not implement PopupMenu and mouse click events at all.
callback instead of calling this method from event handler, because some
ports (e.g. wxCocoa) may not implement PopupMenu and mouse click events at all.
\membersection{wxTaskBarIcon::RemoveIcon}\label{wxtaskbariconremoveicon}
\func{bool}{RemoveIcon}{\void}
Removes the icon previously set with \helpref{SetIcon}{wxtaskbariconseticon}.
\membersection{wxTaskBarIcon::RemoveIcon}\label{wxtaskbariconremoveicon}
\func{bool}{RemoveIcon}{\void}
Removes the icon previously set with \helpref{SetIcon}{wxtaskbariconseticon}.
\membersection{wxTaskBarIcon::SetIcon}\label{wxtaskbariconseticon}
\func{bool}{SetIcon}{\param{const wxIcon\&}{ icon}, \param{const wxString\& }{tooltip}}
\membersection{wxTaskBarIcon::SetIcon}\label{wxtaskbariconseticon}
\func{bool}{SetIcon}{\param{const wxIcon\&}{ icon}, \param{const wxString\& }{tooltip}}
virtual bool RemoveIcon() = 0;
virtual bool PopupMenu(wxMenu *menu) = 0;
virtual bool RemoveIcon() = 0;
virtual bool PopupMenu(wxMenu *menu) = 0;
+ // delayed destruction (similarly to wxWindow::Destroy())
+ void Destroy();
+
protected:
// creates menu to be displayed when user clicks on the icon
virtual wxMenu *CreatePopupMenu() { return NULL; }
protected:
// creates menu to be displayed when user clicks on the icon
virtual wxMenu *CreatePopupMenu() { return NULL; }
#ifndef WX_PRECOMP
#include "wx/app.h"
#ifndef WX_PRECOMP
#include "wx/app.h"
#include "wx/menu.h"
#endif
#include "wx/menu.h"
#endif
+extern WXDLLIMPEXP_DATA_CORE(wxList) wxPendingDelete;
+
// DLL options compatibility check:
WX_CHECK_BUILD_OPTIONS("wxAdvanced")
// DLL options compatibility check:
WX_CHECK_BUILD_OPTIONS("wxAdvanced")
+void wxTaskBarIconBase::Destroy()
+{
+ wxPendingDelete.Append(this);
+}
+
#endif // wxUSE_TASKBARICON
#endif // wxUSE_TASKBARICON