[maemo-commits] [maemo-commits] r10349 - in projects/haf/tags/hildon-theme-cacher: . 0.4.0-1 0.4.0-1/debian 0.4.0-1/scripts 0.4.0-1/src
From: subversion at stage.maemo.org subversion at stage.maemo.orgDate: Mon Mar 5 10:17:02 EET 2007
- Previous message: [maemo-commits] r10348 - in projects/haf/trunk/hildon-theme-cacher: . debian scripts
- Next message: [maemo-commits] r10350 - projects/haf/hafbuildbot
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Author: mdk Date: 2007-03-05 10:17:01 +0200 (Mon, 05 Mar 2007) New Revision: 10349 Added: projects/haf/tags/hildon-theme-cacher/0.4.0-1/ projects/haf/tags/hildon-theme-cacher/0.4.0-1/ChangeLog projects/haf/tags/hildon-theme-cacher/0.4.0-1/NEWS projects/haf/tags/hildon-theme-cacher/0.4.0-1/configure.ac projects/haf/tags/hildon-theme-cacher/0.4.0-1/debian/changelog projects/haf/tags/hildon-theme-cacher/0.4.0-1/scripts/hildon-theme-recache-all.in projects/haf/tags/hildon-theme-cacher/0.4.0-1/src/cacher.c Removed: projects/haf/tags/hildon-theme-cacher/0.4.0-1/ChangeLog projects/haf/tags/hildon-theme-cacher/0.4.0-1/NEWS projects/haf/tags/hildon-theme-cacher/0.4.0-1/configure.ac projects/haf/tags/hildon-theme-cacher/0.4.0-1/debian/changelog projects/haf/tags/hildon-theme-cacher/0.4.0-1/scripts/hildon-theme-recache-all.in projects/haf/tags/hildon-theme-cacher/0.4.0-1/src/cacher.c Log: Tagging for 0.4.0. Copied: projects/haf/tags/hildon-theme-cacher/0.4.0-1 (from rev 8331, projects/haf/trunk/hildon-theme-cacher) Deleted: projects/haf/tags/hildon-theme-cacher/0.4.0-1/ChangeLog =================================================================== --- projects/haf/trunk/hildon-theme-cacher/ChangeLog 2006-11-27 11:21:52 UTC (rev 8331) +++ projects/haf/tags/hildon-theme-cacher/0.4.0-1/ChangeLog 2007-03-05 08:17:01 UTC (rev 10349) @@ -1,6 +0,0 @@ -2006-11-22 Michael Dominic Kostrzewa <michael.kostrzewa at nokia.com> - - * ./: Initially deriving from cache tool from hildon-theme-tools. - Modyfying to recursively scan all sub-directories. Adding a script to - scan everything. - Copied: projects/haf/tags/hildon-theme-cacher/0.4.0-1/ChangeLog (from rev 10348, projects/haf/trunk/hildon-theme-cacher/ChangeLog) Deleted: projects/haf/tags/hildon-theme-cacher/0.4.0-1/NEWS =================================================================== Copied: projects/haf/tags/hildon-theme-cacher/0.4.0-1/NEWS (from rev 10348, projects/haf/trunk/hildon-theme-cacher/NEWS) Deleted: projects/haf/tags/hildon-theme-cacher/0.4.0-1/configure.ac =================================================================== --- projects/haf/trunk/hildon-theme-cacher/configure.ac 2006-11-27 11:21:52 UTC (rev 8331) +++ projects/haf/tags/hildon-theme-cacher/0.4.0-1/configure.ac 2007-03-05 08:17:01 UTC (rev 10349) @@ -1,24 +0,0 @@ -AC_INIT(Makefile.am) -AM_INIT_AUTOMAKE(hildon-theme-cacher, 0.1.0) -AM_CONFIG_HEADER(config.h) - -AC_CANONICAL_HOST - -AC_PROG_CC -AC_PROG_INSTALL -AC_HEADER_STDC - -CFLAGS="$CFLAGS -Wall -pedantic -Wmissing-prototypes -Wmissing-declarations -Werror" - -GTK_VERSION=2.6.4 - -PKG_CHECK_MODULES(GTK, gtk+-2.0 >= $GTK_VERSION) -AC_SUBST(GTK_LIBS) -AC_SUBST(GTK_CFLAGS) -AC_SUBST(GTK_VERSION) - -AC_OUTPUT([Makefile \ - scripts/Makefile \ - src/Makefile \ - scripts/hildon-theme-recache-all]) - Copied: projects/haf/tags/hildon-theme-cacher/0.4.0-1/configure.ac (from rev 10348, projects/haf/trunk/hildon-theme-cacher/configure.ac) Deleted: projects/haf/tags/hildon-theme-cacher/0.4.0-1/debian/changelog =================================================================== --- projects/haf/trunk/hildon-theme-cacher/debian/changelog 2006-11-27 11:21:52 UTC (rev 8331) +++ projects/haf/tags/hildon-theme-cacher/0.4.0-1/debian/changelog 2007-03-05 08:17:01 UTC (rev 10349) @@ -1,6 +0,0 @@ -hildon-theme-cacher (0.1.0-1) unstable; urgency=low - - * First official release. - - -- Michael Dominic Kostrzewa <michael.kostrzewa at nokia.com> Fri, 20 Nov 2006 14:55:06 +0300 - Copied: projects/haf/tags/hildon-theme-cacher/0.4.0-1/debian/changelog (from rev 10348, projects/haf/trunk/hildon-theme-cacher/debian/changelog) Deleted: projects/haf/tags/hildon-theme-cacher/0.4.0-1/scripts/hildon-theme-recache-all.in =================================================================== --- projects/haf/trunk/hildon-theme-cacher/scripts/hildon-theme-recache-all.in 2006-11-27 11:21:52 UTC (rev 8331) +++ projects/haf/tags/hildon-theme-cacher/0.4.0-1/scripts/hildon-theme-recache-all.in 2007-03-05 08:17:01 UTC (rev 10349) @@ -1,4 +0,0 @@ -#! /usr/bin/sh - -hildon-theme-cacher @prefix@/share/themes - Copied: projects/haf/tags/hildon-theme-cacher/0.4.0-1/scripts/hildon-theme-recache-all.in (from rev 10348, projects/haf/trunk/hildon-theme-cacher/scripts/hildon-theme-recache-all.in) Deleted: projects/haf/tags/hildon-theme-cacher/0.4.0-1/src/cacher.c =================================================================== --- projects/haf/trunk/hildon-theme-cacher/src/cacher.c 2006-11-27 11:21:52 UTC (rev 8331) +++ projects/haf/tags/hildon-theme-cacher/0.4.0-1/src/cacher.c 2007-03-05 08:17:01 UTC (rev 10349) @@ -1,119 +0,0 @@ -/* - * GPL license, Copyright (c) 2006 by Nokia Corporation - * - * Authors: - * Tommi Komulainen <tommi.komulainen at nokia.com> - * Michael Dominic K. <michael.kostrzewa at nokia.com> - * - * This program is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License as published by the - * Free Software Foundation, version 2. - * - * This program is distributed in the hope that it will be useful, but - * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY - * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * for more details. - * - * You should have received a copy of the GNU General Public License along - * with this program; if not, write to the Free Software Foundation, Inc., 59 - * Temple Place - Suite 330, Boston, MA 02111-1307, USA. - * - */ - -#include <gtk/gtk.h> -#include "cacher.h" - -/* Parses (resursively) the directory and adds gtkrc matches. - * We assume everything that HAS *gtkrc* and DOESN'T HAVE *cache* - * is a valid gtkrc cache. */ -GSList* parse_dir (const gchar *dir_name, GSList *list, int level) -{ - const gchar *file_name = NULL; - GDir *dir = NULL; - - g_return_val_if_fail (dir_name != NULL, list); - - /* This is a poor-man's protection so that we don't - * go into infinite loop due to broken symlinking */ - if (level > SANITY_LEVEL) - return list; - - dir = g_dir_open (dir_name, 0, NULL); - if (dir == NULL) { - g_warning ("Failed to read '%s' directory!", dir_name); - return list; - } - - while ((file_name = g_dir_read_name (dir)) != NULL) { - gchar *path = g_build_filename (dir_name, file_name, NULL); - - if (g_file_test (path, G_FILE_TEST_IS_REGULAR) && - g_strrstr (file_name, "gtkrc") != NULL && - g_strrstr (file_name, "cache") == NULL) - list = g_slist_append (list, path); - else if (g_file_test (path, G_FILE_TEST_IS_DIR)) - list = parse_dir (path, list, level + 1); - } - - return list; -} - -/* Shows the initial copyright/info banner */ -void show_banner (void) -{ - g_print ("Theme cache tool by Tommi Komulainen and Michael Dominic Kostrzewa\n"); - g_print ("Copyright 2006 by Nokia Corporation.\n\n"); -} - -/* Show some info about basic usage of the tool */ -void show_usage (void) -{ - g_print ("Usage: %s <theme-directory>\n\n", g_get_prgname ()); - g_print ("This tool will pre-generate the cache (.cache) files for gtkrc files.\n" - "It will scan recursively the specified directory and generate the cache for ALL\n" - "the gtk rc files found.\n\n"); -} - -int main (int argc, char **argv) -{ - GtkSettings *settings; - GSList *rc_list = NULL; - GSList *iterator = NULL; - - show_banner (); - gtk_init_check (&argc, &argv); - - if (argc < 2) { - show_usage (); - return 1; - } - - g_setenv ("GSCANNERCACHE_CREATE", "1", TRUE); - - /* Get the list of all gtkrc files */ - rc_list = parse_dir (argv [1], NULL, 1); - - /* Iterate through all themes and generate cache */ - iterator = rc_list; - while (iterator != NULL) { - g_print ("Generating %s.cache\n", (char *) iterator->data); - gtk_rc_parse ((char *) iterator->data); - iterator = g_slist_next (iterator); - } - - settings = g_object_new (GTK_TYPE_SETTINGS, NULL); - gtk_rc_reparse_all_for_settings (settings, TRUE); - - /* Free list */ - iterator = rc_list; - while (iterator != NULL) { - if (iterator->data != NULL) - g_free (iterator->data); - iterator = g_slist_next (iterator); - } - g_slist_free (rc_list); - - g_print ("\nDone!\n"); - - return 0; -} Copied: projects/haf/tags/hildon-theme-cacher/0.4.0-1/src/cacher.c (from rev 10102, projects/haf/trunk/hildon-theme-cacher/src/cacher.c)
- Previous message: [maemo-commits] r10348 - in projects/haf/trunk/hildon-theme-cacher: . debian scripts
- Next message: [maemo-commits] r10350 - projects/haf/hafbuildbot
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]