[gtkmm] AboutDialog: Add unset_license() and set_logo_default().



commit d957d01e1adb32c20a1b25deed363765d3edb33a
Author: Kjell Ahlstedt <kjell ahlstedt bredband net>
Date:   Wed Nov 9 16:57:33 2011 +0100

    AboutDialog: Add unset_license() and set_logo_default().
    
    * gtk/src/aboutdialog.[hg|ccg]: Add unset_license() and set_logo_default().
    Remove an obsolete comment. Bug #616769.

 ChangeLog               |    7 +++++++
 gtk/src/aboutdialog.ccg |   16 ++++++++++++++++
 gtk/src/aboutdialog.hg  |   15 ++++++++++++++-
 3 files changed, 37 insertions(+), 1 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 7a9802d..285dbb0 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2011-11-09  Kjell Ahlstedt  <kjell ahlstedt bredband net>
+
+	AboutDialog: Add unset_license() and set_logo_default().
+
+	* gtk/src/aboutdialog.[hg|ccg]: Add unset_license() and set_logo_default().
+	Remove an obsolete comment. Bug #616769.
+
 3.3.2 (unstable):
 
 2011-10-26  Murray Cumming  <murrayc murrayc com>
diff --git a/gtk/src/aboutdialog.ccg b/gtk/src/aboutdialog.ccg
index 66ca001..0c1f7e4 100644
--- a/gtk/src/aboutdialog.ccg
+++ b/gtk/src/aboutdialog.ccg
@@ -23,3 +23,19 @@
 #include <glibmm/vectorutils.h>
 
 #include <gtk/gtk.h>
+
+namespace Gtk
+{
+
+void AboutDialog::unset_license()
+{
+  gtk_about_dialog_set_license(gobj(), 0); 
+}
+
+void AboutDialog::set_logo_default()
+{
+  gtk_about_dialog_set_logo(gobj(), 0); 
+}
+
+} // namespace Gtk
+
diff --git a/gtk/src/aboutdialog.hg b/gtk/src/aboutdialog.hg
index 10028df..769bad0 100644
--- a/gtk/src/aboutdialog.hg
+++ b/gtk/src/aboutdialog.hg
@@ -30,7 +30,6 @@ namespace Gtk
 
 _WRAP_ENUM(License, GtkLicense)
 
-//TODO: Remove the mention of set_*_hook() when the C documentation has been fixed: https://bugzilla.gnome.org/show_bug.cgi?id=339745
 /** The AboutDialog offers a simple way to display information about a program like its logo, name, copyright,
  * website and license. It is also possible to give credits to the authors, documenters, translators and artists
  * who have worked on the program. An about dialog is typically opened when the user selects the About option
@@ -66,6 +65,12 @@ public:
   _WRAP_METHOD(void set_comments(const Glib::ustring& comments), gtk_about_dialog_set_comments)
   _WRAP_METHOD(Glib::ustring get_license() const, gtk_about_dialog_get_license)
   _WRAP_METHOD(void set_license(const Glib::ustring& license), gtk_about_dialog_set_license)
+
+  /** Hides the license button.
+   * 
+   * @newin{3,4}
+   */
+  void unset_license();
   _WRAP_METHOD(License get_license_type() const, gtk_about_dialog_get_license_type)
   _WRAP_METHOD(void set_license_type(License license_type), gtk_about_dialog_set_license_type)
   _WRAP_METHOD(Glib::ustring get_website() const, gtk_about_dialog_get_website)
@@ -92,6 +97,14 @@ public:
 
   _WRAP_METHOD(void set_logo(const Glib::RefPtr<Gdk::Pixbuf>& logo), gtk_about_dialog_set_logo)
 
+  /** Sets the pixbuf to be displayed as logo in the about dialog.
+   * The logo is set to the default window icon set with
+   * Gtk::Window::set_default_icon() or Gtk::Window::set_default_icon_list().
+   * 
+   * @newin{3,4}
+   */
+  void set_logo_default();
+
   _WRAP_METHOD(Glib::ustring get_logo_icon_name() const, gtk_about_dialog_get_logo_icon_name)
   _WRAP_METHOD(void set_logo_icon_name(const Glib::ustring& icon_name), gtk_about_dialog_set_logo_icon_name)
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]