[eog/gnome-3-4] EogWindow: Make check for initialized a check for not initializing
- From: Felix Riemann <friemann src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [eog/gnome-3-4] EogWindow: Make check for initialized a check for not initializing
- Date: Thu, 7 Jun 2012 17:32:33 +0000 (UTC)
commit a02fe91bbc8d7bb4c4f2945ac577481ee3d0bba7
Author: Felix Riemann <friemann gnome org>
Date: Thu Jun 7 13:33:26 2012 +0200
EogWindow: Make check for initialized a check for not initializing
This allows reusing existing empty windows which got broken in
in the fix for bug 677200 (commit 535d42f6).
src/eog-application.c | 3 ++-
src/eog-window.c | 4 ++--
src/eog-window.h | 2 +-
3 files changed, 5 insertions(+), 4 deletions(-)
---
diff --git a/src/eog-application.c b/src/eog-application.c
index dcef875..df57436 100644
--- a/src/eog-application.c
+++ b/src/eog-application.c
@@ -217,7 +217,8 @@ eog_application_get_empty_window (EogApplication *application)
EogWindow *window = EOG_WINDOW (l->data);
/* Make sure the window is empty and not initializing */
- if (eog_window_is_empty (window) && eog_window_was_initialized (window)) {
+ if (eog_window_is_empty (window) &&
+ eog_window_is_not_initializing (window)) {
empty_window = window;
break;
}
diff --git a/src/eog-window.c b/src/eog-window.c
index 58f572e..b9fe113 100644
--- a/src/eog-window.c
+++ b/src/eog-window.c
@@ -5702,9 +5702,9 @@ eog_window_reload_image (EogWindow *window)
}
gboolean
-eog_window_was_initialized (const EogWindow *window)
+eog_window_is_not_initializing (const EogWindow *window)
{
g_return_val_if_fail (EOG_IS_WINDOW (window), FALSE);
- return window->priv->status == EOG_WINDOW_STATUS_NORMAL;
+ return window->priv->status != EOG_WINDOW_STATUS_INIT;
}
diff --git a/src/eog-window.h b/src/eog-window.h
index b4c3a05..679a14d 100644
--- a/src/eog-window.h
+++ b/src/eog-window.h
@@ -124,7 +124,7 @@ void eog_window_open_file_list (EogWindow *window,
GSList *file_list);
gboolean eog_window_is_empty (EogWindow *window);
-gboolean eog_window_was_initialized (const EogWindow *window);
+gboolean eog_window_is_not_initializing (const EogWindow *window);
void eog_window_reload_image (EogWindow *window);
EogDialog *eog_window_get_properties_dialog (EogWindow *window);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]