Xfce Forum

Sub domains
 

You are not logged in.

#1 2016-07-02 10:14:11

firmgently
Member
Registered: 2016-07-02
Posts: 6

Default application changes every time I use 'open with'

Debian / XFCE / Thunar

Hi, newb here so sorry if I do something wrong! I have spent some time Googling about this and not managed to find anything.

I set a default, to for example always open jpgs in Ristretto Image Viewer. This is what I usually want to open jpegs with.

Occasionally I want to open a jpg with something else, so I do for example right-click > open with > Xconvert

After doing this, doubleclicking a jpg will *always* open it in Xconvert. So the default has been changed just because I used 'open with' once.

But I didn't want to change the default, only to open one file, one time in a different program.

Is this a bug? Is there no way to occasionally open a file in a different program without automatically changing the default?

Thanks for any help

Offline

#2 2016-07-03 02:05:45

MountainDewManiac
Member
From: Where Mr. Bankruptcy is Prez
Registered: 2013-03-24
Posts: 1,115

Re: Default application changes every time I use 'open with'

After you right-click on the file and move your mouse cursor over "Open With" to bring up the list of choices, are you simply picking one of the ones that are displayed - or are you left-clicking on "Open With Other Application" at the bottom of the list and then making your choice from the list in the window that appears? If the latter, make sure that you do NOT have an "X" in the box immediately to the left of "Use as default for this kind of file" (at the bottom). If you do, uncheck it.

Regards,
MDM


Mountain Dew Maniac

How to Ask for Help <=== Click on this link

Offline

#3 2016-07-03 19:48:11

firmgently
Member
Registered: 2016-07-02
Posts: 6

Re: Default application changes every time I use 'open with'

Hi MDM,

Thanks for the suggestion but no that's not the problem. I'm aware of the situation you describe and it's a reasonable thing to point out but no, I'm just picking one of the already-displayed options on the flyout from the right-click menu.

Cheers though!

Offline

#4 2016-07-05 08:32:08

firmgently
Member
Registered: 2016-07-02
Posts: 6

Re: Default application changes every time I use 'open with'

No ideas anybody? Is there a more appropriate place I should be asking this question do you think?

Offline

#5 2016-07-05 12:45:55

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 10,990

Re: Default application changes every time I use 'open with'

Someone has already created a bug report for this issue. You can add your information to that report.


Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki  |  Community | Contribute ---

Offline

#6 2016-07-05 12:51:35

firmgently
Member
Registered: 2016-07-02
Posts: 6

Re: Default application changes every time I use 'open with'

Ah ok thanks I'd not found that in my searching. I'll have a look and see if I have anything useful to add to the report.

Offline

#7 2016-07-05 20:02:13

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 10,990

Re: Default application changes every time I use 'open with'

This is interesting. I've been looking through the Thunar code to see what is happening. If I'm reading this correctly....

The thunar_g_app_info_launch function is what launches the selected menu item/application. Then, down on line #560, we see:

/* if successful, remember the application as last used for the file types */

It then calls the gio function g-app-info-set-as-last-used-for-type which:

Sets the application as the last used application for a given type. This will make the application appear as first in the list returned by g_app_info_get_recommended_for_type(), regardless of the default application for that content type.

...and I wonder whether Thunar somehow assumes that the top entry in this list in the default or somehow, instead of the default, a function call is returning the last used application (which it looks like)?

Someone more familiar with the thunar code will have to review this. The bug report is the place to follow up with this.


Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki  |  Community | Contribute ---

Offline

#8 2016-07-06 07:19:44

firmgently
Member
Registered: 2016-07-02
Posts: 6

Re: Default application changes every time I use 'open with'

Interesting, I also just noticed last night the behaviour *isn't* happening with some file types. I can open a .js or a .php file in Atom via the 'open with' flyout, then afterwards if I doubleclick a .js or .php file it opens in Pluma (the default, which in this case wasn't changed by using 'open with').

WIthout knowing the code, I wonder if there's a last-used-for-type and a proper-default-for-type and if the default isn't set it falls back to last-used-for (obviously not using correct member names but hopefully the gist is clear enough).

I did create a bugzilla account yesterday but then realised my info would have just been repeating what the existing bug report already said. Maybe this new info will be useful though.

Last edited by firmgently (2016-07-06 08:53:55)

Offline

#9 2016-07-06 08:52:53

firmgently
Member
Registered: 2016-07-02
Posts: 6

Re: Default application changes every time I use 'open with'

Ok I just went and specifically set .jpg to open in Ristretto in MIME Type Editor. Now I can use 'open with' in XnConvert, close it, doubleclick a .jpg and it opens in Ristretto.

So the 'fix' for this is to specifically set a default in MIME Type Editor. Presumably this means this behaviour is by-design (but I'd also humbly offer that it isn't very clear to the user). It also sounds like the fallback idea mentioned above might be what's happening.

(I'll copy this info into the bug report)

Last edited by firmgently (2016-07-06 08:53:21)

Offline

Board footer

Powered by FluxBB