[nautilus-actions: 1/45] BaseWindow: make all dialogs transient for their parent



commit 03ab67bac9271989aab59f552a8cd70b29b34ddb
Author: Pierre Wieser <pwieser trychlos org>
Date:   Thu Jul 16 18:39:30 2009 +0200

    BaseWindow: make all dialogs transient for their parent

 ChangeLog                                 |    9 +++++
 src/nact/base-window.c                    |   37 ++++++++++++++++++++-
 src/nact/base-window.h                    |    3 ++
 src/nact/nact-action-conditions-editor.c  |   23 ++++---------
 src/nact/nact-action-profiles-editor.c    |   20 +++--------
 src/nact/nact-main-window.c               |    2 +-
 src/nact/nact-profile-conditions-editor.c |   51 +++++++++++++++++++++--------
 src/nact/nautilus-actions-config.ui       |   42 +++--------------------
 8 files changed, 103 insertions(+), 84 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 85a3a6a..059a5ad 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,14 @@
 2009-07-16 Pierre Wieser <pwieser trychlos org>
 
+	* src/nact/base-window.c:
+	* src/nact/nact-main-window.c:
+	* src/nact/nact-action-conditions-editor.c:
+	* src/nact/nact-action-profiles-editor.c:
+	* src/nact/nact-profile-conditions-editor.c:
+	Make all dialogs transient for their parent in BaseWindow.
+
+2009-07-16 Pierre Wieser <pwieser trychlos org>
+
 	* src/common/na-action.c:
 	* src/common/na-action.h (na_action_get_new_profile_name):
 	New function.
