2006-11-16 Michael Dominic Kostrzewa <michael.kostrzewa@nokia.com>
authorMichael Dominic Kostrzewa <michael.kostrzewa@nokia.com>
Thu, 16 Nov 2006 12:02:41 +0000 (12:02 +0000)
committerMichael Dominic Kostrzewa <michael.kostrzewa@nokia.com>
Thu, 16 Nov 2006 12:02:41 +0000 (12:02 +0000)
* src/Makefile.am:
* src/gtk-infoprint.c:
* src/gtk-infoprint.h: Removing the infoprints for good.

ChangeLog
src/Makefile.am
src/gtk-infoprint.c [deleted file]
src/gtk-infoprint.h [deleted file]

index f06e076..0443f77 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,11 @@
 2006-11-16  Michael Dominic Kostrzewa  <michael.kostrzewa@nokia.com> 
 
+       * src/Makefile.am:
+       * src/gtk-infoprint.c:
+       * src/gtk-infoprint.h: Removing the infoprints for good.
+
+2006-11-16  Michael Dominic Kostrzewa  <michael.kostrzewa@nokia.com> 
+
        * hildon-date-editor.c:
        * hildon-date-editor.h:
        * hildon-time-editor.h: Switching to a common DateTime editor error
index fd92e28..ab18502 100644 (file)
@@ -49,7 +49,6 @@ libhildonwidgets_la_SOURCES                           = hildon-composite-widget.c \
                                                          hildon-color-button.c \
                                                          hildon-defines.c \
                                                          hildon-find-toolbar.c \
-                                                         gtk-infoprint.c \
                                                          hildon-banner.c \
                                                          hildon-caption.c \
                                                          hildon-window.c \
@@ -88,7 +87,6 @@ libhildonwidgets_include_HEADERS                      = hildon-controlbar.h \
                                                          hildon-color-button.h \
                                                          hildon-defines.h \
                                                          hildon-find-toolbar.h \
-                                                         gtk-infoprint.h \
                                                          hildon-banner.h \
                                                          hildon-input-mode-hint.h \
                                                          hildon-caption.h \
