summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMaciej Stachowiak <mstachow@src.gnome.org>2000-08-04 23:40:25 +0000
committerMaciej Stachowiak <mstachow@src.gnome.org>2000-08-04 23:40:25 +0000
commit21f0230e0bf06bc170562501e6628fd8b5466769 (patch)
tree5ce36e26908e6c596e6cc49b2672341299cf76bd
parentb1a0eef7a5bf88b16cf9b1bab43761e47e518d59 (diff)
downloadnautilus-21f0230e0bf06bc170562501e6628fd8b5466769.tar.gz
Removes nautilus_view_report_load_complete call from here...
* components/mozilla/nautilus-mozilla-content-view.c (mozilla_load_location_callback): Removes nautilus_view_report_load_complete call from here... (mozilla_progress_callback): And move it here, because we only want to make that call after all the various report_progress calls. This fixes bugs 1933 and 1955. Pavel did most of the heavy lifting of figuring out why this was killing the state machine.
-rw-r--r--ChangeLog10
-rw-r--r--components/mozilla/nautilus-mozilla-content-view.c13
2 files changed, 15 insertions, 8 deletions
diff --git a/ChangeLog b/ChangeLog
index 56f94f7a5..ac04de75a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+2000-08-04 Maciej Stachowiak <mjs@eazel.com>
+
+ * components/mozilla/nautilus-mozilla-content-view.c
+ (mozilla_load_location_callback): Removes
+ nautilus_view_report_load_complete call from here...
+ (mozilla_progress_callback): And move it here, because we only
+ want to make that call after all the various report_progress
+ calls. This fixes bugs 1933 and 1955. Pavel did most of the heavy
+ lifting of figuring out why this was killing the state machine.
+
2000-08-04 Andy Hertzfeld <andy@eazel.com>
* libnautilus-extensions/nautilus-background.c:
diff --git a/components/mozilla/nautilus-mozilla-content-view.c b/components/mozilla/nautilus-mozilla-content-view.c
index 614d6ab41..c45ddd38c 100644
--- a/components/mozilla/nautilus-mozilla-content-view.c
+++ b/components/mozilla/nautilus-mozilla-content-view.c
@@ -273,7 +273,6 @@ mozilla_load_location_callback (NautilusView *nautilus_view,
nautilus_view_report_load_underway (nautilus_view);
nautilus_mozilla_content_view_load_uri (view, location);
- nautilus_view_report_load_complete (nautilus_view);
}
static void
@@ -519,7 +518,6 @@ mozilla_progress_callback (GtkMozEmbed *mozilla,
gpointer user_data)
{
NautilusMozillaContentView *view;
- gdouble fraction;
view = NAUTILUS_MOZILLA_CONTENT_VIEW (user_data);
g_assert (GTK_MOZ_EMBED (mozilla) == GTK_MOZ_EMBED (view->details->mozilla));
@@ -528,14 +526,13 @@ mozilla_progress_callback (GtkMozEmbed *mozilla,
g_print ("mozilla_progress_callback (max = %d, current = %d)\n", max_progress, current_progress);
#endif
- /* The check for 0.0 is just anal paranoia on my part */
- if (max_progress == 0.0) {
- fraction = 1.0;
+
+ if (max_progress == current_progress || max_progress == 0) {
+ nautilus_view_report_load_complete (view->details->nautilus_view);
} else {
- fraction = current_progress / max_progress;
+ nautilus_view_report_load_progress (view->details->nautilus_view,
+ current_progress / max_progress);
}
-
- nautilus_view_report_load_progress (view->details->nautilus_view, fraction);
}
static gint