After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 72212 - View as Other dialog is modal and should not be
View as Other dialog is modal and should not be
Status: RESOLVED FIXED
Product: nautilus
Classification: Core
Component: general
0.x.x [obsolete]
Other other
: Normal minor
: 1.1.x
Assigned To: Nautilus Maintainers
Nautilus Maintainers
Depends on:
Blocks:
 
 
Reported: 2002-02-22 03:42 UTC by Josh Barrow [No longer recieving mail]
Modified: 2004-12-22 21:47 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Fixes the modal behavior in "Open with ... Other application" dialog (2.10 KB, patch)
2002-05-13 06:06 UTC, Juan Salaverria
none Details | Review
Patch to fix the modal behavior in the "Open with ... Other viewer" dialog (4.46 KB, patch)
2002-05-24 12:34 UTC, Juan Salaverria
none Details | Review
Corrected patch to fix the modal behavior in "Open with ... Other Application" dialog (2.39 KB, patch)
2002-05-30 04:42 UTC, Juan Salaverria
needs-work Details | Review

Description Josh Barrow [No longer recieving mail] 2002-02-22 03:42:25 UTC
1) Start Nautilus
2) Right click on any document or folder
3) Select Open with -> Other application
4) Once the dialog is up, try clicking on the original Nautilus window.  

Note that you can't do anything in the original window.

The dialog is modal.  Seth says that this is bad.  I agree.

Josh
Comment 1 Juan Salaverria 2002-05-13 06:06:15 UTC
Created attachment 8417 [details] [review]
Fixes the modal behavior in "Open with ... Other application" dialog
Comment 2 Juan Salaverria 2002-05-24 12:34:24 UTC
Created attachment 8708 [details] [review]
Patch to fix the modal behavior in the "Open with ... Other viewer" dialog
Comment 3 Alexander Larsson 2002-05-26 01:13:38 UTC
About the first patch:

Wrong indentation here:
+GnomeVFSMimeApplication *application;

The patch breaks the second case
(nautilus_mime_has_any_applications_for_file_type returns false).

It also gives ownership problems due to the fact that the callback is
called later. All callers must be changed to ref the callback data and
unref it in the callback handler. The callback function must also
handle the fact that stuff it uses may have been destroyed at that point.
Comment 4 Alexander Larsson 2002-05-26 01:45:44 UTC
Second patch:

        data_a = a;
-
data_b = a;
+
data_b = b

Good catch! I'm committing that part.

It has the same problems as the first one.

There is also a problem with the hashtable part.
If there is already a dialog open for the parent yo can't just return.
   If you don't call the callback you will leak.
It also only removes the parent from the hash table in the no
components case.
Also, i'm not sure the hash table is right at all. Why only let the
user have one dialog? they may be for different files/types? Of
course, it may be interesting if they are for the same file...

Basically, i think both these patches are to risky to target for gnome
2.0. They could destabilize things.
Comment 5 Juan Salaverria 2002-05-30 04:42:18 UTC
Created attachment 8839 [details] [review]
Corrected patch to fix the modal behavior in "Open with ... Other Application" dialog
Comment 6 Juan Salaverria 2002-05-30 05:25:19 UTC
Thanks for review both patches ... I've attached the corrected 
first patch, now it takes care of the second case. 
As far as I saw, the data used by the callback function is 
created in the callers, and is destroyed by each callback function 
when is no longer needed. There are some data used in other places
that is ref/unref properly inside the callers and the callbacks.
I was trying to find out any leaks or potentially problems in this 
patch, unsuccessfully. Please if anyone finds something wrong 
and point me what to tweak, that would be great.

Comment 7 John Fleck 2002-09-17 13:23:37 UTC
This is fixed. The dialog's no longer modal. Closing.
Comment 8 John Fleck 2002-09-23 12:14:12 UTC
Reopening based on comments from Juan in an email:

"I have installed the 2.0.7 version and the problem still happens."

Juan, I can't duplicate the bug on 2.0.6, which is why I closed it.
Comment 9 Dave Camp 2002-10-20 20:36:33 UTC
This patch doesn't change the Open With->Other component dialog. 
Should that be nonmodal too?  That is a bit more tricky, because a
user might move on to viewing something else with the nautilus window
that the dialog is controlling.

Also, some of the comments in these functions need to be updated.
Comment 10 Kjartan Maraas 2003-10-28 00:08:46 UTC
This is still not fixed in 2.4.x
Comment 11 Dave Camp 2004-04-12 19:48:39 UTC
Comment on attachment 8839 [details] [review]
Corrected patch to fix the modal behavior in "Open with ... Other Application" dialog

marking needs-work as per the comments earlier
Comment 12 Matthew Gatto 2004-10-29 02:13:44 UTC
This dialog is gone in 2.8, so closing.