Index: lib/ephy-state.c
===================================================================
RCS file: /cvs/gnome/epiphany/lib/ephy-state.c,v
retrieving revision 1.6
diff -u -p -r1.6 ephy-state.c
--- lib/ephy-state.c	29 Apr 2003 09:23:05 -0000	1.6
+++ lib/ephy-state.c	30 Apr 2003 06:03:06 -0000
@@ -177,28 +177,36 @@ ephy_state_window_set_position (GtkWidge
 	GdkScreen *screen;
 	int x, y;
 	int screen_width, screen_height;
+	gboolean maximize;
 
 	g_return_if_fail (GTK_IS_WINDOW (window));
 
 	/* Setting the default size doesn't work when the window is already showing. */
 	g_return_if_fail (!GTK_WIDGET_VISIBLE (window));
 
-	x = ephy_node_get_property_int (node, EPHY_NODE_STATE_PROP_POSITION_X);
-	y = ephy_node_get_property_int (node, EPHY_NODE_STATE_PROP_POSITION_Y);
+	maximize = ephy_node_get_property_boolean (node, EPHY_NODE_STATE_PROP_MAXIMIZE);
 
-	screen = gtk_window_get_screen (GTK_WINDOW (window));
-	screen_width  = gdk_screen_get_width  (screen);
-	screen_height = gdk_screen_get_height (screen);
+	/* Don't set the position of the window if it is maximized */	
 
-	if ((x >= screen_width) || (y >= screen_height))
+	if (!maximize)
 	{
-		x = y = WINDOW_POSITION_UNSET;
-	}
+		x = ephy_node_get_property_int (node, EPHY_NODE_STATE_PROP_POSITION_X);
+		y = ephy_node_get_property_int (node, EPHY_NODE_STATE_PROP_POSITION_Y);
 
-	/* If the window has a saved position set it, otherwise let the WM do it */
-	if ((x != WINDOW_POSITION_UNSET) && (y != WINDOW_POSITION_UNSET))
-	{
-		gtk_window_move (GTK_WINDOW (window), x, y);
+		screen = gtk_window_get_screen (GTK_WINDOW (window));
+		screen_width  = gdk_screen_get_width  (screen);
+		screen_height = gdk_screen_get_height (screen);
+
+		if ((x >= screen_width) || (y >= screen_height))
+		{
+			x = y = WINDOW_POSITION_UNSET;
+		}
+
+		/* If the window has a saved position set it, otherwise let the WM do it */
+		if ((x != WINDOW_POSITION_UNSET) && (y != WINDOW_POSITION_UNSET))
+		{
+			gtk_window_move (GTK_WINDOW (window), x, y);
+		}
 	}
 }
 
@@ -243,21 +251,31 @@ static void
 ephy_state_window_save_position (GtkWidget *window, EphyNode *node)
 {
 	int x,y;
+	gboolean maximize;
+	GdkWindowState state;
 	GValue value = { 0, };
+	
+	state = gdk_window_get_state (GTK_WIDGET (window)->window);
+	maximize = ((state & GDK_WINDOW_STATE_MAXIMIZED) > 0);
 
-	gtk_window_get_position (GTK_WINDOW (window), &x, &y);
+	/* Don't save the position if maximized */	
 
-	g_value_init (&value, G_TYPE_INT);
-	g_value_set_int (&value, x);
-	ephy_node_set_property (node, EPHY_NODE_STATE_PROP_POSITION_X,
-			        &value);
-	g_value_unset (&value);
+	if (!maximize)
+	{
+        	gtk_window_get_position (GTK_WINDOW (window), &x, &y);
 
-	g_value_init (&value, G_TYPE_INT);
-	g_value_set_int (&value, y);
-	ephy_node_set_property (node, EPHY_NODE_STATE_PROP_POSITION_Y,
-			        &value);
-	g_value_unset (&value);
+		g_value_init (&value, G_TYPE_INT);
+		g_value_set_int (&value, x);
+		ephy_node_set_property (node, EPHY_NODE_STATE_PROP_POSITION_X,
+				        &value);
+		g_value_unset (&value);
+
+		g_value_init (&value, G_TYPE_INT);
+		g_value_set_int (&value, y);
+		ephy_node_set_property (node, EPHY_NODE_STATE_PROP_POSITION_Y,
+				        &value);
+		g_value_unset (&value);
+	}
 }
 
 static gboolean
Index: src/ephy-history-window.c
===================================================================
RCS file: /cvs/gnome/epiphany/src/ephy-history-window.c,v
retrieving revision 1.13
diff -u -p -r1.13 ephy-history-window.c
--- src/ephy-history-window.c	30 Apr 2003 01:44:40 -0000	1.13
+++ src/ephy-history-window.c	30 Apr 2003 06:03:13 -0000
@@ -860,7 +860,6 @@ ephy_history_window_construct (EphyHisto
 					"vadjustment", NULL,
 					"hscrollbar_policy", GTK_POLICY_AUTOMATIC,
 					"vscrollbar_policy", GTK_POLICY_AUTOMATIC,
-					"shadow_type", GTK_SHADOW_IN,
 					NULL);
 	gtk_paned_add1 (GTK_PANED (hpaned), scrolled_window);
 	gtk_widget_show (scrolled_window);
@@ -895,14 +894,12 @@ ephy_history_window_construct (EphyHisto
 			    build_search_box (editor),
 			    FALSE, FALSE, 0);
 
-
 	/* Pages View */
 	scrolled_window = g_object_new (GTK_TYPE_SCROLLED_WINDOW,
 					"hadjustment", NULL,
 					"vadjustment", NULL,
 					"hscrollbar_policy", GTK_POLICY_AUTOMATIC,
 					"vscrollbar_policy", GTK_POLICY_AUTOMATIC,
-					"shadow_type", GTK_SHADOW_IN,
 					NULL);
 	gtk_box_pack_start (GTK_BOX (vbox), scrolled_window, TRUE, TRUE, 0);
 	gtk_widget_show (scrolled_window);
Index: src/bookmarks/ephy-bookmarks-editor.c
===================================================================
RCS file: /cvs/gnome/epiphany/src/bookmarks/ephy-bookmarks-editor.c,v
retrieving revision 1.70
diff -u -p -r1.70 ephy-bookmarks-editor.c
--- src/bookmarks/ephy-bookmarks-editor.c	30 Apr 2003 01:44:41 -0000	1.70
+++ src/bookmarks/ephy-bookmarks-editor.c	30 Apr 2003 06:03:21 -0000
@@ -1163,7 +1163,6 @@ ephy_bookmarks_editor_construct (EphyBoo
 					"vadjustment", NULL,
 					"hscrollbar_policy", GTK_POLICY_AUTOMATIC,
 					"vscrollbar_policy", GTK_POLICY_AUTOMATIC,
-					"shadow_type", GTK_SHADOW_IN,
 					NULL);
 	gtk_paned_pack1 (GTK_PANED (hpaned), GTK_WIDGET (scrolled_window), TRUE, TRUE);
 	gtk_widget_show (scrolled_window);
@@ -1225,7 +1224,6 @@ ephy_bookmarks_editor_construct (EphyBoo
 					"vadjustment", NULL,
 					"hscrollbar_policy", GTK_POLICY_AUTOMATIC,
 					"vscrollbar_policy", GTK_POLICY_AUTOMATIC,
-					"shadow_type", GTK_SHADOW_IN,
 					NULL);
 	gtk_box_pack_start (GTK_BOX (vbox), scrolled_window, TRUE, TRUE, 0);
 	gtk_widget_show (scrolled_window);
