gimp r25265 - in trunk: . app app/config app/dialogs app/gui



Author: neo
Date: Thu Mar 27 19:42:22 2008
New Revision: 25265
URL: http://svn.gnome.org/viewvc/gimp?rev=25265&view=rev

Log:
2008-03-27  Sven Neumann  <sven gimp org>

	Preparing for a revamp of the "Tip of the Day" feature:

	* app/config/gimpguiconfig.[ch]: removed "show-tips" property.

	* app/gui/gui.[ch]: removed gui_post_init() as it's only purpose 
was
	to show the tips dialog.

	* app/app.c: changed accordingly.

	* app/dialogs/tips-dialog.c: removed some stuff that we are not
	going to need any longer.



Modified:
   trunk/ChangeLog
   trunk/app/app.c
   trunk/app/config/gimpguiconfig.c
   trunk/app/config/gimpguiconfig.h
   trunk/app/dialogs/tips-dialog.c
   trunk/app/gui/gui.c
   trunk/app/gui/gui.h

Modified: trunk/app/app.c
==============================================================================
--- trunk/app/app.c	(original)
+++ trunk/app/app.c	Thu Mar 27 19:42:22 2008
@@ -231,11 +231,6 @@
         file_open_from_command_line (gimp, filenames[i], as_new);
     }
 
-#ifndef GIMP_CONSOLE_COMPILATION
-  if (! no_interface)
-    gui_post_init (gimp);
-#endif
-
   batch_run (gimp, batch_interpreter, batch_commands);
 
   loop = g_main_loop_new (NULL, FALSE);

Modified: trunk/app/config/gimpguiconfig.c
==============================================================================
--- trunk/app/config/gimpguiconfig.c	(original)
+++ trunk/app/config/gimpguiconfig.c	Thu Mar 27 19:42:22 2008
@@ -56,7 +56,6 @@
   PROP_SAVE_SESSION_INFO,
   PROP_RESTORE_SESSION,
   PROP_SAVE_TOOL_OPTIONS,
-  PROP_SHOW_TIPS,
   PROP_SHOW_TOOLTIPS,
   PROP_TEAROFF_MENUS,
   PROP_CAN_CHANGE_ACCELS,
@@ -82,7 +81,8 @@
 
   /* ignored, only for backward compatibility: */
   PROP_INFO_WINDOW_PER_DISPLAY,
-  PROP_SHOW_TOOL_TIPS
+  PROP_SHOW_TOOL_TIPS,
+  PROP_SHOW_TIPS
 };
 
 
@@ -145,10 +145,6 @@
                                     SAVE_TOOL_OPTIONS_BLURB,
                                     FALSE,
                                     GIMP_PARAM_STATIC_STRINGS);
-  GIMP_CONFIG_INSTALL_PROP_BOOLEAN (object_class, PROP_SHOW_TIPS,
-                                    "show-tips", SHOW_TIPS_BLURB,
-                                    TRUE,
-                                    GIMP_PARAM_STATIC_STRINGS);
   GIMP_CONFIG_INSTALL_PROP_BOOLEAN (object_class, PROP_SHOW_TOOLTIPS,
                                     "show-tooltips", SHOW_TOOLTIPS_BLURB,
                                     TRUE,
@@ -266,7 +262,12 @@
                                     GIMP_CONFIG_PARAM_IGNORE);
   GIMP_CONFIG_INSTALL_PROP_BOOLEAN (object_class, PROP_SHOW_TOOL_TIPS,
                                     "show-tool-tips", NULL,
-                                    TRUE,
+                                    FALSE,
+                                    GIMP_PARAM_STATIC_STRINGS |
+                                    GIMP_CONFIG_PARAM_IGNORE);
+  GIMP_CONFIG_INSTALL_PROP_BOOLEAN (object_class, PROP_SHOW_TIPS,
+                                    "show-tips", NULL,
+                                    FALSE,
                                     GIMP_PARAM_STATIC_STRINGS |
                                     GIMP_CONFIG_PARAM_IGNORE);
 }
@@ -320,9 +321,6 @@
     case PROP_SAVE_TOOL_OPTIONS:
       gui_config->save_tool_options = g_value_get_boolean (value);
       break;
-    case PROP_SHOW_TIPS:
-      gui_config->show_tips = g_value_get_boolean (value);
-      break;
     case PROP_SHOW_TOOLTIPS:
       gui_config->show_tooltips = g_value_get_boolean (value);
       break;