diff --git a/src/gtk-infoprint.c b/src/gtk-infoprint.c
deleted file mode 100644 (file)
index 0f9be2a..0000000
+++ /dev/null
@@ -1,341 +0,0 @@
-/*
- * This file is part of hildon-libs
- *
- * Copyright (C) 2005, 2006 Nokia Corporation, all rights reserved.
- *
- * Contact: Michael Dominic Kostrzewa <michael.kostrzewa@nokia.com>
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public License
- * as published by the Free Software Foundation; version 2.1 of
- * the License.
- *
- * This library 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
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA
- *
- */
-
-/**
- * SECTION:gtk-infoprint
- * @short_description: deprecated widget. Use #HildonBanner instead
- *
- * This widget is deprecated. Use #HildonBanner instead
- */
-
-#include "gtk-infoprint.h"
-#include "hildon-banner.h"
-
-/* This is a helper function that searches the banner for
-   given window. This is needed to provide backwards
-   compatibility. */
-static GtkWidget *find_banner_for_parent(GtkWindow *parent)
-{
-   GList *toplevels, *iter;
-   GtkWidget *result = NULL;
-   gboolean is_timed;
-
-   toplevels = gtk_window_list_toplevels();
-   for (iter = toplevels; iter; iter = iter->next)
-      if (HILDON_IS_BANNER(iter->data) && 
-          gtk_window_get_transient_for(GTK_WINDOW(iter->data)) == parent)
-      {
-         g_object_get(iter->data, "is-timed", &is_timed, NULL);
-
-         /* We do not want to touch timed infoprints */
-         if (!is_timed) {
-           result = iter->data;
-           break;
-         }
-      }
-
-   g_list_free(toplevels);
-   return result;
-}
-
-/**************************************************/
-/** Public                                       **/
-/**************************************************/
-
-/**
- * gtk_infoprint:
- * @parent: The transient window for the infoprint.
- * @text: The text in infoprint
- *
- * Opens a new infoprint with @text content.
- * 
- * If parent is %NULL, the infoprint is a system infoprint.
- * Normally you should use your application window
- * or dialog as a transient parent and avoid passing %NULL.
- *
- * Deprecated: Use #hildon_banner_show_information instead.
- */
-void gtk_infoprint(GtkWindow * parent, const gchar * text)
-{
-    hildon_banner_show_information((GtkWidget *) parent, NULL, text);    
-}
-
-/**
- * gtk_infoprint_with_icon_stock:
- * @parent: The transient window for the infoprint.
- * @text: The text in infoprint
- * @stock_id: The stock id of the custom icon
- *
- * Opens a new infoprint with @text content.
- * With this function you can also set a custom icon
- * by giving a stock id as last parameter.
- * 
- * If parent is %NULL, the infoprint is a system infoprint.
- * Normally you should use your application window
- * or dialog as a transient parent and avoid passing %NULL.
- *
- * Deprecated: Use #hildon_banner_show_information instead.
- */
-void
-gtk_infoprint_with_icon_stock(GtkWindow * parent,
-                              const gchar * text, const gchar * stock_id)
-{
-   hildon_banner_show_information((GtkWidget *) parent, NULL, text);
-}
-
-/**
- * gtk_infoprint_with_icon_name:
- * @parent: The transient window for the infoprint.
- * @text: The text in infoprint
- * @icon_name: The name of the icon
- *
- * Opens a new infoprint with @text content.
- * With this function you can also set a custom icon
- * by giving a icon name as last parameter.
- * 
- * If parent is %NULL, the infoprint is a system infoprint.
- * Normally you should use your application window
- * or dialog as a transient parent and avoid passing %NULL.
- *
- * Deprecated: Use #hildon_banner_show_information instead.
- */
-void
-gtk_infoprint_with_icon_name(GtkWindow * parent,
-                              const gchar * text, const gchar * icon_name)
-{
-   hildon_banner_show_information((GtkWidget *) parent, icon_name, text);
-}                                                                        
-
-/**
- * gtk_infoprintf:
- * @parent: The transient window for the infoprint.
- * @format: Format of the text.
- * @Varargs: List of parameters.
- *
- * Opens a new infoprint with @text printf-style formatting
- * string and comma-separated list of parameters.
- * 
- * If parent is %NULL, the infoprint is a system infoprint.
- * This version of infoprint allow you to make printf-like formatting
- * easily.
- *
- * Deprecated: Use #hildon_banner_show_information instead.
- */
-void gtk_infoprintf(GtkWindow * parent, const gchar * format, ...)
-{
-    gchar *message;
-    va_list args;
-
-    va_start(args, format);
-    message = g_strdup_vprintf(format, args);
-    va_end(args);
-
-    gtk_infoprint(parent, message);
-
-    g_free(message);
-}
-
-/**
- * gtk_infoprint_temporarily_disable_wrap:
- * 
- * Will disable wrapping for the next shown infoprint. This only
- * affects next infoprint shown in this application.
- *
- * Currently it does nothing.
- *
- * Deprecated: 
- */
-void gtk_infoprint_temporarily_disable_wrap(void)
-{
-}
-
-/**
- * gtk_confirmation_banner:
- * @parent: The transient window for the confirmation banner.
- * @text: The text in confirmation banner
- * @stock_id: The stock id of the custom icon
- *
- * Opens a new confirmation banner with @text content.
- * With this function you can also set a custom icon
- * by giving a stock id as last parameter.
- *
- * If parent is %NULL, the banner is a system banner.
- * Normally you should use your application window
- * or dialog as a transient parent and avoid passing %NULL.
- * 
- * This function is otherwise similar to
- * gtk_infoprint_with_icon_stock except in always restricts
- * the text to one line and the font is emphasized.
- *
- * Deprecated: Use #hildon_banner_show_information instead.
- */
-void
-gtk_confirmation_banner(GtkWindow * parent, const gchar * text,
-                        const gchar * stock_id)
-{
-  gchar *s;
-  s = g_strdup_printf("<b>%s</b>", text);
-
-  hildon_banner_show_information_with_markup((GtkWidget *) parent, NULL, s);
-
-  g_free(s);
-}
-
-/**
- * gtk_confirmation_banner_with_icon_name:
- * @parent: The transient window for the confirmation banner.
- * @text: The text in confirmation banner
- * @icon_name: The name of the custom icon in icon theme
- *
- * Opens a new confirmation banner with @text content.
- * With this function you can also set a custom icon
- * by giving a icon theme's icon name as last parameter.
- *
- * If parent is %NULL, the banner is a system banner.
- * Normally you should use your application window
- * or dialog as a transient parent and avoid passing %NULL.
- * 
- * This function is otherwise similar to
- * gtk_infoprint_with_icon_name except in always restricts
- * the text to one line and the font is emphasized.
- *
- * Deprecated: Use #hildon_banner_show_information instead.
- */
-void
-gtk_confirmation_banner_with_icon_name(GtkWindow * parent, const gchar * text,
-                        const gchar * icon_name)
-{
-  gchar *s;
-  s = g_strdup_printf("<b>%s</b>", text);
-
-  hildon_banner_show_information_with_markup((GtkWidget *) parent, icon_name, s);
-
-  g_free(s);
-}
-
-/**
- * gtk_banner_show_animation:
- * @parent: #GtkWindow
- * @text: #const gchar *
- *
- * The @text is the text shown in banner.
- * Creates a new banner with the animation.
- *
- * Deprecated: Use #hildon_banner_show_animation instead.
- */
-void gtk_banner_show_animation(GtkWindow * parent, const gchar * text)
-{
-   (void) hildon_banner_show_animation((GtkWidget *) parent, NULL, text);
-}
-
-/**
- * gtk_banner_show_bar
- * @parent: #GtkWindow
- * @text: #const gchar *
- *
- * The @text is the text shown in banner.
- * Creates a new banner with the progressbar.
- *
- * Deprecated: Use #hildon_banner_show_progress instead.
- */
-void gtk_banner_show_bar(GtkWindow * parent, const gchar * text)
-{
-   (void) hildon_banner_show_progress((GtkWidget *) parent, NULL, text);
-}
-
-/**
- * gtk_banner_set_text
- * @parent: #GtkWindow
- * @text: #const gchar *
- *
- * The @text is the text shown in banner.
- * Sets the banner text.
- *
- * Deprecated: Use #hildon_banner_set_text instead.
- */
-void gtk_banner_set_text(GtkWindow * parent, const gchar * text)
-{
-   GtkWidget *banner;
-
-   g_return_if_fail(GTK_IS_WINDOW(parent) || parent == NULL);
-
-   banner = find_banner_for_parent(parent);
-   if (banner)
-      hildon_banner_set_text(HILDON_BANNER(banner), text);
-}
-
-/**
- * gtk_banner_set_fraction:
- * @parent: #GtkWindow
- * @fraction: #gdouble
- *
- * The fraction is the completion of progressbar, 
- * the scale is from 0.0 to 1.0.
- * Sets the amount of fraction the progressbar has.
- *
- * Deprecated: Use #hildon_banner_set_fraction instead.
- */
-void gtk_banner_set_fraction(GtkWindow * parent, gdouble fraction)
-{
-   GtkWidget *banner;
-
-   g_return_if_fail(GTK_IS_WINDOW(parent) || parent == NULL);
-
-   banner = find_banner_for_parent(parent);
-   if (banner)
-      hildon_banner_set_fraction(HILDON_BANNER(banner), fraction);
-}
-
-/**
- * gtk_banner_close:
- * @parent: #GtkWindow
- *
- * Destroys the banner
- *
- * Deprecated:
- */
-void gtk_banner_close(GtkWindow * parent)
-{
-   GtkWidget *banner;
-
-   g_return_if_fail(GTK_IS_WINDOW(parent) || parent == NULL);
-
-   banner = find_banner_for_parent(parent);
-   if (banner)
-      gtk_widget_destroy(banner);
-}
-
-/**
- * gtk_banner_temporarily_disable_wrap
- * 
- * Will disable wrapping for the next shown banner. This only
- * affects next banner shown in this application.
- *
- * Currently it does nothing.
- *
- * Deprecated:
- **/
-void gtk_banner_temporarily_disable_wrap(void)
-{
-}
diff --git a/src/gtk-infoprint.h b/src/gtk-infoprint.h
deleted file mode 100644 (file)
index d97b212..0000000
+++ /dev/null
@@ -1,52 +0,0 @@
-/*
- * This file is part of hildon-libs
- *
- * Copyright (C) 2005, 2006 Nokia Corporation, all rights reserved.
- *
- * Contact: Michael Dominic Kostrzewa <michael.kostrzewa@nokia.com>
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public License
- * as published by the Free Software Foundation; version 2.1 of
- * the License.
- *
- * This library 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
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA
- *
- */
-
-#ifndef __GTK_INFOPRINT_H__
-#define __GTK_INFOPRINT_H__
-
-#include <gtk/gtkwindow.h>
-
-G_BEGIN_DECLS void gtk_infoprint(GtkWindow * parent, const gchar * text);
-void gtk_infoprint_with_icon_stock(GtkWindow * parent, const gchar * text,
-                                   const gchar * stock_id);
-void gtk_infoprint_with_icon_name(GtkWindow * parent, const gchar * text,
-                                   const gchar * icon_name);
-
-void gtk_infoprintf(GtkWindow * parent, const gchar * format, ...);
-void gtk_infoprint_temporarily_disable_wrap(void);
-
-void gtk_confirmation_banner_with_icon_name(GtkWindow * parent, const gchar * text,
-                             const gchar * icon_name);
-void gtk_confirmation_banner(GtkWindow * parent, const gchar * text,
-                             const gchar * stock_id);
-
-void gtk_banner_show_animation(GtkWindow * parent, const gchar * text);
-void gtk_banner_show_bar(GtkWindow * parent, const gchar * text);
-void gtk_banner_set_text(GtkWindow * parent, const gchar * text);
-void gtk_banner_set_fraction(GtkWindow * parent, gdouble fraction);
-void gtk_banner_close(GtkWindow * parent);
-void gtk_banner_temporarily_disable_wrap(void);
-
-G_END_DECLS
-#endif /* __GTK_INFOPRINT_H__ */