[Xfce4-commits] <xfce4-panel:master> Pager: Fixed preprocessor macro.
Nick Schermer
noreply at xfce.org
Sun Mar 4 14:44:03 CET 2012
Updating branch refs/heads/master
to dd65736ef37a5ba82ce4dc5180ca8269f1203dc7 (commit)
from a4283dd61e894e897ba724f249066bf66c4cd0b1 (commit)
commit dd65736ef37a5ba82ce4dc5180ca8269f1203dc7
Author: Andrzej <ndrwrdck at gmail.com>
Date: Sat Mar 3 04:44:18 2012 +0900
Pager: Fixed preprocessor macro.
(cherry picked from commit 02520a3af9ade1afe1a28b7a1e73f76a680e037e)
plugins/pager/pager.c | 10 +++++++---
1 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/plugins/pager/pager.c b/plugins/pager/pager.c
index 0739d1d..6f0a378 100644
--- a/plugins/pager/pager.c
+++ b/plugins/pager/pager.c
@@ -42,7 +42,6 @@
#define WORKSPACE_SETTINGS_COMMAND "xfwm4-workspace-settings"
-#define WNCK_PAGER_HAS_LAYOUT_POLICY (defined (WNCK_CHECK_VERSION) && WNCK_CHECK_VERSION (2,31,0))
@@ -303,12 +302,15 @@ pager_plugin_screen_layout_changed (PagerPlugin *plugin)
wnck_pager_set_display_mode (WNCK_PAGER (plugin->pager), WNCK_PAGER_DISPLAY_CONTENT);
if (!wnck_pager_set_n_rows (WNCK_PAGER (plugin->pager), plugin->rows))
g_message ("Setting the pager rows returned false. Maybe the setting is not applied.");
-#if WNCK_PAGER_HAS_LAYOUT_POLICY
+
+#ifdef WNCK_CHECK_VERSION
+#if WNCK_CHECK_VERSION (2,31,0)
wnck_pager_set_layout_policy (WNCK_PAGER (plugin->pager),
(mode == XFCE_PANEL_PLUGIN_MODE_HORIZONTAL) ?
WNCK_PAGER_LAYOUT_POLICY_WIDTH_FOR_HEIGHT :
WNCK_PAGER_LAYOUT_POLICY_HEIGHT_FOR_WIDTH);
#endif
+#endif
wnck_pager_set_orientation (WNCK_PAGER (plugin->pager), orientation);
}
else
@@ -420,12 +422,14 @@ pager_plugin_mode_changed (XfcePanelPlugin *panel_plugin,
if (plugin->miniature_view)
{
-#if WNCK_PAGER_HAS_LAYOUT_POLICY
+#ifdef WNCK_CHECK_VERSION
+#if WNCK_CHECK_VERSION (2,31,0)
wnck_pager_set_layout_policy (WNCK_PAGER (plugin->pager),
(mode == XFCE_PANEL_PLUGIN_MODE_HORIZONTAL) ?
WNCK_PAGER_LAYOUT_POLICY_WIDTH_FOR_HEIGHT :
WNCK_PAGER_LAYOUT_POLICY_HEIGHT_FOR_WIDTH);
#endif
+#endif
wnck_pager_set_orientation (WNCK_PAGER (plugin->pager), orientation);
}
else
More information about the Xfce4-commits
mailing list