Merge lp:~charlesk/indicator-datetime/nogtk2 into lp:indicator-datetime/12.10

Proposed by Charles Kerr
Status: Merged
Approved by: Lars Karlitski
Approved revision: 177
Merged at revision: 176
Proposed branch: lp:~charlesk/indicator-datetime/nogtk2
Merge into: lp:indicator-datetime/12.10
Diff against target: 127 lines (+10/-51)
3 files modified
configure.ac (+10/-36)
src/datetime-service.c (+0/-7)
src/indicator-datetime.c (+0/-8)
To merge this branch: bzr merge lp:~charlesk/indicator-datetime/nogtk2
Reviewer Review Type Date Requested Status
Lars Karlitski (community) Approve
Review via email: mp+105005@code.launchpad.net
To post a comment you must log in.
177. By Charles Kerr

remove AC_ARG_WITH

Revision history for this message
Lars Karlitski (larsu) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'configure.ac'
--- configure.ac 2012-04-04 21:06:51 +0000
+++ configure.ac 2012-05-08 23:03:19 +0000
@@ -43,16 +43,6 @@
43PKG_PROG_PKG_CONFIG43PKG_PROG_PKG_CONFIG
4444
45###########################45###########################
46# GTK+ version option
47###########################
48
49AC_ARG_WITH([gtk],
50 [AS_HELP_STRING([--with-gtk],
51 [Which version of gtk to use for the indicator @<:@default=3@:>@])],
52 [],
53 [with_gtk=3])
54
55###########################
56# Dependencies46# Dependencies
57###########################47###########################
5848
@@ -71,22 +61,11 @@
71GTK3_REQUIRED_VERSION=3.1.461GTK3_REQUIRED_VERSION=3.1.4
72GCONF_REQUIRED_VERSION=2.3162GCONF_REQUIRED_VERSION=2.31
7363
74AS_IF([test "x$with_gtk" = x3],64PKG_CHECK_MODULES(INDICATOR, indicator3-0.4 >= $INDICATOR_REQUIRED_VERSION
75 [PKG_CHECK_MODULES(INDICATOR, indicator3-0.4 >= $INDICATOR_REQUIRED_VERSION65 glib-2.0 >= $GLIB_REQUIRED_VERSION
76 glib-2.0 >= $GLIB_REQUIRED_VERSION66 dbusmenu-glib-0.4 >= $DBUSMENUGLIB_REQUIRED_VERSION
77 dbusmenu-glib-0.4 >= $DBUSMENUGLIB_REQUIRED_VERSION67 dbusmenu-gtk3-0.4 >= $DBUSMENUGTK_REQUIRED_VERSION
78 dbusmenu-gtk3-0.4 >= $DBUSMENUGTK_REQUIRED_VERSION68 libido3-0.1 >= $INDICATOR_DISPLAY_OBJECTS)
79 libido3-0.1 >= $INDICATOR_DISPLAY_OBJECTS)
80 ],
81 [test "x$with_gtk" = x2],
82 [PKG_CHECK_MODULES(INDICATOR, indicator-0.4 >= $INDICATOR_REQUIRED_VERSION
83 glib-2.0 >= $GLIB_REQUIRED_VERSION
84 dbusmenu-glib-0.4 >= $DBUSMENUGLIB_REQUIRED_VERSION
85 dbusmenu-gtk-0.4 >= $DBUSMENUGTK_REQUIRED_VERSION
86 libido-0.1 >= $INDICATOR_DISPLAY_OBJECTS)
87 ],
88 [AC_MSG_FAILURE([Value for --with-gtk was neither 2 nor 3])]
89)
9069
91PKG_CHECK_MODULES(SERVICE, indicator3-0.4 >= $INDICATOR_REQUIRED_VERSION70PKG_CHECK_MODULES(SERVICE, indicator3-0.4 >= $INDICATOR_REQUIRED_VERSION
92 glib-2.0 >= $GLIB_REQUIRED_VERSION71 glib-2.0 >= $GLIB_REQUIRED_VERSION
@@ -123,7 +102,7 @@
123 if test x${have_ccpanel} = xyes; then102 if test x${have_ccpanel} = xyes; then
124 AC_DEFINE(HAVE_CCPANEL, 1, [Define to 1 to enable Control Center panel])103 AC_DEFINE(HAVE_CCPANEL, 1, [Define to 1 to enable Control Center panel])
125 PKG_CHECK_MODULES(LIBMAP, gio-2.0 >= $GIO_REQUIRED_VERSION104 PKG_CHECK_MODULES(LIBMAP, gio-2.0 >= $GIO_REQUIRED_VERSION
126 gtk+-3.0 >= $GTK3_REQUIRED_VERSION)105 gtk+-3.0 >= $GTK3_REQUIRED_VERSION)
127 fi106 fi
128 if test x${with_ccpanel} = xyes && test x${have_ccpanel} = xno; then107 if test x${with_ccpanel} = xyes && test x${have_ccpanel} = xno; then
129 AC_MSG_ERROR([Control Center panel configured but not found])108 AC_MSG_ERROR([Control Center panel configured but not found])
@@ -167,15 +146,10 @@
167 INDICATORDIR="${libdir}/indicators/2/"146 INDICATORDIR="${libdir}/indicators/2/"
168 INDICATORICONSDIR="${datadir}/libindicate/icons/"147 INDICATORICONSDIR="${datadir}/libindicate/icons/"
169 ],148 ],
170 [AS_IF([test "x$with_gtk" = "x2"],149 [
171 [150 INDICATORDIR=`$PKG_CONFIG --variable=indicatordir indicator3-0.4`
172 INDICATORDIR=`$PKG_CONFIG --variable=indicatordir indicator-0.4`151 INDICATORICONSDIR=`$PKG_CONFIG --variable=iconsdir indicator3-0.4`
173 INDICATORICONSDIR=`$PKG_CONFIG --variable=iconsdir indicator-0.4`152 ])
174 ],
175 [
176 INDICATORDIR=`$PKG_CONFIG --variable=indicatordir indicator3-0.4`
177 INDICATORICONSDIR=`$PKG_CONFIG --variable=iconsdir indicator3-0.4`
178 ])])
179153
180AC_SUBST(INDICATORDIR)154AC_SUBST(INDICATORDIR)
181AC_SUBST(INDICATORICONSDIR)155AC_SUBST(INDICATORICONSDIR)
182156
=== modified file 'src/datetime-service.c'
--- src/datetime-service.c 2012-04-23 00:30:07 +0000
+++ src/datetime-service.c 2012-05-08 23:03:19 +0000
@@ -952,17 +952,10 @@
952 if (color_spec != NULL) {952 if (color_spec != NULL) {
953 g_debug("Creating a cairo surface: size, %d by %d", width, height); 953 g_debug("Creating a cairo surface: size, %d by %d", width, height);
954 cairo_surface_t *surface = cairo_image_surface_create( CAIRO_FORMAT_ARGB32, width, height ); 954 cairo_surface_t *surface = cairo_image_surface_create( CAIRO_FORMAT_ARGB32, width, height );
955
956 cairo_t *cr = cairo_create(surface);955 cairo_t *cr = cairo_create(surface);
957#if GTK_CHECK_VERSION(3,0,0)
958 GdkRGBA rgba;956 GdkRGBA rgba;
959 if (gdk_rgba_parse (&rgba, color_spec))957 if (gdk_rgba_parse (&rgba, color_spec))
960 gdk_cairo_set_source_rgba (cr, &rgba);958 gdk_cairo_set_source_rgba (cr, &rgba);
961#else
962 GdkColor color;
963 if (gdk_color_parse (color_spec, &color))
964 gdk_cairo_set_source_color (cr, &color);
965#endif
966 cairo_paint(cr);959 cairo_paint(cr);
967 cairo_set_source_rgba(cr, 0,0,0,0.5);960 cairo_set_source_rgba(cr, 0,0,0,0.5);
968 cairo_set_line_width(cr, 1);961 cairo_set_line_width(cr, 1);
969962
=== modified file 'src/indicator-datetime.c'
--- src/indicator-datetime.c 2012-03-07 20:49:58 +0000
+++ src/indicator-datetime.c 2012-05-08 23:03:19 +0000
@@ -1220,11 +1220,7 @@
12201220
1221 mi_data->gmi = gtk_menu_item_new();1221 mi_data->gmi = gtk_menu_item_new();
12221222
1223#if GTK_CHECK_VERSION(3,0,0)
1224 GtkWidget * hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 4);1223 GtkWidget * hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 4);
1225#else
1226 GtkWidget * hbox = gtk_hbox_new(FALSE, 4);
1227#endif
12281224
1229 /* Icon, probably someone's face or avatar on an IM */1225 /* Icon, probably someone's face or avatar on an IM */
1230 mi_data->icon = gtk_image_new();1226 mi_data->icon = gtk_image_new();
@@ -1435,11 +1431,7 @@
1435 gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(mi_data->gmi),1431 gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(mi_data->gmi),
1436 dbusmenu_menuitem_property_get_bool(newitem, TIMEZONE_MENUITEM_PROP_RADIO));1432 dbusmenu_menuitem_property_get_bool(newitem, TIMEZONE_MENUITEM_PROP_RADIO));
14371433
1438#if GTK_CHECK_VERSION(3,0,0)
1439 GtkWidget * hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 4);1434 GtkWidget * hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 4);
1440#else
1441 GtkWidget * hbox = gtk_hbox_new(FALSE, 4);
1442#endif
14431435
1444 /* Label, probably a username, chat room or mailbox name */1436 /* Label, probably a username, chat room or mailbox name */
1445 mi_data->label = gtk_label_new("");1437 mi_data->label = gtk_label_new("");

Subscribers

People subscribed via source and target branches