Fix wxGTK compilation when using non X11-based GDK.

Only use X11-specific GDK functions inside "#ifdef GDK_WINDOWING_X11" checks.

Closes #14044.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70701 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2012-02-26 17:18:41 +00:00
parent 8334be51fb
commit 3b81515cb1
6 changed files with 52 additions and 1 deletions

View File

@@ -116,6 +116,7 @@ status_icon_popup_menu(GtkStatusIcon*, guint, guint, wxTaskBarIcon* taskBarIcon)
bool wxTaskBarIconBase::IsAvailable()
{
#ifdef GDK_WINDOWING_X11
char name[32];
g_snprintf(name, sizeof(name), "_NET_SYSTEM_TRAY_S%d",
gdk_x11_get_default_screen());
@@ -124,6 +125,9 @@ bool wxTaskBarIconBase::IsAvailable()
Window manager = XGetSelectionOwner(gdk_x11_get_default_xdisplay(), atom);
return manager != None;
#else
return true;
#endif
}
//-----------------------------------------------------------------------------