Simplify build with Gtk+ 3
This commit is contained in:
parent
18f2aeb195
commit
336c0913e8
|
@ -22,6 +22,7 @@
|
||||||
#include <gdk/gdkx.h>
|
#include <gdk/gdkx.h>
|
||||||
#include <X11/Xatom.h>
|
#include <X11/Xatom.h>
|
||||||
#include <System.h>
|
#include <System.h>
|
||||||
|
#include <Desktop.h>
|
||||||
#include "Panel/applet.h"
|
#include "Panel/applet.h"
|
||||||
#define _(string) gettext(string)
|
#define _(string) gettext(string)
|
||||||
|
|
||||||
|
@ -118,13 +119,8 @@ static Pager * _pager_init(PanelAppletHelper * helper, GtkWidget ** widget)
|
||||||
}
|
}
|
||||||
pager->helper = helper;
|
pager->helper = helper;
|
||||||
orientation = panel_window_get_orientation(helper->window);
|
orientation = panel_window_get_orientation(helper->window);
|
||||||
#if GTK_CHECK_VERSION(3, 0, 0)
|
|
||||||
pager->box = gtk_box_new(orientation, 0);
|
pager->box = gtk_box_new(orientation, 0);
|
||||||
gtk_box_set_homogeneous(GTK_BOX(pager->box), TRUE);
|
gtk_box_set_homogeneous(GTK_BOX(pager->box), TRUE);
|
||||||
#else
|
|
||||||
pager->box = (orientation == GTK_ORIENTATION_HORIZONTAL)
|
|
||||||
? gtk_hbox_new(TRUE, 0) : gtk_vbox_new(TRUE, 0);
|
|
||||||
#endif
|
|
||||||
pager->source = g_signal_connect(pager->box, "screen-changed",
|
pager->source = g_signal_connect(pager->box, "screen-changed",
|
||||||
G_CALLBACK(_pager_on_screen_changed), pager);
|
G_CALLBACK(_pager_on_screen_changed), pager);
|
||||||
pager->widgets = NULL;
|
pager->widgets = NULL;
|
||||||
|
|
|
@ -169,8 +169,8 @@ depends=../../include/Panel.h
|
||||||
[pager]
|
[pager]
|
||||||
type=plugin
|
type=plugin
|
||||||
sources=pager.c
|
sources=pager.c
|
||||||
cflags=`pkg-config --cflags x11`
|
cflags=`pkg-config --cflags libDesktop x11`
|
||||||
ldflags=`pkg-config --libs x11`
|
ldflags=`pkg-config --libs libDesktop x11`
|
||||||
install=$(LIBDIR)/Panel/applets
|
install=$(LIBDIR)/Panel/applets
|
||||||
|
|
||||||
[pager.c]
|
[pager.c]
|
||||||
|
|
Loading…
Reference in New Issue
Block a user