diff --git a/src/nact/base-window.c b/src/nact/base-window.c
index a512cf7..0952594 100644
--- a/src/nact/base-window.c
+++ b/src/nact/base-window.c
@@ -49,6 +49,7 @@ struct BaseWindowClassPrivate {
  */
 struct BaseWindowPrivate {
 	gboolean         dispose_has_run;
+	BaseWindow      *parent;
 	BaseApplication *application;
 	gchar           *toplevel_name;
 	GtkWindow       *toplevel_dialog;
@@ -58,7 +59,8 @@ struct BaseWindowPrivate {
 /* instance properties
  */
 enum {
-	PROP_WINDOW_APPLICATION = 1,
+	PROP_WINDOW_PARENT = 1,
+	PROP_WINDOW_APPLICATION,
 	PROP_WINDOW_TOPLEVEL_NAME,
 	PROP_WINDOW_TOPLEVEL_DIALOG,
 	PROP_WINDOW_INITIALIZED
@@ -144,6 +146,13 @@ class_init( BaseWindowClass *klass )
 
 	GParamSpec *spec;
 	spec = g_param_spec_pointer(
+			PROP_WINDOW_PARENT_STR,
+			PROP_WINDOW_PARENT_STR,
+			"Parent BaseWindow object pointer",
+			G_PARAM_STATIC_STRINGS | G_PARAM_READWRITE );
+	g_object_class_install_property( object_class, PROP_WINDOW_PARENT, spec );
+
+	spec = g_param_spec_pointer(
 			PROP_WINDOW_APPLICATION_STR,
 			PROP_WINDOW_APPLICATION_STR,
 			"BaseApplication object pointer",
@@ -207,6 +216,10 @@ instance_get_property( GObject *object, guint property_id, GValue *value, GParam
 	BaseWindow *self = BASE_WINDOW( object );
 
 	switch( property_id ){
+		case PROP_WINDOW_PARENT:
+			g_value_set_pointer( value, self->private->parent );
+			break;
+
 		case PROP_WINDOW_APPLICATION:
 			g_value_set_pointer( value, self->private->application );
 			break;
@@ -236,6 +249,10 @@ instance_set_property( GObject *object, guint property_id, const GValue *value,
 	BaseWindow *self = BASE_WINDOW( object );
 
 	switch( property_id ){
+		case PROP_WINDOW_PARENT:
+			self->private->parent = g_value_get_pointer( value );
+			break;
+
 		case PROP_WINDOW_APPLICATION:
 			self->private->application = g_value_get_pointer( value );
 			break;
@@ -485,6 +502,16 @@ do_init_window( BaseWindow *window )
 	if( !window->private->initialized ){
 		g_debug( "%s: window=%p", thisfn, window );
 
+		if( !window->private->application ){
+			g_assert( window->private->parent );
+			g_assert( BASE_IS_WINDOW( window->private->parent ));
+			window->private->application = BASE_APPLICATION( base_window_get_application( window->private->parent ));
+			g_debug( "%s: application=%p", thisfn, window->private->application );
+		}
+
+		g_assert( window->private->application );
+		g_assert( BASE_IS_APPLICATION( window->private->application ));
+
 		gchar *dialog_name = v_get_toplevel_name( window );
 		g_assert( dialog_name && strlen( dialog_name ));
 
@@ -518,6 +545,12 @@ do_runtime_init_toplevel( BaseWindow *window )
 {
 	static const gchar *thisfn = "base_window_do_runtime_init_toplevel";
 	g_debug( "%s: window=%p", thisfn, window );
+
+	if( window->private->parent ){
+		g_assert( BASE_IS_WINDOW( window->private->parent ));
+		GtkWindow *parent_toplevel = base_window_get_toplevel_dialog( BASE_WINDOW( window->private->parent ));
+		gtk_window_set_transient_for( window->private->toplevel_dialog, parent_toplevel );
+	}
 }
 
 static void
@@ -545,7 +578,7 @@ do_run_window( BaseWindow *window )
 
 	if( is_main_window( window )){
 		g_signal_connect( G_OBJECT( this_dialog ), "response", G_CALLBACK( v_dialog_response ), window );
-		g_debug( "%s: starting gtk_main", thisfn );
+		g_debug( "%s: application=%p, starting gtk_main", thisfn, window->private->application );
 		gtk_main();
 
 	} else if( GTK_IS_ASSISTANT( this_dialog )){
diff --git a/src/nact/base-window.h b/src/nact/base-window.h
index 66217b4..e94a996 100644
--- a/src/nact/base-window.h
+++ b/src/nact/base-window.h
@@ -35,6 +35,8 @@
  * BaseWindow class definition.
  *
  * This is a base class which encapsulates a Gtk+ windows.
+ * It works together with the BaseApplication class to run a Gtk+
+ * application.
  */
 
 #include <glib-object.h>
@@ -80,6 +82,7 @@ typedef struct {
 
 /* instance properties
  */
+#define PROP_WINDOW_PARENT_STR				"base-window-parent"
 #define PROP_WINDOW_APPLICATION_STR			"base-window-application"
 #define PROP_WINDOW_TOPLEVEL_NAME_STR		"base-window-toplevel-name"
 #define PROP_WINDOW_TOPLEVEL_DIALOG_STR		"base-window-toplevel-dialog"
diff --git a/src/nact/nact-action-conditions-editor.c b/src/nact/nact-action-conditions-editor.c
index 7e07da3..a5d3b10 100644
--- a/src/nact/nact-action-conditions-editor.c
+++ b/src/nact/nact-action-conditions-editor.c
@@ -36,7 +36,6 @@
 
 #include <common/na-action.h>
 
-#include "nact-application.h"
 #include "nact-action-conditions-editor.h"
 #include "nact-imenu-item.h"
 #include "nact-iconditions.h"
@@ -52,7 +51,6 @@ struct NactActionConditionsEditorClassPrivate {
  */
 struct NactActionConditionsEditorPrivate {
 	gboolean    dispose_has_run;
-	NactWindow *parent;
 	NAAction   *original;
 	NAAction   *edited;
 	gboolean    is_new;
@@ -68,7 +66,7 @@ static void     instance_init( GTypeInstance *instance, gpointer klass );
 static void     instance_dispose( GObject *dialog );
 static void     instance_finalize( GObject *dialog );
 
-static NactActionConditionsEditor *action_conditions_editor_new( BaseApplication *application );
+static NactActionConditionsEditor *action_conditions_editor_new( NactWindow *parent );
 
 static gchar   *do_get_iprefs_window_id( NactWindow *window );
 static gchar   *do_get_dialog_name( BaseWindow *dialog );
@@ -156,11 +154,11 @@ class_init( NactActionConditionsEditorClass *klass )
 	klass->private = g_new0( NactActionConditionsEditorClassPrivate, 1 );
 
 	BaseWindowClass *base_class = BASE_WINDOW_CLASS( klass );
+	base_class->get_toplevel_name = do_get_dialog_name;
 	base_class->initial_load_toplevel = on_initial_load_dialog;
 	base_class->runtime_init_toplevel = on_runtime_init_dialog;
 	base_class->all_widgets_showed = on_all_widgets_showed;
 	base_class->dialog_response = on_dialog_response;
-	base_class->get_toplevel_name = do_get_dialog_name;
 
 	NactWindowClass *nact_class = NACT_WINDOW_CLASS( klass );
 	nact_class->get_iprefs_window_id = do_get_iprefs_window_id;
@@ -250,9 +248,9 @@ instance_finalize( GObject *dialog )
  * toplevel window of the application).
  */
 static NactActionConditionsEditor *
-action_conditions_editor_new( BaseApplication *application )
+action_conditions_editor_new( NactWindow *parent )
 {
-	return( g_object_new( NACT_ACTION_CONDITIONS_EDITOR_TYPE, PROP_WINDOW_APPLICATION_STR, application, NULL ));
+	return( g_object_new( NACT_ACTION_CONDITIONS_EDITOR_TYPE, PROP_WINDOW_PARENT_STR, parent, NULL ));
 }
 
 /**
@@ -272,11 +270,7 @@ nact_action_conditions_editor_run_editor( NactWindow *parent, NAAction *action )
 
 	g_assert( NACT_IS_MAIN_WINDOW( parent ));
 
-	BaseApplication *application = BASE_APPLICATION( base_window_get_application( BASE_WINDOW( parent )));
-	g_assert( NACT_IS_APPLICATION( application ));
-
-	NactActionConditionsEditor *dialog = action_conditions_editor_new( application );
-	dialog->private->parent = parent;
+	NactActionConditionsEditor *dialog = action_conditions_editor_new( parent );
 
 	if( !action ){
 		dialog->private->original = na_action_new_with_profile();
@@ -357,10 +351,6 @@ on_runtime_init_dialog( BaseWindow *dialog )
 	g_assert( NACT_IS_ACTION_CONDITIONS_EDITOR( dialog ));
 	NactActionConditionsEditor *editor = NACT_ACTION_CONDITIONS_EDITOR( dialog );
 
-	GtkWindow *toplevel = base_window_get_toplevel_dialog( dialog );
-	GtkWindow *parent_toplevel = base_window_get_toplevel_dialog( BASE_WINDOW( editor->private->parent ));
-	gtk_window_set_transient_for( toplevel, parent_toplevel );
-
 	setup_dialog_title( editor, FALSE );
 
 	nact_imenu_item_runtime_init( NACT_WINDOW( editor ), editor->private->edited );
@@ -497,7 +487,8 @@ on_dialog_response( GtkDialog *dialog, gint code, BaseWindow *window )
 					editor->private->original = na_action_duplicate( editor->private->edited );
 					editor->private->is_new = FALSE;
 					on_modified_field( NACT_WINDOW( editor ));
-					nact_window_set_current_action( editor->private->parent, editor->private->original );
+					/* TODO : set current action in parent */
+					/*nact_window_set_current_action( editor->private->parent, editor->private->original );*/
 				}
 			}
 			break;
diff --git a/src/nact/nact-action-profiles-editor.c b/src/nact/nact-action-profiles-editor.c
index c2f2ca8..18f1274 100644
--- a/src/nact/nact-action-profiles-editor.c
+++ b/src/nact/nact-action-profiles-editor.c
@@ -37,7 +37,6 @@
 #include <common/na-action.h>
 #include <common/na-action-profile.h>
 
-#include "nact-application.h"
 #include "nact-action-profiles-editor.h"
 #include "nact-profile-conditions-editor.h"
 #include "nact-imenu-item.h"
@@ -52,7 +51,6 @@ struct NactActionProfilesEditorClassPrivate {
  */
 struct NactActionProfilesEditorPrivate {
 	gboolean    dispose_has_run;
-	NactWindow *parent;
 	NAAction   *original;
 	NAAction   *edited;
 	gboolean    is_new;
@@ -68,7 +66,7 @@ static void     instance_init( GTypeInstance *instance, gpointer klass );
 static void     instance_dispose( GObject *dialog );
 static void     instance_finalize( GObject *dialog );
 
-static NactActionProfilesEditor *action_profiles_editor_new( BaseApplication *application );
+static NactActionProfilesEditor *action_profiles_editor_new( NactWindow *parent );
 
 static gchar   *do_get_iprefs_window_id( NactWindow *window );
 static gchar   *do_get_dialog_name( BaseWindow *dialog );
@@ -164,11 +162,11 @@ class_init( NactActionProfilesEditorClass *klass )
 	klass->private = g_new0( NactActionProfilesEditorClassPrivate, 1 );
 
 	BaseWindowClass *base_class = BASE_WINDOW_CLASS( klass );
+	base_class->get_toplevel_name = do_get_dialog_name;
 	base_class->initial_load_toplevel = on_initial_load_dialog;
 	base_class->runtime_init_toplevel = on_runtime_init_dialog;
 	base_class->all_widgets_showed = on_all_widgets_showed;
 	base_class->dialog_response = on_dialog_response;
-	base_class->get_toplevel_name = do_get_dialog_name;
 
 	NactWindowClass *nact_class = NACT_WINDOW_CLASS( klass );
 	nact_class->get_iprefs_window_id = do_get_iprefs_window_id;
@@ -259,9 +257,9 @@ instance_finalize( GObject *dialog )
  * toplevel window of the application).
  */
 static NactActionProfilesEditor *
-action_profiles_editor_new( BaseApplication *application )
+action_profiles_editor_new( NactWindow *parent )
 {
-	return( g_object_new( NACT_ACTION_PROFILES_EDITOR_TYPE, PROP_WINDOW_APPLICATION_STR, application, NULL ));
+	return( g_object_new( NACT_ACTION_PROFILES_EDITOR_TYPE, PROP_WINDOW_PARENT_STR, parent, NULL ));
 }
 
 /**
@@ -279,11 +277,7 @@ action_profiles_editor_new( BaseApplication *application )
 void
 nact_action_profiles_editor_run_editor( NactWindow *parent, gpointer user_data )
 {
-	BaseApplication *application = BASE_APPLICATION( base_window_get_application( BASE_WINDOW( parent )));
-	g_assert( NACT_IS_APPLICATION( application ));
-
-	NactActionProfilesEditor *dialog = action_profiles_editor_new( application );
-	dialog->private->parent = parent;
+	NactActionProfilesEditor *dialog = action_profiles_editor_new( parent );
 
 	g_assert( NA_IS_ACTION( user_data ));
 	NAAction *action = NA_ACTION( user_data );
@@ -343,10 +337,6 @@ on_runtime_init_dialog( BaseWindow *dialog )
 	g_assert( NACT_IS_ACTION_PROFILES_EDITOR( dialog ));
 	NactActionProfilesEditor *editor = NACT_ACTION_PROFILES_EDITOR( dialog );
 
-	GtkWindow *toplevel = base_window_get_toplevel_dialog( dialog );
-	GtkWindow *parent_toplevel = base_window_get_toplevel_dialog( BASE_WINDOW( editor->private->parent ));
-	gtk_window_set_transient_for( toplevel, parent_toplevel );
-
 	setup_dialog_title( editor, FALSE );
 
 	nact_imenu_item_runtime_init( NACT_WINDOW( editor ), editor->private->edited );
diff --git a/src/nact/nact-main-window.c b/src/nact/nact-main-window.c
index e9b9059..c24a1b9 100644
--- a/src/nact/nact-main-window.c
+++ b/src/nact/nact-main-window.c
@@ -171,10 +171,10 @@ class_init( NactMainWindowClass *klass )
 	klass->private = g_new0( NactMainWindowClassPrivate, 1 );
 
 	BaseWindowClass *base_class = BASE_WINDOW_CLASS( klass );
+	base_class->get_toplevel_name = get_toplevel_name;
 	base_class->initial_load_toplevel = on_initial_load_toplevel;
 	base_class->runtime_init_toplevel = on_runtime_init_toplevel;
 	base_class->dialog_response = on_dialog_response;
-	base_class->get_toplevel_name = get_toplevel_name;
 
 	NactWindowClass *nact_class = NACT_WINDOW_CLASS( klass );
 	nact_class->get_iprefs_window_id = get_iprefs_window_id;
diff --git a/src/nact/nact-profile-conditions-editor.c b/src/nact/nact-profile-conditions-editor.c
index f581c70..cc74067 100644
--- a/src/nact/nact-profile-conditions-editor.c
+++ b/src/nact/nact-profile-conditions-editor.c
@@ -37,7 +37,6 @@
 #include <common/na-action.h>
 #include <common/na-action-profile.h>
 
-#include "nact-application.h"
 #include "nact-profile-conditions-editor.h"
 #include "nact-iprofile-item.h"
 #include "nact-iconditions.h"
@@ -51,7 +50,6 @@ struct NactProfileConditionsEditorClassPrivate {
  */
 struct NactProfileConditionsEditorPrivate {
 	gboolean         dispose_has_run;
-	NactWindow      *parent;
 	NAAction        *original_action;
 	NAActionProfile *original_profile;
 	gboolean         saved;
@@ -70,12 +68,13 @@ static void     instance_init( GTypeInstance *instance, gpointer klass );
 static void     instance_dispose( GObject *dialog );
 static void     instance_finalize( GObject *dialog );
 
-static NactProfileConditionsEditor *profile_conditions_editor_new( BaseApplication *application );
+static NactProfileConditionsEditor *profile_conditions_editor_new( NactWindow *parent );
 
 static gchar   *do_get_iprefs_window_id( NactWindow *window );
 static gchar   *do_get_dialog_name( BaseWindow *dialog );
 static void     on_initial_load_dialog( BaseWindow *dialog );
 static void     on_runtime_init_dialog( BaseWindow *dialog );
+static void     on_all_widgets_showed( BaseWindow *dialog );
 static void     setup_dialog_title( NactProfileConditionsEditor *dialog, gboolean is_modified );
 static void     setup_buttons( NactProfileConditionsEditor *dialog, gboolean can_save );
 static void     on_modified_field( NactWindow *dialog );
@@ -156,6 +155,7 @@ class_init( NactProfileConditionsEditorClass *klass )
 	base_class->get_toplevel_name = do_get_dialog_name;
 	base_class->initial_load_toplevel = on_initial_load_dialog;
 	base_class->runtime_init_toplevel = on_runtime_init_dialog;
+	base_class->all_widgets_showed = on_all_widgets_showed;
 	base_class->dialog_response = on_dialog_response;
 
 	NactWindowClass *nact_class = NACT_WINDOW_CLASS( klass );
@@ -241,9 +241,9 @@ instance_finalize( GObject *dialog )
  * toplevel window of the application).
  */
 static NactProfileConditionsEditor *
-profile_conditions_editor_new( BaseApplication *application )
+profile_conditions_editor_new( NactWindow *parent )
 {
-	return( g_object_new( NACT_PROFILE_CONDITIONS_EDITOR_TYPE, PROP_WINDOW_APPLICATION_STR, application, NULL ));
+	return( g_object_new( NACT_PROFILE_CONDITIONS_EDITOR_TYPE, PROP_WINDOW_PARENT_STR, parent, NULL ));
 }
 
 /**
@@ -262,11 +262,7 @@ profile_conditions_editor_new( BaseApplication *application )
 NAAction *
 nact_profile_conditions_editor_run_editor( NactWindow *parent, NAAction *action, NAActionProfile *profile )
 {
-	BaseApplication *application = BASE_APPLICATION( base_window_get_application( BASE_WINDOW( parent )));
-	g_assert( NACT_IS_APPLICATION( application ));
-
-	NactProfileConditionsEditor *editor = profile_conditions_editor_new( application );
-	editor->private->parent = parent;
+	NactProfileConditionsEditor *editor = profile_conditions_editor_new( parent );
 
 	g_assert( action );
 	g_assert( NA_IS_ACTION( action ));
@@ -314,6 +310,12 @@ static void
 on_initial_load_dialog( BaseWindow *dialog )
 {
 	static const gchar *thisfn = "nact_profile_conditions_editor_on_initial_load_dialog";
+
+	/* call parent class at the very beginning */
+	if( BASE_WINDOW_CLASS( st_parent_class )->initial_load_toplevel ){
+		BASE_WINDOW_CLASS( st_parent_class )->initial_load_toplevel( dialog );
+	}
+
 	g_debug( "%s: dialog=%p", thisfn, dialog );
 
 	g_assert( NACT_IS_PROFILE_CONDITIONS_EDITOR( dialog ));
@@ -327,15 +329,17 @@ static void
 on_runtime_init_dialog( BaseWindow *dialog )
 {
 	static const gchar *thisfn = "nact_profile_conditions_editor_on_runtime_init_dialog";
+
+	/* call parent class at the very beginning */
+	if( BASE_WINDOW_CLASS( st_parent_class )->runtime_init_toplevel ){
+		BASE_WINDOW_CLASS( st_parent_class )->runtime_init_toplevel( dialog );
+	}
+
 	g_debug( "%s: dialog=%p", thisfn, dialog );
 
 	g_assert( NACT_IS_PROFILE_CONDITIONS_EDITOR( dialog ));
 	NactProfileConditionsEditor *editor = NACT_PROFILE_CONDITIONS_EDITOR( dialog );
 
-	GtkWindow *toplevel = base_window_get_toplevel_dialog( dialog );
-	GtkWindow *parent_toplevel = base_window_get_toplevel_dialog( BASE_WINDOW( editor->private->parent ));
-	gtk_window_set_transient_for( toplevel, parent_toplevel );
-
 	setup_dialog_title( editor, FALSE );
 
 	nact_iprofile_item_runtime_init( NACT_WINDOW( editor ), editor->private->edited_profile );
@@ -343,6 +347,25 @@ on_runtime_init_dialog( BaseWindow *dialog )
 }
 
 static void
+on_all_widgets_showed( BaseWindow *dialog )
+{
+	static const gchar *thisfn = "nact_profile_conditions_editor_on_all_widgets_showed";
+
+	/* call parent class at the very beginning */
+	if( BASE_WINDOW_CLASS( st_parent_class )->all_widgets_showed ){
+		BASE_WINDOW_CLASS( st_parent_class )->all_widgets_showed( dialog );
+	}
+
+	g_debug( "%s: dialog=%p", thisfn, dialog );
+
+	GtkNotebook *notebook = GTK_NOTEBOOK( base_window_get_widget( dialog, "Notebook" ));
+	gtk_notebook_set_current_page( notebook, 0 );
+
+	nact_iprofile_item_all_widgets_showed( NACT_WINDOW( dialog ));
+	nact_iconditions_all_widgets_showed( NACT_WINDOW( dialog ));
+}
+
+static void
 setup_dialog_title( NactProfileConditionsEditor *editor, gboolean is_modified )
 {
 	gchar *title;
diff --git a/src/nact/nautilus-actions-config.ui b/src/nact/nautilus-actions-config.ui
index 2ed9214..bd5de49 100644
--- a/src/nact/nautilus-actions-config.ui
+++ b/src/nact/nautilus-actions-config.ui
@@ -4,9 +4,6 @@
   <!-- interface-naming-policy toplevel-contextual -->
   <object class="GtkDialog" id="ActionsDialog">
     <property name="title" translatable="yes">Nautilus Actions</property>
-    <property name="window_position">center</property>
-    <property name="default_width">300</property>
-    <property name="default_height">350</property>
     <property name="type_hint">dialog</property>
     <child internal-child="vbox">
       <object class="GtkVBox" id="dialog-vbox3">
@@ -1415,19 +1412,7 @@ file(s)/folder(s)</property>
             <property name="visible">True</property>
             <property name="layout_style">end</property>
             <child>
-              <object class="GtkButton" id="CancelButton">
-                <property name="label">gtk-cancel</property>
-                <property name="visible">True</property>
-                <property name="can_focus">True</property>
-                <property name="can_default">True</property>
-                <property name="receives_default">False</property>
-                <property name="use_stock">True</property>
-              </object>
-              <packing>
-                <property name="expand">False</property>
-                <property name="fill">False</property>
-                <property name="position">0</property>
-              </packing>
+              <placeholder/>
             </child>
             <child>
               <object class="GtkButton" id="SaveButton">
@@ -1454,17 +1439,15 @@ file(s)/folder(s)</property>
       </object>
     </child>
     <action-widgets>
-      <action-widget response="-6">CancelButton</action-widget>
       <action-widget response="-5">SaveButton</action-widget>
     </action-widgets>
   </object>
   <object class="GtkDialog" id="ProfileConditionsDialog">
     <property name="border_width">5</property>
     <property name="modal">True</property>
-    <property name="type_hint">normal</property>
-    <property name="has_separator">False</property>
+    <property name="type_hint">dialog</property>
     <child internal-child="vbox">
-      <object class="GtkVBox" id="dialog-vbox4">
+      <object class="GtkVBox" id="dialog-vbox1">
         <property name="visible">True</property>
         <property name="orientation">vertical</property>
         <property name="spacing">2</property>
@@ -2010,19 +1993,7 @@ file(s)/folder(s)</property>
             <property name="visible">True</property>
             <property name="layout_style">end</property>
             <child>
-              <object class="GtkButton" id="CancelButton">
-                <property name="label">gtk-cancel</property>
-                <property name="visible">True</property>
-                <property name="can_focus">True</property>
-                <property name="can_default">True</property>
-                <property name="receives_default">True</property>
-                <property name="use_stock">True</property>
-              </object>
-              <packing>
-                <property name="expand">False</property>
-                <property name="fill">False</property>
-                <property name="position">0</property>
-              </packing>
+              <placeholder/>
             </child>
             <child>
               <object class="GtkButton" id="OKButton">
@@ -2049,7 +2020,6 @@ file(s)/folder(s)</property>
       </object>
     </child>
     <action-widgets>
-      <action-widget response="-6">CancelButton</action-widget>
       <action-widget response="-5">OKButton</action-widget>
     </action-widgets>
   </object>
@@ -2117,8 +2087,8 @@ to extend a selection.</property>
             <property name="visible">True</property>
             <property name="orientation">vertical</property>
             <property name="use_preview_label">False</property>
-            <property name="action">select-folder</property>
             <property name="local_only">False</property>
+            <property name="action">select-folder</property>
             <property name="preview_widget_active">False</property>
           </object>
           <packing>
@@ -2169,8 +2139,8 @@ to extend a selection.</property>
         <property name="visible">True</property>
         <property name="orientation">vertical</property>
         <property name="use_preview_label">False</property>
-        <property name="select_multiple">True</property>
         <property name="local_only">False</property>
+        <property name="select_multiple">True</property>
         <property name="preview_widget_active">False</property>
       </object>
     </child>



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