LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (http://www.linuxquestions.org/questions/linux-software-2/)
-   -   Nautilus Annoying Warning box (http://www.linuxquestions.org/questions/linux-software-2/nautilus-annoying-warning-box-365345/)

madiyaan 09-20-2005 03:52 PM

Nautilus Annoying Warning box
 
I have a few CD's that have *.wmv files. I have installed mplayer and the corresponding wmv9 codecs on my Fedora Core 4 box to play those files. When I right click on that file using nautilus and click on Open with Gmplayer, it works fine. However, when I double click the file I get a large warning dialog box with only one option (cancel). The dialog box reads:

[BEGIN DIALOG BOX]

Cannot open ABC.wmv

The filename "ABC.wmv" indicates that this file is of type "Microsoft WMV Video". The contents of the file indicate that the file is of type "Microsoft ASF video". If you open this file, the file might present a security risk to your system.

Do not open the file unless you created the file yourself, or recieved the file from a trusted source. To open the file, rename the file to the correct extension for "Microsoft ASF video", then open the file normally. Alternatively, use the Open With menu to choose a specific application for the file.

[END DIALOG BOX]

This is highly annoying since I can't rename the file (it's on a CD) and I have to go through right clicking and opening every time I want to see the video. Does anyone know how to fix this?

Keywords: mimetype, wmv, asf, nautilus

Thanks,
Madiyaan

jamesnine 09-29-2005 09:03 AM

Here is a solution that worked for me (I am using Fedora Core 4):

Using terminal:
1) log in as root
2) cd /usr/share/mime/packages
3) edit (I use vi) the file "freedesktop.org.xml"
4) look for the following line:

<mime-type type="video/x-ms-asf">
<comment>Microsoft ASF video</comment>

5) scroll down a bit to the bottom of that mime-type, look for the following line:

<glob pattern="*.asf"/>
<glob pattern="*.asx"/>
<magic priority="50">

6) after those lines, add: <alias type="video/x-ms-wmv"/>

i.e. it should look like this:

<glob pattern="*.asf"/>
<glob pattern="*.asx"/>
<alias type="video/x-ms-wmv"/>
<magic priority="50">

7) save the file, run the following command at the prompt:

# update-mime-database /usr/share/mime

8) You're done. That should work. I know there are other ways to do this, but this way worked for me.


All times are GMT -5. The time now is 11:00 PM.