@@ -396,6 +394,7 @@
 
     case PROP_INFO_WINDOW_PER_DISPLAY:
     case PROP_SHOW_TOOL_TIPS:
+    case PROP_SHOW_TIPS:
       /* ignored */
       break;
 
@@ -436,9 +435,6 @@
     case PROP_SAVE_TOOL_OPTIONS:
       g_value_set_boolean (value, gui_config->save_tool_options);
       break;
-    case PROP_SHOW_TIPS:
-      g_value_set_boolean (value, gui_config->show_tips);
-      break;
     case PROP_SHOW_TOOLTIPS:
       g_value_set_boolean (value, gui_config->show_tooltips);
       break;
@@ -508,6 +504,7 @@
 
     case PROP_INFO_WINDOW_PER_DISPLAY:
     case PROP_SHOW_TOOL_TIPS:
+    case PROP_SHOW_TIPS:
       /* ignored */
       break;
 

Modified: trunk/app/config/gimpguiconfig.h
==============================================================================
--- trunk/app/config/gimpguiconfig.h	(original)
+++ trunk/app/config/gimpguiconfig.h	Thu Mar 27 19:42:22 2008
@@ -47,7 +47,6 @@
   gboolean             save_session_info;
   gboolean             restore_session;
   gboolean             save_tool_options;
-  gboolean             show_tips;
   gboolean             show_tooltips;
   gboolean             tearoff_menus;
   gboolean             can_change_accels;

Modified: trunk/app/dialogs/tips-dialog.c
==============================================================================
--- trunk/app/dialogs/tips-dialog.c	(original)
+++ trunk/app/dialogs/tips-dialog.c	Thu Mar 27 19:42:22 2008
@@ -141,15 +141,6 @@
                         gtk_image_new_from_stock (GTK_STOCK_GO_FORWARD,
                                                   GTK_ICON_SIZE_BUTTON));
 
-  button = gtk_dialog_add_button (GTK_DIALOG (tips_dialog),
-                                  GTK_STOCK_CLOSE, GTK_RESPONSE_CLOSE);
-
-  gtk_dialog_set_alternative_button_order (GTK_DIALOG (tips_dialog),
-                                           GTK_RESPONSE_CLOSE,
-                                           RESPONSE_PREVIOUS,
-                                           RESPONSE_NEXT,
-                                           -1);
-
   gtk_dialog_set_response_sensitive (GTK_DIALOG (tips_dialog),
                                      RESPONSE_NEXT, tips_count > 1);
   gtk_dialog_set_response_sensitive (GTK_DIALOG (tips_dialog),
@@ -201,11 +192,6 @@
   gtk_box_pack_start (GTK_BOX (vbox2), image, TRUE, FALSE, 0);
   gtk_widget_show (image);
 
-  button = gimp_prop_check_button_new (G_OBJECT (config), "show-tips",
-                                       _("Show tip next time GIMP starts"));
-  gtk_box_pack_start (GTK_BOX (vbox), button, FALSE, FALSE, 0);
-  gtk_widget_show (button);
-
   tips_set_labels (current_tip->data);
 
   return tips_dialog;

Modified: trunk/app/gui/gui.c
==============================================================================
--- trunk/app/gui/gui.c	(original)
+++ trunk/app/gui/gui.c	Thu Mar 27 19:42:22 2008
@@ -254,17 +254,6 @@
   return status_callback;
 }
 
-void
-gui_post_init (Gimp *gimp)
-{
-  g_return_if_fail (GIMP_IS_GIMP (gimp));
-
-  if (GIMP_GUI_CONFIG (gimp->config)->show_tips)
-    gimp_dialog_factory_dialog_new (global_dialog_factory,
-                                    gdk_screen_get_default (),
-                                    "gimp-tips-dialog", -1, TRUE);
-}
-
 
 /*  private functions  */
 

Modified: trunk/app/gui/gui.h
==============================================================================
--- trunk/app/gui/gui.h	(original)
+++ trunk/app/gui/gui.h	Thu Mar 27 19:42:22 2008
@@ -24,8 +24,7 @@
 void               gui_abort     (const gchar    *abort_message);
 
 GimpInitStatusFunc gui_init      (Gimp           *gimp,
-                                  gboolean        no_spash);
-void               gui_post_init (Gimp           *gimp);
+                                  gboolean        no_splash);
 
 
 #endif /* __GUI_H__ */



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